|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--uk.ac.man.cs.rainbow.simulator.RASMList
A list of RASM instructions. This is designed for use as an output format for a compiler so that blocks of code do not need to be generated in order.
Instruction
,
RASMCode
, Serialized FormConstructor Summary | |
RASMList()
|
Method Summary | |
RASMList |
append(Instruction instr)
Append an instruction to the list. |
RASMList |
append(RASMList list)
Append another list to the list. |
Object |
clone()
Clone the list. |
RASMCode |
makeAndLinkCode(String name,
Hashtable library)
Create a code block from this list of instructions. |
RASMList |
placeLabelHere(String label)
Place a label at this point. |
RASMList |
pushLabelReference(String label)
Push a reference to the given label. |
void |
spoolToCode(RASMCode code)
Write the list into a block of code. |
String |
toString()
Produce a displayable version. |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public RASMList()
Method Detail |
public RASMList append(Instruction instr)
instr
- The instruction to append.public RASMList append(RASMList list)
list
- The list of instructions to append to this list.public RASMList placeLabelHere(String label)
label
- The label to place at this point. The label should be a local
label.RASMCode.Label
,
RASMCode.MODULE_SEPARATOR
public RASMList pushLabelReference(String label)
label
- The label to place at this point. The label can be a local
or a global label.RASMCode.Label
,
RASMCode.MODULE_SEPARATOR
,
RASM.Push
public void spoolToCode(RASMCode code)
code
- The block of code to write into.public Object clone()
clone
in class Object
public RASMCode makeAndLinkCode(String name, Hashtable library) throws RASMCode.Exception
name
- The name of the block of code to create.library
- The library context (for linking external references in the code.)RASMCode.Exception
- If linking fails for some reason.public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |