de.uniulm.sai.util
Class CpuTime

java.lang.Object
  extended byde.uniulm.sai.util.CpuTime

public class CpuTime
extends java.lang.Object

This class makes it possible to access the user and the system time of the current process (not thread!). These times are summed over all processes and also include time consumed by the JVM (e.g. for garbage collection).

Version:
0.9, 2005-12-20
Author:
Johannes Mayer

Method Summary
static double getSystemTime()
          Returns the system time of the current process in seconds.
static double getTotalTime()
          Returns the sum of the user and system times of the current process in seconds.
static double getUserTime()
          Returns the user time of the current process in seconds.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getUserTime

public static double getUserTime()
Returns the user time of the current process in seconds.

Returns:
the user time of the current process in seconds.

getSystemTime

public static double getSystemTime()
Returns the system time of the current process in seconds.

Returns:
the system time of the current process in seconds.

getTotalTime

public static double getTotalTime()
Returns the sum of the user and system times of the current process in seconds.

Returns:
the sum of the user and system times of the current process in seconds.