Interface ICollectionExtractor
- All Known Subinterfaces:
IMapExtractor
- All Known Implementing Classes:
ArrayCollectionExtractor
,ArrayListSubListCollectionExtractor
,ConcurrentHashMapCollectionExtractor
,ConcurrentSkipListCollectionExtractor
,ConcurrentSkipListSetCollectionExtractor
,EmptyCollectionExtractor
,EmptyMapExtractor
,FieldArrayCollectionExtractor
,FieldSizeArrayCollectionExtractor
,FieldSizeArrayMapExtractor
,FieldSizedCapacityCollectionExtractor
,FieldSizedCapacityMapExtractor
,FieldSizedCollectionExtractor
,HashedMapCollectionExtractorBase
,HashMapCollectionExtractor
,HashSetCollectionExtractor
,IBM6ArrayListCollectionExtractor
,IdentityHashMapCollectionExtractor
,KeySetCollectionExtractor
,LinkedListCollectionExtractor
,MapCollectionExtractorBase
,MATArrayBig
,MATCollectionExtractor
,NoContentCollectionExtractor
,Pair12CollectionExtractor
,PairCollectionExtractor
,RegularEnumSetExtractor
,ReplicatedValueCollectionExtractor
,SetFromCollectionExtractor
,SingletonCollectionExtractor
,SingletonMapExtractor
,TreeMapArrayCollectionExtractor
,TreeMapCollectionExtractor
,TreeSetArrayCollectionExtractor
,TreeSetCollectionExtractor
,ValuesCollectionExtractor
,WrapperCollectionExtractor
,WrapperFieldCollectionExtractor
,WrapperFieldMapExtractor
,WrapperMapExtractor
,WrapperSetFromMapExtractor
public interface ICollectionExtractor
CollectionExtractors are used to extract from the heap dump the contents of
an object which represents a collection of a certain type. It knows the
internal details of how the collection contents are stored and if the
collection has certain properties or not
- Since:
- 1.5
-
Method Summary
Modifier and TypeMethodDescriptionextractEntries
(IObject collection) Extracts the array containing the collection contentint[]
extractEntryIds
(IObject collection) Returns the object ids (int) for all objects which are contained in the collectiongetCapacity
(IObject collection) Return the capacity of the collection, if applicablegetFillRatio
(IObject collection) Calculate the fill ratio of a collectiongetNumberOfNotNullElements
(IObject collection) Returns the number of non-null elements in the collection.Extract the size of the collection.boolean
Check if the collection has capacity, e.g.boolean
Return true if the collection array based and the array can be extracted from the heap dumpboolean
Check if the collection has extractable contentsboolean
Check if fill ratio for the collection can be calculated, i.e.boolean
hasSize()
Check if the size of the collection can be extracted.
-
Method Details
-
hasSize
boolean hasSize()Check if the size of the collection can be extracted.- Returns:
- true if
getSize(IObject)
could be called - See Also:
-
getSize
Extract the size of the collection.- Parameters:
collection
- - the collection to find the size of- Returns:
- the size, or null if not available
- Throws:
SnapshotException
- if there is a problem retrieving data from the snapshot- See Also:
-
hasCapacity
boolean hasCapacity()Check if the collection has capacity, e.g. ArrayList- Returns:
- true if
getCapacity(IObject)
could be called - See Also:
-
getCapacity
Return the capacity of the collection, if applicable- Parameters:
collection
- - the collection to find the capacity of- Returns:
- the capacity in bytes, or null if unavailable
- Throws:
SnapshotException
- if there is a problem retrieving data from the snapshot- See Also:
-
hasFillRatio
boolean hasFillRatio()Check if fill ratio for the collection can be calculated, i.e. if it has some predefined capacity and actual size.- Returns:
- true if
getFillRatio(IObject)
could be called - See Also:
-
getFillRatio
Calculate the fill ratio of a collection- Parameters:
collection
- - the collection to find the fill ratio of- Returns:
- the fill ratio, between 0.0 and 1.0, or null if unavailable
- Throws:
SnapshotException
- if there is a problem retrieving data from the snapshot- See Also:
-
hasExtractableContents
boolean hasExtractableContents()Check if the collection has extractable contents- Returns:
- true if
extractEntryIds(IObject)
could be called - See Also:
-
extractEntryIds
Returns the object ids (int) for all objects which are contained in the collection- Parameters:
collection
- - the collection to find the objects it holds- Returns:
- an array of ints which are the object ids.
- Throws:
SnapshotException
- if there is a problem retrieving data from the snapshot- See Also:
-
hasExtractableArray
boolean hasExtractableArray()Return true if the collection array based and the array can be extracted from the heap dump- Returns:
- true if
extractEntries(IObject)
could be called - See Also:
-
extractEntries
Extracts the array containing the collection content- Parameters:
collection
- - the collection to find the object array holding its contents- Returns:
- the backing array for the collection
- Throws:
SnapshotException
- if there is a problem retrieving data from the snapshot- See Also:
-
getNumberOfNotNullElements
Returns the number of non-null elements in the collection. Requires hasExtractableContents or hasExtractableArray- Parameters:
collection
- - the collection to find the number of non-null content objects- Returns:
- the number of non-null elements, or null if not available
- Throws:
SnapshotException
- See Also:
-