Package cloud.commandframework
Class CommandComponent<C>
java.lang.Object
cloud.commandframework.CommandComponent<C>
- Type Parameters:
C
- Command sender type
A single literal or argument component of a command
- Since:
- 1.3.0
-
Method Summary
Modifier and TypeMethodDescriptionboolean
@NonNull CommandArgument<C,?>
Gets the command component argument details@NonNull ArgumentDescription
Gets the command component description@NonNull Description
Deprecated.for removal since 1.4.0.int
hashCode()
static <C> @NonNull CommandComponent<C>
of(@NonNull CommandArgument<C,?> commandArgument, @NonNull ArgumentDescription commandDescription)
Creates a new CommandComponent with the provided argument and descriptionstatic <C> @NonNull CommandComponent<C>
of(@NonNull CommandArgument<C,?> commandArgument, @NonNull Description commandDescription)
Deprecated.for removal since 1.4.0.@NonNull String
toString()
-
Method Details
-
getArgument
Gets the command component argument details- Returns:
- command component argument details
-
getDescription
Deprecated.for removal since 1.4.0. UsegetArgumentDescription()
instead.Gets the command component description- Returns:
- command component description
-
getArgumentDescription
Gets the command component description- Returns:
- command component description
- Since:
- 1.4.0
-
hashCode
public int hashCode() -
equals
-
toString
-
of
@Deprecated public static <C> @NonNull CommandComponent<C> of(@NonNull CommandArgument<C,?> commandArgument, @NonNull Description commandDescription)Deprecated.for removal since 1.4.0. Useof(CommandArgument, ArgumentDescription)
instead.Creates a new CommandComponent with the provided argument and description- Type Parameters:
C
- Command sender type- Parameters:
commandArgument
- Command Component ArgumentcommandDescription
- Command Component Description- Returns:
- new CommandComponent
-
of
public static <C> @NonNull CommandComponent<C> of(@NonNull CommandArgument<C,?> commandArgument, @NonNull ArgumentDescription commandDescription)Creates a new CommandComponent with the provided argument and description- Type Parameters:
C
- Command sender type- Parameters:
commandArgument
- Command Component ArgumentcommandDescription
- Command Component Description- Returns:
- new CommandComponent
-