Class BaseCommand<T extends BaseCommand<T>>

    • Constructor Summary

      Constructors 
      Constructor Description
      BaseCommand​(java.lang.String name, java.lang.String description)  
    • Constructor Detail

      • BaseCommand

        public BaseCommand​(@Nonnull
                           java.lang.String name,
                           @Nonnull
                           java.lang.String description)
    • Method Detail

      • setName

        @Nonnull
        public T setName​(@Nonnull
                         java.lang.String name)
        Configure the name
        Parameters:
        name - The lowercase alphanumeric (with dash) name, 1-32 characters
        Returns:
        The builder, for chaining
        Throws:
        java.lang.IllegalArgumentException - If the name is null, not alphanumeric, or not between 1-32 characters
      • setDescription

        @Nonnull
        public T setDescription​(@Nonnull
                                java.lang.String description)
        Configure the description
        Parameters:
        description - The description, 1-100 characters
        Returns:
        The builder, for chaining
        Throws:
        java.lang.IllegalArgumentException - If the name is null or not between 1-100 characters
      • getName

        @Nonnull
        public java.lang.String getName()
        The configured name
        Returns:
        The name
      • getDescription

        @Nonnull
        public java.lang.String getDescription()
        The configured description
        Returns:
        The description
      • getOptions

        @Nonnull
        public java.util.List<OptionData> getOptions()
        The options for this command.
        Returns:
        Immutable list of OptionData