Class DWARFSourceInfo


  • public class DWARFSourceInfo
    extends java.lang.Object
    Small class to hold the filename and line number info values from DWARF DIEs.
    • Method Detail

      • getSourceInfoWithFallbackToParent

        public static DWARFSourceInfo getSourceInfoWithFallbackToParent​(DIEAggregate diea)
        Creates a new DWARFSourceInfo instance from the supplied DIEAggregate, falling back to the parent containing DIE record if the first record did not have any source info.
        Parameters:
        diea - DIEAggregate to query for source info.
        Returns:
        new DWARFSourceInfo with filename:linenum info, or null if no info present in the specified DIEA and its parent.
      • getFilename

        public java.lang.String getFilename()
        Returns the filename
        Returns:
        string filename.
      • getDescriptionStr

        public java.lang.String getDescriptionStr()
        Returns the source location info as a string formatted as "filename:linenum"
        Returns:
        "filename:linenum"
      • getDescriptionStr2

        public java.lang.String getDescriptionStr2()
        Returns the source location info as a string formatted as "File: filename Line: linenum"
        Returns:
        "File: filename Line: linenum"
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object