Interface SizeFunction<T>


public interface SizeFunction<T>
An interface for computing (typically approximate) size of a specific kind of object.
Author:
Evren Sirin
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    sizeOf(T obj)
    Returns the (approximate) number of bytes an object uses in memory.
  • Method Details

    • sizeOf

      int sizeOf(T obj)
      Returns the (approximate) number of bytes an object uses in memory. The objects references via an object's fields may or may not be included in the result. Different implementations may choose different strategies for deciding what parts will be included in the result.