public class IdentityHashMapCollectionExtractor extends FieldSizeArrayCollectionExtractor implements IMapExtractor
IMapExtractor.EntryObject
Constructor and Description |
---|
IdentityHashMapCollectionExtractor(String sizeField,
String arrayField) |
Modifier and Type | Method and Description |
---|---|
int[] |
extractEntryIds(IObject idMap)
Returns the object ids (int) for all objects which are contained in the
collection
|
Iterator<Map.Entry<IObject,IObject>> |
extractMapEntries(IObject coll)
Extracts the contents of a map (i.e.
|
Integer |
getCapacity(IObject collection)
Gets the capacity of the map.
|
Double |
getCollisionRatio(IObject coll)
Calculates the collision ratio in the collection
|
Double |
getFillRatio(IObject coll)
Calculate the fill ration of a collection
|
Integer |
getNumberOfNotNullElements(IObject coll)
Returns the number of non-null elements in the collection.
|
Integer |
getSize(IObject coll)
Extract the size of the collection
|
boolean |
hasCollisionRatio()
Can't calculate the collision ratio as we don't have the identityHashCode for the keys,
even if we did know the hash algorithm.
|
boolean |
hasExtractableArray()
Return true if the collection array based and the array can be extracted
from the heap dump
|
boolean |
hasExtractableContents()
Check if the collection has extractable contents
|
hasSize
extractEntries, hasCapacity, hasFillRatio
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
extractEntries, hasCapacity, hasFillRatio, hasSize
public Integer getCapacity(IObject collection) throws SnapshotException
getCapacity
in interface ICollectionExtractor
getCapacity
in class FieldArrayCollectionExtractor
SnapshotException
public boolean hasExtractableArray()
ICollectionExtractor
hasExtractableArray
in interface ICollectionExtractor
hasExtractableArray
in class FieldArrayCollectionExtractor
public boolean hasExtractableContents()
ICollectionExtractor
hasExtractableContents
in interface ICollectionExtractor
hasExtractableContents
in class FieldArrayCollectionExtractor
public Integer getSize(IObject coll) throws SnapshotException
ICollectionExtractor
getSize
in interface ICollectionExtractor
getSize
in class FieldSizeArrayCollectionExtractor
SnapshotException
public int[] extractEntryIds(IObject idMap) throws SnapshotException
ICollectionExtractor
extractEntryIds
in interface ICollectionExtractor
extractEntryIds
in class FieldArrayCollectionExtractor
SnapshotException
public boolean hasCollisionRatio()
hasCollisionRatio
in interface IMapExtractor
public Double getCollisionRatio(IObject coll) throws SnapshotException
IMapExtractor
getCollisionRatio
in interface IMapExtractor
SnapshotException
public Double getFillRatio(IObject coll) throws SnapshotException
ICollectionExtractor
getFillRatio
in interface ICollectionExtractor
getFillRatio
in class FieldArrayCollectionExtractor
SnapshotException
public Integer getNumberOfNotNullElements(IObject coll) throws SnapshotException
ICollectionExtractor
getNumberOfNotNullElements
in interface ICollectionExtractor
getNumberOfNotNullElements
in class FieldArrayCollectionExtractor
SnapshotException
public Iterator<Map.Entry<IObject,IObject>> extractMapEntries(IObject coll) throws SnapshotException
IMapExtractor
extractMapEntries
in interface IMapExtractor
coll
- - the map to extract contents fromSnapshotException