public class LineNumberTable extends Object implements Code.BytecodeMapAttribute
| Modifier and Type | Class and Description |
|---|---|
static class |
LineNumberTable.Entry |
BytecodeAttribute.Fn, BytecodeAttribute.Reader, BytecodeAttribute.Unknown| Constructor and Description |
|---|
LineNumberTable(Collection<LineNumberTable.Entry> entries) |
| Modifier and Type | Method and Description |
|---|---|
void |
addPoolItems(Set<Constant.Info> constantPool)
When this method is called, the attribute must add all items that it
needs to the constant pool.
|
void |
apply(List<Code.Rewrite> rewrites)
This method accepts a list of rewrites which should be applied.
|
List<LineNumberTable.Entry> |
entries() |
String |
name() |
void |
print(PrintWriter output,
Map<Constant.Info,Integer> constantPool)
This method is used to print the contents of the attribute in
human-readable form, similar to that produced by "javap".
|
void |
write(BinaryOutputStream writer,
Map<Constant.Info,Integer> constantPool)
This method requires the attribute to write itself to the binary stream.
|
void |
write(int[] bytecodeOffsets,
BinaryOutputStream writer,
Map<Constant.Info,Integer> constantPool)
This method requires the attribute to write itself to the binary
stream.
|
public LineNumberTable(Collection<LineNumberTable.Entry> entries)
public void apply(List<Code.Rewrite> rewrites)
Code.BytecodeMapAttributeapply in interface Code.BytecodeMapAttributepublic List<LineNumberTable.Entry> entries()
public String name()
name in interface BytecodeAttributepublic void write(BinaryOutputStream writer, Map<Constant.Info,Integer> constantPool) throws IOException
BytecodeAttributewrite in interface BytecodeAttributewriter - Outputstream to which the attribute should be written.constantPool - Map of CONSTANT_info items to their index in the constant pool.IOExceptionpublic void write(int[] bytecodeOffsets,
BinaryOutputStream writer,
Map<Constant.Info,Integer> constantPool)
throws IOException
Code.BytecodeMapAttributewrite in interface Code.BytecodeMapAttributebytecodeOffsets - --- maps each bytecode index to its actual offset in the
code block.writer - --- stream to write attribute toconstantPool - --- map of constant pool items to their actual pool indexIOExceptionpublic void addPoolItems(Set<Constant.Info> constantPool)
BytecodeAttributeaddPoolItems in interface BytecodeAttributepublic void print(PrintWriter output, Map<Constant.Info,Integer> constantPool) throws IOException
BytecodeAttributeprint in interface BytecodeAttributeoutput - Output writer to which the attribute is printed.constantPool - Map of CONSTANT_info items to their index in the constant
pool.IOExceptionCopyright © 2016. All rights reserved.