Class ClassOption

    • Constructor Detail

      • ClassOption

        protected ClassOption​(OptionManager owner,
                              String commandline,
                              String property,
                              Object defValue,
                              UserMode minUserMode)
        Initializes the option. Will always output the default value.
        Parameters:
        owner - the owner of this option
        commandline - the commandline string to identify the option
        property - the name of bean property
        defValue - the default value, if null then the owner's current state is used
        minUserMode - the minimum user mode before showing this option
      • ClassOption

        protected ClassOption​(OptionManager owner,
                              String commandline,
                              String property,
                              Object defValue,
                              boolean outputDefValue,
                              UserMode minUserMode)
        Initializes the option.
        Parameters:
        owner - the owner of this option
        commandline - the commandline string to identify the option
        property - the name of bean property
        defValue - the default value, if null then the owner's current state is used
        outputDefValue - whether to output the default value or not
        minUserMode - the minimum user mode before showing this option
    • Method Detail

      • compareValues

        protected boolean compareValues​(Object value,
                                        Object defValue)
        Skips the test, as it would be too expensive.
        Specified by:
        compareValues in class AbstractArgumentOption
        Parameters:
        value - the value to compare against the default value
        defValue - the default value to compare against
        Returns:
        always false
      • toString

        public String toString​(Object obj)
        Returns a string representation of the specified object.
        Specified by:
        toString in class AbstractArgumentOption
        Parameters:
        obj - the object to turn into a string
        Returns:
        the string representation
      • setNestedValues

        protected void setNestedValues​(ArrayList values)
        Sets the values obtained from the nested structure.
        Parameters:
        values - the values to set
      • addArgumentInfo

        protected void addArgumentInfo​(StringBuilder buffer)
        Adds additional information about the argument, e.g., the class.
        Parameters:
        buffer - the buffer to add the information to
      • toString

        public String toString()
        Returns the commandline option and the property as string.
        Overrides:
        toString in class AbstractArgumentOption
        Returns:
        the commandline option and property