Class SimpleArgument<T>
java.lang.Object
dev.rollczi.litecommands.argument.SimpleArgument<T>
- All Implemented Interfaces:
Argument<T>,MutableArgument<T>,MetaHolder,Requirement<T>
-
Constructor Summary
ConstructorsModifierConstructorDescriptionSimpleArgument(String name, TypeToken<T> type) SimpleArgument(String name, TypeToken<T> type, boolean nullable) protectedSimpleArgument(String name, TypeToken<T> type, @Nullable Argument<?> pattern) -
Method Summary
Modifier and TypeMethodDescription<P extends ArgumentProfile<P>>
SimpleArgument<T> addProfile(P profile) <NEW> Argument<NEW> Create a child of the current argument.booleangetKey()getName()<P> Optional<P> getProfile(ArgumentProfileNamespace<P> key) getType()booleaninthashCode()meta()@Nullable MetaHoldervoidsetKey(ArgumentKey key) withoutProfile(ArgumentProfileNamespace<?> profile) Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface dev.rollczi.litecommands.argument.Argument
defaultValueMethods inherited from interface dev.rollczi.litecommands.meta.MetaHolder
metaCollector
-
Constructor Details
-
SimpleArgument
-
SimpleArgument
-
SimpleArgument
-
-
Method Details
-
getName
-
getKey
-
setKey
- Specified by:
setKeyin interfaceMutableArgument<T>
-
getType
- Specified by:
getTypein interfaceRequirement<T>
-
meta
- Specified by:
metain interfaceMetaHolder
-
parentMeta
- Specified by:
parentMetain interfaceMetaHolder
-
getDefaultValue
- Specified by:
getDefaultValuein interfaceArgument<T>
-
hasDefaultValue
public boolean hasDefaultValue()- Specified by:
hasDefaultValuein interfaceArgument<T>
-
addProfile
- Specified by:
addProfilein interfaceMutableArgument<T>
-
getProfile
- Specified by:
getProfilein interfaceArgument<T>
-
getProfiles
- Specified by:
getProfilesin interfaceArgument<T>
-
child
Description copied from interface:ArgumentCreate a child of the current argument. This is useful when resolver handles a parametrized type for class such as Optional, List, CompletableFuture, etc. -
withoutProfile
- Specified by:
withoutProfilein interfaceArgument<T>
-
equals
-
hashCode
public int hashCode()
-