Skip to content

Instantly share code, notes, and snippets.

@dimitris-papadimitriou-chr
Created November 3, 2020 17:49
Show Gist options
  • Save dimitris-papadimitriou-chr/293e0ec3ae6e00f3f41a7ec348f25008 to your computer and use it in GitHub Desktop.
Save dimitris-papadimitriou-chr/293e0ec3ae6e00f3f41a7ec348f25008 to your computer and use it in GitHub Desktop.
@FunctionalInterface
public interface SupplierFunctor<T> extends Supplier<T> {
default <T1> SupplierFunctor<T1> andThen(Function<T, T1> f) {
return () -> f.apply(this.get());
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment