|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.glassfish.grizzly.AbstractSocketConnectorHandler
public abstract class AbstractSocketConnectorHandler
Abstract class simplifies the implementation of
SocketConnectorHandler
interface by preimplementing some of its methods.
| Field Summary | |
|---|---|
protected Processor |
defaultProcessor
|
protected ProcessorSelector |
defaultProcessorSelector
|
protected Transport |
transport
|
| Constructor Summary | |
|---|---|
AbstractSocketConnectorHandler(Transport transport)
|
|
| Method Summary | |
|---|---|
Future<Connection> |
connect(SocketAddress remoteAddress)
Creates, initializes and connects socket to the specific SocketAddress and returns Connection, representing socket. |
abstract Future<Connection> |
connect(SocketAddress remoteAddress,
SocketAddress localAddress)
Creates, initializes socket, binds it to the specific local and remote SocketAddress and returns Connection, representing socket. |
Future<Connection> |
connect(String host,
int port)
Creates, initializes and connects socket to the specific remote host and port and returns Connection, representing socket. |
Processor |
getProcessor()
Get the default Processor to process IOEvent, occuring
on connection phase. |
ProcessorSelector |
getProcessorSelector()
Gets the default ProcessorSelector, which will be used to get
Processor to process I/O events, occuring on connection phase. |
void |
setProcessor(Processor defaultProcessor)
Set the default Processor to process IOEvent, occuring
on connection phase. |
void |
setProcessorSelector(ProcessorSelector defaultProcessorSelector)
Sets the default ProcessorSelector, which will be used to get
Processor to process I/O events, occuring on connection phase. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected Transport transport
protected Processor defaultProcessor
protected ProcessorSelector defaultProcessorSelector
| Constructor Detail |
|---|
public AbstractSocketConnectorHandler(Transport transport)
| Method Detail |
|---|
public Future<Connection> connect(String host,
int port)
throws IOException
SocketConnectorHandlerConnection, representing socket.
connect in interface SocketConnectorHandlerhost - remote host to connect to.port - remote port to connect to.
Future of connect operation, which could be used to get
resulting Connection.
IOException
public Future<Connection> connect(SocketAddress remoteAddress)
throws IOException
SocketConnectorHandlerSocketAddress and returns Connection, representing socket.
connect in interface SocketConnectorHandlerremoteAddress - remote address to connect to.
Future of connect operation, which could be used to get
resulting Connection.
IOException
public abstract Future<Connection> connect(SocketAddress remoteAddress,
SocketAddress localAddress)
throws IOException
SocketConnectorHandlerSocketAddress and returns Connection, representing socket.
connect in interface SocketConnectorHandlerremoteAddress - remote address to connect to.localAddress - local address to bind socket to.
Future of connect operation, which could be used to get
resulting Connection.
IOExceptionpublic Processor getProcessor()
SocketConnectorHandlerProcessor to process IOEvent, occuring
on connection phase.
getProcessor in interface SocketConnectorHandlerProcessor to process IOEvent,
occuring on connection phase.public void setProcessor(Processor defaultProcessor)
SocketConnectorHandlerProcessor to process IOEvent, occuring
on connection phase.
setProcessor in interface SocketConnectorHandlerdefaultProcessor - the default Processor to process
IOEvent, occuring on connection phase.public ProcessorSelector getProcessorSelector()
SocketConnectorHandlerProcessorSelector, which will be used to get
Processor to process I/O events, occuring on connection phase.
getProcessorSelector in interface SocketConnectorHandlerProcessorSelector, which will be used to get
Processor to process I/O events, occuring on connection phase.public void setProcessorSelector(ProcessorSelector defaultProcessorSelector)
SocketConnectorHandlerProcessorSelector, which will be used to get
Processor to process I/O events, occuring on connection phase.
setProcessorSelector in interface SocketConnectorHandlerdefaultProcessorSelector - the default ProcessorSelector,
which will be used to get Processor to process I/O events,
occuring on connection phase.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||