abstract class AsynchronousByteChannel extends Channel
A byte channel that reads and writes asynchronously.
The read and write operations will never block the calling thread.
- Alphabetic
- By Inheritance
- AsynchronousByteChannel
- Channel
- IOCloseable
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- val channel: java.nio.channels.AsynchronousByteChannel
- Attributes
- protected
- Definition Classes
- AsynchronousByteChannel → Channel
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- final def close(implicit trace: Trace): IO[IOException, Unit]
Closes this channel.
Closes this channel.
- Definition Classes
- Channel → IOCloseable
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def isOpen(implicit trace: Trace): UIO[Boolean]
Tells whether or not this channel is open.
Tells whether or not this channel is open.
- Definition Classes
- Channel
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def read(b: ByteBuffer)(implicit trace: Trace): IO[IOException, Int]
Reads data from this channel into buffer, returning the number of bytes read.
Reads data from this channel into buffer, returning the number of bytes read.
Fails with
java.io.EOFException
if end-of-stream is reached. - final def readChunk(capacity: Int)(implicit trace: Trace): IO[IOException, Chunk[Byte]]
- def sink(bufferConstruct0: => UIO[ByteBuffer])(implicit trace: Trace): ZSink[Any, IOException, Byte, Byte, Long]
A sink that will write all the bytes it receives to this channel.
- def sink()(implicit trace: Trace): ZSink[Any, IOException, Byte, Byte, Long]
- def stream(bufferConstruct: UIO[ByteBuffer])(implicit trace: Trace): Stream[IOException, Byte]
A
ZStream
that reads from this channel.A
ZStream
that reads from this channel. The stream terminates without error if the channel reaches end-of-stream.- bufferConstruct
Optional, overrides how to construct the buffer used to transfer bytes read from this channel into the stream.
- def stream()(implicit trace: Trace): Stream[IOException, Byte]
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def write(b: ByteBuffer)(implicit trace: Trace): IO[IOException, Int]
Writes data into this channel from buffer, returning the number of bytes written.
- final def writeChunk(chunk: Chunk[Byte])(implicit trace: Trace): ZIO[Any, IOException, Unit]
Writes a chunk of bytes to this channel.
Writes a chunk of bytes to this channel.
More than one write operation may be performed to write out the entire chunk.