Class HprofHeapObjectReader

    • Field Detail

      • VERSION_PROPERTY

        public static final java.lang.String VERSION_PROPERTY
        See Also:
        Constant Field Values
      • HPROF_LENGTH_PROPERTY

        public static final java.lang.String HPROF_LENGTH_PROPERTY
        See Also:
        Constant Field Values
      • HPROF_HEAP_START

        public static final java.lang.String HPROF_HEAP_START
        See Also:
        Constant Field Values
    • Constructor Detail

      • HprofHeapObjectReader

        public HprofHeapObjectReader()
    • Method Detail

      • open

        public void open​(ISnapshot snapshot)
                  throws java.io.IOException
        Description copied from interface: IObjectReader
        Open the dump file associated with the snapshot
        Specified by:
        open in interface IObjectReader
        Parameters:
        snapshot - the snapshot
        Throws:
        java.io.IOException - an IO problem, or corrupt indexes or unexpected data in the dump
      • readObjectArrayContent

        public long[] readObjectArrayContent​(ObjectArrayImpl array,
                                             int offset,
                                             int length)
                                      throws java.io.IOException,
                                             SnapshotException
        Description copied from interface: IObjectReader
        Get detailed information about a object array
        Specified by:
        readObjectArrayContent in interface IObjectReader
        Parameters:
        array - the array
        offset - where in the array to start
        length - how much to read
        Returns:
        an array of object addresses, with 0 for nulls
        Throws:
        java.io.IOException - an IO problem or unexpected data in the dump
        SnapshotException - some other problem such as where the object is incompatible with the snapshot
      • readPrimitiveArrayContent

        public java.lang.Object readPrimitiveArrayContent​(PrimitiveArrayImpl array,
                                                          int offset,
                                                          int length)
                                                   throws java.io.IOException,
                                                          SnapshotException
        Description copied from interface: IObjectReader
        Get detailed information about a primitive array
        Specified by:
        readPrimitiveArrayContent in interface IObjectReader
        Parameters:
        array - the array
        offset - where in the array to start
        length - how much to read
        Returns:
        a byte[], short[], int[], long[], boolean[], char[], float[], double[]
        Throws:
        java.io.IOException - an IO problem or unexpected data in the dump
        SnapshotException - some other problem such as where the object is incompatible with the snapshot
      • close

        public void close()
                   throws java.io.IOException
        Description copied from interface: IObjectReader
        tidy up when snapshot no longer required
        Specified by:
        close in interface IObjectReader
        Throws:
        java.io.IOException - should not normally occur