Class ActivityContext<TData>
What an activity is given when it runs.
public sealed class ActivityContext<TData>
Type Parameters
TData
- Inheritance
-
ActivityContext<TData>
- Inherited Members
Remarks
Mutating Data is how an activity records its result: the engine persists the document as part of the checkpoint that also completes the activity's job.
Constructors
- ActivityContext(TData, WorkflowInstanceId, string, string, int)
Constructs a context for one activity execution.
Properties
- Data
The workflow's data document. Mutate it to record results.
- DefinitionId
Which workflow this is an instance of.
- InstanceId
The instance this execution belongs to.
- LoopIndex
Zero-based iteration index when this activity runs inside a
ForEachbody; zero otherwise.
- NodeId
The graph node being executed — the same id the persisted cursor carries.
- Version
The definition version this instance started on. An in-flight instance always finishes on the version it started with, so this can differ from the latest registered version.