edu.uci.isr.yancees.client.rmi
Class YanceesRMIClient.SubscriberMediator

java.lang.Object
  extended by java.rmi.server.RemoteObject
      extended by java.rmi.server.RemoteServer
          extended by java.rmi.server.UnicastRemoteObject
              extended by edu.uci.isr.yancees.server.rmi.RemoteAbstractSubscriberImplementation
                  extended by edu.uci.isr.yancees.client.rmi.YanceesRMIClient.SubscriberMediator
All Implemented Interfaces:
RemoteSubscriberInterface, java.io.Serializable, java.rmi.Remote
Enclosing class:
YanceesRMIClient

public class YanceesRMIClient.SubscriberMediator
extends RemoteAbstractSubscriberImplementation

The subscriber mediator receives notifications from the plug-ins and forward them to their specific subscribers.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class java.rmi.server.RemoteObject
ref
 
Constructor Summary
YanceesRMIClient.SubscriberMediator(SubscriberInterface s)
          Constructor
 
Method Summary
 void decReferenceCounter()
           
 int getReferenceCounter()
           
 void incReferenceCounter()
           
 void notify(EventInterface evt)
          Receives notification as RemoteSubscriberInterface and forwards it to the client SubscriberInterface
 void notify(EventInterface[] evtList)
          Receives notification list as RemoteSubscriberInterface and forwards it to the client SubscriberInterface
 void notifyBuffer(java.lang.Object[] objList)
          Receives a batch of events and patterns as a notification
 
Methods inherited from class java.rmi.server.UnicastRemoteObject
clone, exportObject, exportObject, exportObject, unexportObject
 
Methods inherited from class java.rmi.server.RemoteServer
getClientHost, getLog, setLog
 
Methods inherited from class java.rmi.server.RemoteObject
equals, getRef, hashCode, toString, toStub
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

YanceesRMIClient.SubscriberMediator

public YanceesRMIClient.SubscriberMediator(SubscriberInterface s)
                                    throws java.rmi.RemoteException
Constructor

Parameters:
s - is the subscriber interface to be notified when the plug-in evaluation tree is completed.
Throws:
java.rmi.RemoteException
Method Detail

notify

public void notify(EventInterface evt)
            throws java.rmi.RemoteException
Receives notification as RemoteSubscriberInterface and forwards it to the client SubscriberInterface

Specified by:
notify in interface RemoteSubscriberInterface
Specified by:
notify in class RemoteAbstractSubscriberImplementation
Parameters:
evt - is the event received from the remote notification service
Throws:
java.rmi.RemoteException - in case of connection errors.

notify

public void notify(EventInterface[] evtList)
            throws java.rmi.RemoteException
Receives notification list as RemoteSubscriberInterface and forwards it to the client SubscriberInterface

Specified by:
notify in interface RemoteSubscriberInterface
Specified by:
notify in class RemoteAbstractSubscriberImplementation
Parameters:
evtList - is the list of events received from the remote notification service
Throws:
java.rmi.RemoteException - in case of connection errors.

incReferenceCounter

public void incReferenceCounter()

decReferenceCounter

public void decReferenceCounter()

getReferenceCounter

public int getReferenceCounter()

notifyBuffer

public void notifyBuffer(java.lang.Object[] objList)
                  throws java.rmi.RemoteException
Receives a batch of events and patterns as a notification

Specified by:
notifyBuffer in interface RemoteSubscriberInterface
Overrides:
notifyBuffer in class RemoteAbstractSubscriberImplementation
Throws:
java.rmi.RemoteException