jef.dna.attributes
Interface LineNumberTableAttribute

All Superinterfaces:
Attribute, BytesCountable, java.lang.Cloneable
All Known Implementing Classes:
LineNumberTableAttribute

public interface LineNumberTableAttribute
extends Attribute

Class representing a Line Number Table Attribute. The LineNumberTable attribute is an optional variable-length attribute in the attributes table of a Code attribute. It may be used by debuggers to determine which part of the Java virtual machine code array corresponds to a given line number in the original source file. If LineNumberTable attributes are present in the attributes table of a given Code attribute, then they may appear in any order. Furthermore, multiple LineNumberTable attributes may together represent a given line of a source file; that is, LineNumberTable attributes need not be one-to-one with source lines.

Author:
Francesco Russo frusso@cs.unibo.it

Method Summary
 CodeAttribute getAttributeContainer()
          Get the CodeAttrbute which contains the current LineNumberTableAttribute.
 java.util.List<LineNumberTableEntry> getLineNumberTable()
          Each entry in the line_number_table array indicates that the line number in the original source file changes at a given point in the code array.
 int getLineNumberTableLength()
          This method tells how many entries are stored inside the current line number table.
 void setAttributeContainer(CodeAttribute attr)
          Set the CodeAttrbute which contains the current LineNumberTableAttribute.
 
Methods inherited from interface jef.dna.attributes.Attribute
clone, fromStream, getDna, getLength, getNameIndex, setDna, setNameIndex, toStream, updateRefs, validate
 
Methods inherited from interface jef.dna.util.BytesCountable
getBytesCount
 

Method Detail

getLineNumberTableLength

int getLineNumberTableLength()
This method tells how many entries are stored inside the current line number table.

Returns:
int The dimension of the line number table

getLineNumberTable

java.util.List<LineNumberTableEntry> getLineNumberTable()
Each entry in the line_number_table array indicates that the line number in the original source file changes at a given point in the code array. The line number table is shaped as a List containing LineNumberTableAttribute instances.

Returns:
List The line number table

setAttributeContainer

void setAttributeContainer(CodeAttribute attr)
Set the CodeAttrbute which contains the current LineNumberTableAttribute.

Parameters:
attr - The container

getAttributeContainer

CodeAttribute getAttributeContainer()
Get the CodeAttrbute which contains the current LineNumberTableAttribute.

Returns:
CodeAttribute The container