Interface Member

  • All Superinterfaces:
    MetadataElement
    All Known Subinterfaces:
    Measure

    public interface Member
    extends MetadataElement
    Member is a data value in an OLAP Dimension.
    Since:
    Aug 22, 2006
    Author:
    jhyde
    • Method Detail

      • getChildMemberCount

        int getChildMemberCount()
                         throws OlapException
        Returns the number of children this Member has.

        This method has the same effect as getChildMembers().size(), but is typically less expensive.

        Returns:
        number of children
        Throws:
        OlapException - if database error occurs
      • getParentMember

        Member getParentMember()
        Returns the parent of this Member, or null if it has no parent.
        Returns:
        Parent member, or null if member has no parent
      • getLevel

        Level getLevel()
        Returns the Level of this Member.

        Never returns null.

        Returns:
        Level which this Member belongs to
      • getHierarchy

        Hierarchy getHierarchy()
        Returns the Hierarchy of this Member.

        Never returns null. Result is always the same as getLevel().getHierarchy().

        Returns:
        Hierarchy which this Member belongs to
      • getDimension

        Dimension getDimension()
        Returns the Dimension of this Member.

        Never returns null. Result is always the same as getLevel().getHierarchy().getDimension().

        Returns:
        Dimension which this Member belongs to
      • getMemberType

        Member.Type getMemberType()
        Returns the type of this Member.

        Never returns null.

        Returns:
        What kind of member this is
      • isAll

        boolean isAll()
        Returns whether this Member represents the aggregation of all members in its Dimension.

        An 'all' member is always the root of its Hierarchy; that is, its parent member is the null member, and Hierarchy.getRootMembers() returns the 'all' member and no others. Some hierarchies do not have an 'all' member.

        Returns:
        whether this Member is the 'all' member of its Dimension
        See Also:
        Hierarchy.hasAll()
      • isChildOrEqualTo

        boolean isChildOrEqualTo​(Member member)
        Returns whether member is equal to, a child of, or a descendent of this Member.
        Parameters:
        member - Member
        Returns:
        Whether the given Member is a descendent of this Member
      • isCalculated

        boolean isCalculated()
        Returns whether this member is calculated using a formula.

        Examples of calculated members include those defined using a WITH MEMBER clause in an MDX query (getMemberType() will return Member.Type.FORMULA for these), or a calculated member defined in a cube.

        Returns:
        Whether this Member is calculated
        See Also:
        isCalculatedInQuery()
      • getSolveOrder

        int getSolveOrder()
        Returns the solve order of this member in a formula.
        Returns:
        solve order of this Member
      • getExpression

        ParseTreeNode getExpression()
        Expression by which this member is derived, if it is a calculated member. If the member is not calulated, returns null.
        Returns:
        expression for this member
      • getAncestorMembers

        java.util.List<Member> getAncestorMembers()
        Returns array of all members which are ancestor to this.
        Returns:
        ancestor Members
      • isCalculatedInQuery

        boolean isCalculatedInQuery()
        Returns whether this member is computed from a WITH MEMBER clause in an MDX query. (Calculated members can also be calculated in a cube.)
        Returns:
        Whether this member is calculated in a query
        See Also:
        isCalculated()
      • getPropertyFormattedValue

        java.lang.String getPropertyFormattedValue​(Property property)
                                            throws OlapException
        Returns the formatted value of a given property.

        Returns null if the property is not set.

        Every member has certain system properties such as "name" and "caption" (the full list is described in the Property.StandardMemberProperty enumeration), as well as extra properties defined for its Level (see Level.getProperties()).

        Parameters:
        property - Property
        Returns:
        formatted value of the given property
        Throws:
        OlapException - if database error occurs
        See Also:
        getPropertyValue(Property)
      • setProperty

        void setProperty​(Property property,
                         java.lang.Object value)
                  throws OlapException
        Sets a property of this member to a given value.

        Every member has certain system properties such as "name" and "caption" (the full list is described in the Property.StandardMemberProperty enumeration), as well as extra properties defined for its Level (see Level.getProperties()).

        Parameters:
        property - property
        value - Property value
        Throws:
        OlapException - if the value not valid for this property (for example, a String value assigned to a Boolean property)
      • getProperties

        NamedList<Property> getProperties()
        Returns the definitions of the properties this member may have.

        For many providers, properties are defined against a Level, so result of this method will be identical to member.getLevel().getProperties().

        Returns:
        properties of this Member
      • getOrdinal

        int getOrdinal()
        Returns the ordinal of the member.
        Returns:
        ordinal of this Member
      • isHidden

        boolean isHidden()
        Returns whether this member is 'hidden', as per the rules which define a ragged hierarchy.
        Returns:
        whether this member is a hidden member of a ragged hierarchy
      • getDepth

        int getDepth()
        Returns the depth of this member.

        In regular hierarchies, this is as the same as the level's depth, but in parent-child and ragged hierarchies the value may be different.

        Returns:
        depth of this Member
      • getDataMember

        Member getDataMember()
        Returns the system-generated data member that is associated with a non-leaf member of a dimension.

        Returns this member if this member is a leaf member, or if the non-leaf member does not have an associated data member.

        Returns:
        system-generated data member