org.eclipse.mat.inspections
Class ReferenceQuery

java.lang.Object
  extended by org.eclipse.mat.inspections.ReferenceQuery
All Implemented Interfaces:
IQuery

public class ReferenceQuery
extends java.lang.Object
implements IQuery

Extract information about objects extending java.lang.ref.Reference, e.g. weak and soft references, and Finalizer.


Field Summary
 IHeapObjectArgument objects
           
 java.lang.String referent_attribute
           
 ISnapshot snapshot
           
 
Constructor Summary
ReferenceQuery()
           
 
Method Summary
static CompositeResult execute(ArrayInt instanceSet, SetInt referentSet, ISnapshot snapshot, java.lang.String labelHistogramReferenced, java.lang.String labelHistogramRetained, java.lang.String labelHistogramStronglyRetainedReferents, IProgressListener listener)
           
static CompositeResult execute(ArrayInt instanceSet, SetInt referentSet, ISnapshot snapshot, java.lang.String labelHistogramReferenced, java.lang.String labelHistogramRetained, java.lang.String labelHistogramStronglyRetainedReferents, java.lang.String referentField, IProgressListener listener)
           
 IResult execute(IProgressListener listener)
          The execute method is called after all arguments have been injected into the query instance.
static IResult execute(java.lang.String className, ISnapshot snapshot, java.lang.String labelHistogramReferenced, java.lang.String labelHistogramRetained, java.lang.String labelHistogramStronglyRetainedReferents, IProgressListener listener)
          Important: the className must point to java.lang.ref.Reference or one of its subclasses.
static ObjectReference getReferent(IInstance instance)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

snapshot

public ISnapshot snapshot

objects

public IHeapObjectArgument objects

referent_attribute

public java.lang.String referent_attribute
Constructor Detail

ReferenceQuery

public ReferenceQuery()
Method Detail

execute

public IResult execute(IProgressListener listener)
                throws java.lang.Exception
Description copied from interface: IQuery
The execute method is called after all arguments have been injected into the query instance. Typical results are TextResult, CompositeResult, SectionSpec etc.

Specified by:
execute in interface IQuery
Parameters:
listener - Monitor to report progress and check for cancellation.
Returns:
The result of the query.
Throws:
java.lang.Exception

execute

public static IResult execute(java.lang.String className,
                              ISnapshot snapshot,
                              java.lang.String labelHistogramReferenced,
                              java.lang.String labelHistogramRetained,
                              java.lang.String labelHistogramStronglyRetainedReferents,
                              IProgressListener listener)
                       throws SnapshotException
Important: the className must point to java.lang.ref.Reference or one of its subclasses. It is not possible to check this, as some heap dumps lack class hierarchy information.

Throws:
SnapshotException

execute

public static CompositeResult execute(ArrayInt instanceSet,
                                      SetInt referentSet,
                                      ISnapshot snapshot,
                                      java.lang.String labelHistogramReferenced,
                                      java.lang.String labelHistogramRetained,
                                      java.lang.String labelHistogramStronglyRetainedReferents,
                                      IProgressListener listener)
                               throws SnapshotException
Throws:
SnapshotException

execute

public static CompositeResult execute(ArrayInt instanceSet,
                                      SetInt referentSet,
                                      ISnapshot snapshot,
                                      java.lang.String labelHistogramReferenced,
                                      java.lang.String labelHistogramRetained,
                                      java.lang.String labelHistogramStronglyRetainedReferents,
                                      java.lang.String referentField,
                                      IProgressListener listener)
                               throws SnapshotException
Throws:
SnapshotException

getReferent

public static ObjectReference getReferent(IInstance instance)
                                   throws SnapshotException
Throws:
SnapshotException