symbolHandling
Class IntSymbol
java.lang.Object
symbolHandling.AbstractSymbol
symbolHandling.IntSymbol
public class IntSymbol
- extends AbstractSymbol
String table entry for integer constants
- See Also:
AbstractSymbol
Constructor Summary |
IntSymbol(java.lang.String str,
int len,
int index)
|
Method Summary |
java.lang.Object |
clone()
Returns a copy of this symbol |
void |
codeDef(int intclasstag,
java.io.PrintWriter s)
Generates code for the integer constant definition. |
void |
codeRef(java.io.PrintWriter s)
Emits a reference to this integer constant. |
Methods inherited from class java.lang.Object |
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
IntSymbol
public IntSymbol(java.lang.String str,
int len,
int index)
codeDef
public void codeDef(int intclasstag,
java.io.PrintWriter s)
- Generates code for the integer constant definition. This method is
incomplete; you get to finish it up in programming assignment 5.
- Parameters:
intclasstag
- the class tag for string objects
- the output stream
codeRef
public void codeRef(java.io.PrintWriter s)
- Emits a reference to this integer constant.
- Parameters:
s
- the output stream
clone
public java.lang.Object clone()
- Returns a copy of this symbol
- Specified by:
clone
in class AbstractSymbol