Class SettingSearchInfo

java.lang.Object
com.saperion.settings.SettingSearchInfo
All Implemented Interfaces:
Serializable

public final class SettingSearchInfo extends Object implements Serializable
Defines how to search for a setting. Searching is possible for name, section or both. A search is possible for one setting-type (long/regular) at a time only. Name and section are not case-sensitive.
See Also:
  • Method Details

    • create

      public static SettingSearchInfo create()
      Returns:
      new empty SettingSearchInfo
    • name

      public SettingSearchInfo name(String name, SettingSearchInfo.MatchKind matchKind)
      Sets the name to search for and the match kind to search with.
      Parameters:
      name - name to search for
      matchKind - match-kind for the given setting name
      Returns:
      current SettingSearchInfo instance
    • section

      public SettingSearchInfo section(String section, SettingSearchInfo.MatchKind matchKind)
      Sets the section to search for and the match kind to search with.
      Parameters:
      section - section to search for
      matchKind - match-kind for the given section name
      Returns:
      current SettingSearchInfo instance
    • longSetting

      public SettingSearchInfo longSetting(boolean longSetting)
      Whether to search for long or for regular settings. Default is false (regular setting).
      Parameters:
      longSetting - if true, search will be performed to long settings
      Returns:
      current SettingSearchInfo instance
    • getName

      public String getName()
      Returns:
      the name to search for
    • getNameMatchkind

      public SettingSearchInfo.MatchKind getNameMatchkind()
      Returns:
      the match-kind for name matching.
    • getSection

      public String getSection()
      Returns:
      the section to search for
    • getSectionMatchkind

      public SettingSearchInfo.MatchKind getSectionMatchkind()
      Returns:
      the match-kind for section matching.
    • isLong

      public boolean isLong()
      Returns:
      whether to search for long or regular settings
    • isValid

      public boolean isValid()
      Returns:
      true if this is a valid SettingSearchInfo, which means that either name or section contain a value that is not null or empty.
    • toString

      public String toString()
      Overrides:
      toString in class Object