FileDocCategorySizeDatePackage
FromNode.javaAPI DocGlassfish v2 API3594Tue May 22 16:54:38 BST 2007oracle.toplink.essentials.internal.parsing

FromNode

public class FromNode extends MajorNode
INTERNAL

Purpose: Represent a FROM

Responsibilities:

  • Determines the context for the Parse Tree
  • Determine the reference class for a query
  • Handle any FROM ... IN clauses
author
Jon Driscoll
since
TopLink 5.0

Fields Summary
private List
declarations
Constructors Summary
Methods Summary
public java.util.ListgetDeclarations()

        return declarations;
    
public java.lang.StringgetFirstVariable()

        String variable = null;
        if ((declarations != null) && (declarations.size() > 0)) {
            variable = ((IdentificationVariableDeclNode)declarations.get(0)).getCanonicalVariableName();
        }
        return variable;
    
public oracle.toplink.essentials.internal.parsing.NodequalifyAttributeAccess(oracle.toplink.essentials.internal.parsing.ParseTreeContext context)
INTERNAL Check the declaration nodes for a path expression starting with a unqualified field access and if so, replace it by a qualified field access.

        for (int i = 0; i < declarations.size(); i++) {
            Node decl = (Node)declarations.get(i);
            declarations.set(i, decl.qualifyAttributeAccess(context));
        }
        return this;
    
public voidsetDeclarations(java.util.List decls)

        declarations = decls;
    
public voidvalidate(oracle.toplink.essentials.internal.parsing.ParseTreeContext context)
INTERNAL Validate the current node.

        for (Iterator i = declarations.iterator(); i.hasNext();) {
            Node decl = (Node)i.next();
            decl.validate(context);
        }