at.ac.tuwien.infosys.sm4all.copal.esper
Class EventNotifier

java.lang.Object
  extended by at.ac.tuwien.infosys.sm4all.copal.esper.EventNotifier

public class EventNotifier
extends Object

Esper subscriber which helps transform Esper event to context events understood by ContextQuery. This class is bridge between Esper and COPAL.

Author:
fei, sanjin

Constructor Summary
EventNotifier(com.espertech.esper.client.EPAdministrator administrator, ContextQuery query)
          Creates Esper subscriber using specified administrator to create Esper statement from specified context query.
 
Method Summary
 void destroy()
          Destroys the Esper statement used to get the update notifications.
 void update(Node node)
          Called when Esper has new event that is represented with specified XML node.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EventNotifier

public EventNotifier(com.espertech.esper.client.EPAdministrator administrator,
                     ContextQuery query)
Creates Esper subscriber using specified administrator to create Esper statement from specified context query.

Parameters:
administrator - the Esper administrator.
query - the context query.
Method Detail

update

public void update(Node node)
Called when Esper has new event that is represented with specified XML node. This method in return calls the context-query for which this notifier was created.

Parameters:
node - the event.

destroy

public void destroy()
Destroys the Esper statement used to get the update notifications.



Copyright © 2010 Distributed Systems Group, Vienna University of Technology. All Rights Reserved.