PageBoxLib
Class LinuxUsageProbe

java.lang.Object
  extended byPageBoxLib.LinuxUsageProbe
All Implemented Interfaces:
UsageIF

class LinuxUsageProbe
extends java.lang.Object
implements UsageIF

Returns resource data on Linux. Returns a UsageIF object.

alexis.grandemange@pagebox.net

Copyright (c) 2002-2004 Alexis Grandemange

This program is free software; you can redistribute it and/or
 modify it under the terms of the GNU Lesser General Public License
 as published by the Free Software Foundation; version 2.1 of the
 License.
 This library is distributed in the hope that it will be useful,
 but WITHOUT ANY WARRANTY; without even the implied warranty of
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 GNU Lesser General Public License for more details.
 A copy of the GNU Lesser General Public License lesser.txt should be
 included in the distribution.

Version:
0, 0, 13
Author:
Alexis Grandemange

Field Summary
(package private)  boolean first
          true at first call of collect.
(package private)  int idleJiffies
          number of jiffies (1/100ths of a second) in idle process
(package private)  Log log
          Logging object
(package private)  int systemJiffies
          number of jiffies (1/100ths of a second) in system mode
(package private)  long time
          Last measurement time
(package private)  int userJiffies
          number of jiffies (1/100ths of a second) in user mode
(package private)  int userLowJiffies
          number of jiffies (1/100ths of a second) in user low (nice) mode
 
Constructor Summary
(package private) LinuxUsageProbe(Log log)
          Constructor.
 
Method Summary
 ResourceUsage collect()
          Get resource usage information.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

userJiffies

int userJiffies
number of jiffies (1/100ths of a second) in user mode


userLowJiffies

int userLowJiffies
number of jiffies (1/100ths of a second) in user low (nice) mode


systemJiffies

int systemJiffies
number of jiffies (1/100ths of a second) in system mode


idleJiffies

int idleJiffies
number of jiffies (1/100ths of a second) in idle process


time

long time
Last measurement time


first

boolean first
true at first call of collect. Then measure is not valid.


log

Log log
Logging object

Constructor Detail

LinuxUsageProbe

LinuxUsageProbe(Log log)
Constructor.

Parameters:
log - logging object
Method Detail

collect

public ResourceUsage collect()
Get resource usage information. From UsageIF.

Specified by:
collect in interface UsageIF
Returns:
ResourceUsage object