Interface LineNumberTableAttribute
- All Superinterfaces:
Attribute<LineNumberTableAttribute>,ClassFileElement
Models the
LineNumberTable attribute (JVMS 4.7.12), which can appear
on a Code attribute, and records the mapping between indexes into
the code table and line numbers in the source file.
Delivered as a LineNumber when traversing the
elements of a CodeModel, according to the setting of the
ClassFile.LineNumbersOption option.
The attribute permits multiple instances in a given location.
- Since:
- 24
-
Method Summary
Modifier and TypeMethodDescriptionReturns the table mapping bytecode offsets to source line numbers.static LineNumberTableAttributeof(List<LineNumberInfo> lines) Returns aLineNumberTableattribute.Methods declared in interface java.lang.classfile.Attribute
attributeMapper, attributeName
-
Method Details
-
lineNumbers
List<LineNumberInfo> lineNumbers()Returns the table mapping bytecode offsets to source line numbers.- Returns:
- the table mapping bytecode offsets to source line numbers
-
of
Returns aLineNumberTableattribute.- Parameters:
lines- the line number descriptions- Returns:
- a
LineNumberTableattribute
-