Package mondrian.olap

Class Id.NameSegment

  • Enclosing class:
    Id

    public static class Id.NameSegment
    extends Id.Segment
    Component in a compound identifier that describes the name of an object. Optionally, the name is quoted in brackets.
    See Also:
    Id.KeySegment
    • Field Summary

      Fields 
      Modifier and Type Field Description
      java.lang.String name  
    • Constructor Summary

      Constructors 
      Constructor Description
      NameSegment​(java.lang.String name)
      Creates a quoted name segment.
      NameSegment​(java.lang.String name, Id.Quoting quoting)
      Creates a name segment with the given quoting.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object o)  
      java.util.List<Id.NameSegment> getKeyParts()  
      java.lang.String getName()  
      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.
      void toString​(java.lang.StringBuilder buf)
      Appends this segment to a StringBuilder.
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Field Detail

      • name

        public final java.lang.String name
    • Constructor Detail

      • NameSegment

        public NameSegment​(java.lang.String name,
                           Id.Quoting quoting)
        Creates a name segment with the given quoting.
        Parameters:
        name - Name
        quoting - Quoting style
      • NameSegment

        public NameSegment​(java.lang.String name)
        Creates a quoted name segment.
        Parameters:
        name - Name
    • Method Detail

      • 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
      • getName

        public java.lang.String getName()
      • toString

        public void toString​(java.lang.StringBuilder buf)
        Description copied from class: Id.Segment
        Appends this segment to a StringBuilder.
        Specified by:
        toString in class Id.Segment
        Parameters:
        buf - String builder to write to
      • matches

        public boolean matches​(java.lang.String name)
        Description copied from class: Id.Segment
        Returns whether this segment matches a given name according to the rules of case-sensitivity and quoting.
        Specified by:
        matches in class Id.Segment
        Parameters:
        name - Name to match
        Returns:
        Whether matches