org.teatrove.tea.parsetree
Class ImportDirective

java.lang.Object
  extended by org.teatrove.tea.parsetree.Node
      extended by org.teatrove.tea.parsetree.Directive
          extended by org.teatrove.tea.parsetree.ImportDirective
All Implemented Interfaces:
Serializable, Cloneable

public class ImportDirective
extends Directive

An import directive allows for a shorthand name qualifier for type names

Author:
Guy Molinari
See Also:
Serialized Form

Constructor Summary
ImportDirective(SourceInfo info, String name)
          Used for variable declarations.
 
Method Summary
 Object accept(NodeVisitor visitor)
          Every subclass of Node must override this method with the following: return visitor.visit(this).
 Object clone()
          Returns a clone of this Node and all its children.
 boolean equals(Object other)
          ImportDirectives are tested for equality only by their name and type.
 String getName()
           
 int hashCode()
           
 void setName(String name)
           
 
Methods inherited from class org.teatrove.tea.parsetree.Node
getSourceInfo, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ImportDirective

public ImportDirective(SourceInfo info,
                       String name)
Used for variable declarations.

Method Detail

accept

public Object accept(NodeVisitor visitor)
Description copied from class: Node
Every subclass of Node must override this method with the following: return visitor.visit(this).

Specified by:
accept in class Directive
Parameters:
visitor - A visitor of this Node
Returns:
Node The Node returned by the visitor
See Also:
NodeVisitor

getName

public String getName()

setName

public void setName(String name)

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object other)
ImportDirectives are tested for equality only by their name and type. Field status is ignored.

Overrides:
equals in class Object

clone

public Object clone()
Description copied from class: Node
Returns a clone of this Node and all its children. Immutable child objects are not necessarily cloned

Overrides:
clone in class Node


Copyright © 1997-2012 TeaTrove.org. All Rights Reserved.