Skip to content

Instantly share code, notes, and snippets.

@turastory
Created March 26, 2018 10:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save turastory/2aa752bda8ea82077cbf4ce4e5c559e8 to your computer and use it in GitHub Desktop.
Save turastory/2aa752bda8ea82077cbf4ce4e5c559e8 to your computer and use it in GitHub Desktop.
Runner, for Runnable chain
public interface Runner {
void run();
default Runner andThen(Runner after) {
return () -> { run(); after.run(); };
}
default Runnable convert() {
return this::run;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment