edu.uci.isr.yancees
Class ProtocolFacade

java.lang.Object
  extended by edu.uci.isr.yancees.ProtocolFacade

public class ProtocolFacade
extends java.lang.Object

This class deals with generic messages, that are parserd by installed protocol plug-ins. For example, mobility, authentication and so on. This class stays behind the YanceesFacade class and deals specifically with protocol manipulation operations.


Method Summary
 ProtocolPluginInterface connectToNewProtocol(java.lang.String protocolId, SubscriberInterface si)
          Connects to a protocol object under the name protocolId
 ProtocolPluginInterface connectToSharedProtocol(java.lang.String protocolId, SubscriberInterface si)
          Connects to a protocol object under the name protocolId
 void disconnectFromProtocol(java.lang.String protocolId, SubscriberInterface si)
          This method informs that the protocol object is not necessary anymore, so it can be garbage collected
protected static ProtocolFacade getInstance()
           
protected  void setProtocolManager(ProtocolManager pm)
          Used by the Yancees API to initialize this API.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

protected static ProtocolFacade getInstance()

connectToSharedProtocol

public ProtocolPluginInterface connectToSharedProtocol(java.lang.String protocolId,
                                                       SubscriberInterface si)
                                                throws YanceesException
Connects to a protocol object under the name protocolId

Parameters:
protocolId - is the name of the protocol plug-in to connect to
Returns:
a reference to the plug-in created to handle the protocol, or throws an exception if an error or no protoocol plug-in found. It pretty much works as a binding to the protocol object through a name server such as rmid.
Throws:
YanceesException

connectToNewProtocol

public ProtocolPluginInterface connectToNewProtocol(java.lang.String protocolId,
                                                    SubscriberInterface si)
                                             throws YanceesException
Connects to a protocol object under the name protocolId

Parameters:
protocolId - is the name of the protocol plug-in to connect to
Returns:
a reference to the plug-in created to handle the protocol, or throws an exception if an error or no protoocol plug-in found. It pretty much works as a binding to the protocol object through a name server such as rmid.
Throws:
YanceesException

disconnectFromProtocol

public void disconnectFromProtocol(java.lang.String protocolId,
                                   SubscriberInterface si)
                            throws YanceesException
This method informs that the protocol object is not necessary anymore, so it can be garbage collected

Parameters:
protocolId - is the name of the protocol plug-in to connect to
si - is the subscriber interface
Throws:
YanceesException

setProtocolManager

protected void setProtocolManager(ProtocolManager pm)
Used by the Yancees API to initialize this API.

Parameters:
pm - is the instance of the protocol manager to be used by this component