Package mondrian.olap
Class Formula
- java.lang.Object
-
- mondrian.olap.QueryPart
-
- mondrian.olap.Formula
-
public class Formula extends QueryPart
AFormula
is a clause in an MDX query which defines a Set or a Member.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Object
accept(MdxVisitor visitor)
Accepts a visitor to this Formula.Object
clone()
void
compile()
String
getCaption()
Returns this formula's caption.Object[]
getChildren()
Exp
getExpression()
Id
getIdentifier()
Returns the Identifier of the set or member which is declared by this Formula.Member
getMdxMember()
Returns the Member.String
getName()
Returns this formula's name.NamedSet
getNamedSet()
Number
getSolveOrder()
Returns the solve order.boolean
isMember()
void
unparse(PrintWriter pw)
Writes a string representation of this parse tree node to the given writer.
-
-
-
Constructor Detail
-
Formula
public Formula(Id id, Exp exp, MemberProperty[] memberProperties)
Constructs a formula specifying a member.
-
-
Method Detail
-
getChildren
public Object[] getChildren()
- Overrides:
getChildren
in classQueryPart
-
unparse
public void unparse(PrintWriter pw)
Description copied from class:QueryPart
Writes a string representation of this parse tree node to the given writer.
-
isMember
public boolean isMember()
-
getNamedSet
public NamedSet getNamedSet()
-
getIdentifier
public Id getIdentifier()
Returns the Identifier of the set or member which is declared by this Formula.- Returns:
- Identifier
-
getName
public String getName()
Returns this formula's name.
-
getCaption
public String getCaption()
Returns this formula's caption.
-
getExpression
public Exp getExpression()
-
getMdxMember
public Member getMdxMember()
Returns the Member. (Not valid if this formula defines a set.)
-
getSolveOrder
public Number getSolveOrder()
Returns the solve order. (Not valid if this formula defines a set.)- Returns:
- Solve order, or null if SOLVE_ORDER property is not specified or is not a number or is not constant
-
compile
public void compile()
-
accept
public Object accept(MdxVisitor visitor)
Accepts a visitor to this Formula. The default implementation dispatches to theMdxVisitor.visit(Formula)
method.- Parameters:
visitor
- Visitor
-
-