Package dev.jorel.commandapi.arguments
Class DoubleArgument
java.lang.Object
dev.jorel.commandapi.AbstractArgumentTree<Argument<Double>,Argument<?>,com.velocitypowered.api.command.CommandSource>
dev.jorel.commandapi.arguments.AbstractArgument<Double,Argument<Double>,Argument<?>,com.velocitypowered.api.command.CommandSource>
dev.jorel.commandapi.arguments.Argument<Double>
dev.jorel.commandapi.arguments.SafeOverrideableArgument<Double,Double>
dev.jorel.commandapi.arguments.DoubleArgument
- All Implemented Interfaces:
SafeOverrideable<Double,,Double, Argument<Double>, Argument<?>, com.velocitypowered.api.command.CommandSource> ChainableBuilder<Argument<Double>>,PlatformExecutable<Argument<Double>,,com.velocitypowered.api.command.CommandSource> VelocityExecutable<Argument<Double>>
An argument that represents primitive Java doubles
- API Note:
- Returns a
invalid reference
double
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected CommandAPIExecutor<com.velocitypowered.api.command.CommandSource, AbstractCommandSender<? extends com.velocitypowered.api.command.CommandSource>> -
Constructor Summary
ConstructorsConstructorDescriptionDoubleArgument(String nodeName) A double argumentDoubleArgument(String nodeName, double min) A double argument with a minimum valueDoubleArgument(String nodeName, double min, double max) A double argument with a minimum and maximum value -
Method Summary
Modifier and TypeMethodDescriptionCommandAPIExecutor<com.velocitypowered.api.command.CommandSource, AbstractCommandSender<? extends com.velocitypowered.api.command.CommandSource>> <Source> DoubleparseArgument(com.mojang.brigadier.context.CommandContext<Source> cmdCtx, String key, CommandArguments previousArgs) voidsetExecutor(CommandAPIExecutor<com.velocitypowered.api.command.CommandSource, AbstractCommandSender<? extends com.velocitypowered.api.command.CommandSource>> arg0) Methods inherited from class dev.jorel.commandapi.arguments.SafeOverrideableArgument
getMapperMethods inherited from class dev.jorel.commandapi.arguments.AbstractArgument
combineWith, copyPermissionsAndRequirements, getArgumentPermission, getCombinedArguments, getEntityNames, getHelpString, getIncludedSuggestions, getNodeName, getOverriddenSuggestions, getRawType, getRequirements, hasCombinedArguments, includeSuggestions, isListed, isOptional, replaceSuggestions, setListed, setOptional, toString, withPermission, withPermission, withRequirementMethods inherited from class dev.jorel.commandapi.AbstractArgumentTree
then, thenNested, thenNestedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface dev.jorel.commandapi.ChainableBuilder
instanceMethods inherited from interface dev.jorel.commandapi.PlatformExecutable
getExecutorMethods inherited from interface dev.jorel.commandapi.arguments.SafeOverrideable
includeSafeSuggestions, includeSuggestions, replaceSafeSuggestions, replaceSuggestionsMethods inherited from interface dev.jorel.commandapi.VelocityExecutable
executes, executes, executes, executes, executesConsole, executesConsole, executesConsole, executesConsole, executesPlayer, executesPlayer, executesPlayer, executesPlayer
-
Field Details
-
executor
protected CommandAPIExecutor<com.velocitypowered.api.command.CommandSource,AbstractCommandSender<? extends com.velocitypowered.api.command.CommandSource>> executor
-
-
Constructor Details
-
DoubleArgument
A double argument- Parameters:
nodeName- the name of the node for this argument
-
DoubleArgument
A double argument with a minimum value- Parameters:
nodeName- the name of the node for this argumentmin- The minimum value this argument can take (inclusive)
-
DoubleArgument
A double argument with a minimum and maximum value- Parameters:
nodeName- the name of the node for this argumentmin- The minimum value this argument can take (inclusive)max- The maximum value this argument can take (inclusive)
-
-
Method Details
-
getPrimitiveType
- Specified by:
getPrimitiveTypein classAbstractArgument<Double,Argument<Double>, Argument<?>, com.velocitypowered.api.command.CommandSource>
-
getArgumentType
- Specified by:
getArgumentTypein classAbstractArgument<Double,Argument<Double>, Argument<?>, com.velocitypowered.api.command.CommandSource>
-
parseArgument
public <Source> Double parseArgument(com.mojang.brigadier.context.CommandContext<Source> cmdCtx, String key, CommandArguments previousArgs) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Specified by:
parseArgumentin classAbstractArgument<Double,Argument<Double>, Argument<?>, com.velocitypowered.api.command.CommandSource> - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getExecutor
public CommandAPIExecutor<com.velocitypowered.api.command.CommandSource,AbstractCommandSender<? extends com.velocitypowered.api.command.CommandSource>> getExecutor() -
setExecutor
public void setExecutor(CommandAPIExecutor<com.velocitypowered.api.command.CommandSource, AbstractCommandSender<? extends com.velocitypowered.api.command.CommandSource>> arg0) -
clearExecutors
-