org.apache.mina.registry
Interface ServiceRegistry

All Known Implementing Classes:
SimpleServiceRegistry

public interface ServiceRegistry

Interface for the internet service registry. The registry is used by MINA to associate services with ports and transport protocols.

Version:
$Rev: 332218 $, $Date: 2005-11-10 12:52:42 +0900 $
Author:
The Apache Directory Project (dev@directory.apache.org)

Method Summary
 void bind(Service service, IoHandler ioHandler)
          Binds the specified I/O handler to the specified service.
 void bind(Service service, ProtocolProvider protocolProvider)
          Binds the specified protocol provider to the specified service.
 Set getAllServices()
          Returns Set of all services bound in this registry.
 IoAcceptor getIoAcceptor(TransportType transportType)
           
 ProtocolAcceptor getProtocolAcceptor(TransportType transportType)
           
 Set getServices(int port)
          Returns Set of services bound in this registry with the specified port number.
 Set getServices(String name)
          Returns Set of services bound in this registry with the specified service(or protocol) name.
 Set getServices(TransportType transportType)
          Returns Set of services bound in this registry with the specified transport type.
 void unbind(Service service)
          Unbinds the specified service (and its aggregated I/O handler or protocol provider).
 void unbindAll()
          Unbinds all services (and their aggregated I/O handlers or protocol providers).
 

Method Detail

bind

void bind(Service service,
          IoHandler ioHandler)
          throws IOException
Binds the specified I/O handler to the specified service.

Throws:
IOException

bind

void bind(Service service,
          ProtocolProvider protocolProvider)
          throws IOException
Binds the specified protocol provider to the specified service.

Throws:
IOException

unbind

void unbind(Service service)
Unbinds the specified service (and its aggregated I/O handler or protocol provider).


unbindAll

void unbindAll()
Unbinds all services (and their aggregated I/O handlers or protocol providers).


getAllServices

Set getAllServices()
Returns Set of all services bound in this registry.


getServices

Set getServices(String name)
Returns Set of services bound in this registry with the specified service(or protocol) name.


getServices

Set getServices(TransportType transportType)
Returns Set of services bound in this registry with the specified transport type.


getServices

Set getServices(int port)
Returns Set of services bound in this registry with the specified port number.


getIoAcceptor

IoAcceptor getIoAcceptor(TransportType transportType)

getProtocolAcceptor

ProtocolAcceptor getProtocolAcceptor(TransportType transportType)


Copyright © 2004-2005 . All Rights Reserved.