mondrian.olap
Class Id.Segment
java.lang.Object
mondrian.olap.Id.Segment
- Enclosing class:
- Id
public static class Id.Segment
- extends java.lang.Object
Component in a compound identifier. It is described by its name and how
the name is quoted.
For example, the identifier
[Store].USA.[New Mexico].&[45]
has four segments:
Method Summary |
boolean |
equals(java.lang.Object o)
|
int |
hashCode()
|
boolean |
matches(java.lang.String name)
Returns whether this segment matches a given name according to
the rules of case-sensitivity and quoting. |
static java.util.List<Id.Segment> |
toList(java.lang.String... nameParts)
Converts an array of names to a list of segments. |
java.lang.String |
toString()
|
void |
toString(java.lang.StringBuilder buf)
Appends this segment to a StringBuffer |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
name
public final java.lang.String name
quoting
public final Id.Quoting quoting
Id.Segment
public Id.Segment(java.lang.String name,
Id.Quoting quoting)
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object
toString
public void toString(java.lang.StringBuilder buf)
- Appends this segment to a StringBuffer
- Parameters:
buf
- StringBuffer
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in class java.lang.Object
hashCode
public int hashCode()
- Overrides:
hashCode
in class java.lang.Object
toList
public static java.util.List<Id.Segment> toList(java.lang.String... nameParts)
- Converts an array of names to a list of segments.
- Parameters:
nameParts
- Array of names
- Returns:
- List of segments
matches
public boolean matches(java.lang.String name)
- Returns whether this segment matches a given name according to
the rules of case-sensitivity and quoting.
- Parameters:
name
- Name to match
- Returns:
- Whether matches