Package mondrian.rolap
Class RolapNativeSet
- java.lang.Object
-
- mondrian.rolap.RolapNative
-
- mondrian.rolap.RolapNativeSet
-
- Direct Known Subclasses:
RolapNativeCrossJoin
,RolapNativeFilter
,RolapNativeTopCount
public abstract class RolapNativeSet extends RolapNative
Analyses set expressions and executes them in SQL if possible. Supports crossjoin, member.children, level.members and member.descendants - all in non empty mode, i.e. there is a join to the fact table.TODO: the order of the result is different from the order of the enumeration. Should sort.
- Since:
- Nov 12, 2005
- Author:
- av
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
RolapNativeSet.SchemaReaderWithMemberReaderAvailable
protected static class
RolapNativeSet.SetConstraint
Constraint for non empty {crossjoin, member.children, member.descendants, level.members}protected class
RolapNativeSet.SetEvaluator
-
Field Summary
Fields Modifier and Type Field Description protected static org.apache.logging.log4j.Logger
LOGGER
-
Fields inherited from class mondrian.rolap.RolapNative
listener
-
-
Constructor Summary
Constructors Constructor Description RolapNativeSet()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected CrossJoinArgFactory
crossJoinArgFactory()
void
flushCache()
protected boolean
isPreferInterpreter(CrossJoinArg[] args, boolean joinArg)
Tests whether non-native evaluation is preferred for the given arguments.protected void
overrideContext(RolapEvaluator evaluator, CrossJoinArg[] cargs, RolapStoredMeasure storedMeasure)
Overrides current members in position by default members in hierarchies which are involved in this filter/topcount.protected abstract boolean
restrictMemberTypes()
Returns whether certain member types (e.g.
-
-
-
Method Detail
-
restrictMemberTypes
protected abstract boolean restrictMemberTypes()
Returns whether certain member types (e.g. calculated members) should disable native SQL evaluation for expressions containing them.If true, expressions containing calculated members will be evaluated by the interpreter, instead of using SQL.
If false, calc members will be ignored and the computation will be done in SQL, returning more members than requested. This is ok, if the superflous members are filtered out in java code afterwards.
- Returns:
- whether certain member types should disable native SQL evaluation
-
crossJoinArgFactory
protected CrossJoinArgFactory crossJoinArgFactory()
-
isPreferInterpreter
protected boolean isPreferInterpreter(CrossJoinArg[] args, boolean joinArg)
Tests whether non-native evaluation is preferred for the given arguments.- Parameters:
joinArg
- true if evaluating a cross-join; false if evaluating a single-input expression such as filter- Returns:
- true if all args prefer the interpreter
-
overrideContext
protected void overrideContext(RolapEvaluator evaluator, CrossJoinArg[] cargs, RolapStoredMeasure storedMeasure)
Overrides current members in position by default members in hierarchies which are involved in this filter/topcount. Stores the RolapStoredMeasure into the context because that is needed to generate a cell request to constraint the sql.The current context may contain a calculated measure, this measure was translated into an sql condition (filter/topcount). The measure is not used to constrain the result but only to access the star.
- Parameters:
evaluator
- Evaluation context to modifycargs
- Cross join argumentsstoredMeasure
- Stored measure- See Also:
RolapAggregationManager.makeRequest(RolapEvaluator)
-
flushCache
public void flushCache()
-
-