com.sun.mfwk.cib.sdk.states
Class CIBOperationalStatusStateImpl

java.lang.Object
  extended bycom.sun.mfwk.cib.sdk.states.CIBOperationalStatusStateImpl
All Implemented Interfaces:
CIBOperationalStatusState, CIBProvider, CIBState
Direct Known Subclasses:
CIBApplicationOperationalStatusImpl, CIBExternalResourceOperationalStatusImpl, CIBResourceOperationalStatusImpl, CIBServiceOperationalStatusImpl

public class CIBOperationalStatusStateImpl
extends java.lang.Object
implements CIBOperationalStatusState

Provides a default implementation for a CIBOperationalStatusState object. This implementation is fully based on the Java-ES MF Instrumentation SDK.


Field Summary
 
Fields inherited from interface com.sun.mfwk.cib.states.CIBOperationalStatusState
FAILED, RUNNING, STARTING, STOPPED, STOPPING
 
Constructor Summary
CIBOperationalStatusStateImpl(javax.management.MBeanServerConnection connection, java.util.Map map)
          Constructor
 
Method Summary
 void destroy()
          destroy the statistics and clean the statistics objects/values when needed, close all the communications.
 long getLastChange()
          Get the LastChange time of the operationla status object
 long getStartTime()
          getUpTime
 int getState()
          getState
 void init()
          Initialize the statistics mechanism.
 void start()
          Start the statistics collections and clean the statistics objects/values when needed, close all the communications.
 void stop()
          Stop the statistics collections and clean the statistics objects/values when needed, close all the communications.
 java.lang.String toStateString()
          getStateString
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CIBOperationalStatusStateImpl

public CIBOperationalStatusStateImpl(javax.management.MBeanServerConnection connection,
                                     java.util.Map map)
Constructor

Parameters:
connection - MBeanServerConnection
map - Map
Method Detail

getLastChange

public long getLastChange()
Get the LastChange time of the operationla status object

Specified by:
getLastChange in interface CIBState
Returns:
long

getState

public int getState()
getState

Specified by:
getState in interface CIBState
Returns:
int

toStateString

public java.lang.String toStateString()
                               throws CIBIOException,
                                      CIBAttributeNotFoundException
getStateString

Specified by:
toStateString in interface CIBState
Returns:
String
Throws:
CIBAttributeNotFoundException
CIBIOException

getStartTime

public long getStartTime()
getUpTime

Specified by:
getStartTime in interface CIBOperationalStatusState
Returns:
long

init

public void init()
          throws CIBIOException,
                 CIBException
Initialize the statistics mechanism. In particular, initialize the communication to the instrumentation layer.

Specified by:
init in interface CIBProvider
Throws:
CIBIOException
CIBException

destroy

public void destroy()
             throws CIBIOException,
                    CIBException
destroy the statistics and clean the statistics objects/values when needed, close all the communications.

Specified by:
destroy in interface CIBProvider
Throws:
CIBIOException
CIBException

start

public void start()
Start the statistics collections and clean the statistics objects/values when needed, close all the communications.


stop

public void stop()
Stop the statistics collections and clean the statistics objects/values when needed, close all the communications.


toString

public java.lang.String toString()