Class Nio2Acceptor
java.lang.Object
org.apache.sshd.common.util.logging.AbstractLoggingBean
org.apache.sshd.common.util.closeable.IoBaseCloseable
org.apache.sshd.common.util.closeable.AbstractCloseable
org.apache.sshd.common.util.closeable.AbstractInnerCloseable
org.apache.sshd.common.io.nio2.Nio2Service
org.apache.sshd.common.io.nio2.Nio2Acceptor
- All Implemented Interfaces:
Closeable, AutoCloseable, Channel, org.apache.sshd.common.Closeable, org.apache.sshd.common.io.IoAcceptor, org.apache.sshd.common.io.IoService, org.apache.sshd.common.io.IoServiceEventListenerManager
- Author:
- Apache MINA SSHD Project
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class org.apache.sshd.common.util.closeable.AbstractCloseable
org.apache.sshd.common.util.closeable.AbstractCloseable.State -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final Map<SocketAddress, AsynchronousServerSocketChannel> Fields inherited from class Nio2Service
CONFIGURABLE_OPTIONS, disposing, propertyResolver, sessionsFields inherited from class org.apache.sshd.common.util.closeable.AbstractCloseable
closeFuture, futureLock, stateFields inherited from class org.apache.sshd.common.util.logging.AbstractLoggingBean
logFields inherited from interface org.apache.sshd.common.io.IoService
DEFAULT_REUSE_ADDRESS -
Constructor Summary
ConstructorsConstructorDescriptionNio2Acceptor(Nio2ServiceFactory nio2ServiceFactory, org.apache.sshd.common.PropertyResolver propertyResolver, org.apache.sshd.common.io.IoHandler handler, AsynchronousChannelGroup group, ExecutorService resumeTasks) -
Method Summary
Modifier and TypeMethodDescriptionvoidbind(SocketAddress address) voidbind(Collection<? extends SocketAddress> addresses) protected voidprotected CompletionHandler<AsynchronousSocketChannel, ? super SocketAddress> createSocketCompletionHandler(Map<SocketAddress, AsynchronousServerSocketChannel> channelsMap, AsynchronousServerSocketChannel socket) protected org.apache.sshd.common.Closeableprotected AsynchronousServerSocketChannelopenAsynchronousServerSocketChannel(SocketAddress address, AsynchronousChannelGroup group) protected voidpreClose()protected CloseableprotectInProgressBinding(SocketAddress address, AsynchronousServerSocketChannel asyncChannel) toString()voidunbind()voidunbind(SocketAddress address) voidunbind(Collection<? extends SocketAddress> addresses) Methods inherited from class Nio2Service
dispose, getChannelGroup, getExecutorService, getIoHandler, getIoServiceEventListener, getManagedSessions, mapSession, sessionClosed, setIoServiceEventListener, setOption, setSocketOptions, unmapSessionMethods inherited from class org.apache.sshd.common.util.closeable.AbstractInnerCloseable
doCloseGracefully, doCloseImmediatelyMethods inherited from class org.apache.sshd.common.util.closeable.AbstractCloseable
addCloseFutureListener, builder, close, getFutureLock, isClosed, isClosing, removeCloseFutureListenerMethods inherited from class org.apache.sshd.common.util.logging.AbstractLoggingBean
debug, debug, debug, debug, debug, error, error, error, error, error, getSimplifiedLogger, info, info, warn, warn, warn, warn, warn, warn, warn, warnMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.sshd.common.Closeable
addCloseFutureListener, close, close, isClosed, isClosing, isOpen, removeCloseFutureListenerMethods inherited from interface org.apache.sshd.common.io.IoService
getManagedSessionsMethods inherited from interface org.apache.sshd.common.io.IoServiceEventListenerManager
getIoServiceEventListener, setIoServiceEventListener
-
Field Details
-
channels
-
-
Constructor Details
-
Nio2Acceptor
public Nio2Acceptor(Nio2ServiceFactory nio2ServiceFactory, org.apache.sshd.common.PropertyResolver propertyResolver, org.apache.sshd.common.io.IoHandler handler, AsynchronousChannelGroup group, ExecutorService resumeTasks)
-
-
Method Details
-
bind
- Specified by:
bindin interfaceorg.apache.sshd.common.io.IoAcceptor- Throws:
IOException
-
protectInProgressBinding
protected Closeable protectInProgressBinding(SocketAddress address, AsynchronousServerSocketChannel asyncChannel) -
openAsynchronousServerSocketChannel
protected AsynchronousServerSocketChannel openAsynchronousServerSocketChannel(SocketAddress address, AsynchronousChannelGroup group) throws IOException - Throws:
IOException
-
createSocketCompletionHandler
protected CompletionHandler<AsynchronousSocketChannel, ? super SocketAddress> createSocketCompletionHandler(Map<SocketAddress, AsynchronousServerSocketChannel> channelsMap, AsynchronousServerSocketChannel socket) throws IOException - Throws:
IOException
-
bind
- Specified by:
bindin interfaceorg.apache.sshd.common.io.IoAcceptor- Throws:
IOException
-
unbind
public void unbind()- Specified by:
unbindin interfaceorg.apache.sshd.common.io.IoAcceptor
-
unbind
- Specified by:
unbindin interfaceorg.apache.sshd.common.io.IoAcceptor
-
unbind
- Specified by:
unbindin interfaceorg.apache.sshd.common.io.IoAcceptor
-
getBoundAddresses
- Specified by:
getBoundAddressesin interfaceorg.apache.sshd.common.io.IoAcceptor
-
preClose
protected void preClose()- Overrides:
preClosein classorg.apache.sshd.common.util.closeable.AbstractCloseable
-
getInnerCloseable
protected org.apache.sshd.common.Closeable getInnerCloseable()- Overrides:
getInnerCloseablein classNio2Service
-
closeImmediately0
protected void closeImmediately0() -
toString
-