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