org.ogf.graap.wsag.server.monitoring
Interface IMonitoringContext

All Known Implementing Classes:
MonitoringContext

public interface IMonitoringContext

IMonitoringContext The monitoring context holds the current service term states of the monitoring process. It is used by the @see ServiceTermStateMonitor to update the service term states, and by the @see AgreementMonitor to retrieve the actual service term states.

Author:
Oliver Waeldrich

Field Summary
static String WSAG4J_AGREEMENT_EXECUTION_CONTEXT
          Key to look up the IAgreementContext from the transient monitoring properties.
 
Method Summary
 void addMonitoringHandler(IServiceTermMonitoringHandler handler)
          Adds a service term monitoring handler to this context.
 void addServiceTemState(ServiceTermStateType state)
          Adds the given service term state for monitoring to the context.
 void addServiceTemState(String name)
          Adds a new service term state with the given name for monitoring to the context.
 Object clone()
          Creates and returns a copy of this object.
 IAccountingSystem getAccountingSystem()
          Retrieves the accounting system that is used with this monitoring context.
 IServiceTermMonitoringHandler[] getMonitoringHandler()
          Gets all service term monitoring handler for this context.
 Map<String,org.apache.xmlbeans.XmlObject> getProperties()
           
 ServiceTermStateType getServiceTermStateByName(String name)
          Retrieves a ServiceTermState identified by the given name.
 ServiceTermStateType[] getServiceTermStates()
          Retrieves all ServiceTermStates monitored in this context.
 Map<String,Object> getTransientProperties()
           
 void removeMonitoringHandler(IServiceTermMonitoringHandler handler)
          Removes a service term monitoring handler from this context.
 void setAccountingSystem(IAccountingSystem system)
          Sets the accounting system that is used with this monitoring context.
 void setMonitoringHandler(IServiceTermMonitoringHandler[] handler)
          Sets the service term monitoring handler for this context.
 void setProperties(Map<String,org.apache.xmlbeans.XmlObject> properties)
           
 void setServiceTemState(ServiceTermStateType[] states)
          Adds the given service term state for monitoring to the context.
 void setTransientProperties(Map<String,Object> properties)
           
 

Field Detail

WSAG4J_AGREEMENT_EXECUTION_CONTEXT

static final String WSAG4J_AGREEMENT_EXECUTION_CONTEXT
Key to look up the IAgreementContext from the transient monitoring properties.

See Also:
getTransientProperties(), Constant Field Values
Method Detail

getProperties

Map<String,org.apache.xmlbeans.XmlObject> getProperties()
Returns:
the properties defined for this monitoring context

setProperties

void setProperties(Map<String,org.apache.xmlbeans.XmlObject> properties)
Parameters:
properties - the monitoring properties to set

getTransientProperties

Map<String,Object> getTransientProperties()
Returns:
the transient properties defined for this monitoring context

setTransientProperties

void setTransientProperties(Map<String,Object> properties)
Parameters:
properties - the monitoring transient properties to set

addServiceTemState

void addServiceTemState(ServiceTermStateType state)
Adds the given service term state for monitoring to the context.

Parameters:
state - the state to add

addServiceTemState

void addServiceTemState(String name)
Adds a new service term state with the given name for monitoring to the context.

Parameters:
name - the name of the service term state

getServiceTermStates

ServiceTermStateType[] getServiceTermStates()
Retrieves all ServiceTermStates monitored in this context.

Returns:
an array of ServiceTermStates monitored in this context

getServiceTermStateByName

ServiceTermStateType getServiceTermStateByName(String name)
Retrieves a ServiceTermState identified by the given name.

Parameters:
name - the name of the ServiceTerm
Returns:
the state of the ServiceTerm

setServiceTemState

void setServiceTemState(ServiceTermStateType[] states)
Adds the given service term state for monitoring to the context.

Parameters:
states - the state array to set

addMonitoringHandler

void addMonitoringHandler(IServiceTermMonitoringHandler handler)
Adds a service term monitoring handler to this context.

Parameters:
handler - the handler to add

setMonitoringHandler

void setMonitoringHandler(IServiceTermMonitoringHandler[] handler)
Sets the service term monitoring handler for this context.

Parameters:
handler - the handlers to set

removeMonitoringHandler

void removeMonitoringHandler(IServiceTermMonitoringHandler handler)
Removes a service term monitoring handler from this context.

Parameters:
handler - the handler to remove

getMonitoringHandler

IServiceTermMonitoringHandler[] getMonitoringHandler()
Gets all service term monitoring handler for this context.

Returns:
the service term monitoring handler for this context

clone

Object clone()
             throws CloneNotSupportedException
Creates and returns a copy of this object.

Returns:
a coned copy of this instance
Throws:
CloneNotSupportedException - indicates that the implementation does not support cloning

setAccountingSystem

void setAccountingSystem(IAccountingSystem system)
Sets the accounting system that is used with this monitoring context.

Parameters:
system - the accounting system to set

getAccountingSystem

IAccountingSystem getAccountingSystem()
Retrieves the accounting system that is used with this monitoring context.

Returns:
the registered accounting systems


Copyright © 2008-2012. All Rights Reserved.