Table of Contents

Class EntityProviderBase

Namespace
JJMasterData.Commons.Data.Entity.Providers
Assembly
JJMasterData.Commons.dll
public abstract class EntityProviderBase
Inheritance
EntityProviderBase
Derived
Inherited Members

Constructors

EntityProviderBase(IOptionsSnapshot<MasterDataCommonsOptions>, ILoggerFactory)

protected EntityProviderBase(IOptionsSnapshot<MasterDataCommonsOptions> options, ILoggerFactory loggerFactory)

Parameters

options IOptionsSnapshot<MasterDataCommonsOptions>
loggerFactory ILoggerFactory

Properties

Options

protected MasterDataCommonsOptions Options { get; }

Property Value

MasterDataCommonsOptions

VariablePrefix

public abstract string VariablePrefix { get; }

Property Value

string

Methods

CreateDataModel(Element, List<RelationshipReference>?)

public void CreateDataModel(Element element, List<RelationshipReference>? relationships = null)

Parameters

element Element
relationships List<RelationshipReference>

CreateDataModelAsync(Element, List<RelationshipReference>?)

public Task CreateDataModelAsync(Element element, List<RelationshipReference>? relationships = null)

Parameters

element Element
relationships List<RelationshipReference>

Returns

Task

Delete(Element, Dictionary<string, object>)

public int Delete(Element element, Dictionary<string, object> primaryKeys)

Parameters

element Element
primaryKeys Dictionary<string, object>

Returns

int

DeleteAsync(Element, Dictionary<string, object>)

public Task<int> DeleteAsync(Element element, Dictionary<string, object> primaryKeys)

Parameters

element Element
primaryKeys Dictionary<string, object>

Returns

Task<int>

GetAlterTableScript(Element, IEnumerable<ElementField>)

public abstract string? GetAlterTableScript(Element element, IEnumerable<ElementField> addedFields)

Parameters

element Element
addedFields IEnumerable<ElementField>

Returns

string

GetCreateTableScript(Element, List<RelationshipReference>?)

public abstract string GetCreateTableScript(Element element, List<RelationshipReference>? relationships = null)

Parameters

element Element
relationships List<RelationshipReference>

Returns

string

GetDeleteCommand(Element, Dictionary<string, object>)

public abstract DataAccessCommand GetDeleteCommand(Element element, Dictionary<string, object> primaryKeys)

Parameters

element Element
primaryKeys Dictionary<string, object>

Returns

DataAccessCommand

GetDictionaryList(Element, EntityParameters, bool)

public DictionaryListResult GetDictionaryList(Element element, EntityParameters entityParameters, bool recoverTotalOfRecords = true)

Parameters

element Element
entityParameters EntityParameters
recoverTotalOfRecords bool

Returns

DictionaryListResult

GetDictionaryListAsync(Element, EntityParameters, bool)

public Task<DictionaryListResult> GetDictionaryListAsync(Element element, EntityParameters entityParameters, bool recoverTotalOfRecords = true)

Parameters

element Element
entityParameters EntityParameters
recoverTotalOfRecords bool

Returns

Task<DictionaryListResult>

GetElementFromTableAsync(string, Guid?)

public abstract Task<Element> GetElementFromTableAsync(string tableName, Guid? connectionId = null)

Parameters

tableName string
connectionId Guid?

Returns

Task<Element>

GetFieldsListAsTextAsync(Element, EntityParameters, bool, string)

public Task<string> GetFieldsListAsTextAsync(Element element, EntityParameters entityParameters, bool showLogInfo, string delimiter = "|")

Parameters

element Element
entityParameters EntityParameters
showLogInfo bool
delimiter string

Returns

Task<string>

GetInsertCommand(Element, Dictionary<string, object?>)

public abstract DataAccessCommand GetInsertCommand(Element element, Dictionary<string, object?> values)

Parameters

element Element
values Dictionary<string, object>

Returns

DataAccessCommand

GetInsertOrReplaceCommand(Element, Dictionary<string, object?>)

protected abstract DataAccessCommand GetInsertOrReplaceCommand(Element element, Dictionary<string, object?> values)

Parameters

element Element
values Dictionary<string, object>

Returns

DataAccessCommand

GetReadCommand(Element, EntityParameters, DataAccessParameter)

public abstract DataAccessCommand GetReadCommand(Element element, EntityParameters parameters, DataAccessParameter totalOfRecordsParameter)

Parameters

element Element
parameters EntityParameters
totalOfRecordsParameter DataAccessParameter

Returns

DataAccessCommand

GetReadProcedureScript(Element)

public abstract string? GetReadProcedureScript(Element element)

Parameters

element Element

Returns

string

GetUpdateCommand(Element, Dictionary<string, object?>)

public abstract DataAccessCommand GetUpdateCommand(Element element, Dictionary<string, object?> values)

Parameters

element Element
values Dictionary<string, object>

Returns

DataAccessCommand

GetWriteProcedureScript(Element)

public abstract string? GetWriteProcedureScript(Element element)

Parameters

element Element

Returns

string

Insert(Element, Dictionary<string, object?>)

public void Insert(Element element, Dictionary<string, object?> values)

Parameters

element Element
values Dictionary<string, object>

InsertAsync(Element, Dictionary<string, object?>)

public Task InsertAsync(Element element, Dictionary<string, object?> values)

Parameters

element Element
values Dictionary<string, object>

Returns

Task

SetValues(Element, Dictionary<string, object?>, bool)

public CommandOperation SetValues(Element element, Dictionary<string, object?> values, bool ignoreResults)

Parameters

element Element
values Dictionary<string, object>
ignoreResults bool

Returns

CommandOperation

SetValuesAsync(Element, Dictionary<string, object?>)

public Task<CommandOperation> SetValuesAsync(Element element, Dictionary<string, object?> values)

Parameters

element Element
values Dictionary<string, object>

Returns

Task<CommandOperation>

SetValuesAsync(Element, Dictionary<string, object?>, bool)

public Task<CommandOperation> SetValuesAsync(Element element, Dictionary<string, object?> values, bool ignoreResults)

Parameters

element Element
values Dictionary<string, object>
ignoreResults bool

Returns

Task<CommandOperation>

Update(Element, Dictionary<string, object?>)

public int Update(Element element, Dictionary<string, object?> values)

Parameters

element Element
values Dictionary<string, object>

Returns

int

UpdateAsync(Element, Dictionary<string, object?>)

public Task<int> UpdateAsync(Element element, Dictionary<string, object?> values)

Parameters

element Element
values Dictionary<string, object>

Returns

Task<int>