net.sf.saffron.ext
Class ExtentRel
java.lang.Object
|
+--net.sf.saffron.rel.SaffronRel
|
+--net.sf.saffron.ext.ExtentRel
- public class ExtentRel
- extends SaffronRel
ExtentRel
represents all of the instances of a particular
class (including subtypes).
It cannot be implemented as such, but can often be transformed into an
expression which can. For example, in
JavaReflectConnection reflect;
select
from reflect.fields as field
join reflect.classes as clazz
on field.getDeclaringClass() == clazz &&
clazz.getPackage().getName().equals("java.lang");
the field
and clazz
are constrained by join and
filter conditions so that we can enumerate the required fields.
todo: Why is this not just a TableAccess?
- See Also:
ExtentTable
Methods inherited from class net.sf.saffron.rel.SaffronRel |
childrenAccept, computeDigest, computeSelfCost, getChildExps, getCluster, getConvention, getCorrelVariable, getId, getInput, getInputs, getOrCreateCorrelVariable, getQualifier, getQuery, getRelTypeName, getRows, getRowType, getVariablesStopped, implement, implementFieldAccess, isAccessTo, onRegister, recomputeDigest, register, registerCorrelVariable, replaceInput, setCorrelVariable, toString |
table
private SaffronTable table
ExtentRel
public ExtentRel(VolcanoCluster cluster,
SaffronType rowType,
SaffronTable table)
- Creates an
ExtentRel
.
- Pre-condition:
- rowType != null, table != null
isDistinct
public boolean isDistinct()
- Description copied from class:
SaffronRel
- Returns whether the same value will not come out twice. Default value
is
false
, derived classes should override.
- Overrides:
isDistinct
in class SaffronRel
clone
public Object clone()
- Specified by:
clone
in class SaffronRel
explain
public void explain(PlanWriter pw)
- Overrides:
explain
in class SaffronRel
getTable
public SaffronTable getTable()
- Description copied from class:
SaffronRel
- If this relational expression represents an access to a table, returns
that table, otherwise returns null.
- Overrides:
getTable
in class SaffronRel
deriveRowType
protected SaffronType deriveRowType()
- Specified by:
deriveRowType
in class SaffronRel