Search Results for

    Show / Hide Table of Contents

    Interface IFluentTransactionBuilder

    Builds and stores all information for a transaction that is represented in fluent-style

    Namespace: Simplic.Data
    Assembly: Simplic.Data.dll
    Syntax
    public interface IFluentTransactionBuilder

    Properties

    | Improve this Doc View Source

    Tasks

    Gets the actual list of tasks to execute when committing or aborting

    Declaration
    IList<Func<Task>> Tasks { get; }
    Property Value
    Type Description
    System.Collections.Generic.IList<System.Func<System.Threading.Tasks.Task>>
    | Improve this Doc View Source

    TransactionService

    Gets the transaction service for executing transaction operations on commit and abort

    Declaration
    ITransactionService TransactionService { get; }
    Property Value
    Type Description
    ITransactionService

    Methods

    | Improve this Doc View Source

    AddService<TModel, TId>(ITransactionRepository<TModel, TId>)

    Adds a service-instance to the current builder

    Declaration
    void AddService<TModel, TId>(ITransactionRepository<TModel, TId> service)
        where TModel : new()
    Parameters
    Type Name Description
    ITransactionRepository<TModel, TId> service

    Service instance

    Type Parameters
    Name Description
    TModel

    Object type

    TId

    Unique id type

    | Improve this Doc View Source

    GetService<TModel, TId>()

    Gets a service from the builder

    Declaration
    ITransactionRepository<TModel, TId> GetService<TModel, TId>()
        where TModel : new()
    Returns
    Type Description
    ITransactionRepository<TModel, TId>

    Service instance

    Type Parameters
    Name Description
    TModel

    Object type

    TId

    Unique id type

    | Improve this Doc View Source

    GetTransaction()

    Creates a new transaction if no transaction is existing. Only one instance will be created during builder-lifetime.

    Declaration
    Task<ITransaction> GetTransaction()
    Returns
    Type Description
    System.Threading.Tasks.Task<ITransaction>

    Transaction instance

    Extension Methods

    FluentTransactionExtension.AddService<TService, TModel, TId>(IFluentTransactionBuilder, TService)
    FluentTransactionExtension.Create<TService, TModel, TId>(IFluentTransactionBuilder, Func<ITransactionRepository<TModel, TId>, TModel>)
    FluentTransactionExtension.Update<TService, TModel, TId>(IFluentTransactionBuilder, Func<ITransactionRepository<TModel, TId>, TModel>)
    FluentTransactionExtension.Delete<TService, TModel, TId>(IFluentTransactionBuilder, Func<ITransactionRepository<TModel, TId>, TId>)
    FluentTransactionExtension.CommitAsync(IFluentTransactionBuilder)
    FluentTransactionExtension.AbortAsync(IFluentTransactionBuilder)
    • Improve this Doc
    • View Source
    In This Article
    Back to top Copyright © 2018 SIMPLIC GmbH
    Generated by DocFx