|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectmondrian.olap.fun.TestMember
public class TestMember
Mock implementation of Member for testing.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface mondrian.olap.Member |
|---|
Member.MemberType |
| Nested classes/interfaces inherited from interface mondrian.olap.OlapElement |
|---|
OlapElement.LocalizedProperty |
| Constructor Summary | |
|---|---|
TestMember(String identifer)
|
|
| Method Summary | |
|---|---|
int |
compareTo(Object o)
|
List<Member> |
getAncestorMembers()
Returns a list of the ancestor members of this member. |
Map<String,Annotation> |
getAnnotationMap()
Returns a list of annotations. |
String |
getCaption()
|
Member |
getDataMember()
Returns the system-generated data member that is associated with a nonleaf member of a dimension. |
int |
getDepth()
returns the depth of this member, which is not the level's depth in case of parent child dimensions |
String |
getDescription()
|
Dimension |
getDimension()
Returns the dimension of a this expression, or null if no dimension is defined. |
Exp |
getExpression()
|
Hierarchy |
getHierarchy()
|
Level |
getLevel()
|
String |
getLocalized(OlapElement.LocalizedProperty prop,
Locale locale)
Returns the value of a property (caption or description) of this element in the given locale. |
Member.MemberType |
getMemberType()
Returns the type of member. |
String |
getName()
|
Comparable |
getOrderKey()
Returns the order key of the member (relative to its siblings); null if undefined or unavailable. |
int |
getOrdinal()
Returns the ordinal of the member. |
Member |
getParentMember()
Returns this member's parent, or null (not the 'null member', as returned by Hierarchy.getNullMember()) if it has no parent. |
String |
getParentUniqueName()
Returns name of parent member, or empty string (not null) if we are the root. |
Property[] |
getProperties()
Returns the definitions of the properties this member may have. |
String |
getPropertyFormattedValue(String propertyName)
Returns the formatted value of the property named propertyName. |
Object |
getPropertyValue(String propertyName)
Returns the value of the property named propertyName. |
Object |
getPropertyValue(String propertyName,
boolean matchCase)
Returns the value of the property named propertyName,
matching according to the required case-sensitivity. |
String |
getQualifiedName()
Returns the name of this element qualified by its class, for example "hierarchy 'Customers'". |
int |
getSolveOrder()
|
String |
getUniqueName()
|
boolean |
isAll()
Returns whether this is the 'all' member. |
boolean |
isCalculated()
Returns whether this member is computed using either a with
member clause in an mdx query or a calculated member defined in
cube. |
boolean |
isCalculatedInQuery()
Returns whether this member is computed from a WITH MEMBER
clause in an MDX query. |
boolean |
isChildOrEqualTo(Member member)
Returns whether member is equal to, a child, or a
descendent of this Member. |
boolean |
isEvaluated()
Returns whether this member should be evaluated within the Evaluator. |
boolean |
isHidden()
Returns whether this member is 'hidden', as per the rules which define a ragged hierarchy. |
boolean |
isMeasure()
Returns whether this is a member of the measures dimension. |
boolean |
isNull()
Returns whether this is the 'null member'. |
boolean |
isParentChildLeaf()
|
boolean |
isVisible()
Returns whether this element is visible to end-users. |
OlapElement |
lookupChild(SchemaReader schemaReader,
Id.Segment s,
MatchType matchType)
Looks up a child element, returning null if it does not exist. |
void |
setName(String name)
Only allowable if the member is part of the WITH clause of
a query. |
void |
setProperty(String name,
Object value)
Sets a property of this member to a given value. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public TestMember(String identifer)
| Method Detail |
|---|
public String toString()
toString in class Objectpublic int compareTo(Object o)
compareTo in interface Comparablepublic Member getParentMember()
MemberHierarchy.getNullMember()) if it has no parent.
In an access-control context, a member may have no visible
parents, so use SchemaReader.getMemberParent(mondrian.olap.Member).
getParentMember in interface Memberpublic Level getLevel()
getLevel in interface Memberpublic Hierarchy getHierarchy()
getHierarchy in interface MembergetHierarchy in interface OlapElementpublic String getParentUniqueName()
Member
getParentUniqueName in interface Memberpublic Member.MemberType getMemberType()
Member
getMemberType in interface Memberpublic boolean isParentChildLeaf()
isParentChildLeaf in interface Memberpublic void setName(String name)
MemberWITH clause of
a query.
setName in interface Memberpublic boolean isAll()
Member
isAll in interface Memberpublic boolean isMeasure()
Member
isMeasure in interface Memberpublic boolean isNull()
Member
isNull in interface Memberpublic boolean isChildOrEqualTo(Member member)
Membermember is equal to, a child, or a
descendent of this Member.
isChildOrEqualTo in interface Memberpublic boolean isCalculated()
Memberwith
member clause in an mdx query or a calculated member defined in
cube.
isCalculated in interface Memberpublic boolean isEvaluated()
MemberNormally Member.isCalculated() and Member.isEvaluated() should return
the same value, but in situations where mondrian would like to treat the
two concepts separately such in role based security, these values may
differ.
isEvaluated in interface Memberpublic int getSolveOrder()
getSolveOrder in interface Memberpublic Exp getExpression()
getExpression in interface Memberpublic List<Member> getAncestorMembers()
Member
getAncestorMembers in interface Memberpublic boolean isCalculatedInQuery()
MemberWITH MEMBER
clause in an MDX query.
isCalculatedInQuery in interface Memberpublic Object getPropertyValue(String propertyName)
MemberpropertyName.
Name match is case-sensitive.
getPropertyValue in interface Member
public Object getPropertyValue(String propertyName,
boolean matchCase)
MemberpropertyName,
matching according to the required case-sensitivity.
getPropertyValue in interface Memberpublic String getPropertyFormattedValue(String propertyName)
MemberpropertyName.
getPropertyFormattedValue in interface Member
public void setProperty(String name,
Object value)
Member
setProperty in interface Memberpublic Property[] getProperties()
Member
getProperties in interface Memberpublic int getOrdinal()
Member
getOrdinal in interface Memberpublic Comparable getOrderKey()
Member
getOrderKey in interface Memberpublic boolean isHidden()
Member
isHidden in interface Memberpublic int getDepth()
Member
getDepth in interface Memberpublic Member getDataMember()
MemberReturns this member if this member is a leaf member, or if the nonleaf member does not have an associated data member.
getDataMember in interface Memberpublic String getUniqueName()
getUniqueName in interface OlapElementpublic String getName()
getName in interface OlapElementpublic String getDescription()
getDescription in interface OlapElement
public OlapElement lookupChild(SchemaReader schemaReader,
Id.Segment s,
MatchType matchType)
OlapElement
lookupChild in interface OlapElementpublic String getQualifiedName()
OlapElement
getQualifiedName in interface OlapElementpublic String getCaption()
getCaption in interface OlapElement
public String getLocalized(OlapElement.LocalizedProperty prop,
Locale locale)
OlapElement
getLocalized in interface OlapElementlocale - Locale
public boolean isVisible()
OlapElementVisibility is a hint for client applications. An element's visibility does not affect how it is treated when MDX queries are evaluated.
isVisible in interface OlapElementpublic Dimension getDimension()
OlapElementExample 1:
has dimension[Sales].children
[Sales].
Example 2:
order(except([Promotion Media].[Media Type].members,
{[Promotion Media].[Media Type].[No Media]}),
[Measures].[Unit Sales], DESC)
has dimension [Promotion Media].
Example 3:
CrossJoin([Product].[Product Department].members,
[Gender].members)
has no dimension (well, actually it is [Product] x [Gender], but we
can't represent that, so we return null);
getDimension in interface OlapElementpublic Map<String,Annotation> getAnnotationMap()
AnnotatedThe map may be empty, never null.
getAnnotationMap in interface Annotated
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||