Search Results for

    Show / Hide Table of Contents

    Class FluentTransactionExtension

    Contains all fluent operations as extension method

    Inheritance
    System.Object
    FluentTransactionExtension
    Inherited Members
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: Simplic.Data
    Assembly: Simplic.Data.dll
    Syntax
    public static class FluentTransactionExtension

    Methods

    | Improve this Doc View Source

    AbortAsync(IFluentTransactionBuilder)

    Abort the actual transaction and undo changes

    Declaration
    public static async Task AbortAsync(this IFluentTransactionBuilder builder)
    Parameters
    Type Name Description
    IFluentTransactionBuilder builder

    Actual builder instance

    Returns
    Type Description
    System.Threading.Tasks.Task
    | Improve this Doc View Source

    AddService<TService, TModel, TId>(IFluentTransactionBuilder, TService)

    Add a service to the actual fluent builder

    Declaration
    public static IFluentTransactionBuilder AddService<TService, TModel, TId>(this IFluentTransactionBuilder builder, TService service)
        where TService : ITransactionRepository<TModel, TId> where TModel : new()
    Parameters
    Type Name Description
    IFluentTransactionBuilder builder

    Actual builder instance

    TService service

    Service to register/add

    Returns
    Type Description
    IFluentTransactionBuilder

    The builder instance that was passed to the method

    Type Parameters
    Name Description
    TService

    Service type

    TModel

    Object type

    TId

    Object unique id type

    | Improve this Doc View Source

    CommitAsync(IFluentTransactionBuilder)

    Commit all operations

    Declaration
    public static async Task CommitAsync(this IFluentTransactionBuilder builder)
    Parameters
    Type Name Description
    IFluentTransactionBuilder builder

    Actual builder instance

    Returns
    Type Description
    System.Threading.Tasks.Task
    | Improve this Doc View Source

    Create<TService, TModel, TId>(IFluentTransactionBuilder, Func<ITransactionRepository<TModel, TId>, TModel>)

    Calls the create method from a service

    Declaration
    public static IFluentTransactionBuilder Create<TService, TModel, TId>(this IFluentTransactionBuilder builder, Func<ITransactionRepository<TModel, TId>, TModel> func)
        where TService : ITransactionRepository<TModel, TId> where TModel : new()
    Parameters
    Type Name Description
    IFluentTransactionBuilder builder

    Actual builder instance

    System.Func<ITransactionRepository<TModel, TId>, TModel> func

    Delegate for getting the data to create

    Returns
    Type Description
    IFluentTransactionBuilder

    The builder instance that was passed to the method

    Type Parameters
    Name Description
    TService

    Service type

    TModel

    Object type

    TId

    Object unique id type

    | Improve this Doc View Source

    Delete<TService, TModel, TId>(IFluentTransactionBuilder, Func<ITransactionRepository<TModel, TId>, TId>)

    Calls the delete method from a service

    Declaration
    public static IFluentTransactionBuilder Delete<TService, TModel, TId>(this IFluentTransactionBuilder builder, Func<ITransactionRepository<TModel, TId>, TId> func)
        where TService : ITransactionRepository<TModel, TId> where TModel : new()
    Parameters
    Type Name Description
    IFluentTransactionBuilder builder

    Actual builder instance

    System.Func<ITransactionRepository<TModel, TId>, TId> func

    Delegate for getting the id of the data to delete

    Returns
    Type Description
    IFluentTransactionBuilder

    The builder instance that was passed to the method

    Type Parameters
    Name Description
    TService

    Service type

    TModel

    Object type

    TId

    Object unique id type

    | Improve this Doc View Source

    Update<TService, TModel, TId>(IFluentTransactionBuilder, Func<ITransactionRepository<TModel, TId>, TModel>)

    Calls the update method from a service

    Declaration
    public static IFluentTransactionBuilder Update<TService, TModel, TId>(this IFluentTransactionBuilder builder, Func<ITransactionRepository<TModel, TId>, TModel> func)
        where TService : ITransactionRepository<TModel, TId> where TModel : new()
    Parameters
    Type Name Description
    IFluentTransactionBuilder builder

    Actual builder instance

    System.Func<ITransactionRepository<TModel, TId>, TModel> func

    Delegate for getting the data to update

    Returns
    Type Description
    IFluentTransactionBuilder

    The builder instance that was passed to the method

    Type Parameters
    Name Description
    TService

    Service type

    TModel

    Object type

    TId

    Object unique id type

    • Improve this Doc
    • View Source
    In This Article
    Back to top Copyright © 2018 SIMPLIC GmbH
    Generated by DocFx