Class DictionaryRecordDataExtensions
Extension methods to make it easy to fetch DictionaryRecordData objects from the database,
using the TargetedSelect infrastructure
Inheritance
DictionaryRecordDataExtensions
Assembly: SoDataBase.dll
Syntax
public static class DictionaryRecordDataExtensions
Methods
FromRecord(TargetedDataRecord<DictionaryTableInfo>)
From a TargetedDataRecord<DictionaryTableInfo>, create and populate a DictionaryRecordData POCO object
Declaration
public static DictionaryRecordData FromRecord(this TargetedDataRecord<DictionaryTableInfo> record)
Parameters
Returns
Examples
var s = S.NewSelect<DataRightTableInfo>( /* add meaningful restrictions here, or later */ );
/* add joins, return fields etc. as you wish */
s.ReturnFields.Add(s.Table.All);
var result = s.Records().Select(r => new { DictionaryItem = r.FromRecord(), /* fetch other fields here */ });
FromSelect(TargetedSelect<DictionaryTableInfo>)
From a TargetedSelect<DictionaryTableInfo>, execute it and return an IEnumerable<DictionaryRecordData> with the results
Declaration
public static IEnumerable<DictionaryRecordData> FromSelect(this TargetedSelect<DictionaryTableInfo> select)
Parameters
Returns
Examples
var s = S.NewSelect<DataRightTableInfo>( /* add meaningful restrictions here, or later */ );
var result = s.FromSelect();
FromSelectAsync(TargetedSelect<DictionaryTableInfo>, CancellationToken)
From a TargetedSelect<DictionaryTableInfo>, execute it and return an IEnumerable<DictionaryRecordData> with the results
Declaration
[CreateSyncVersion(OmitNullableDirective = true)]
public static IAsyncEnumerable<DictionaryRecordData> FromSelectAsync(this TargetedSelect<DictionaryTableInfo> select, CancellationToken cancellationToken = default)
Parameters
Returns
Examples
var s = S.NewSelect<DataRightTableInfo>( /* add meaningful restrictions here, or later */ );
var result = s.FromSelect();
ToInsertAsync(DictionaryRecordData, CancellationToken)
Extension methods to make it easy to fetch DictionaryRecordData objects from the database,
using the TargetedSelect infrastructure
Declaration
public static Task<Insert> ToInsertAsync(this DictionaryRecordData record, CancellationToken cancellationToken = default)
Parameters
Returns
ToInsertsAsync(IEnumerable<DictionaryRecordData>, CancellationToken)
Extension methods to make it easy to fetch DictionaryRecordData objects from the database,
using the TargetedSelect infrastructure
Declaration
public static IAsyncEnumerable<Insert> ToInsertsAsync(this IEnumerable<DictionaryRecordData> records, CancellationToken cancellationToken = default)
Parameters
Returns
ToRecordData(DictionaryRow)
Extension methods to make it easy to fetch DictionaryRecordData objects from the database,
using the TargetedSelect infrastructure
Declaration
public static DictionaryRecordData ToRecordData(this DictionaryRow row)
Parameters
Returns