Channel
Platform and version requirements: JVM
Creates a channel without a buffer – RendezvousChannel.
Platform and version requirements: JVM
Creates a channel with the specified buffer capacity (or without a buffer by default).
The resulting channel type depends on the specified capacity parameter:
- when
capacity
is 0 – creates RendezvousChannel without a buffer; - when
capacity
is Channel.UNLIMITED – creates LinkedListChannel with buffer of unlimited size; - when
capacity
is Channel.CONFLATED – creates ConflatedChannel that conflates back-to-back sends; - when
capacity
is positive, but less than UNLIMITED – creates ArrayChannel with a buffer of the specifiedcapacity
; - otherwise – throws IllegalArgumentException.