public static IStream <TParsed> CrossApplyExcelRows <TParsed>(this IStream <ExcelSheetSelection> stream, string name, ExcelFileDefinition <TParsed> mapping, bool noParallelisation = false) => stream.CrossApply(name, new ExcelRowsValuesProvider <ExcelSheetSelection, TParsed, TParsed>(new ExcelRowsValuesProviderArgs <ExcelSheetSelection, TParsed, TParsed> { Mapping = mapping, GetSheetSelection = i => i, GetOutput = (i, j) => i }), noParallelisation);
public static ISortedStream <TIn, TKey> ToExcelFile <TIn, TKey>(this ISortedStream <TIn, TKey> stream, string name, ISingleStream <Stream> resourceStream, ExcelFileDefinition <TIn> mapping = null) { return(new ToExcelFileStreamNode <TIn, ISortedStream <TIn, TKey> >(name, new ToExcelFileArgs <TIn, ISortedStream <TIn, TKey> > { MainStream = stream, TargetStream = resourceStream, Mapping = mapping }).Output); }
public static IStream <IFileValue> ToExcelFile <TIn>(this IStream <TIn> stream, string name, string fileName, ExcelFileDefinition <TIn> mapping = null) { return(new ToExcelFileStreamNode <TIn>(name, new ToExcelFileArgs <TIn> { MainStream = stream, Mapping = mapping, FileName = fileName }).Output); }
public static IStream <TOut> CrossApplyExcelRows <TIn, TParsed, TOut>(this IStream <TIn> stream, string name, ExcelFileDefinition <TParsed> mapping, Func <TIn, ExcelSheetSelection> sheetSelection, Func <TParsed, TIn, TOut> selector, bool noParallelisation = false) => stream.CrossApply(name, new ExcelRowsValuesProvider <TIn, TParsed, TOut>(new ExcelRowsValuesProviderArgs <TIn, TParsed, TOut> { Mapping = mapping, GetSheetSelection = sheetSelection, GetOutput = selector }), noParallelisation);
public ExcelRowsValuesProvider(ExcelFileDefinition <TParsed> mapping) { _mapping = mapping; }
public static IStream <TParsed> CrossApplyExcelRows <TParsed>(this IStream <ExcelSheetSelection> stream, string name, ExcelFileDefinition <TParsed> mapping, bool noParallelisation = false) { var valueProvider = new ExcelRowsValuesProvider <TParsed>(mapping); return(stream.CrossApply <ExcelSheetSelection, ExcelSheetSelection, TParsed, TParsed>(name, valueProvider.PushValues, i => i, (i, s) => i, noParallelisation)); }
public static IStream <TOut> CrossApplyExcelRows <TIn, TParsed, TOut>(this IStream <TIn> stream, string name, ExcelFileDefinition <TParsed> mapping, Func <TIn, ExcelSheetSelection> sheetSelection, Func <TParsed, TIn, TOut> selector, bool noParallelisation = false) { var valueProvider = new ExcelRowsValuesProvider <TParsed>(mapping); return(stream.CrossApply(name, valueProvider.PushValues, sheetSelection, selector, noParallelisation)); }
public static IStream <TParsed> CrossApplyExcelRows <TParsed>(this IStream <ExcelSheetSelection> stream, string name, ExcelFileDefinition <TParsed> mapping) where TParsed : new() { return(stream.CrossApply(name, new ExcelRowsValuesProvider <TParsed>(new ExcelRowsValuesProviderArgs <TParsed> { Mapping = mapping, NoParallelisation = false }), i => i, (i, s) => i)); }
public static IStream <TOut> CrossApplyExcelRows <TIn, TParsed, TOut>(this IStream <TIn> stream, string name, ExcelFileDefinition <TParsed> mapping, Func <TIn, ExcelSheetSelection> sheetSelection, Func <TParsed, TIn, TOut> selector) where TParsed : new() { return(stream.CrossApply(name, new ExcelRowsValuesProvider <TParsed>(new ExcelRowsValuesProviderArgs <TParsed> { Mapping = mapping, NoParallelisation = false }), sheetSelection, selector)); }