Example usage for Java org.apache.lucene.util RamUsageEstimator fields, constructors, methods, implement or subclass
The text is from its open source code.
int | NUM_BYTES_OBJECT_REF Number of bytes this JVM uses to represent an object reference. |
int | NUM_BYTES_OBJECT_HEADER Number of bytes to represent an object header (no fields, no alignments). |
int | NUM_BYTES_ARRAY_HEADER Number of bytes to represent an array header (no content, but with alignments). |
RamUsageEstimator() No instantiation. |
String | humanReadableUnits(long bytes) Returns size in human-readable units (GB, MB, KB or bytes). |
long | shallowSizeOf(Object[] arr) Returns the shallow size in bytes of the Object[] object. |
long | shallowSizeOf(Object obj) Estimates a "shallow" memory usage of the given object. |
long | sizeOf(Long value) Return the size of the provided Long object, returning 0 if it is cached by the JVM and its shallow size otherwise. |
long | sizeOf(byte[] arr) Returns the size in bytes of the byte[] object. |
long | sizeOf(boolean[] arr) Returns the size in bytes of the boolean[] object. |
long | sizeOf(char[] arr) Returns the size in bytes of the char[] object. |
long | sizeOf(short[] arr) Returns the size in bytes of the short[] object. |
long | sizeOf(int[] arr) Returns the size in bytes of the int[] object. |
long | sizeOf(float[] arr) Returns the size in bytes of the float[] object. |
long | sizeOf(long[] arr) Returns the size in bytes of the long[] object. |
long | sizeOf(double[] arr) Returns the size in bytes of the double[] object. |
long | sizeOf(String[] arr) Returns the size in bytes of the String[] object. |
long | sizeOf(Query q) Returns the size in bytes of a Query object. |
long | sizeOf(Accountable accountable) Returns the size in bytes of the Accountable object, using its Accountable#ramBytesUsed() method. |
long | sizeOf(String s) Returns the size in bytes of the String object. |
long | sizeOf(Accountable[] accountables) Return the size of the provided array of Accountable s by summing up the shallow size of the array and the Accountable#ramBytesUsed() memory usage reported by each Accountable . |