class Marmot::OnChannelTask(T)

Defined in:

tasks.cr

Constructors

Instance Method Summary

Instance methods inherited from class Marmot::Task

cancel cancel, canceled? : Bool canceled?

Constructor Detail

def self.new(channel : Channel(T), callback : Callback) #

[View source]

Instance Method Detail

def value : T | Nil #

Gets the value received on the channel.

If the channel is closed a nil value will saved here, and the task will run one last time.


[View source]