Class AsynchronousChannelHelper
- java.lang.Object
-
- com.mongodb.async.client.gridfs.helpers.AsynchronousChannelHelper
-
Deprecated.Prefer the Reactive Streams-based asynchronous driver (mongodb-driver-reactivestreams artifactId)
@Deprecated public final class AsynchronousChannelHelper extends java.lang.Object
A helper class to convert toAsynchronousByteChannel
orAsynchronousFileChannel
instances intoAsyncInputStream
orAsyncOutputStream
instances.Requires Java 7 or greater.
- Since:
- 3.3
-
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static AsyncInputStream
channelToInputStream(java.nio.channels.AsynchronousByteChannel asynchronousByteChannel)
Deprecated.Converts aAsynchronousByteChannel
into aAsyncInputStream
static AsyncInputStream
channelToInputStream(java.nio.channels.AsynchronousFileChannel asynchronousFileChannel)
Deprecated.Converts aAsynchronousFileChannel
into aAsyncInputStream
static AsyncOutputStream
channelToOutputStream(java.nio.channels.AsynchronousByteChannel asynchronousByteChannel)
Deprecated.Converts aAsynchronousByteChannel
into aAsyncOutputStream
static AsyncOutputStream
channelToOutputStream(java.nio.channels.AsynchronousFileChannel asynchronousFileChannel)
Deprecated.Converts aAsynchronousFileChannel
into aAsyncOutputStream
-
-
-
Method Detail
-
channelToInputStream
public static AsyncInputStream channelToInputStream(java.nio.channels.AsynchronousByteChannel asynchronousByteChannel)
Deprecated.Converts aAsynchronousByteChannel
into aAsyncInputStream
- Parameters:
asynchronousByteChannel
- the AsynchronousByteChannel- Returns:
- the AsyncInputStream
-
channelToInputStream
public static AsyncInputStream channelToInputStream(java.nio.channels.AsynchronousFileChannel asynchronousFileChannel)
Deprecated.Converts aAsynchronousFileChannel
into aAsyncInputStream
- Parameters:
asynchronousFileChannel
- the AsynchronousFileChannel- Returns:
- the AsyncInputStream
-
channelToOutputStream
public static AsyncOutputStream channelToOutputStream(java.nio.channels.AsynchronousByteChannel asynchronousByteChannel)
Deprecated.Converts aAsynchronousByteChannel
into aAsyncOutputStream
- Parameters:
asynchronousByteChannel
- the AsynchronousByteChannel- Returns:
- the AsyncOutputStream
-
channelToOutputStream
public static AsyncOutputStream channelToOutputStream(java.nio.channels.AsynchronousFileChannel asynchronousFileChannel)
Deprecated.Converts aAsynchronousFileChannel
into aAsyncOutputStream
- Parameters:
asynchronousFileChannel
- the AsynchronousFileChannel- Returns:
- the AsyncOutputStream
-
-