Package org.mozilla.javascript.ast
Class Symbol
- java.lang.Object
- 
- org.mozilla.javascript.ast.Symbol
 
- 
 public class Symbol extends java.lang.ObjectRepresents a symbol-table entry.
- 
- 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description ScopegetContainingTable()Returns the Scope in which this symbol is enteredintgetDeclType()Returns symbol declaration typejava.lang.StringgetDeclTypeName()intgetIndex()Returns symbol's index in its scopejava.lang.StringgetName()Returns symbol nameNodegetNode()Returns the node associated with this identifiervoidsetContainingTable(Scope containingTable)Sets this symbol's ScopevoidsetDeclType(int declType)Sets symbol declaration typevoidsetIndex(int index)Sets symbol's index in its scopevoidsetName(java.lang.String name)Sets symbol namevoidsetNode(Node node)Sets the node associated with this identifierjava.lang.StringtoString()
 
- 
- 
- 
Constructor Detail- 
Symbolpublic Symbol() 
 - 
Symbolpublic Symbol(int declType, java.lang.String name)Constructs a new Symbol with a specific name and declaration type- Parameters:
- declType-- Token.FUNCTION,- Token.LP(for params),- Token.VAR,- Token.LETor- Token.CONST
 
 
- 
 - 
Method Detail- 
getDeclTypepublic int getDeclType() Returns symbol declaration type
 - 
setDeclTypepublic void setDeclType(int declType) Sets symbol declaration type
 - 
getNamepublic java.lang.String getName() Returns symbol name
 - 
setNamepublic void setName(java.lang.String name) Sets symbol name
 - 
getNodepublic Node getNode() Returns the node associated with this identifier
 - 
getIndexpublic int getIndex() Returns symbol's index in its scope
 - 
setIndexpublic void setIndex(int index) Sets symbol's index in its scope
 - 
setNodepublic void setNode(Node node) Sets the node associated with this identifier
 - 
getContainingTablepublic Scope getContainingTable() Returns the Scope in which this symbol is entered
 - 
setContainingTablepublic void setContainingTable(Scope containingTable) Sets this symbol's Scope
 - 
getDeclTypeNamepublic java.lang.String getDeclTypeName() 
 - 
toStringpublic java.lang.String toString() - Overrides:
- toStringin class- java.lang.Object
 
 
- 
 
-