Added destructurability to EntityArgParseResult

This commit is contained in:
Auxilor
2022-01-07 09:24:02 +00:00
parent 2fafef17d7
commit bc92f8a444

View File

@@ -13,4 +13,21 @@ import java.util.function.Predicate;
*/
public record EntityArgParseResult(@NotNull Predicate<Entity> test,
@NotNull Consumer<Entity> modifier) {
/**
* Kotlin destructuring support.
*
* @return The test.
*/
public Predicate<Entity> component1() {
return test;
}
/**
* Kotlin destructuring support.
*
* @return The modifier.
*/
public Consumer<Entity> component2() {
return modifier;
}
}