|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--saffron.ext.ClassSchema
A ClassSchema
is a schema whose tables are reflections of the
the public fields of a given class.
Field Summary | |
private Class |
clazz
|
private boolean |
ignoreCase
|
Constructor Summary | |
ClassSchema(Class clazz,
boolean ignoreCase)
|
Method Summary | |
private Field |
findField(String name)
|
Table |
getTableForMember(String name)
Retrieves a Table based upon a member access. |
Table |
getTableForMethodCall(MethodCall call)
Retrieves a Table based upon a method call (for example,
salesSchema.empsInDept("SALES") ). |
protected Expression |
getTarget(Expression connectionExp)
|
TypeFactory |
getTypeFactory()
Returns the type factory used to generate types for
this schema. |
void |
registerRules(Planner planner)
Registers all of the rules supported by this schema. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private final Class clazz
private final boolean ignoreCase
Constructor Detail |
public ClassSchema(Class clazz, boolean ignoreCase)
Method Detail |
public TypeFactory getTypeFactory()
Schema
type factory
used to generate types for
this schema.
getTypeFactory
in interface Schema
public Table getTableForMember(String name)
Schema
Table
based upon a member access.
For example, the Saffron expression salesSchema.emps
would be resolved using a call to
salesSchema.getTableForMember(typeFactory, "emps")
.
getTableForMember
in interface Schema
private Field findField(String name)
protected Expression getTarget(Expression connectionExp)
public Table getTableForMethodCall(MethodCall call)
Schema
Table
based upon a method call (for example,
salesSchema.empsInDept("SALES")
).
getTableForMethodCall
in interface Schema
public void registerRules(Planner planner) throws Exception
Schema
Planner.registerSchema(saffron.Schema)
.
registerRules
in interface Schema
Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |