final class DatagramChannel extends GatheringByteChannel with ScatteringByteChannel

A java.nio.channels.DatagramChannel wrapper allowing for idiomatic zio.ZIO interoperability.

Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. DatagramChannel
  2. ScatteringByteChannel
  3. GatheringByteChannel
  4. Channel
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. val channel: java.nio.channels.DatagramChannel
    Attributes
    protected[channels]
    Definition Classes
    DatagramChannelScatteringByteChannelGatheringByteChannelChannel
  6. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  7. def disconnect: IO[IOException, DatagramChannel]

    Disconnects this channel's underlying socket.

    Disconnects this channel's underlying socket.

    returns

    the disconnected datagram channel

  8. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  9. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  10. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  11. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  12. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  13. def isConnected: UIO[Boolean]

    Tells whether this channel's underlying socket is both open and connected.

    Tells whether this channel's underlying socket is both open and connected.

    returns

    true when the socket is both open and connected, otherwise false

  14. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  15. final def isOpen: UIO[Boolean]

    Tells whether or not this channel is open.

    Tells whether or not this channel is open.

    Definition Classes
    Channel
  16. def localAddress: IO[IOException, Option[SocketAddress]]

    Optionally returns the socket address that this channel's underlying socket is bound to.

    Optionally returns the socket address that this channel's underlying socket is bound to.

    returns

    the local address if the socket is bound, otherwise None

  17. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  18. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  19. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  20. def read(dst: ByteBuffer): IO[IOException, Int]

    Reads a datagram into the given zio.nio.core.ByteBuffer.

    Reads a datagram into the given zio.nio.core.ByteBuffer. This effect can only succeed if the channel is connected, and it only accepts datagrams from the connected remote address.

    dst

    the destination buffer

    returns

    the number of bytes that were read from this channel

  21. final def read(capacity: Int): IO[Exception, Chunk[Byte]]
    Definition Classes
    ScatteringByteChannel
  22. final def readBuffer(dst: Buffer[Byte]): IO[Exception, Option[Long]]
    Definition Classes
    ScatteringByteChannel
  23. final def readBuffer(dsts: List[Buffer[Byte]]): IO[Exception, Option[Long]]
    Definition Classes
    ScatteringByteChannel
  24. def receive(dst: ByteBuffer): IO[IOException, Option[SocketAddress]]

    Receives a datagram via this channel into the given zio.nio.core.ByteBuffer.

    Receives a datagram via this channel into the given zio.nio.core.ByteBuffer.

    dst

    the destination buffer

    returns

    the socket address of the datagram's source, if available.

  25. def remoteAddress: IO[IOException, Option[SocketAddress]]

    Optionally returns the remote socket address that this channel's underlying socket is connected to.

    Optionally returns the remote socket address that this channel's underlying socket is connected to.

    returns

    the remote address if the socket is connected, otherwise None

  26. def send(src: ByteBuffer, target: SocketAddress): IO[IOException, Int]

    Sends a datagram via this channel to the given target zio.nio.core.SocketAddress.

    Sends a datagram via this channel to the given target zio.nio.core.SocketAddress.

    src

    the source buffer

    target

    the target address

    returns

    the number of bytes that were sent over this channel

  27. def setOption[T](name: SocketOption[T], value: T): IO[IOException, DatagramChannel]

    Sets the value of the given socket option.

    Sets the value of the given socket option.

    name

    the socket option to be set

    value

    the value to be set

    returns

    the datagram channel with the given socket option set to the provided value

  28. def socket: UIO[DatagramSocket]

    Returns a reference to this channel's underlying datagram socket.

    Returns a reference to this channel's underlying datagram socket.

    returns

    the underlying datagram socket

  29. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  30. def toString(): String
    Definition Classes
    AnyRef → Any
  31. def validOps: UIO[Int]

    Returns the set of operations supported by this channel.

    Returns the set of operations supported by this channel.

    returns

    the set of valid operations

  32. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  33. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  34. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  35. def write(src: ByteBuffer): IO[IOException, Int]

    Writes a datagram read from the given zio.nio.core.ByteBuffer.

    Writes a datagram read from the given zio.nio.core.ByteBuffer. This effect can only succeed if the channel is connected, and it only sends datagrams to the connected remote address.

    src

    the source buffer from which the datagram is to be read

    returns

    the number of bytes that were written to this channel

  36. final def write(src: Chunk[Byte]): IO[Exception, Long]
    Definition Classes
    GatheringByteChannel
  37. final def write(srcs: List[Chunk[Byte]]): IO[Exception, Long]
    Definition Classes
    GatheringByteChannel
  38. final def writeBuffer(src: Buffer[Byte]): IO[Exception, Long]
    Definition Classes
    GatheringByteChannel
  39. final def writeBuffer(srcs: List[Buffer[Byte]]): IO[Exception, Long]
    Definition Classes
    GatheringByteChannel

Inherited from ScatteringByteChannel

Inherited from GatheringByteChannel

Inherited from Channel

Inherited from AnyRef

Inherited from Any

Ungrouped