final case class Channel[-A](channel: io.netty.channel.Channel, convert: (A) ⇒ Any) extends Product with Serializable
An immutable and type-safe representation of one or more netty channels. A
represents the type of messages that can be written on the channel.
- Self Type
- Channel[A]
- Alphabetic
- By Inheritance
- Channel
- Serializable
- Serializable
- Product
- Equals
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
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
-
def
autoRead(flag: Boolean): UIO[Unit]
When set to
true(default) it will automatically read messages from the channel.When set to
true(default) it will automatically read messages from the channel. When set to false, the channel will not read messages untilreadis called. -
def
awaitClose: UIO[Unit]
Provides a way to wait for the channel to be closed.
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native() @HotSpotIntrinsicCandidate()
-
def
close(await: Boolean = false): Task[Unit]
Closes the channel.
Closes the channel. Pass true to await to wait for the channel to be closed.
-
def
contramap[A1](f: (A1) ⇒ A): Channel[A1]
Creates a new channel that can write a different type of message by using a transformation function.
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
flush: Task[Unit]
Flushes the pending write operations on the channel.
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
def
id: String
Returns the globally unique identifier of this channel.
-
def
isAutoRead: UIO[Boolean]
Returns
trueif auto-read is set to true. -
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
def
read: UIO[Unit]
Schedules a read operation on the channel.
Schedules a read operation on the channel. This is not necessary if auto-read is enabled.
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
def
write(msg: A, await: Boolean = false): Task[Unit]
Schedules a write operation on the channel.
Schedules a write operation on the channel. The actual write only happens after calling
flush. Passtrueto await the completion of the write operation. -
def
writeAndFlush(msg: A, await: Boolean = false): Task[Unit]
Writes and flushes the message on the channel.
Writes and flushes the message on the channel. Pass
trueto await the completion of the write operation.