Flow<'env, 'error, 'value>Union

PackageAxial
Represents a cold workflow that reads an environment, returns a typed result, and is executed explicitly through one of its execution members such as ToTask, ToAsync, or RunSynchronously.

Specification

Kind
Union
Members
4
Examples
0
RunSynchronouslySignature
this.RunSynchronously
StartAsTaskSignature
this.StartAsTask
StartAsValueTaskSignature
this.StartAsValueTask
ToAsyncSignature
this.ToAsync

Summary

NameSignatureSynopsis
RunSynchronouslythis.RunSynchronouslyStarts the workflow and blocks until the final exit is available.
StartAsTaskthis.StartAsTaskStarts the workflow immediately and returns a task handle for its final exit.
StartAsValueTaskthis.StartAsValueTaskStarts the workflow immediately and returns a value-task handle for its final exit.
ToAsyncthis.ToAsyncBuilds a cold async that runs the workflow when it is started.

RunSynchronously

this.RunSynchronously
Member
Starts the workflow and blocks until the final exit is available.

Parameters

NameTypeDescription
environment'envThe environment used by the workflow.
timeoutint
cancellationTokenCancellationToken

Returns

Exit<'value, 'error>

StartAsTask

this.StartAsTask
Member
Starts the workflow immediately and returns a task handle for its final exit.

Parameters

NameTypeDescription
environment'envThe environment used by the workflow.
cancellationTokenCancellationToken

Returns

Task<Exit<'value, 'error>>

StartAsValueTask

this.StartAsValueTask
Member
Starts the workflow immediately and returns a value-task handle for its final exit.

Parameters

NameTypeDescription
environment'envThe environment used by the workflow.
cancellationTokenCancellationToken

Returns

ValueTask<Exit<'value, 'error>>

ToAsync

this.ToAsync
Member
Builds a cold async that runs the workflow when it is started.

Parameters

NameTypeDescription
environment'envThe environment used by the workflow.
cancellationTokenCancellationToken

Returns

Async<Exit<'value, 'error>>