-
- All Implemented Interfaces:
public abstract class PaddedInstruction extends Instruction
Base class for instructions which need a four byte padding relative to the start of the enclosing code of the parent Code attribute before reading immediate arguments.
-
-
Constructor Summary
Constructors Constructor Description PaddedInstruction(Opcode opcode)
-
Method Summary
Modifier and Type Method Description IntegergetPaddedSize(Integer offset)Get the padded size in bytes of this instruction. Unitread(ByteCodeInput input)Read this instruction from the given ByteCodeInput. Unitwrite(ByteCodeOutput output)Write this instruction to the given ByteCodeOutput. -
-
Constructor Detail
-
PaddedInstruction
PaddedInstruction(Opcode opcode)
-
-
Method Detail
-
getPaddedSize
Integer getPaddedSize(Integer offset)
Get the padded size in bytes of this instruction.
- Parameters:
offset- the offset at which this instruction is found.
-
read
Unit read(ByteCodeInput input)
Read this instruction from the given ByteCodeInput. Expects ByteCodeInput to be in JVM class file format and just before a instruction of this kind.
- Parameters:
input- the ByteCodeInput from which to read
-
write
Unit write(ByteCodeOutput output)
Write this instruction to the given ByteCodeOutput.
- Parameters:
output- the ByteCodeOutput to which to write
-
-
-
-