java.lang.Object
com.ibm.dtfj.phd.parser.Base
com.ibm.dtfj.phd.parser.HeapdumpReader
This class parses a PHD format heapdump file. To use it, first create the object
  (see 
HeapdumpReader(java.lang.String)) passing the file name and then parse it (see parse(com.ibm.dtfj.phd.parser.PortableHeapDumpListener))
  passing it an object that obeys the PortableHeapDumpListener interface.- 
Constructor SummaryConstructorsModifierConstructorDescriptionHeapdumpReader(File file, PHDImage image) Create a new HeapdumpReader object from the given file.protectedHeapdumpReader(String filename) Create a new HeapdumpReader object from the given file.protectedHeapdumpReader(ImageInputStream stream) Create a new HeapdumpReader object from the given stream.HeapdumpReader(ImageInputStream stream, PHDImage image) 
- 
Method SummaryModifier and TypeMethodDescriptionbooleanReturns true all objects in this heap dump will have hashcodes set, regardless of the flags on the record.voidclose()voidReturns the full version for the JVM that created this heapdump.booleanis64Bit()Returns true if this is a 64-bit heap dump.booleanisJ9()Returns true if this is a J9 heap dump.static voidThis method just prints out the following info from the header: is64Bit phd version full version total objects total refsbooleanparse(PortableHeapDumpListener listener) Parse the heapdump.voidintReturns the total number of objects in the dump.intReturns the total number of references in the dump.intversion()Returns the Phd version number.
- 
Constructor Details- 
HeapdumpReaderCreate a new HeapdumpReader object from the given file. The file must be in Phd format. Image must be supplied to allow us to clean up streams when it is closed.- Throws:
- IOException
 
- 
HeapdumpReader- Throws:
- IOException
 
- 
HeapdumpReaderCreate a new HeapdumpReader object from the given stream. The file must be in Phd format.- Throws:
- IOException
 
- 
HeapdumpReaderCreate a new HeapdumpReader object from the given file. The file must be in Phd format.- Throws:
- IOException
 
 
- 
- 
Method Details- 
full_versionReturns the full version for the JVM that created this heapdump.
- 
versionpublic int version()Returns the Phd version number. Recognized values are 4 and 5.
- 
is64Bitpublic boolean is64Bit()Returns true if this is a 64-bit heap dump.
- 
isJ9public boolean isJ9()Returns true if this is a J9 heap dump.
- 
allObjectsHashedpublic boolean allObjectsHashed()Returns true all objects in this heap dump will have hashcodes set, regardless of the flags on the record.
- 
totalObjectspublic int totalObjects()Returns the total number of objects in the dump.
- 
totalRefspublic int totalRefs()Returns the total number of references in the dump.
- 
exitParsepublic void exitParse()
- 
parseParse the heapdump. This uses callbacks via the PortableHeapDumpListener interface. Any exceptions that the listener raises are propagated back.- Returns:
- true if there is more data to parse
- Throws:
- Exception
 
- 
closepublic void close()
- 
releaseResourcespublic void releaseResources()
- 
mainThis method just prints out the following info from the header:- is64Bit
- phd version
- full version
- total objects
- total refs
 - Throws:
- IOException
 
 
-