All Packages This Package Class Hierarchy Class Search Index
java.lang.Object | +----Refable | +----utah.npm.core.MemPool
Summary |
public final class MemPool extends Refable { // Constructors 2 public MemPool(long, Reference, Reference, Reference); public MemPool(long, Reference, Reference, Reference, int); // Methods 4 public void destroy(); public long getAvailable(); public long getSize(); public String toString(); }
MemPool objects encapsulate management of a chunk of memory.
TODO: protocol for destroying mempool and reclaiming what memory we can, and giving that memory back to the parent pool...
Constructors |
· MemPool | Summary | Top |
public MemPool(long size, Reference pPoolRef, Reference spaceRef, Reference keeperPortRef)
Create a MemPool of the requested size. The MemPool is associated with the given space, and gets its memory from the given parent MemPool. The KeeperPort is used to send requests for more memory and out of memory messages.
Parameter Description size the requested initial size. Use the getSize() method to determine the size actually granted. pPoolRef a Reference to the parent pool to allocate the space out of. spaceRef a Reference to the space to associate this pool with. keeperPortRef a Port Reference to which out of memory messages will be sent.
· MemPool | Summary | Top |
public MemPool(long size, Reference pPoolRef, Reference spaceRef, Reference keeperPortRef, int hashCode)
Same as the previous constructor with the addition of the hashCode specification.
Methods |
· getSize | Summary | Top |
public long getSize()
Get the total size in bytes of this MemPool.
- Returns:
- the total size in bytes of the MemPool.
· getAvailable | Summary | Top |
public long getAvailable()
Get the available number of bytes in this MemPool. This number is approximate as Garbage collection and the action of other threads can change the amount.
- Returns:
- the available number of byte in this MemPool.
See Also: getWatermark
· destroy | Summary | Top |
public void destroy()
Destroy this mempool.
· toString | Summary | Top |
public String toString()
All Packages This Package Class Hierarchy Class Search IndexFreshly brewed Java API Documentation automatically generated with polardoc Version 1.0.7