public final class TypeDeclaration extends DeclarationBase
Constructor and Description |
---|
TypeDeclaration(TypeDeclIdentifier name,
Type type)
construct type declaration with denoted name and type.
|
Modifier and Type | Method and Description |
---|---|
AST |
accept(ASTVisitor visitor)
Accept visitor for a visit.
|
Identifier |
getIdentifier()
returns declaration name
|
Symbol |
getSymbol()
returns symbol
|
Type |
getType()
returns declaration type
|
TypeDeclIdentifier |
getTypeDeclIdentifier()
returns declaration name
|
TypeDeclaration |
instantiate()
create instantiated copy of declaration
|
void |
printCore(java.io.PrintWriter out)
Prints text representation of tree on out (without new line termination).
|
print
printParens, toString
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
printParens, toString
public TypeDeclaration(TypeDeclIdentifier name, Type type)
name
- the declared nametype
- the type associated to the name (may be null)public TypeDeclIdentifier getTypeDeclIdentifier()
public Identifier getIdentifier()
public Type getType()
public TypeDeclaration instantiate()
public void printCore(java.io.PrintWriter out)
public Symbol getSymbol()
public AST accept(ASTVisitor visitor)
visitor
- the visitor who is accepted by this node.