Search Results for

    Show / Hide Table of Contents

    Class OpenOrRefreshResultItem<T>

    An implementation of OpenOrRefreshResultItem that works with a specific type T of the result type to be processed for a task

    This handler will open, or refresh, each entity type/id specified as being part of the results of a task so the user can see those items immediately as being data this task updated

    Inheritance
    object
    OpenOrRefreshResultItem
    OpenOrRefreshResultItem<T>
    AlgorithmResultHandler
    BlendResultProcessor
    CustomObjectSaveResultProcessor
    GroupedTransactionResultProcessor
    ObjectEntityTypeResultProcessor
    PeriodEndResultProcessor
    SplitResultProcessor
    StepChangeResultProcessorHandler
    TransactionRevertResultHandler
    TransferResultProcessorHandler
    WatcherNotificationHandler
    Implements
    IClientTaskResultHandler
    ITaskResultHandler
    Inherited Members
    OpenOrRefreshResultItem.Init(IModelLayoutCommon)
    OpenOrRefreshResultItem.ProcessResult(IServerTask, IServerTaskData)
    OpenOrRefreshResultItem.ProcessRawResult(ITaskRunner, ServerTaskParameter, object)
    OpenOrRefreshResultItem.GetItemsToOpenOrRefresh(IServerTask, IServerTaskData)
    OpenOrRefreshResultItem.Displayer
    object.GetType()
    object.MemberwiseClone()
    object.ToString()
    object.Equals(object)
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetHashCode()
    Namespace: LemonEdge.Client.Core.Tasks
    Assembly: LemonEdge.ClientCore.dll
    Syntax
    public abstract class OpenOrRefreshResultItem<T> : OpenOrRefreshResultItem, IClientTaskResultHandler, ITaskResultHandler where T : ServerTaskResult
    Type Parameters
    Name Description
    T

    The servertask result type that this class handles for a task

    Constructors

    OpenOrRefreshResultItem()

    Declaration
    protected OpenOrRefreshResultItem()

    Methods

    ConvertRawResultIntoResult(ServerTaskParameter, object)

    Calls ConvertRawResultIntoResultType(ServerTaskParameter, object) which returns a type T instead

    Declaration
    protected override sealed Task<ServerTaskResult> ConvertRawResultIntoResult(ServerTaskParameter parameter, object rawResult)
    Parameters
    Type Name Description
    ServerTaskParameter parameter

    The parameter that was used to run the task

    object rawResult

    The raw result of running the task

    Returns
    Type Description
    Task<ServerTaskResult>

    A conversion of the raw task result into T which is an appropriate ServerTaskResult

    Overrides
    OpenOrRefreshResultItem.ConvertRawResultIntoResult(ServerTaskParameter, object)

    ConvertRawResultIntoResultType(ServerTaskParameter, object)

    Must be implemented by a derived type to convert the raw task result into type T

    Declaration
    protected abstract Task<T> ConvertRawResultIntoResultType(ServerTaskParameter parameter, object rawResult)
    Parameters
    Type Name Description
    ServerTaskParameter parameter

    The parameter that was used to run the task

    object rawResult

    The raw result of running the task

    Returns
    Type Description
    Task<T>

    A conversion of the raw task result into type T

    GetItemToOpenOrRefresh(SerializedParam)

    Calls GetItemToOpenOrRefresh(T) converting the result type into the expected type T

    You must override either the GetItemToOpenOrRefresh(T) or the GetItemsToOpenOrRefresh(T) method

    Declaration
    protected override sealed (Guid TypeID, Guid ID) GetItemToOpenOrRefresh(SerializedParam resultInfo)
    Parameters
    Type Name Description
    SerializedParam resultInfo

    The result of the task that this is handling that should be of type T

    Returns
    Type Description
    (Guid TypeID, Guid ID)

    The single entity type/id item that should be handled by this class

    Overrides
    OpenOrRefreshResultItem.GetItemToOpenOrRefresh(SerializedParam)

    GetItemToOpenOrRefresh(T)

    Should be implemented by a derived type to retrieve the entity type/id for a single item that must be opened or refreshed by this handler

    You must override either the GetItemsToOpenOrRefresh(T) or the GetItemToOpenOrRefresh(T) method

    Declaration
    protected virtual (Guid TypeID, Guid ID) GetItemToOpenOrRefresh(T resultInfo)
    Parameters
    Type Name Description
    T resultInfo

    The result of the task that this is handling

    Returns
    Type Description
    (Guid TypeID, Guid ID)

    The single entity type/id item that should be handled by this class

    GetItemsToOpenOrRefresh(SerializedParam)

    Calls GetItemsToOpenOrRefresh(T)(T) converting the result type into the expected type T

    You must override either the GetItemToOpenOrRefresh(T) or the GetItemsToOpenOrRefresh(T) method

    Declaration
    protected override sealed IEnumerable<(Guid TypeID, Guid ID)> GetItemsToOpenOrRefresh(SerializedParam resultInfo)
    Parameters
    Type Name Description
    SerializedParam resultInfo

    The result of the task that this is handling that should be of type T

    Returns
    Type Description
    IEnumerable<(Guid TypeID, Guid ID)>

    All entity type/id items that should be handled by this class

    Overrides
    OpenOrRefreshResultItem.GetItemsToOpenOrRefresh(SerializedParam)

    GetItemsToOpenOrRefresh(T)

    Should be implemented by a derived type to retrieve the entity type/id for all items that must be opened or refreshed by this handler

    You must override either the GetItemToOpenOrRefresh(T) or the GetItemsToOpenOrRefresh(T) method

    Declaration
    protected virtual IEnumerable<(Guid TypeID, Guid ID)> GetItemsToOpenOrRefresh(T resultInfo)
    Parameters
    Type Name Description
    T resultInfo

    The result of the task that this is handling

    Returns
    Type Description
    IEnumerable<(Guid TypeID, Guid ID)>

    All entity type/id items that should be handled by this class

    ProcessPriorToOpeningResult(SerializedParam)

    Calls ProcessPriorToOpeningResult(T) converting the param into the correct type T

    Declaration
    protected override sealed void ProcessPriorToOpeningResult(SerializedParam param)
    Parameters
    Type Name Description
    SerializedParam param

    The parameter that holds the result of the task to process

    Overrides
    OpenOrRefreshResultItem.ProcessPriorToOpeningResult(SerializedParam)

    ProcessPriorToOpeningResult(T)

    Provides any inheriting implementation the chance to process the rseult before this handler will open, or refresh, the result items

    Declaration
    protected virtual void ProcessPriorToOpeningResult(T param)
    Parameters
    Type Name Description
    T param

    The parameter that holds the result of the task to process

    Implements

    IClientTaskResultHandler
    ITaskResultHandler

    Extension Methods

    LinqExtensions.AsArray<T>(T)
    LinqExtensions.ToArrayOfOne<T>(T)
    LinqExtensions.ToListOfOne<T>(T)
    MiscExtensions.SetIfNotEqual<T, TP>(T, Expression<Func<T, TP>>, TP)
    WeakReferenceExtensions.WeakReference(object)
    SQLExtensions.ToSQLValue(object, bool)
    ReflectionExtensions.ClearEventInvocations(object, string)
    StringExtensions.ToCSVFormatString(object, Type)
    In this article
    Back to top © LemonEdge Technologies. All rights reserved.