// D = filter C by y > 0;
// The plan is built with the filter having been pushed above the join
// but the listners not yet having been called.
// A = load
lp = new LogicalPlan();
LogicalSchema aschema = new LogicalSchema();
aschema.addField(new LogicalSchema.LogicalFieldSchema(
"x", null, DataType.INTEGER));
aschema.getField(0).uid = 1;
LOLoad A = new LOLoad(null, null, lp, null);
A.neverUseForRealSetSchema(aschema);
lp.add(A);
// B = load
LogicalSchema bschema = new LogicalSchema();
bschema.addField(new LogicalSchema.LogicalFieldSchema(
"y", null, DataType.INTEGER));
bschema.getField(0).uid = 2;
LOLoad B = new LOLoad(null, null, lp, null);
B.neverUseForRealSetSchema(bschema);
lp.add(B);
// C = join
LogicalSchema cschema = new LogicalSchema();
cschema.addField(new LogicalSchema.LogicalFieldSchema(
"x", null, DataType.INTEGER));
cschema.addField(new LogicalSchema.LogicalFieldSchema(
"y", null, DataType.INTEGER));
cschema.getField(0).uid = 1;
cschema.getField(1).uid = 2;
MultiMap<Integer, LogicalExpressionPlan> mm =
new MultiMap<Integer, LogicalExpressionPlan>();
LOJoin C = new LOJoin(lp, mm, JOINTYPE.HASH, new boolean[] {true, true});