Interface LineNumberTableAttribute

All Superinterfaces:
Attribute<LineNumberTableAttribute>, ClassfileElement, WritableElement<LineNumberTableAttribute>
All Known Implementing Classes:
BoundAttribute.BoundLineNumberTableAttribute, UnboundAttribute.UnboundLineNumberTableAttribute

Models the LineNumberTable attribute , 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.Option.processLineNumbers(boolean) option.
  • 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 a LineNumberTable attribute.
      Parameters:
      lines - the line number descriptions
      Returns:
      a LineNumberTable attribute