Rio Project 4.2 API Documentation



org.rioproject.system.measurable.cpu
Class ProcessCpuUtilization

java.lang.Object
  extended by org.rioproject.system.MeasuredResource
      extended by org.rioproject.system.measurable.cpu.ProcessCpuUtilization
All Implemented Interfaces:
Serializable

public class ProcessCpuUtilization
extends MeasuredResource
implements Serializable

Measured process CPU utilization

See Also:
Serialized Form

Constructor Summary
ProcessCpuUtilization(String identifier, double totalPercentage, long system, long user, ThresholdValues tVals)
          Construct a ProcessCpuUtilization with parameters
ProcessCpuUtilization(String identifier, double totalPercentage, ThresholdValues tVals)
          Construct a ProcessCpuUtilization with parameters
 
Method Summary
 double getSystem()
          Get the cpu kernel usage for the process
 double getTotal()
          Get the cpu utilization
 double getTotalPercentage()
          Get the cpu utilization percentage
 double getUser()
          Get the cpu user usage
 
Methods inherited from class org.rioproject.system.MeasuredResource
equals, evaluate, getIdentifier, getThresholdValues, getValue, hashCode, thresholdCrossed, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ProcessCpuUtilization

public ProcessCpuUtilization(String identifier,
                             double totalPercentage,
                             ThresholdValues tVals)
Construct a ProcessCpuUtilization with parameters

Parameters:
identifier - Identifier for the ProcessCpuUtilization
totalPercentage - The total system cpu utilization percentage
tVals - ThresholdValues for the ProcessCpuUtilization

ProcessCpuUtilization

public ProcessCpuUtilization(String identifier,
                             double totalPercentage,
                             long system,
                             long user,
                             ThresholdValues tVals)
Construct a ProcessCpuUtilization with parameters

Parameters:
identifier - Identifier for the ProcessCpuUtilization
totalPercentage - The total system cpu utilization percentage
system - The cpu kernel usage
user - The cpu user usage
tVals - ThresholdValues for the ProcessCpuUtilization
Method Detail

getSystem

public double getSystem()
Get the cpu kernel usage for the process

Returns:
The cpu kernel usage for the process; or -1 if not available.

getUser

public double getUser()
Get the cpu user usage

Returns:
The cpu user usage for the process; or -1 if not available.

getTotal

public double getTotal()
Get the cpu utilization

Returns:
The cpu utilization for the process; or -1 if not available.

getTotalPercentage

public double getTotalPercentage()
Get the cpu utilization percentage

Returns:
The cpu utilization percentage for the process; or -1 if not available.

Copyright © Rio Project.

Copyright © 2006-2011 Rio Project. All Rights Reserved.