mirror of
https://github.com/PolyhedralDev/Terra.git
synced 2026-04-11 18:26:08 +00:00
Lazy#of -> Lazy#lazy
This commit is contained in:
@@ -9,7 +9,7 @@ import java.util.Collection;
|
||||
public interface EnumProperty<T extends Enum<T>> extends Property<T> {
|
||||
static <T extends Enum<T>> EnumProperty<T> of(String name, Class<T> clazz) {
|
||||
return new EnumProperty<T>() {
|
||||
private final Lazy<Collection<T>> constants = Lazy.of(() -> Arrays.asList(clazz.getEnumConstants()));
|
||||
private final Lazy<Collection<T>> constants = Lazy.lazy(() -> Arrays.asList(clazz.getEnumConstants()));
|
||||
|
||||
@Override
|
||||
public Class<T> getType() {
|
||||
|
||||
@@ -11,7 +11,7 @@ public final class Lazy<T> {
|
||||
this.valueSupplier = valueSupplier;
|
||||
}
|
||||
|
||||
public static <T> Lazy<T> of(Supplier<T> valueSupplier) {
|
||||
public static <T> Lazy<T> lazy(Supplier<T> valueSupplier) {
|
||||
return new Lazy<>(valueSupplier);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user