Class VerbalProperty

All Implemented Interfaces:
Serializable

public class VerbalProperty extends SettableProperty<VerbalChoice>
This class represents the Value property of a VerbalRuleComponent The entire set of choices can be obtained through the getPermutedChoices(String pattern) method It also provides paged access to the list of valid choices through the getPermutedChoicesPaged(String pattern, int maxPageSize) method
Since:
12.1.2
Author:
gopandey
See Also:
  • Constructor Details

  • Method Details

    • forceSync

      public void forceSync()
    • getChoices

      public List<VerbalChoice> getChoices(String pattern)
      Returns an immutable list of the most relevant valid choices for the VerbalProperty. This API returns the choices that are algorithmically evaluated to be most relevant in the current context. This method would return the list of all possible Choices for the given pattern, the size of which would depend on the size of the Dictionary datamodel. Use getPagedChoices to obtain choices in a paged manner.
      Parameters:
      pattern - the pattern to look for in the choices
      Returns:
      a list of matching choices
    • getChoicesWithoutGenerics

      public List<VerbalChoice> getChoicesWithoutGenerics(String pattern)
    • getPagedChoices

      public List<VerbalChoice> getPagedChoices(String pattern)
      Returns an immutable list of the most relevant valid choices for the VerbalProperty. This API can be called repeatedly to obtain choices which are valid but were algorithmically deemed less relevant. Subsequent calls to this API will also include choices that were returned earlier by this API. After a few calls, the API will return all valid choices.
      Parameters:
      pattern - the pattern to look for in the choices
      Returns:
      a list of matching choices
    • getChoices

      public List<VerbalChoice> getChoices(VerbalChoice pc)
    • getValue

      public VerbalChoice getValue()
      Description copied from class: DictionaryProperty
      Get property value.
      Overrides:
      getValue in class DictionaryProperty<VerbalChoice>
      Returns:
      T value
    • setValue

      public void setValue(VerbalChoice value)
      Description copied from class: SettableProperty
      Set the value of the property
      Overrides:
      setValue in class SettableProperty<VerbalChoice>
    • hasMoreChoices

      public boolean hasMoreChoices(String pattern)
      Returns:
      true if a call to getPagedChocies(pattern) will return fresh, non-generic choices, false otherwise.
    • clearCache

      public void clearCache()
    • hasDiff

      public boolean hasDiff()
      Description copied from class: DictionaryProperty
      Does this property have diffs?
      Overrides:
      hasDiff in class DictionaryProperty<VerbalChoice>
      Returns:
      boolean
    • getEditSession

      public EditSession getEditSession()