public abstract class SizeOf extends Object
| Constructor and Description |
|---|
SizeOf(SizeOfFilter fieldFilter,
boolean caching,
boolean bypassFlyweight)
Builds a new SizeOf that will filter fields according to the provided filter
|
| Modifier and Type | Method and Description |
|---|---|
long |
deepSizeOf(Object... obj) |
long |
deepSizeOf(VisitorListener listener,
Object... obj)
Measures the size in memory (heap) of the objects passed in, walking their graph down
Any overlap of the graphs being passed in will be recognized and only measured once
|
static SizeOf |
newInstance(boolean bypassFlyweight,
boolean cache,
SizeOfFilter... filters) |
static SizeOf |
newInstance(SizeOfFilter... filters) |
abstract long |
sizeOf(Object obj)
Calculates the size in memory (heap) of the instance passed in, not navigating the down graph
|
public SizeOf(SizeOfFilter fieldFilter, boolean caching, boolean bypassFlyweight)
fieldFilter - The filter to applycaching - whether to cache reflected fieldsbypassFlyweight - whether "Flyweight Objects" are to be ignoredSizeOfFilterpublic abstract long sizeOf(Object obj)
obj - the object to measure the size ofpublic long deepSizeOf(VisitorListener listener, Object... obj)
listener - A listener to visited objectsobj - the root objects of the graphs to measuresizeOf(Object)public long deepSizeOf(Object... obj)
public static SizeOf newInstance(SizeOfFilter... filters)
public static SizeOf newInstance(boolean bypassFlyweight, boolean cache, SizeOfFilter... filters)
Copyright © 2024 Terracotta. All rights reserved.