edu.UCL.xmiddle.lib.protocols
Class XMLProtocolRegistry

java.lang.Object
  |
  +--edu.UCL.xmiddle.lib.protocols.XMLProtocolRegistry
All Implemented Interfaces:
ProtocolRegistry

public class XMLProtocolRegistry
extends java.lang.Object
implements ProtocolRegistry

XMLProtocolRegistry.java Registers the protocols which are available to the platform. It uses a hashtable internaly to store the data. Loading and saving (not implemented yet) will be done using XML. Created: Fri Jul 27 12:29:50 2001


Constructor Summary
XMLProtocolRegistry()
           
 
Method Summary
 java.lang.String getProtocolByName(java.lang.String name)
          Returns the protocol's absolute class name
 void init()
          initialises a new ProtocolRegistry from scratch
 void load(java.lang.String file)
          loads a registry stored to disk [FIXME: not implemented]
 void registerProtocol(java.lang.String className, java.lang.String protocolName)
          Registers a new protocol as available to the platform.
 void save(java.lang.String file)
          saves the registry to disk in xml format [FIXME: not implemented]
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XMLProtocolRegistry

public XMLProtocolRegistry()
Method Detail

init

public void init()
initialises a new ProtocolRegistry from scratch

Specified by:
init in interface ProtocolRegistry

load

public void load(java.lang.String file)
loads a registry stored to disk [FIXME: not implemented]

Specified by:
load in interface ProtocolRegistry
Parameters:
file - the file where the registry is stored

save

public void save(java.lang.String file)
saves the registry to disk in xml format [FIXME: not implemented]

Specified by:
save in interface ProtocolRegistry
Parameters:
file - the file where the registry is to be stored

getProtocolByName

public java.lang.String getProtocolByName(java.lang.String name)
Returns the protocol's absolute class name

Specified by:
getProtocolByName in interface ProtocolRegistry
Parameters:
name - The protocol's name
Returns:
the protocol's absolute class name

registerProtocol

public void registerProtocol(java.lang.String className,
                             java.lang.String protocolName)
Registers a new protocol as available to the platform. The protocol's name must be unique

Specified by:
registerProtocol in interface ProtocolRegistry
Parameters:
className - The absolute classname of the protocol where it can be located.
protocolName - The protocol's name