org.eclipse.mat.hprof
Class HprofParserHandlerImpl

java.lang.Object
  extended by org.eclipse.mat.hprof.HprofParserHandlerImpl
All Implemented Interfaces:
IHprofParserHandler

public class HprofParserHandlerImpl
extends java.lang.Object
implements IHprofParserHandler


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.eclipse.mat.hprof.IHprofParserHandler
IHprofParserHandler.HeapObject
 
Field Summary
 
Fields inherited from interface org.eclipse.mat.hprof.IHprofParserHandler
CREATION_DATE, IDENTIFIER_SIZE, REFERENCE_SIZE, VERSION
 
Constructor Summary
HprofParserHandlerImpl()
           
 
Method Summary
 void addClass(ClassImpl clazz, long filePosition)
           
 void addGCRoot(long id, long referrer, int rootType)
           
 void addObject(IHprofParserHandler.HeapObject object, long filePosition)
           
 void addProperty(java.lang.String name, java.lang.String value)
           
 void beforePass1(XSnapshotInfo snapshotInfo)
           
 void beforePass2(IProgressListener monitor)
           
 void cancel()
           
 IIndexReader.IOne2LongIndex fillIn(IPreliminaryIndex index)
           
 HashMapLongObject<java.lang.String> getConstantPool()
           
 int getIdentifierSize()
           
 long getObjectArrayHeapSize(ClassImpl arrayType, int size)
           
 long getPrimitiveArrayHeapSize(byte elementType, int size)
           
 XSnapshotInfo getSnapshotInfo()
           
 ClassImpl lookupClass(long classId)
           
 IClass lookupClassByIndex(int objIndex)
           
 IClass lookupClassByName(java.lang.String name, boolean failOnMultipleInstances)
           
 int mapAddressToId(long address)
           
 void reportInstance(long id, long filePosition)
           
 void reportRequiredObjectArray(long arrayClassID)
           
 void reportRequiredPrimitiveArray(int arrayType)
           
 java.util.List<IClass> resolveClassHierarchy(long classId)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HprofParserHandlerImpl

public HprofParserHandlerImpl()
Method Detail

beforePass1

public void beforePass1(XSnapshotInfo snapshotInfo)
                 throws java.io.IOException
Specified by:
beforePass1 in interface IHprofParserHandler
Throws:
java.io.IOException

beforePass2

public void beforePass2(IProgressListener monitor)
                 throws java.io.IOException,
                        SnapshotException
Specified by:
beforePass2 in interface IHprofParserHandler
Throws:
java.io.IOException
SnapshotException

fillIn

public IIndexReader.IOne2LongIndex fillIn(IPreliminaryIndex index)
                                   throws java.io.IOException
Specified by:
fillIn in interface IHprofParserHandler
Throws:
java.io.IOException

cancel

public void cancel()
Specified by:
cancel in interface IHprofParserHandler

addProperty

public void addProperty(java.lang.String name,
                        java.lang.String value)
                 throws java.io.IOException
Specified by:
addProperty in interface IHprofParserHandler
Throws:
java.io.IOException

addGCRoot

public void addGCRoot(long id,
                      long referrer,
                      int rootType)
Specified by:
addGCRoot in interface IHprofParserHandler

addClass

public void addClass(ClassImpl clazz,
                     long filePosition)
              throws java.io.IOException
Specified by:
addClass in interface IHprofParserHandler
Throws:
java.io.IOException

addObject

public void addObject(IHprofParserHandler.HeapObject object,
                      long filePosition)
               throws java.io.IOException
Specified by:
addObject in interface IHprofParserHandler
Throws:
java.io.IOException

reportInstance

public void reportInstance(long id,
                           long filePosition)
Specified by:
reportInstance in interface IHprofParserHandler

reportRequiredObjectArray

public void reportRequiredObjectArray(long arrayClassID)
Specified by:
reportRequiredObjectArray in interface IHprofParserHandler

reportRequiredPrimitiveArray

public void reportRequiredPrimitiveArray(int arrayType)
Specified by:
reportRequiredPrimitiveArray in interface IHprofParserHandler

getIdentifierSize

public int getIdentifierSize()
Specified by:
getIdentifierSize in interface IHprofParserHandler

getConstantPool

public HashMapLongObject<java.lang.String> getConstantPool()
Specified by:
getConstantPool in interface IHprofParserHandler

lookupClass

public ClassImpl lookupClass(long classId)
Specified by:
lookupClass in interface IHprofParserHandler

lookupClassByName

public IClass lookupClassByName(java.lang.String name,
                                boolean failOnMultipleInstances)
Specified by:
lookupClassByName in interface IHprofParserHandler

lookupClassByIndex

public IClass lookupClassByIndex(int objIndex)
Specified by:
lookupClassByIndex in interface IHprofParserHandler

resolveClassHierarchy

public java.util.List<IClass> resolveClassHierarchy(long classId)
Specified by:
resolveClassHierarchy in interface IHprofParserHandler

mapAddressToId

public int mapAddressToId(long address)
Specified by:
mapAddressToId in interface IHprofParserHandler

getSnapshotInfo

public XSnapshotInfo getSnapshotInfo()
Specified by:
getSnapshotInfo in interface IHprofParserHandler

getObjectArrayHeapSize

public long getObjectArrayHeapSize(ClassImpl arrayType,
                                   int size)
Specified by:
getObjectArrayHeapSize in interface IHprofParserHandler

getPrimitiveArrayHeapSize

public long getPrimitiveArrayHeapSize(byte elementType,
                                      int size)
Specified by:
getPrimitiveArrayHeapSize in interface IHprofParserHandler