public class ImmediateShortInstruction extends AbstractInstruction
Constructor and Description |
---|
ImmediateShortInstruction(Opcode opcode)
Constructor.
|
ImmediateShortInstruction(Opcode opcode,
int immediateShort)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
int |
getImmediateShort()
Get the immediate unsigned short of this instruction.
|
int |
getSize()
Get the size in bytes of this instruction.
|
void |
read(ByteCodeInput in)
Read this instruction from the given ByteCodeInput.
|
void |
setImmediateShort(int immediateShort)
Set the immediate unsigned short of this instruction.
|
void |
write(ByteCodeOutput out)
Write this instruction to the given ByteCodeOutput.
|
getOffset, getOpcode, setOffset, setOpcode
public ImmediateShortInstruction(Opcode opcode)
opcode
- the opcode.public ImmediateShortInstruction(Opcode opcode, int immediateShort)
opcode
- the opcode.immediateShort
- the immediate short value.public int getSize()
AbstractInstruction
getSize
in class AbstractInstruction
public int getImmediateShort()
public void setImmediateShort(int immediateShort)
immediateShort
- the shortpublic void read(ByteCodeInput in) throws IOException
AbstractInstruction
Expects ByteCodeInput to be in JVM class file format and just before a instruction of this kind.
read
in class AbstractInstruction
in
- the ByteCodeInput from which to readIOException
- if an exception occurs with the ByteCodeInputpublic void write(ByteCodeOutput out) throws IOException
AbstractInstruction
write
in class AbstractInstruction
out
- the ByteCodeOutput to which to writeIOException
- if an exception occurs with the ByteCodeOutput