net.jetrix
Class ProtocolManager

java.lang.Object
  extended by net.jetrix.ProtocolManager

public class ProtocolManager
extends Object

Manages protocols. Protocol instances are obtained by calling the getProtocol() method. The ProtocolManager is in charge to serve the same unique instance of the specified protocol.

Version:
$Revision: 544 $, $Date: 2005-01-05 02:29:56 +0100 (mer., 05 janv. 2005) $
Author:
Emmanuel Bourg

Method Summary
static ProtocolManager getInstance()
          Returns the instance of the ProtocolManager.
 Protocol getProtocol(Class cls)
          Returns a protocol of the specified class.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static ProtocolManager getInstance()
Returns the instance of the ProtocolManager.


getProtocol

public Protocol getProtocol(Class cls)
Returns a protocol of the specified class. If a protocol of this class has already been created, the same instance is returned.

Parameters:
cls - Class of the protocol to return
Returns:
Protocol of the specified class.


Copyright © 2001-2008 Emmanuel Bourg. All Rights Reserved.