|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.mina.common.BaseSessionManager org.apache.mina.io.socket.SocketAcceptor
public class SocketAcceptor
IoAcceptor
for socket transport (TCP/IP).
Field Summary |
---|
Fields inherited from class org.apache.mina.common.BaseSessionManager |
---|
exceptionMonitor |
Constructor Summary | |
---|---|
SocketAcceptor()
Creates a new instance. |
Method Summary | |
---|---|
void |
bind(SocketAddress address,
IoHandler handler)
Binds to the specified address and handles incoming
connections with the specified handler . |
int |
getBacklog()
Returns the default backlog value which is used when user binds. |
IoFilterChain |
getFilterChain()
Returns the filter chain that filters all events which is related with sessions this manager manages. |
IoSession |
newSession(SocketAddress remoteAddress,
SocketAddress localAddress)
(Optional) Returns an IoSession that is bound to the specified
localAddress and remoteAddress which reuses
the localAddress that is already bound by IoAcceptor
via IoAcceptor.bind(SocketAddress, IoHandler) . |
void |
setBacklog(int defaultBacklog)
Sets the default backlog value which is used when user binds. |
void |
unbind(SocketAddress address)
Unbinds from the specified address . |
Methods inherited from class org.apache.mina.common.BaseSessionManager |
---|
getExceptionMonitor, setExceptionMonitor |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.mina.common.SessionManager |
---|
getExceptionMonitor, setExceptionMonitor |
Constructor Detail |
---|
public SocketAcceptor()
Method Detail |
---|
public void bind(SocketAddress address, IoHandler handler) throws IOException
address
and handles incoming
connections with the specified handler
. Backlog value
is configured to the value of backlog
property.
bind
in interface IoAcceptor
IOException
- if failed to bindpublic void unbind(SocketAddress address)
IoAcceptor
address
.
unbind
in interface IoAcceptor
public int getBacklog()
public void setBacklog(int defaultBacklog)
public IoFilterChain getFilterChain()
IoSessionManager
getFilterChain
in interface IoSessionManager
public IoSession newSession(SocketAddress remoteAddress, SocketAddress localAddress)
IoAcceptor
IoSession
that is bound to the specified
localAddress and remoteAddress which reuses
the localAddress that is already bound by IoAcceptor
via IoAcceptor.bind(SocketAddress, IoHandler)
.
This operation is optional. Please throw UnsupportedOperationException
if the transport type doesn't support this operation. This operation is
usually implemented for connectionless transport types.
newSession
in interface IoAcceptor
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |