Package mondrian.olap
Class QueryAxis
java.lang.Object
mondrian.olap.QueryPart
mondrian.olap.QueryAxis
An axis in an MDX query. For example, the typical MDX query has two axes,
which appear as the "ON COLUMNS" and "ON ROWS" clauses.
- Author:
- jhyde, 20 January, 1999
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic enum
SubtotalVisibility
enumerates the allowed values of whether subtotals are visible. -
Constructor Summary
ConstructorDescriptionQueryAxis
(boolean nonEmpty, Exp set, AxisOrdinal axisOrdinal, QueryAxis.SubtotalVisibility subtotalVisibility) Creates an axis with no dimension properties.QueryAxis
(boolean nonEmpty, Exp set, AxisOrdinal axisOrdinal, QueryAxis.SubtotalVisibility subtotalVisibility, Id[] dimensionProperties) Creates an axis. -
Method Summary
Modifier and TypeMethodDescriptionaccept
(MdxVisitor visitor) void
clone()
compile
(ExpCompiler compiler, ResultStyle resultStyle) Returns the ordinal of this axis, for exampleAxisOrdinal.StandardAxisOrdinal.ROWS
.Object[]
Id[]
getSet()
Returns the expression which is used to compute the value of this axis.boolean
Returns whether the axis has theNON EMPTY
property set.boolean
Returns whether the axis has theORDER
property set.void
void
void
setNonEmpty
(boolean nonEmpty) Sets whether the axis has theNON EMPTY
property set.void
setOrdered
(boolean ordered) Sets whether the axis has theORDER
property set.void
Sets the expression which is used to compute the value of this axis.void
unparse
(PrintWriter pw) Writes a string representation of this parse tree node to the given writer.void
-
Constructor Details
-
QueryAxis
public QueryAxis(boolean nonEmpty, Exp set, AxisOrdinal axisOrdinal, QueryAxis.SubtotalVisibility subtotalVisibility, Id[] dimensionProperties) Creates an axis.- Parameters:
nonEmpty
- Whether to filter out members of this axis whose cells are all emptyset
- Expression to populate the axisaxisOrdinal
- Which axis (ROWS, COLUMNS, etc.)subtotalVisibility
- Whether to show subtotalsdimensionProperties
- List of dimension properties
-
QueryAxis
public QueryAxis(boolean nonEmpty, Exp set, AxisOrdinal axisOrdinal, QueryAxis.SubtotalVisibility subtotalVisibility) Creates an axis with no dimension properties.
-
-
Method Details
-
clone
-
accept
-
compile
-
getAxisName
-
getAxisOrdinal
Returns the ordinal of this axis, for exampleAxisOrdinal.StandardAxisOrdinal.ROWS
. -
isNonEmpty
public boolean isNonEmpty()Returns whether the axis has theNON EMPTY
property set. -
setNonEmpty
public void setNonEmpty(boolean nonEmpty) Sets whether the axis has theNON EMPTY
property set. SeeisNonEmpty()
. -
isOrdered
public boolean isOrdered()Returns whether the axis has theORDER
property set. -
setOrdered
public void setOrdered(boolean ordered) Sets whether the axis has theORDER
property set. -
getSet
Returns the expression which is used to compute the value of this axis. -
setSet
Sets the expression which is used to compute the value of this axis. SeegetSet()
. -
resolve
-
getChildren
- Overrides:
getChildren
in classQueryPart
-
unparse
Description copied from class:QueryPart
Writes a string representation of this parse tree node to the given writer. -
addLevel
-
getSubtotalVisibility
-
resetSubtotalVisibility
public void resetSubtotalVisibility() -
validate
-
getDimensionProperties
-