org.globus.ogsa.impl.core.notification.framework.jms
Class JMSQueryEvaluator

java.lang.Object
  extended byorg.globus.ogsa.impl.core.notification.framework.jms.JMSQueryEvaluator
All Implemented Interfaces:
QueryEvaluator, RegisterSubscriptionMessageReceiver, ServiceDataChangeMessageReceiver, UnregisterSubscriptionMessageReceiver
Direct Known Subclasses:
JMSServiceDataNameQueryEvaluator, JMSXPathQueryEvaluator, JMSXSLQueryEvaluator

public abstract class JMSQueryEvaluator
extends java.lang.Object
implements QueryEvaluator, ServiceDataChangeMessageReceiver, RegisterSubscriptionMessageReceiver, UnregisterSubscriptionMessageReceiver

The JMSQueryEvaluator class. This class is used to create and evaluate a Subscription.


Field Summary
protected static java.util.HashMap theSubscriptionCriteriaMap
          The place holder for subscriptions.
 
Constructor Summary
JMSQueryEvaluator(java.lang.String aSubscriptionExpressionType)
          The constructor of the class
 
Method Summary
protected  Message formatNotifyMessage()
          The formatNotifyMessage method.
protected  JMSAdapter getJMSAdapter()
          The getJMSAdapter method.
 SubscriptionInfo getSubscriptionInfo(java.lang.String aSubscriptionId)
          Accessor for the Subscription Registration info.
protected  void publishNotifyMessage(Message aMessage)
          The publishNotifyMessage method.
protected  void publishRefreshServiceDataMessage(Message aMessage)
          The publishRefreshServiceDataMessage method.
abstract  void receiveRegisterSubscriptionMessage(Message aMessage)
          The receiveRegisterSubscriptionMessage method.
abstract  void receiveServiceDataChangeMessage(Message aServiceDataChangeMessage)
          The receiveServiceDataChangeMessage method.
abstract  void receiveUnregisterSubscriptionMessage(Message aMessage)
          The receiveUnregisterSubscriptionMessage method.
 void registerSubscription(java.lang.String aSubscriptionId, SubscriptionInfo aSubscriptionInformation)
          Register Subscription information.
 void unregisterSubscription(java.lang.String aSubscriptionID)
          The unregisterSubscription method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.globus.ogsa.impl.core.notification.framework.QueryEvaluator
evaluateCriteria
 

Field Detail

theSubscriptionCriteriaMap

protected static java.util.HashMap theSubscriptionCriteriaMap
The place holder for subscriptions.

Constructor Detail

JMSQueryEvaluator

public JMSQueryEvaluator(java.lang.String aSubscriptionExpressionType)
                  throws java.lang.Exception
The constructor of the class

Throws:
java.lang.Exception - if an adapter can not be optained
Method Detail

receiveServiceDataChangeMessage

public abstract void receiveServiceDataChangeMessage(Message aServiceDataChangeMessage)
The receiveServiceDataChangeMessage method. This is an abstract method so that we can have any kind of receiver listening to the ServiceDataChange topic.

Specified by:
receiveServiceDataChangeMessage in interface ServiceDataChangeMessageReceiver
Parameters:
aServiceDataChangeMessage - - The service data change message.

receiveRegisterSubscriptionMessage

public abstract void receiveRegisterSubscriptionMessage(Message aMessage)
The receiveRegisterSubscriptionMessage method. This is an abstract method so that we can have any kind of receiver listening to the RegisterSubscription topic.

Specified by:
receiveRegisterSubscriptionMessage in interface RegisterSubscriptionMessageReceiver
Parameters:
aMessage - - The Register Subscription message.

receiveUnregisterSubscriptionMessage

public abstract void receiveUnregisterSubscriptionMessage(Message aMessage)
The receiveUnregisterSubscriptionMessage method. This is an abstract method so that we can have any kind of receiver listening to the UnregisterSubscription topic.

Specified by:
receiveUnregisterSubscriptionMessage in interface UnregisterSubscriptionMessageReceiver
Parameters:
aMessage - - The Unregister Subscription message.

getJMSAdapter

protected JMSAdapter getJMSAdapter()
The getJMSAdapter method. Accessor for the JMSAdapter.


registerSubscription

public void registerSubscription(java.lang.String aSubscriptionId,
                                 SubscriptionInfo aSubscriptionInformation)
Register Subscription information.


getSubscriptionInfo

public SubscriptionInfo getSubscriptionInfo(java.lang.String aSubscriptionId)
Accessor for the Subscription Registration info.


unregisterSubscription

public void unregisterSubscription(java.lang.String aSubscriptionID)
The unregisterSubscription method. Pull out the subscription id from the JMS unregister message, and remove the entry of this susbcription id from the hash map.

Parameters:
aSubscriptionID - - The subscriptionID to be removed.

formatNotifyMessage

protected Message formatNotifyMessage()
The formatNotifyMessage method. This method is used to format the the notify message

Returns:
Message.

publishNotifyMessage

protected void publishNotifyMessage(Message aMessage)
The publishNotifyMessage method. This method publishes the notify message.

Parameters:
aMessage - - The message to be published.

publishRefreshServiceDataMessage

protected void publishRefreshServiceDataMessage(Message aMessage)
The publishRefreshServiceDataMessage method. This method publishes the RefreshServiceData message.

Parameters:
aMessage - - The message to be published.