Class SingleEntitySelectorArgument<C>

java.lang.Object
cloud.commandframework.arguments.CommandArgument<C,SingleEntitySelector>
cloud.commandframework.bukkit.parsers.selector.SingleEntitySelectorArgument<C>
All Implemented Interfaces:
cloud.commandframework.keys.CloudKeyHolder<SingleEntitySelector>, Comparable<cloud.commandframework.arguments.CommandArgument<?,?>>

public final class SingleEntitySelectorArgument<C> extends cloud.commandframework.arguments.CommandArgument<C,SingleEntitySelector>
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static final class 
     
    static final class 
     

    Nested classes/interfaces inherited from class cloud.commandframework.arguments.CommandArgument

    cloud.commandframework.arguments.CommandArgument.TypedBuilder<C extends Object,T extends Object,B extends cloud.commandframework.arguments.CommandArgument.Builder<C,T>>
  • Method Summary

    Modifier and Type
    Method
    Description
    static <C> @NonNull SingleEntitySelectorArgument.Builder<C>
    newBuilder(@NonNull String name)
    Create a new builder
    static <C> @NonNull cloud.commandframework.arguments.CommandArgument<C,SingleEntitySelector>
    of(@NonNull String name)
    Create a new required command argument
    static <C> @NonNull cloud.commandframework.arguments.CommandArgument<C,SingleEntitySelector>
    optional(@NonNull String name)
    Create a new optional command argument
    static <C> @NonNull cloud.commandframework.arguments.CommandArgument<C,SingleEntitySelector>
    optional(@NonNull String name, @NonNull String defaultEntitySelector)
    Create a new required command argument with a default value

    Methods inherited from class cloud.commandframework.arguments.CommandArgument

    addPreprocessor, compareTo, copy, equals, getDefaultDescription, getDefaultValue, getKey, getName, getOwningCommand, getParser, getSuggestionsProvider, getValueType, hasDefaultValue, hashCode, isArgumentRegistered, isRequired, ofType, ofType, preprocess, setArgumentRegistered, setOwningCommand, toString

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Method Details

    • newBuilder

      public static <C> @NonNull SingleEntitySelectorArgument.Builder<C> newBuilder(@NonNull String name)
      Create a new builder
      Type Parameters:
      C - Command sender type
      Parameters:
      name - Name of the argument
      Returns:
      Created builder
    • of

      public static <C> @NonNull cloud.commandframework.arguments.CommandArgument<C,SingleEntitySelector> of(@NonNull String name)
      Create a new required command argument
      Type Parameters:
      C - Command sender type
      Parameters:
      name - Argument name
      Returns:
      Created argument
    • optional

      public static <C> @NonNull cloud.commandframework.arguments.CommandArgument<C,SingleEntitySelector> optional(@NonNull String name)
      Create a new optional command argument
      Type Parameters:
      C - Command sender type
      Parameters:
      name - Argument name
      Returns:
      Created argument
    • optional

      public static <C> @NonNull cloud.commandframework.arguments.CommandArgument<C,SingleEntitySelector> optional(@NonNull String name, @NonNull String defaultEntitySelector)
      Create a new required command argument with a default value
      Type Parameters:
      C - Command sender type
      Parameters:
      name - Argument name
      defaultEntitySelector - Default player
      Returns:
      Created argument