implement main functionality

This commit is contained in:
2025-05-25 03:42:11 +03:00
parent fb3f79e468
commit 21f3d7e6ce
7 changed files with 270 additions and 47 deletions

View File

@ -0,0 +1,20 @@
package ua.com.dxrkness.function;
@FunctionalInterface
public interface Action {
void execute();
default Action andThen(Action after) {
return () -> {
this.execute();
after.execute();
};
}
default Action compose(Action before) {
return () -> {
before.execute();
this.execute();
};
}
}