public class SizeOf extends Object
Modifier and Type | Class and Description |
---|---|
static interface |
SizeOf.ObjectCreator
For use with constructors which require arguments.
|
Constructor and Description |
---|
SizeOf() |
Modifier and Type | Method and Description |
---|---|
static long |
getMemoryUse() |
static void |
main(String[] args)
Display the approximate size (in bytes) of the class given in the
first argument.
|
static long |
sizeof(Class cls)
Return the approximate size in bytes of an instance of the given
class.
|
static long |
sizeof(SizeOf.ObjectCreator oc)
Return the approximate size in bytes of the object returned by the
given ObjectCreator.
|
public static long getMemoryUse()
public static long sizeof(SizeOf.ObjectCreator oc)
public static long sizeof(Class cls)
public static void main(String[] args)
Abbot is hosted on