com.metamatrix.query.optimizer.relational.rules
Class RuleAssignOutputElements

java.lang.Object
  extended by com.metamatrix.query.optimizer.relational.rules.RuleAssignOutputElements
All Implemented Interfaces:
OptimizerRule

public final class RuleAssignOutputElements
extends java.lang.Object
implements OptimizerRule

This rule is responsible for assigning the output elements to every node in the plan. The output elements define the columns that are returned from every node. This is generally done by figuring out top-down all the elements required to execute the operation at each node and making sure those elements are selected from the children nodes.


Constructor Summary
RuleAssignOutputElements()
           
 
Method Summary
 PlanNode execute(PlanNode plan, QueryMetadataInterface metadata, CapabilitiesFinder capFinder, RuleStack rules, AnalysisRecord analysisRecord, CommandContext context)
          Execute the rule.
 java.lang.String toString()
          Get name of the rule
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RuleAssignOutputElements

public RuleAssignOutputElements()
Method Detail

execute

public PlanNode execute(PlanNode plan,
                        QueryMetadataInterface metadata,
                        CapabilitiesFinder capFinder,
                        RuleStack rules,
                        AnalysisRecord analysisRecord,
                        CommandContext context)
                 throws QueryPlannerException,
                        QueryMetadataException,
                        MetaMatrixComponentException
Execute the rule. This rule is executed exactly once during every planning call. The plan is modified in place - only properties are manipulated, structure is unchanged.

Specified by:
execute in interface OptimizerRule
Parameters:
plan - The plan to execute rule on
metadata - The metadata interface
rules - The rule stack, not modified
Returns:
The updated plan
Throws:
QueryPlannerException
QueryMetadataException
MetaMatrixComponentException

toString

public java.lang.String toString()
Get name of the rule

Overrides:
toString in class java.lang.Object
Returns:
Name of the rule


Copyright © 2009. All Rights Reserved.