Class HistoryRecordDataExtensions
Extension methods to make it easy to fetch HistoryRecordData objects from the database,
using the TargetedSelect infrastructure
Inheritance
HistoryRecordDataExtensions
Assembly: SoDataBase.dll
Syntax
public static class HistoryRecordDataExtensions
Methods
FromRecord(TargetedDataRecord<HistoryTableInfo>)
From a TargetedDataRecord<HistoryTableInfo>, create and populate a HistoryRecordData POCO object
Declaration
public static HistoryRecordData FromRecord(this TargetedDataRecord<HistoryTableInfo> 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 { HistoryItem = r.FromRecord(), /* fetch other fields here */ });
FromSelect(TargetedSelect<HistoryTableInfo>)
From a TargetedSelect<HistoryTableInfo>, execute it and return an IEnumerable<HistoryRecordData> with the results
Declaration
public static IEnumerable<HistoryRecordData> FromSelect(this TargetedSelect<HistoryTableInfo> select)
Parameters
Returns
Examples
var s = S.NewSelect<DataRightTableInfo>( /* add meaningful restrictions here, or later */ );
var result = s.FromSelect();
FromSelectAsync(TargetedSelect<HistoryTableInfo>, CancellationToken)
From a TargetedSelect<HistoryTableInfo>, execute it and return an IEnumerable<HistoryRecordData> with the results
Declaration
[CreateSyncVersion(OmitNullableDirective = true)]
public static IAsyncEnumerable<HistoryRecordData> FromSelectAsync(this TargetedSelect<HistoryTableInfo> select, CancellationToken cancellationToken = default)
Parameters
Returns
Examples
var s = S.NewSelect<DataRightTableInfo>( /* add meaningful restrictions here, or later */ );
var result = s.FromSelect();
ToInsertAsync(HistoryRecordData, CancellationToken)
Extension methods to make it easy to fetch HistoryRecordData objects from the database,
using the TargetedSelect infrastructure
Declaration
public static Task<Insert> ToInsertAsync(this HistoryRecordData record, CancellationToken cancellationToken = default)
Parameters
Returns
ToInsertsAsync(IEnumerable<HistoryRecordData>, CancellationToken)
Extension methods to make it easy to fetch HistoryRecordData objects from the database,
using the TargetedSelect infrastructure
Declaration
public static IAsyncEnumerable<Insert> ToInsertsAsync(this IEnumerable<HistoryRecordData> records, CancellationToken cancellationToken = default)
Parameters
Returns
ToRecordData(HistoryRow)
Extension methods to make it easy to fetch HistoryRecordData objects from the database,
using the TargetedSelect infrastructure
Declaration
public static HistoryRecordData ToRecordData(this HistoryRow row)
Parameters
Returns