Enum Class InputFieldProperty

java.lang.Object
java.lang.Enum<InputFieldProperty>
nz.org.riskscape.engine.bind.InputFieldProperty
All Implemented Interfaces:
Serializable, Comparable<InputFieldProperty>, Constable, nz.org.riskscape.engine.bind.ParameterProperty

public enum InputFieldProperty extends Enum<InputFieldProperty> implements nz.org.riskscape.engine.bind.ParameterProperty

Describes aspects of how the UI should present the parameter to the user, i.e. what type of input field should be used on the form.

  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    Same as multiselect, but on the UI it appears as a set of checkboxes.
    Specify explicitly that the UI should be a drop-down select box.
    Hide this parameter by default, i.e.
    User can specify multiple values, either from a pre-defined set of choices or as free-form numbers
    Display this parameter's value, but don't let the user edit it by default
    Specify explicitly that the UI should be a simple textbox, i.e.
    Specify explicitly that we don't want the default formatting for numbers.
  • Method Summary

    Modifier and Type
    Method
    Description
    List<nz.org.riskscape.engine.bind.ParameterProperty>
     
     
    boolean
    isCompatible(nz.org.riskscape.engine.bind.ParameterProperty other)
     
    Returns the enum constant of this class with the specified name.
    Returns an array containing the constants of this enum class, in the order they are declared.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface nz.org.riskscape.engine.bind.ParameterProperty

    getValueOr, hasKeyValuePair, implies, validate, withValue, withValue
  • Enum Constant Details

    • HIDDEN

      public static final InputFieldProperty HIDDEN

      Hide this parameter by default, i.e. it's expert-only

    • READONLY

      public static final InputFieldProperty READONLY
      Display this parameter's value, but don't let the user edit it by default
    • UNFORMATTED

      public static final InputFieldProperty UNFORMATTED
      Specify explicitly that we don't want the default formatting for numbers. Useful for things like years, where we want to see 2024 rather than 2,024
    • MULTISELECT

      public static final InputFieldProperty MULTISELECT
      User can specify multiple values, either from a pre-defined set of choices or as free-form numbers
    • CHECKBOX

      public static final InputFieldProperty CHECKBOX
      Same as multiselect, but on the UI it appears as a set of checkboxes. This requires that options are defined for the template
    • TEXTBOX

      public static final InputFieldProperty TEXTBOX
      Specify explicitly that the UI should be a simple textbox, i.e. don't go inferring any fancy numeric multiselects, just let the user enter things in plain text
  • Method Details

    • values

      public static InputFieldProperty[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static InputFieldProperty valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • isCompatible

      public boolean isCompatible(nz.org.riskscape.engine.bind.ParameterProperty other)
      Specified by:
      isCompatible in interface nz.org.riskscape.engine.bind.ParameterProperty
    • getKeyword

      public String getKeyword()
      Specified by:
      getKeyword in interface nz.org.riskscape.engine.bind.ParameterProperty
    • getImplied

      public List<nz.org.riskscape.engine.bind.ParameterProperty> getImplied()
      Specified by:
      getImplied in interface nz.org.riskscape.engine.bind.ParameterProperty