Table of Contents

Class WithStartWorkflowOperation

Namespace
Temporalio.Client
Assembly
Temporalio.dll

Representation of a workflow start operation to be used in WorkflowStartUpdateWithStartOptions and WorkflowUpdateWithStartOptions for update with start calls.

public abstract class WithStartWorkflowOperation : ICloneable
Inheritance
WithStartWorkflowOperation
Implements
Derived
Inherited Members

Remarks

WARNING: Workflow update with start is experimental and APIs may change.

Properties

Args

Gets or sets the workflow arguments.

public IReadOnlyCollection<object?> Args { get; set; }

Property Value

IReadOnlyCollection<object>

Headers

Gets or sets the workflow headers.

public IDictionary<string, Payload>? Headers { get; set; }

Property Value

IDictionary<string, Payload>

Remarks

NOTE: Some interceptors may mutate the dictionary.

Options

Gets or sets the workflow options.

public WorkflowOptions Options { get; set; }

Property Value

WorkflowOptions

Workflow

Gets or sets the workflow type to start.

public string Workflow { get; set; }

Property Value

string

Methods

Clone()

Create a shallow copy of this operation.

public abstract object Clone()

Returns

object

A shallow copy of these options and any transitive options fields. But it will not clone the arguments, headers, nor will it clone the underlying promise that is fulfilled when the workflow has started.

Create(string, IReadOnlyCollection<object?>, WorkflowOptions)

Create a start workflow operation by name.

public static WithStartWorkflowOperation<WorkflowHandle> Create(string workflow, IReadOnlyCollection<object?> args, WorkflowOptions options)

Parameters

workflow string

Workflow type name.

args IReadOnlyCollection<object>

Arguments for the workflow.

options WorkflowOptions

Start workflow options. Id, TaskQueue, and IdConflictPolicy are required. StartSignal, StartSignalArgs, RequestEagerStart, and Rpc are disallowed.

Returns

WithStartWorkflowOperation<WorkflowHandle>

Start workflow operation.

Remarks

WARNING: Workflow update with start is experimental and APIs may change.

Create<TWorkflow>(Expression<Func<TWorkflow, Task>>, WorkflowOptions)

Create a start workflow operation via lambda invoking the run method.

public static WithStartWorkflowOperation<WorkflowHandle<TWorkflow>> Create<TWorkflow>(Expression<Func<TWorkflow, Task>> workflowRunCall, WorkflowOptions options)

Parameters

workflowRunCall Expression<Func<TWorkflow, Task>>

Invocation of workflow run method.

options WorkflowOptions

Start workflow options. Id, TaskQueue, and IdConflictPolicy are required. StartSignal, StartSignalArgs, RequestEagerStart, and Rpc are disallowed.

Returns

WithStartWorkflowOperation<WorkflowHandle<TWorkflow>>

Start workflow operation.

Type Parameters

TWorkflow

Workflow class type.

Remarks

WARNING: Workflow update with start is experimental and APIs may change.

Create<TWorkflow, TResult>(Expression<Func<TWorkflow, Task<TResult>>>, WorkflowOptions)

Create a start workflow operation via lambda invoking the run method.

public static WithStartWorkflowOperation<WorkflowHandle<TWorkflow, TResult>> Create<TWorkflow, TResult>(Expression<Func<TWorkflow, Task<TResult>>> workflowRunCall, WorkflowOptions options)

Parameters

workflowRunCall Expression<Func<TWorkflow, Task<TResult>>>

Invocation of workflow run method with a result.

options WorkflowOptions

Start workflow options. Id, TaskQueue, and IdConflictPolicy are required. StartSignal, StartSignalArgs, RequestEagerStart, and Rpc are disallowed.

Returns

WithStartWorkflowOperation<WorkflowHandle<TWorkflow, TResult>>

Start workflow operation.

Type Parameters

TWorkflow

Workflow class type.

TResult

Workflow result type.

Remarks

WARNING: Workflow update with start is experimental and APIs may change.