1 10 package mondrian.calc.impl; 11 12 import mondrian.olap.Evaluator; 13 import mondrian.olap.Exp; 14 import mondrian.olap.type.DimensionType; 15 import mondrian.calc.impl.AbstractCalc; 16 import mondrian.calc.DimensionCalc; 17 import mondrian.calc.Calc; 18 19 30 public abstract class AbstractDimensionCalc 31 extends AbstractCalc implements DimensionCalc { 32 private final Calc[] calcs; 33 34 protected AbstractDimensionCalc(Exp exp, Calc[] calcs) { 35 super(exp); 36 this.calcs = calcs; 37 assert getType() instanceof DimensionType; 38 } 39 40 public Object evaluate(Evaluator evaluator) { 41 return evaluateDimension(evaluator); 42 } 43 44 public Calc[] getCalcs() { 45 return calcs; 46 } 47 } 48 49 | Popular Tags |