Class ParameterTypes
java.lang.Object
studio.mevera.imperat.command.parameters.type.ParameterTypes
-
Method Summary
Modifier and TypeMethodDescriptionstatic <S extends Source,E>
ParameterArray<S,E> static <S extends Source>
ParameterBoolean<S>bool()static <S extends Source,E, C extends Collection<E>>
ParameterCollection<S,E, C> collection(TypeWrap<C> type, Supplier<C> collectionSupplier, ParameterType<S, E> componentResolver) static <S extends Source>
@NotNull ParameterCommand<S>static <S extends Source>
ParameterFlag<S>static <S extends Source,T>
ParameterCompletableFuture<S,T> future(TypeWrap<CompletableFuture<T>> typeWrap, ParameterType<S, T> resolverType) static <S extends Source,K, V, M extends Map<K, V>>
ParameterMap<S,K, V, M> map(TypeWrap<M> type, Supplier<M> mapInitializer, ParameterType<S, K> keyResolver, ParameterType<S, V> valueResolver) static <S extends Source,N extends Number>
ParameterNumber<S,N> static <S extends Source,T>
ParameterOptional<S,T> optional(TypeWrap<Optional<T>> typeWrap, ParameterType<S, T> resolverType) static <S extends Source>
ParameterString<S>string()static <S extends Source>
ParameterUUID<S>uuid()
-
Method Details
-
string
-
numeric
-
bool
-
flag
-
command
@NotNull public static <S extends Source> @NotNull ParameterCommand<S> command(String name, List<String> aliases) -
uuid
-
array
public static <S extends Source,E> ParameterArray<S,E> array(TypeWrap<E[]> type, Function<Integer, Object[]> initializer, ParameterType<S, E> componentType) -
collection
public static <S extends Source,E, ParameterCollection<S,C extends Collection<E>> E, collectionC> (TypeWrap<C> type, Supplier<C> collectionSupplier, ParameterType<S, E> componentResolver) -
map
public static <S extends Source,K, ParameterMap<S,V, M extends Map<K, V>> K, mapV, M> (TypeWrap<M> type, Supplier<M> mapInitializer, ParameterType<S, K> keyResolver, ParameterType<S, V> valueResolver) -
future
public static <S extends Source,T> ParameterCompletableFuture<S,T> future(TypeWrap<CompletableFuture<T>> typeWrap, ParameterType<S, T> resolverType) -
optional
public static <S extends Source,T> ParameterOptional<S,T> optional(TypeWrap<Optional<T>> typeWrap, ParameterType<S, T> resolverType)
-