Class DependentComboboxSearchOption


  • public final class DependentComboboxSearchOption
    extends ExtendedSearchOption
    Allows one combo box to have a set of possible values depending on the selected value of another combo box option.

    Warning: a dependent options cannot depend on another dependent option.

    • Constructor Summary

      Constructors 
      Constructor Description
      DependentComboboxSearchOption​(java.lang.String code, java.lang.String dependeeCode, java.util.Map<java.lang.String,​java.lang.String[]> valuesMap, java.util.Map<java.lang.String,​java.lang.String> defaultValues, java.lang.String label)
      Default constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Map<java.lang.String,​java.lang.String> getDefaultValues()
      Returns a Map of the dependee values to a default value for this combo box when that value is selected in the dependee.
      java.lang.String getDependeeCode()
      Returns the unique identifier of the ComboBoxSearchOption that this depends on.
      java.util.Map<java.lang.String,​java.lang.String[]> getValuesMap()
      Returns a Map of the dependee values to the set of values that this combo box should have for each of those values.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • DependentComboboxSearchOption

        public DependentComboboxSearchOption​(java.lang.String code,
                                             java.lang.String dependeeCode,
                                             java.util.Map<java.lang.String,​java.lang.String[]> valuesMap,
                                             java.util.Map<java.lang.String,​java.lang.String> defaultValues,
                                             java.lang.String label)
        Default constructor.
        Parameters:
        code - Unique identifier for this option
        dependeeCode - Unique identifier of the ComboBoxSearchOption that this depends on
        valuesMap - a map from each of the dependee values to the set of values that this combo box should have for each of those values
        defaultValues - a map from each of the dependee values to a default value for this combo box when that value is selected in the dependee
        label - An optional label to display next to the combo-box or null if no label
    • Method Detail

      • getDependeeCode

        public java.lang.String getDependeeCode()
        Returns the unique identifier of the ComboBoxSearchOption that this depends on.
        Returns:
        the unique identifier of the ComboBoxSearchOption that this depends on
      • getValuesMap

        public java.util.Map<java.lang.String,​java.lang.String[]> getValuesMap()
        Returns a Map of the dependee values to the set of values that this combo box should have for each of those values.
        Returns:
        a Map of dependee values to possible combo box values
      • getDefaultValues

        public java.util.Map<java.lang.String,​java.lang.String> getDefaultValues()
        Returns a Map of the dependee values to a default value for this combo box when that value is selected in the dependee.
        Returns:
        a Map of dependee values to selected combo box values