|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.opennms.bb.dp.common.components.PollerClient | +--org.opennms.bb.dp.actiond.components.ActiondEventReceiver
ActiondEventReceiver does the initial process/receiving of all events coming over the eventd JSDT channel.
It extends the PollerClient and implements the 'ChannelConsumer' interface to receive the events
Field Summary | |
private com.sun.media.jsdt.Channel |
m_channel
The JSDT channel on which eventd is broadcasting events |
private ActiondEventListener |
m_eventListenerMain
the event listener |
private PCQueue |
m_listenerQ
queue to which the incoming event stream is to be added |
private boolean |
m_pauseOperation
Flag indicating that operation is to be paused For now events received are simply discarded during pause |
private com.sun.media.jsdt.Session |
m_session
The JSDT event session |
private static int |
numEventsRcvd
|
Fields inherited from class org.opennms.bb.dp.common.components.PollerClient |
m_name |
Constructor Summary | |
ActiondEventReceiver(ActiondEventListener eListener,
PCQueue listenerQ)
Creates a ActiondEventReceiver for actiond |
Method Summary | |
void |
dataReceived(com.sun.media.jsdt.Data data)
If operation is not paused, add the incoming event to the 'listenerQ' as an input stream. |
private boolean |
jsdtConnect()
Connect to the eventd JSDT channel for event reception |
void |
pauseOperation()
Pause the operation - ignore the received messages? |
void |
resumeOperation()
Resume the paused operation |
void |
shutdown()
Removes itself as a consumer for the JSDT session and closes the session |
Methods inherited from class org.opennms.bb.dp.common.components.PollerClient |
authenticate, getName |
Methods inherited from class java.lang.Object |
|
Field Detail |
private ActiondEventListener m_eventListenerMain
private PCQueue m_listenerQ
private com.sun.media.jsdt.Session m_session
private com.sun.media.jsdt.Channel m_channel
private boolean m_pauseOperation
private static int numEventsRcvd
Constructor Detail |
public ActiondEventReceiver(ActiondEventListener eListener, PCQueue listenerQ) throws org.xml.sax.SAXException
eListener
- the event listenerlistenerQ
- queue to which events sent in are to be addedthrows
- a RunTimException if connection to JSDT failsthrows
- a SAXException if the events parser cannot be createdMethod Detail |
public void dataReceived(com.sun.media.jsdt.Data data)
dataReceived
in interface com.sun.media.jsdt.ChannelConsumer
data
- received JSDT dataprivate boolean jsdtConnect() throws InterruptedException
InterruptedException
- Thrown if the running
thread is interrupted by another thread.public void pauseOperation()
public void resumeOperation()
public void shutdown()
Removes itself as a consumer for the JSDT session and closes the session
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |