Search Results for

    Show / Hide Table of Contents

    Class DataSetProcessorFactory

    A helper factory that loads all implementations of IBaseDataSetProcessorFactory and allows the system to create them automatically where required

    Inheritance
    System.Object
    DataSetProcessorFactory
    Inherited Members
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: LemonEdge.API.Processors
    Assembly: API.dll
    Syntax
    public static class DataSetProcessorFactory

    Methods

    Create(IBaseEntity, IEntityUpdater, IReadOnlyCache, UserInfo, Type)

    Returns a new instance of the processor (either specified via processorType, or the default)

    Declaration
    public static IBaseDataSetProcessor Create(IBaseEntity forItem, IEntityUpdater updater, IReadOnlyCache cache, UserInfo user, Type processorType = null)
    Parameters
    Type Name Description
    IBaseEntity forItem

    The item to create a processor for

    IEntityUpdater updater

    A context for querying and updating all items in the LemonEdge platform

    IReadOnlyCache cache

    A local current cache

    UserInfo user

    The current logged in user

    System.Type processorType

    An optional type when requiring a processor of a specific type if it can be involved in more than one

    Returns
    Type Description
    IBaseDataSetProcessor

    A new instance of the processor (either specified via processorType, or the default)

    GetPossibleSaveProcessorTypes(Type)

    Returns an enumeration of processor types that can be created for the specified entity type.

    Also includes a function for each one which specifies if the type is valid against an instance of the entity.

    Declaration
    public static IEnumerable<(Type ProcessorType, Func<IBaseEntity, bool> BelongsInProcessorType)> GetPossibleSaveProcessorTypes(Type forItemType)
    Parameters
    Type Name Description
    System.Type forItemType

    The type of item to return possible processor types that can work against them

    Returns
    Type Description
    System.Collections.Generic.IEnumerable<System.ValueTuple<System.Type, System.Func<IBaseEntity, System.Boolean>>>

    An enumeration of processor types that can be created for the specified entity type

    HasProcessor(Type)

    Returns true if the specified entity type has one or more associated processors that can work with it

    Declaration
    public static bool HasProcessor(Type type)
    Parameters
    Type Name Description
    System.Type type

    The type of entity to check if a processor works with it

    Returns
    Type Description
    System.Boolean

    True if the specified entity type has one or more associated processors that can work with it

    HasSaveProcessor(Type)

    Returns true if the specified entity type has an associated processor that implements IBaseDataSetProcessorWithDBSave

    Declaration
    public static bool HasSaveProcessor(Type type)
    Parameters
    Type Name Description
    System.Type type

    The type of entity to check if a processor of type IBaseDataSetProcessorWithDBSave works with it

    Returns
    Type Description
    System.Boolean

    True if the specified entity type has an associated processor that implements IBaseDataSetProcessorWithDBSave

    See Also

    IBaseDataSetProcessorFactory
    In This Article
    Back to top © LemonEdge Technology. All rights reserved.