org.sapia.ubik.rmi.server.transport.nio.tcp
Class NioRmiConnectionFactory

java.lang.Object
  extended by org.sapia.ubik.net.SocketConnectionFactory
      extended by org.sapia.ubik.rmi.server.transport.nio.tcp.NioRmiConnectionFactory
All Implemented Interfaces:
ConnectionFactory

public class NioRmiConnectionFactory
extends SocketConnectionFactory

Implements a factory of SocketRmiConnection instances.

Author:
Yanick Duchesne
Copyright:
Copyright © 2002-2003 Sapia Open Source Software . All Rights Reserved.
License:
Read the license.txt file of the jar or visit the license page at the Sapia OSS web site

Field Summary
 
Fields inherited from class org.sapia.ubik.net.SocketConnectionFactory
_clientSocketFactory, _loader
 
Constructor Summary
NioRmiConnectionFactory(int bufsize)
          Constructor for RMIConnectionFactory.
 
Method Summary
 Connection newConnection(java.net.Socket sock)
          Creates a new Connection around the given socket.
 Connection newConnection(java.lang.String host, int port)
          Returns a client Connection instance that connects to the server at the given host and port.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NioRmiConnectionFactory

public NioRmiConnectionFactory(int bufsize)
Constructor for RMIConnectionFactory.

Method Detail

newConnection

public Connection newConnection(java.net.Socket sock)
                         throws java.io.IOException
Description copied from class: SocketConnectionFactory
Creates a new Connection around the given socket.

Overrides:
newConnection in class SocketConnectionFactory
Returns:
a SocketConnection.
Throws:
java.io.IOException
See Also:
SocketConnectionFactory.newConnection(Socket)

newConnection

public Connection newConnection(java.lang.String host,
                                int port)
                         throws java.io.IOException
Description copied from interface: ConnectionFactory
Returns a client Connection instance that connects to the server at the given host and port.

Specified by:
newConnection in interface ConnectionFactory
Overrides:
newConnection in class SocketConnectionFactory
Parameters:
host - the host to connect to.
port - the port on which the server is listening at the given host.
Throws:
java.io.IOException - if the connection instance could not be created.
See Also:
SocketConnectionFactory.newConnection(String, int)


Copyright © 2010 Sapia OSS. All Rights Reserved.