Package ghidra.app.util.bin.format.dwarf

# Class DWARFRangeList

java.lang.Object
ghidra.app.util.bin.format.dwarf.DWARFRangeList

public class DWARFRangeList extends Object
Represents a list of `DWARFRange`s.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final DWARFRangeList`
  `EMTPY`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `DWARFRangeList(DWARFRange singleRange)`
  `DWARFRangeList(List<DWARFRange> ranges)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `DWARFRange`
  `get(int index)`
  `DWARFRange`
  `getFirst()`
  `long`
  `getFirstAddress()`
  `DWARFRange`
  `getFlattenedRange()`
  `DWARFRange`
  `getLast()`
  `int`
  `getListCount()`
  `boolean`
  `isEmpty()`
  `List<DWARFRange>`
  `ranges()`
  `static DWARFRangeList`
  `readV4(BinaryReader reader, DWARFCompilationUnit cu)`
  Reads a v4 `DWARFRangeList` from the .debug_ranges stream.
  `static DWARFRangeList`
  `readV5(BinaryReader reader, DWARFCompilationUnit cu)`
  Reads a v5 `DWARFRangeList` from the .debug_rnglists stream.
  `String`
  `toString()`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Field Details

  - ### EMTPY

    public static final DWARFRangeList EMTPY

- ## Constructor Details

  - ### DWARFRangeList

    public DWARFRangeList(DWARFRange singleRange)

  - ### DWARFRangeList

    public DWARFRangeList(List<DWARFRange> ranges)

- ## Method Details

  - ### readV4

    public static DWARFRangeList readV4(BinaryReader reader, DWARFCompilationUnit cu) throws IOException
    Reads a v4 `DWARFRangeList` from the .debug_ranges stream.
    Parameters:
      `reader` - stream positioned to the start of a .debug_ranges range list
      `cu` - the compUnit referring to this range
    Returns:
      new `DWARFRangeList`, never null
    Throws:
      `IOException` - if error reading

  - ### readV5

    public static DWARFRangeList readV5(BinaryReader reader, DWARFCompilationUnit cu) throws IOException
    Reads a v5 `DWARFRangeList` from the .debug_rnglists stream.
    Parameters:
      `reader` - stream positioned to the start of a .debug_rnglists range list
      `cu` - the compUnit referring to this range
    Returns:
      new `DWARFRangeList`, never null
    Throws:
      `IOException` - if error reading

  - ### isEmpty

    public boolean isEmpty()

  - ### getFirstAddress

    public long getFirstAddress()

  - ### getFirst

    public DWARFRange getFirst()

  - ### get

    public DWARFRange get(int index)

  - ### ranges

    public List<DWARFRange> ranges()

  - ### getListCount

    public int getListCount()

  - ### getLast

    public DWARFRange getLast()

  - ### getFlattenedRange

    public DWARFRange getFlattenedRange()

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`