Package org.apache.tomcat.websocket

## Class AsyncChannelWrapperNonSecure

- java.lang.Object
- - org.apache.tomcat.websocket.AsyncChannelWrapperNonSecure

All Implemented Interfaces:
  `AsyncChannelWrapper`

    public class AsyncChannelWrapperNonSecure
    extends java.lang.Object
    implements AsyncChannelWrapper

Generally, just passes calls straight to the wrapped `AsynchronousSocketChannel`. In some cases exceptions may be swallowed to save them being swallowed by the calling code.

### Constructor Summary

Constructors
`AsyncChannelWrapperNonSecure​(java.nio.channels.AsynchronousSocketChannel socketChannel)`

### Method Summary

All Methods Instance Methods Concrete Methods
`void` `close()`
`java.net.SocketAddress` `getLocalAddress()`
`java.util.concurrent.Future<java.lang.Void>` `handshake()`
`java.util.concurrent.Future<java.lang.Integer>` `read​(java.nio.ByteBuffer dst)`
`<B,​A extends B> void` `read​(java.nio.ByteBuffer dst, A attachment, java.nio.channels.CompletionHandler<java.lang.Integer,​B> handler)`
`java.util.concurrent.Future<java.lang.Integer>` `write​(java.nio.ByteBuffer src)`
`<B,​A extends B> void` `write​(java.nio.ByteBuffer[] srcs, int offset, int length, long timeout, java.util.concurrent.TimeUnit unit, A attachment, java.nio.channels.CompletionHandler<java.lang.Long,​B> handler)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### AsyncChannelWrapperNonSecure

    public AsyncChannelWrapperNonSecure​(java.nio.channels.AsynchronousSocketChannel socketChannel)

### Method Detail

#### read

    public java.util.concurrent.Future<java.lang.Integer> read​(java.nio.ByteBuffer dst)

Specified by:
  `read` in interface `AsyncChannelWrapper`

#### read

    public <B,​A extends B> void read​(java.nio.ByteBuffer dst,
                                           A attachment,
                                           java.nio.channels.CompletionHandler<java.lang.Integer,​B> handler)

Specified by:
  `read` in interface `AsyncChannelWrapper`

#### write

    public java.util.concurrent.Future<java.lang.Integer> write​(java.nio.ByteBuffer src)

Specified by:
  `write` in interface `AsyncChannelWrapper`

#### write

    public <B,​A extends B> void write​(java.nio.ByteBuffer[] srcs,
                                            int offset,
                                            int length,
                                            long timeout,
                                            java.util.concurrent.TimeUnit unit,
                                            A attachment,
                                            java.nio.channels.CompletionHandler<java.lang.Long,​B> handler)

Specified by:
  `write` in interface `AsyncChannelWrapper`

#### close

    public void close()

Specified by:
  `close` in interface `AsyncChannelWrapper`

#### handshake

    public java.util.concurrent.Future<java.lang.Void> handshake()

Specified by:
  `handshake` in interface `AsyncChannelWrapper`

#### getLocalAddress

    public java.net.SocketAddress getLocalAddress()
                                           throws java.io.IOException

Specified by:
  `getLocalAddress` in interface `AsyncChannelWrapper`
Throws:
  `java.io.IOException`