Class MemoryUsageInformation

java.lang.Object
org.jppf.management.diagnostics.MemoryUsageInformation
All Implemented Interfaces:
Serializable

public class MemoryUsageInformation extends Object implements Serializable
A Serializable implementation of MemoryUsage.
Author:
Laurent Cohen
See Also:
  • Constructor Details

    • MemoryUsageInformation

      public MemoryUsageInformation(MemoryUsage memUsage)
      Initialize this object from a MemoryUsage instance.
      Parameters:
      memUsage - contains the memroy usage information to use.
  • Method Details

    • getInit

      public long getInit()
      Get the initial memory size.
      Returns:
      the initial memory size.
    • getCommitted

      public long getCommitted()
      Get the current memory size.
      Returns:
      the current memory size.
    • getUsed

      public long getUsed()
      Get the used memory size.
      Returns:
      the used memory size.
    • getMax

      public long getMax()
      Get the maximum memory size.
      Returns:
      the maximum memory size.
    • getUsedRatio

      public double getUsedRatio()
      Return the ratio of used memory over maximum available memory.
      Returns:
      the ratio as a double value in the range [0, 1], or -1 if the maximum memory information is not available.
    • toString

      public String toString()
      Overrides:
      toString in class Object