net.sf.saffron.oj.rel
Class IterCalcRel

java.lang.Object
  |
  +--net.sf.saffron.rel.SaffronRel
        |
        +--net.sf.saffron.rel.SingleRel
              |
              +--net.sf.saffron.rel.ProjectRelBase
                    |
                    +--net.sf.saffron.oj.rel.IterCalcRel

public class IterCalcRel
extends ProjectRelBase

IterCalcRel is an iterator implementation of a combination of ProjectRel above an optional FilterRel. It takes an iterator as input, and for each row applies the filter condition if defined. Rows passing the filter expression are transformed via projection and returned. Note that the same object is always returned (with different values), so parents must not buffer the result.


Nested Class Summary
 
Nested classes inherited from class net.sf.saffron.rel.ProjectRelBase
ProjectRelBase.Flags
 
Field Summary
private  RexNode[] childExps
           
 RexNode condition
           
 
Fields inherited from class net.sf.saffron.rel.ProjectRelBase
exps, fieldNames, flags
 
Fields inherited from class net.sf.saffron.rel.SingleRel
child
 
Fields inherited from class net.sf.saffron.rel.SaffronRel
cluster, digest, id, rowType
 
Constructor Summary
IterCalcRel(VolcanoCluster cluster, SaffronRel child, RexNode[] exps, RexNode condition, String[] fieldNames, int flags)
           
 
Method Summary
 Object clone()
           
 void explain(PlanWriter pw)
           
 RexNode[] getChildExps()
          Returns an array of this SaffronRel's child expressions (not including the inputs returned by SingleRel.getInputs().
 CallingConvention getConvention()
          Returns a value from CallingConvention.
 Object implement(RelImplementor implementor, int ordinal)
          Create a plan for this expression according to a calling convention.
 
Methods inherited from class net.sf.saffron.rel.ProjectRelBase
computeSelfCost, defineTerms, deriveRowType, getFieldNames, getFlags, implementFieldAccess, isBoxed
 
Methods inherited from class net.sf.saffron.rel.SingleRel
childrenAccept, getInputs, getRows, replaceInput
 
Methods inherited from class net.sf.saffron.rel.SaffronRel
computeDigest, getCluster, getCorrelVariable, getId, getInput, getOrCreateCorrelVariable, getQualifier, getQuery, getRelTypeName, getRowType, getTable, getVariablesStopped, isAccessTo, isDistinct, onRegister, recomputeDigest, register, registerCorrelVariable, setCorrelVariable, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

condition

public final RexNode condition

childExps

private RexNode[] childExps
Constructor Detail

IterCalcRel

public IterCalcRel(VolcanoCluster cluster,
                   SaffronRel child,
                   RexNode[] exps,
                   RexNode condition,
                   String[] fieldNames,
                   int flags)
Method Detail

getChildExps

public RexNode[] getChildExps()
Description copied from class: SaffronRel
Returns an array of this SaffronRel's child expressions (not including the inputs returned by SaffronRel.getInputs(). If there are no child expressions, returns an empty array, not null.

Overrides:
getChildExps in class ProjectRelBase

explain

public void explain(PlanWriter pw)
Overrides:
explain in class ProjectRelBase

getConvention

public CallingConvention getConvention()
Description copied from class: SaffronRel
Returns a value from CallingConvention.

Overrides:
getConvention in class SaffronRel

clone

public Object clone()
Specified by:
clone in class SaffronRel

implement

public Object implement(RelImplementor implementor,
                        int ordinal)
Description copied from class: SaffronRel
Create a plan for this expression according to a calling convention.

Overrides:
implement in class SaffronRel
Parameters:
implementor - implementor
ordinal - indicates our position in the pre-, in- and postfix walk over the tree; ordinal is -1 when called from the parent, and i when called from the ith child.

SourceForge.net_Logo