Receiver
public class Receiverextension CoChannel.Receiver: CoCancellableA CoChannel wrapper that provides receive-only functionality.
- 
                  
                  The type of channel buffer. DeclarationSwift public var bufferType: BufferType { get }
- 
                  
                  Retrieves and removes an element from this channel if it’s not empty, or suspends a coroutine while the channel is empty. Throws CoChannelError when canceled or closed.DeclarationSwift public func awaitReceive() throws -> ElementReturn ValueRemoved value from the channel. 
- 
                  
                  Retrieves and removes an element from this channel. DeclarationSwift public func poll() -> Element?Return ValueElement from this channel if its not empty, or returns nill if the channel is empty or is closed or canceled. 
- 
                  
                  Adds an observer callback to receive an element from this channel. DeclarationSwift public func whenReceive(_ callback: @escaping (Result<Element, CoChannelError>) -> Void)ParameterscallbackThe callback that is called when a value is received. 
- 
                  
                  Returns a number of elements in this channel. DeclarationSwift public var count: Int { get }
- 
                  
                  Returns trueif the channel is empty (contains no elements), which means no elements to receive.DeclarationSwift public var isEmpty: Bool { get }
- 
                  
                  Returns trueif the channel is closed.DeclarationSwift public var isClosed: Bool { get }
- 
                  
                  Closes the channel and removes all buffered sent elements from it. DeclarationSwift public func cancel()
- 
                  
                  Returns trueif the channel is canceled.DeclarationSwift public var isCanceled: Bool { get }
- 
                  
                  Make an iterator which successively retrieves and removes values from the channel. If next()was called inside a coroutine and there are no more elements in the channel, then the coroutine will be suspended until a new element will be added to the channel or it will be closed or canceled.DeclarationSwift @inlinable public func makeIterator() -> AnyIterator<Element>Return ValueIterator for the channel elements. 
- 
                  
                  Returns a publisher that emits elements of this Receiver.DeclarationSwift public func publisher() -> AnyPublisher<Element, CoChannelError>
 Receiver Class Reference
        Receiver Class Reference