Class ServerArgument<C>
- java.lang.Object
-
- cloud.commandframework.arguments.CommandArgument<C,com.velocitypowered.api.proxy.server.RegisteredServer>
-
- cloud.commandframework.velocity.arguments.ServerArgument<C>
-
- Type Parameters:
C- Command sender type
- All Implemented Interfaces:
java.lang.Comparable<cloud.commandframework.arguments.CommandArgument<?,?>>
public final class ServerArgument<C> extends cloud.commandframework.arguments.CommandArgument<C,com.velocitypowered.api.proxy.server.RegisteredServer>Argument parser forservers- Since:
- 1.1.0
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classServerArgument.Builder<C>static classServerArgument.ServerParseExceptionstatic classServerArgument.ServerParser<C>
-
Method Summary
Modifier and Type Method Description static <C> @NonNull cloud.commandframework.arguments.CommandArgument.Builder<C,com.velocitypowered.api.proxy.server.RegisteredServer>newBuilder(@NonNull java.lang.String name)Create a new argument builderstatic <C> @NonNull cloud.commandframework.arguments.CommandArgument<C,com.velocitypowered.api.proxy.server.RegisteredServer>of(@NonNull java.lang.String name)Create a new required player argumentstatic <C> @NonNull cloud.commandframework.arguments.CommandArgument<C,com.velocitypowered.api.proxy.server.RegisteredServer>optional(@NonNull java.lang.String name)Create a new optional server argument-
Methods inherited from class cloud.commandframework.arguments.CommandArgument
addPreprocessor, compareTo, copy, equals, getDefaultValue, getName, getOwningCommand, getParser, getSuggestionsProvider, getValueType, hasDefaultValue, hashCode, isArgumentRegistered, isRequired, ofType, ofType, preprocess, setArgumentRegistered, setOwningCommand, toString
-
-
-
-
Method Detail
-
newBuilder
public static <C> @NonNull cloud.commandframework.arguments.CommandArgument.Builder<C,com.velocitypowered.api.proxy.server.RegisteredServer> newBuilder(@NonNull java.lang.String name)
Create a new argument builder- Type Parameters:
C- Command sender type- Parameters:
name- Argument name- Returns:
- Constructed builder
-
of
public static <C> @NonNull cloud.commandframework.arguments.CommandArgument<C,com.velocitypowered.api.proxy.server.RegisteredServer> of(@NonNull java.lang.String name)
Create a new required player argument- Type Parameters:
C- Command sender type- Parameters:
name- Argument name- Returns:
- Created argument
-
optional
public static <C> @NonNull cloud.commandframework.arguments.CommandArgument<C,com.velocitypowered.api.proxy.server.RegisteredServer> optional(@NonNull java.lang.String name)
Create a new optional server argument- Type Parameters:
C- Command sender type- Parameters:
name- Argument name- Returns:
- Created argument
-
-