Package de.hybris.platform.cockpit.util
Class TreeUtils
java.lang.Object
de.hybris.platform.cockpit.util.TreeUtils
Provides useful functionalities for zk trees, especially for searching within treenodes.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classSubclass ofAbstractTreeModelthat can be used as a filter.static interfaceUsed byTreeUtils.FilteredTreeModelto determine the string representation of a treenode that should be used for filtering.static classThis class can be used to store the state of a tree regarding expanded/collapsed nodes. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanmatchCamelCase(String value, String searchString) Camelcase string matching.static booleanmatchFilterString(Object data, String filterString, boolean camelCase) Checks, if argument data can be represented by argument filterString, i.e.static booleanmatchFilterStringSimple(String value, String filterString) Checks, if argument value starts (case-insensitive) with argument filterString.
-
Constructor Details
-
TreeUtils
public TreeUtils()
-
-
Method Details
-
matchCamelCase
Camelcase string matching.- Parameters:
value- the string that should be checked.searchString- the "camelcased" search string.- Returns:
- true, if the search string is a camelcase representation of the value.
-
matchFilterStringSimple
Checks, if argument value starts (case-insensitive) with argument filterString. -
matchFilterString
Checks, if argument data can be represented by argument filterString, i.e. it first checks, if data is aString, then invokesmatchFilterString(Object, String, boolean)and optionally invokesmatchCamelCase(String, String), depending on argument camelCase.
-