| Modifier and Type | Method and Description |
|---|---|
| private void | addAtEnd(String keyword)
Overrides org. Adds the given keyword at the end of the chain. |
| public int | compareTo(Keyword
the object to be compared. o)Implements java. Compares this object with the specified object for order. |
| public boolean | equals(Object
the reference object with which to compare. o)Overrides java. Indicates whether some other object is "equal to" this one. |
| public Set | |
| public String | |
| public Set | getAllSubchainsAsString(Character hierarchicalDelimiter)
Returns all subchains starting at this node. |
| public String | getPathFromRootAsString(Character hierarchicalDelimiter)
Returns a text representation of the path from the root to this item. |
| private String | getSubchainAsString(Character hierarchicalDelimiter)
Returns a text representation of the subchain starting at this item. |
| public int | |
| public static Keyword | |
| public String |
| DEFAULT_HIERARCHICAL_DELIMITER | back to summary |
|---|---|
| public static Character DEFAULT_HIERARCHICAL_DELIMITER | |
| keyword | back to summary |
|---|---|
| private final String keyword | |
| Keyword | back to summary |
|---|---|
| public Keyword(String keyword) | |
| addAtEnd | back to summary |
|---|---|
| private void addAtEnd(String keyword) Overrides org. Adds the given keyword at the end of the chain. E.g., "A > B > C" + "D" -> "A > B > C > D". | |
| compareTo | back to summary |
|---|---|
| public int compareTo(Keyword o) Implements java. Doc from java. Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object. The implementor must ensure The implementor must also ensure that the relation is transitive:
Finally, the implementor must ensure that | |
| equals | back to summary |
|---|---|
| public boolean equals(Object o) Overrides java. Doc from java. Indicates whether some other object is "equal to" this one.
The
An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes. | |
| flatten | back to summary |
|---|---|
| public Set Returns all nodes in this chain as separate keywords. E.g, for "A > B > C" we get {"A", "B", "C"}. | |
| get | back to summary |
|---|---|
| public String get() Gets the keyword of this node in the chain. | |
| getAllSubchainsAsString | back to summary |
|---|---|
| public Set Returns all subchains starting at this node. E.g., for the chain "A > B > C" the subchains {"A", "A > B", "A > B > C"} are returned. | |
| getPathFromRootAsString | back to summary |
|---|---|
| public String getPathFromRootAsString(Character hierarchicalDelimiter) Returns a text representation of the path from the root to this item.
E.g., calling | |
| getSubchainAsString | back to summary |
|---|---|
| private String getSubchainAsString(Character hierarchicalDelimiter) Returns a text representation of the subchain starting at this item.
E.g., calling | |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |
| of | back to summary |
|---|---|
| public static Keyword of(String... keywords) Connects all the given keywords into one chain and returns its root, e.g. "A", "B", "C" is transformed into "A > B > C". | |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object.
Satisfying this method's contract implies a non- | |