Class CommandOption

java.lang.Object
org.episteme.natural.chemistry.loaders.cml.util.CommandOption

public class CommandOption extends Object
Represents a single command-line option for JVM-based tools. Supports various types including Boolean, String, Double, etc.
Since:
1.0
Author:
Silvere Martin-Michiellot, Gemini AI (Google DeepMind)
  • Constructor Details

    • CommandOption

      public CommandOption(String name, Class<?> classx, CommandOptionValue[] optionValue, Object value, String desc)
      Creates a new CommandOption object.
      Parameters:
      name - the name of the option
      classx - the expected value type
      optionValue - allowed value descriptors (can be null)
      value - the default value
      desc - the option description
  • Method Details

    • setValue

      public void setValue(Object value)
      Sets the value of this option.
      Parameters:
      value - the new value
    • getValue

      public Object getValue()
      Returns the current value of this option.
      Returns:
      the value
    • getName

      public String getName()
      Returns the name of this option.
      Returns:
      the name
    • getClassx

      public Class<?> getClassx()
      Returns the class type of this option.
      Returns:
      the class type
    • getDescription

      public String getDescription()
      Returns the description of this option.
      Returns:
      the description
    • toString

      public String toString()
      Returns a string representation of this option and its current value.
      Overrides:
      toString in class Object
      Returns:
      the string representation