improved functional interfaces to work with lambda throwing java.lang.Throwable
instances
This commit is contained in:
@@ -12,5 +12,5 @@ public interface BiCon<T, U> extends BiConsumer<T, U> {
|
||||
exec(t, u);
|
||||
}
|
||||
|
||||
void exec(T t, U u) throws Exception;
|
||||
void exec(T t, U u) throws Throwable;
|
||||
}
|
||||
|
@@ -12,5 +12,5 @@ public interface BiFun<T, U, V> extends BiFunction<T, U, V> {
|
||||
return exec(t, u);
|
||||
}
|
||||
|
||||
V exec(T t, U u) throws Exception;
|
||||
V exec(T t, U u) throws Throwable;
|
||||
}
|
||||
|
@@ -12,5 +12,5 @@ public interface Con<T> extends Consumer<T> {
|
||||
exec(t);
|
||||
}
|
||||
|
||||
void exec(T t) throws Exception;
|
||||
void exec(T t) throws Throwable;
|
||||
}
|
||||
|
@@ -12,5 +12,5 @@ public interface Fun<T, U> extends Function<T, U> {
|
||||
return exec(t);
|
||||
}
|
||||
|
||||
U exec(T t) throws Exception;
|
||||
U exec(T t) throws Throwable;
|
||||
}
|
||||
|
@@ -12,5 +12,5 @@ public interface Pre<T> extends Predicate<T> {
|
||||
return exec(t);
|
||||
}
|
||||
|
||||
boolean exec(T t) throws Exception;
|
||||
boolean exec(T t) throws Throwable;
|
||||
}
|
||||
|
@@ -12,5 +12,5 @@ public interface Sup<T> extends Supplier<T> {
|
||||
return exec();
|
||||
}
|
||||
|
||||
T exec() throws Exception;
|
||||
T exec() throws Throwable;
|
||||
}
|
||||
|
Reference in New Issue
Block a user