Search Results for

    Show / Hide Table of Contents

    Class ProgressStatusResult

    A factory class that provides static methods for creating ProgressStatusResult<TResult> immutable struct values, which are typically used (to avoid out parameters) when returning an ProgressStatus plus one more result from a method. This is e.g. used by OnOutputRowDemand(). This struct can also be wrapped in a Task when returning from asynchronous methods.

    Note that you must ensure Status is NotCompleted or Succeeded (or IsFailed is false) before using the Result property.

    Inheritance
    Object
    ProgressStatusResult
    Namespace: actionETL
    Assembly: actionETL.dll
    Syntax
    public static class ProgressStatusResult

    Methods

    Create<TResult>(ProgressStatus, TResult)

    A factory that creates a new instance of the immutable ProgressStatusResult<TResult> struct, which are typically used (to avoid out parameters) when returning an ProgressStatus plus one more result from a method. This is e.g. used by OnOutputRowDemand(). This struct can also be wrapped in a Task when returning from asynchronous methods.

    Declaration
    public static ProgressStatusResult<TResult> Create<TResult>(ProgressStatus status, TResult result)
    Parameters
    Type Name Description
    ProgressStatus status

    The resulting status.

    NotCompleted if the operation should continue and Succeeded on successful completion. In both cases result must have a valid value.

    A failure status on failure (IsFailed is true), in which case result will be undefined.

    TResult result

    The result. Only defined when status is NotCompleted or Succeeded.

    Returns
    Type Description
    ProgressStatusResult<TResult>

    The immutable struct. Note that it can be deconstructed for easy access to the members.

    Type Parameters
    Name Description
    TResult

    The type of the result parameter.

    NotCompleted<TResult>(TResult)

    A factory that creates a new instance of the immutable ProgressStatusResult<TResult> struct, with Status set to NotCompleted.

    The class is typically used (to avoid out parameters) when returning an ProgressStatus plus one more result from a method. This is e.g. used by OnOutputRowDemand(). This struct can also be wrapped in a Task when returning from asynchronous methods.

    Declaration
    public static ProgressStatusResult<TResult> NotCompleted<TResult>(TResult result)
    Parameters
    Type Name Description
    TResult result

    The result.

    Returns
    Type Description
    ProgressStatusResult<TResult>

    The immutable struct. Note that it can be deconstructed for easy access to the members.

    Type Parameters
    Name Description
    TResult

    The type of the result parameter.

    Succeeded<TResult>(TResult)

    A factory that creates a new instance of the immutable ProgressStatusResult<TResult> struct, with Status set to Succeeded.

    The class is typically used (to avoid out parameters) when returning an ProgressStatus plus one more result from a method. This is e.g. used by OnOutputRowDemand(). This struct can also be wrapped in a Task when returning from asynchronous methods.

    Declaration
    public static ProgressStatusResult<TResult> Succeeded<TResult>(TResult result)
    Parameters
    Type Name Description
    TResult result

    The result.

    Returns
    Type Description
    ProgressStatusResult<TResult>

    The immutable struct. Note that it can be deconstructed for easy access to the members.

    Type Parameters
    Name Description
    TResult

    The type of the result parameter.

    In This Article
    Back to top Copyright © 2023 Envobi Ltd