org.openoss.opennms.spring.qosd.spring
Class AlarmListConnectionManagerSpringImpl

java.lang.Object
  extended by org.openoss.opennms.spring.qosd.spring.AlarmListConnectionManagerSpringImpl
All Implemented Interfaces:
AlarmListConnectionManager

public class AlarmListConnectionManagerSpringImpl
extends Object
implements AlarmListConnectionManager

AlarmListConnectionManagerSpringImpl class.

Version:
$Id: $
Author:
openoss

Field Summary
 
Fields inherited from interface org.openoss.opennms.spring.qosd.AlarmListConnectionManager
CONNECTED, DISCONNECTED, REBUILD, SEND, SENT, STOP
 
Constructor Summary
AlarmListConnectionManagerSpringImpl()
          The AlarmListConnectionManagerSpringImpl instantiates the AlarmMonitorBean within OpenNMS without Jboss This is an alternative to contacting the bean in jboss.
 
Method Summary
 int getStatus()
          Getter for the field status.
 void init(PropertiesLoader props, Properties env)
          Initialises the ConnectionManagerThread
 void kill()
          kill
 javax.oss.fm.monitor.AlarmValue makeAlarmValue()
          Makes a new empty alarm value object NOTE THIS IS A PATCH to proxy for JVTAlarmMonitorSession.makeAlarmValue()
 javax.oss.fm.monitor.AlarmValue makeAlarmValueFromSpec()
          Makes a new alarm value object pre-populated with internal objects which have been made from a local invarient specification.
 void reset_list(String _rebuilt_message)
          this method resets the alarm list in the AlarmMonitorBean and causes an alarmlist rebuilt event to be sent.
 void run()
          run
 void send(Hashtable<AlarmKey,AlarmValue> alarmList)
          Sends the AlarmList to the AlarmMonitorBean
 void setAlarmMonitorDao(AlarmMonitorDao alarmMonitorDao)
          Setter for the field alarmMonitorDao.
 void setApplicationContext(org.springframework.context.support.ClassPathXmlApplicationContext m_context)
          Used by jmx mbean QoSD to pass in Spring Application context
 void start()
          start
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AlarmListConnectionManagerSpringImpl

public AlarmListConnectionManagerSpringImpl()
The AlarmListConnectionManagerSpringImpl instantiates the AlarmMonitorBean within OpenNMS without Jboss This is an alternative to contacting the bean in jboss. This only deals with XML alarms

Method Detail

setAlarmMonitorDao

public void setAlarmMonitorDao(AlarmMonitorDao alarmMonitorDao)

Setter for the field alarmMonitorDao.

Parameters:
alarmMonitorDao - the alarmMonitorDao to set

setApplicationContext

public void setApplicationContext(org.springframework.context.support.ClassPathXmlApplicationContext m_context)
Used by jmx mbean QoSD to pass in Spring Application context Used by jmx mbean QoSD to pass in Spring Application context

Specified by:
setApplicationContext in interface AlarmListConnectionManager
Parameters:
m_context - - application context for this bean to use

getStatus

public int getStatus()

Getter for the field status.

Specified by:
getStatus in interface AlarmListConnectionManager
Returns:
a int.

init

public void init(PropertiesLoader props,
                 Properties env)
Initialises the ConnectionManagerThread

Specified by:
init in interface AlarmListConnectionManager
Parameters:
props - The PropertiesLoader method which reads the Qosd.properties file
env - the returned properties for setting up the connections to the AlarmMonitorBean

kill

public void kill()

kill

Specified by:
kill in interface AlarmListConnectionManager

reset_list

public void reset_list(String _rebuilt_message)
this method resets the alarm list in the AlarmMonitorBean and causes an alarmlist rebuilt event to be sent.

Specified by:
reset_list in interface AlarmListConnectionManager
Parameters:
_rebuilt_message - message to include in the NotifyAlarmListRebuiltEvent

run

public void run()
         throws IllegalStateException

run

Specified by:
run in interface AlarmListConnectionManager
Throws:
IllegalStateException - if any.

send

public void send(Hashtable<AlarmKey,AlarmValue> alarmList)
Sends the AlarmList to the AlarmMonitorBean

Specified by:
send in interface AlarmListConnectionManager
Parameters:
alarmList - a Hashtable object.

start

public void start()

start

Specified by:
start in interface AlarmListConnectionManager

makeAlarmValue

public javax.oss.fm.monitor.AlarmValue makeAlarmValue()
Makes a new empty alarm value object NOTE THIS IS A PATCH to proxy for JVTAlarmMonitorSession.makeAlarmValue()

Specified by:
makeAlarmValue in interface AlarmListConnectionManager
Returns:
a javax$oss$fm$monitor$AlarmValue object.

makeAlarmValueFromSpec

public javax.oss.fm.monitor.AlarmValue makeAlarmValueFromSpec()
Makes a new alarm value object pre-populated with internal objects which have been made from a local invarient specification. NOTE THIS IS A PATCH to proxy for JVTAlarmMonitorSession

Specified by:
makeAlarmValueFromSpec in interface AlarmListConnectionManager
Returns:
a javax$oss$fm$monitor$AlarmValue object.


Copyright © 2011. All Rights Reserved.