size property

int size

The size (in bytes) of this object on the heap.

If an object is not heap-allocated, this will be null.

Note that the size can be zero for some objects. In the current VM implementation, this occurs for small integers, which are stored entirely within their object pointers.


final int size;