public class IpedXinstr extends java.lang.Object implements Instruction
IPED( XINSTR )
IPED
a pre-specified array of
instructions.Modifier and Type | Field and Description |
---|---|
protected @NotNull java.util.List<Instruction> |
instructions
The instructions to be executed.
|
protected @Nullable Tree |
tree
The tree from where this instruction was declared.
|
Constructor and Description |
---|
IpedXinstr(Instruction... instructions)
Construct a new instruction that executes the given
instructions in order
in IPED style. |
IpedXinstr(@NotNull java.util.List<Instruction> instructions)
Construct a new instruction that executes the given
instructions in order
in a IPED style. |
IpedXinstr(@NotNull Tree tree,
Instruction... instructions)
Construct a new instruction that executes the given
instructions in order
in a IPED style. |
IpedXinstr(@NotNull Tree tree,
@NotNull java.util.List<Instruction> instructions)
Construct a new instruction that executes the given
instructions in order
in a IPED style. |
Modifier and Type | Method and Description |
---|---|
void |
exec(@NotNull Environment environment,
@NotNull Memory memory)
Execute this instruction with the given
environment and memory . |
@Nullable Tree |
getTree()
Return the tree from where this instruction was declared.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
create, create
@NotNull protected final @NotNull java.util.List<Instruction> instructions
@Nullable protected final @Nullable Tree tree
public IpedXinstr(@Nullable Instruction... instructions)
instructions
in order
in IPED
style.
instructions
- the instructions to be executed.java.lang.NullPointerException
- if the given instructions
is null.public IpedXinstr(@NotNull @NotNull java.util.List<Instruction> instructions)
instructions
in order
in a IPED
style.
instructions
- the instructions to be executed.java.lang.NullPointerException
- if the given instructions
is null.public IpedXinstr(@NotNull @NotNull Tree tree, @Nullable Instruction... instructions)
instructions
in order
in a IPED
style.
tree
- the tree from where this instruction was declared.instructions
- the instructions to be executed.java.lang.NullPointerException
- if the given tree
or instructions
is
null.public IpedXinstr(@NotNull @NotNull Tree tree, @NotNull @NotNull java.util.List<Instruction> instructions)
instructions
in order
in a IPED
style.
tree
- the tree from where this instruction was declared.instructions
- the instructions to be executed.java.lang.NullPointerException
- if the given tree
or instructions
is
null.public void exec(@NotNull @NotNull Environment environment, @NotNull @NotNull Memory memory)
Instruction
environment
and memory
.exec
in interface Instruction
environment
- the environment this instruction is executed in.memory
- the memory holding the variables for this instruction to depend
on.@Nullable public @Nullable Tree getTree()
Instruction
getTree
in interface Instruction