mondrian.olap.fun
Class DistinctFunDef.CalcImpl

java.lang.Object
  extended by mondrian.calc.impl.AbstractCalc
      extended by mondrian.calc.impl.AbstractListCalc
          extended by mondrian.olap.fun.DistinctFunDef.CalcImpl
All Implemented Interfaces:
Calc, ListCalc, MemberListCalc, TupleListCalc
Enclosing class:
DistinctFunDef

static class DistinctFunDef.CalcImpl
extends AbstractListCalc


Field Summary
 
Fields inherited from class mondrian.calc.impl.AbstractListCalc
tuple
 
Fields inherited from class mondrian.calc.impl.AbstractCalc
exp, type
 
Constructor Summary
DistinctFunDef.CalcImpl(ResolvedFunCall call, ListCalc listCalc)
           
 
Method Summary
(package private) static java.util.List<java.lang.Object> distinct(java.util.List list)
           
 java.util.List evaluateList(Evaluator evaluator)
          Evaluates an expression to yield a list of members or tuples.
 java.util.List<Member> evaluateMemberList(Evaluator evaluator)
          Evaluates an expression to yield a list of members.
 java.util.List<Member[]> evaluateTupleList(Evaluator evaluator)
          Evaluates an expression to yield a list of tuples.
 
Methods inherited from class mondrian.calc.impl.AbstractListCalc
evaluate, evaluateEitherList, getResultStyle, getType
 
Methods inherited from class mondrian.calc.impl.AbstractCalc
accept, anyDepends, anyDependsButFirst, butDepends, dependsOn, getArguments, getCalcs, getName, simplifyEvaluator
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface mondrian.calc.Calc
accept, dependsOn
 

Constructor Detail

DistinctFunDef.CalcImpl

public DistinctFunDef.CalcImpl(ResolvedFunCall call,
                               ListCalc listCalc)
Method Detail

evaluateList

public java.util.List evaluateList(Evaluator evaluator)
Description copied from interface: ListCalc
Evaluates an expression to yield a list of members or tuples.

The list is immutable if Calc.getResultStyle() yields ResultStyle.MUTABLE_LIST. Otherwise, the caller must not modify the list.

Parameters:
evaluator - Evaluation context
Returns:
A list of members or tuples, never null.

distinct

static java.util.List<java.lang.Object> distinct(java.util.List list)

evaluateMemberList

public java.util.List<Member> evaluateMemberList(Evaluator evaluator)
Description copied from interface: MemberListCalc
Evaluates an expression to yield a list of members.

The list is immutable if Calc.getResultStyle() yields ResultStyle.MUTABLE_LIST. Otherwise, the caller must not modify the list.

Specified by:
evaluateMemberList in interface MemberListCalc
Overrides:
evaluateMemberList in class AbstractListCalc
Parameters:
evaluator - Evaluation context
Returns:
A list of members, never null.

evaluateTupleList

public java.util.List<Member[]> evaluateTupleList(Evaluator evaluator)
Description copied from interface: TupleListCalc
Evaluates an expression to yield a list of tuples.

Each tuple is represented by an array of members.

The list is immutable if Calc.getResultStyle() yields ResultStyle.MUTABLE_LIST. Otherwise, the caller must not modify the list.

Specified by:
evaluateTupleList in interface TupleListCalc
Overrides:
evaluateTupleList in class AbstractListCalc
Parameters:
evaluator - Evaluation context
Returns:
A list of tuples, never null.

Get Mondrian at SourceForge.net. Fast, secure and free Open Source software downloads