mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-20 20:20:56 +07:00
18 lines
377 B
Java
18 lines
377 B
Java
|
|
import java.io.IOException;
|
|
|
|
@FunctionalInterface
|
|
interface ThrowableRunnable<E extends Exception> {
|
|
|
|
void get() throws E;
|
|
|
|
static <E extends Exception> void m(ThrowableRunnable<E> supplier, Object... params) throws E {}
|
|
|
|
|
|
default void getContent() {
|
|
try {
|
|
m(() -> { throw new IOException(); });
|
|
} catch (IOException e) { }
|
|
}
|
|
|
|
} |