Skip to contents

R6 class for relay configuration.

Details

See crew_relay().

See also

Other relay: crew_relay()

Active bindings

condition

Main condition variable.

from

Condition variable to relay from.

to

Condition variable to relay to.

throttle

A crew_throttle() object for wait().

Methods


crew_class_relay$new()

Relay constructor.

Usage

crew_class_relay$new(throttle)

Arguments

throttle

A crew_throttle() object.

Returns

A crew_relay() object.


crew_class_relay$validate()

Validate the object.

Usage

crew_class_relay$validate()

Returns

NULL (invisibly).


crew_class_relay$start()

Start the relay object.

Usage

crew_class_relay$start()

Returns

NULL (invisibly).


crew_class_relay$terminate()

Terminate the relay object.

Usage

crew_class_relay$terminate()

Returns

NULL (invisibly).


crew_class_relay$set_from()

Set the condition variable to relay from.

Usage

crew_class_relay$set_from(from)

Arguments

from

Condition variable to relay from.

Returns

NULL (invisibly).


crew_class_relay$set_to()

Set the condition variable to relay to.

Usage

crew_class_relay$set_to(to)

Arguments

to

Condition variable to relay to.

Returns

NULL (invisibly).


crew_class_relay$wait()

Wait until an unobserved task resolves or the timeout is reached. Use the throttle to determine the waiting time.

Usage

crew_class_relay$wait()

Returns

NULL (invisibly).

Examples

crew_relay()
#> <crew_class_relay>
#>   Public:
#>     condition: active binding
#>     from: active binding
#>     initialize: function (throttle) 
#>     private: environment
#>     self: crew_class_relay, R6
#>     set_from: function (from) 
#>     set_to: function (to) 
#>     start: function () 
#>     terminate: function () 
#>     throttle: active binding
#>     to: active binding
#>     validate: function () 
#>     wait: function () 
#>   Private:
#>     .condition: NULL
#>     .from: NULL
#>     .throttle: crew_class_throttle, R6
#>     .to: NULL