net.rim.device.api.system
Class MemoryStats

java.lang.Object
  extended by net.rim.vm.MemStats
      extended by net.rim.device.api.system.MemoryStats

public final class MemoryStats
extends MemStats

Class used to provide utility methods for reporting on available device memory/storage statistics.

Note that the precise behaviour of each of these methods varies with the type of memory/storage the object has been created to report upon. Typcailly, an application uses the static methods provided by the Memory class to retrieve a MemStats object appropriate for a particular purpose.


Constructor Summary
MemoryStats()
          Constructs a new MemoryStats object.
 
Method Summary
 int getAllocated()
          Returns the amount of memory/storage already allocated.
 int getFree()
          Returns the amount of memory/storage still free and available for use.
 int getObjectCount()
          Returns the number of objects occupying memory/storage type.
 int getObjectSize()
          Returns the total size of objects occupying memory/storage type.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 



Constructor Detail

MemoryStats

public MemoryStats()
Constructs a new MemoryStats object.



Method Detail

getAllocated

public int getAllocated()
Returns the amount of memory/storage already allocated.

Overrides:
getAllocated in class MemStats
Returns:
Amount of memory/storage already allocated.

getFree

public int getFree()
Returns the amount of memory/storage still free and available for use.

Overrides:
getFree in class MemStats
Returns:
Amount of memory/stroage free.

getObjectSize

public int getObjectSize()
Returns the total size of objects occupying memory/storage type.

Overrides:
getObjectSize in class MemStats
Returns:
Total size of objects occupying memory/storage type.

getObjectCount

public int getObjectCount()
Returns the number of objects occupying memory/storage type.

Overrides:
getObjectCount in class MemStats
Returns:
Number of objects occupying memory/storage type.





Copyright 1999-2010 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Copyright 1993-2003 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A. All Rights Reserved.
Copyright 2002-2003 Nokia Corporation All Rights Reserved.
Java is a trademark of Sun Microsystems, Inc.