Workflow Engine .NET

Assembly: OptimaJet.Workflow.Core

Class BulkTaskResult<TResult>

OptimaJet.Workflow.Core.Runtime.Bulk.BulkTaskResult<TResult>

Represents the result of a bulk task execution. For tasks that have not finished, BulkTaskResult<TResult>.Empty is used.

public record BulkTaskResult<TResult> : IEquatable<BulkTaskResult<TResult>>

Inheritance

  • Object

Implemented Interfaces

  • System.IEquatable{OptimaJet.Workflow.Core.Runtime.Bulk.BulkTaskResult`1}

Constructors

public BulkTaskResult(BulkTaskState State, TResult? Result = default, Exception? Exception = null, DateTimeOffset? StartedAt = null, DateTimeOffset? FinalizedAt = null) #
Represents the result of a bulk task execution. For tasks that have not finished, BulkTaskResult<TResult>.Empty is used.

Parameters

Name
Type
Description
State
BulkTaskState
The state of the task.
Result
{TResult}
If the task has completed with the status BulkTaskState.Completed, the result will be stored here; otherwise, it will be null.
Exception
Exception
If the task has completed with the status BulkTaskState.Failed, the exception will be stored here; otherwise, it will be null.
StartedAt
Nullable<DateTimeOffset>
The timestamp recorded when the task transitions to BulkTaskState.Running and before task execution starts.
FinalizedAt
Nullable<DateTimeOffset>
The timestamp recorded after transitioning to BulkTaskState.Completed or BulkTaskState.Failed, before the task result is returned.

Properties

Name
Type
State #
BulkTaskState
The state of the task.
Result #
{TResult}
If the task has completed with the status BulkTaskState.Completed, the result will be stored here; otherwise, it will be null.
Exception #
Exception
If the task has completed with the status BulkTaskState.Failed, the exception will be stored here; otherwise, it will be null.
StartedAt #
Nullable<DateTimeOffset>
The timestamp recorded when the task transitions to BulkTaskState.Running and before task execution starts.
FinalizedAt #
Nullable<DateTimeOffset>
The timestamp recorded after transitioning to BulkTaskState.Completed or BulkTaskState.Failed, before the task result is returned.
Empty #
BulkTaskResult<TResult>
Gets a canonical result value for a task that has not yet started.
Duration #
Nullable<TimeSpan>
Gets the elapsed time between task start and finalization.