com.tivoli.jmx.daemon
Class Daemon

java.lang.Object
  |
  +--com.tivoli.jmx.daemon.Daemon

public class Daemon
extends java.lang.Object
implements DaemonMBean

Represents the daemon process which launches the agent. Used to obtain information on the controlling process, which is most commonly an NT Service or unix daemon, and the host environment.

Version:
1.2
Author:
Alessio Menale

Constructor Summary
Daemon(java.lang.String version, int processID)
          Constructor.
 
Method Summary
 java.lang.String gethostName()
          Returns the name of the host machine.
 java.lang.String getipAddress()
          Returns the IP Address of the host machine.
 int getprocessID()
          Returns the process id (pid) of the controlling process
 java.lang.String getstartTime()
          Returns the time the daemon process was started, as a String date.
 java.lang.String getupTime()
          Returns the length of time the process the process has been running for, as a String formatted time (ie.
 java.lang.String getversion()
          Returns the version number of the daemon executable.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Daemon

public Daemon(java.lang.String version,
              int processID)
       throws java.net.UnknownHostException
Constructor. Sets the startime of the daemon and the host IP address.
Parameters:
version - String version number of the daemon executable
processID - the process id (pid) of the daemon executable.
Throws:
java.net.UnknownHostException - in the case that the local host of the Java Virtual Machine cannot be determined.
Method Detail

gethostName

public java.lang.String gethostName()
Returns the name of the host machine.
Specified by:
gethostName in interface DaemonMBean

getipAddress

public java.lang.String getipAddress()
Returns the IP Address of the host machine.
Specified by:
getipAddress in interface DaemonMBean

getversion

public java.lang.String getversion()
Returns the version number of the daemon executable.
Specified by:
getversion in interface DaemonMBean

getprocessID

public int getprocessID()
Returns the process id (pid) of the controlling process
Specified by:
getprocessID in interface DaemonMBean

getstartTime

public java.lang.String getstartTime()
Returns the time the daemon process was started, as a String date.
Specified by:
getstartTime in interface DaemonMBean

getupTime

public java.lang.String getupTime()
Returns the length of time the process the process has been running for, as a String formatted time (ie. d:h:m:s)
Specified by:
getupTime in interface DaemonMBean