Skip to content
🤔 Documentation issue? Report it

Core: Hprof

shark-hprof / shark

Package shark

Types

Name Summary
GcRoot sealed class GcRoot
A GcRoot as identified by HprofRecord.HeapDumpRecord.GcRootRecord in the heap dump.
Hprof class Hprof :Closeable
An opened Hprof file which can be read via reader. Open a new hprof with open, and don’t forget to call close once done.
HprofPrimitiveArrayStripper class HprofPrimitiveArrayStripper
Converts a Hprof file to another file with all primitive arrays replaced with arrays of zeroes, which can be useful to remove PII. Char arrays are handled slightly differently because 0 would be the null character so instead these become arrays of ‘?’.
HprofReader class HprofReader
Reads hprof content from an Okio BufferedSource.
HprofRecord sealed class HprofRecord
A Hprof record. These data structure map 1:1 with how records are written in hprof files.
HprofWriter class HprofWriter :Closeable
Generates Hprof files.
OnHprofRecordListener interface OnHprofRecordListener
Listener passed in to HprofReader.readHprofRecords, gets notified for each HprofRecord found in the heap dump which types is in the set of the recordTypes parameter passed to HprofReader.readHprofRecords.
PrimitiveType enum class PrimitiveType
A primitive type in the prof.
ValueHolder sealed class ValueHolder
A value in the heap dump, which can be a ReferenceHolder or a primitive type.