Skip to main content

IExporter

Definition

Namespace: Surya.Ab.Export.Client.Interface
Assembly: Surya.Ab.Export.dll

Manages Data export on the basis of ExportType in simple format.

public interface IExporter

Methods

ExportMethod with five overloads to export to specific format on the basis of ExportType.

First OverLoad : Keyvalue pairs

Stream Export(
ExportType exportType,
IEnumerable<IEnumerable<KeyValuePair<string, object>>> keyValuePair,
SingleDataSetOptions? reportExportOptions);

Input Data Format: List of List of Key-Value Pairs
Output: Returns a Stream of the ExportType specified

Second OverLoad : Generic data

Stream Export<TData>(
ExportType exportType,
IEnumerable<TData> genericData,
SingleDataSetOptions? exportOptions);

Input Data Format: List of objects
Output: Returns a Stream of the ExportType specified

Third OverLoad : Datatable

Stream Export(
ExportType exportType,
DataTable dataTable,
SingleDataSetOptions? dataSetOption,
Dictionary<string, string>? columnMapping);

Input Data Format: DataTable
Output: Returns a Stream of the ExportType specified


note

Column Mapping is used only when the DataTable is for Hierarchy Export. Pass Null as it's value when DataTable is not Hierarchy type.

Fourth OverLoad : HierarchyItem

Stream Export<TData>(
ExportType exportType,
IEnumerable<HierarchyReportItem<TData>> hierarchyReportItems,
SingleDataSetOptions? dataSetOption);

Input Data Format: List of HierarchyReportItem
Output Returns a Stream of the ExportType specified

Fifth Overload : Images

Stream Export(ExportType exportType, List<AbImage> images, SingleDataSetOptions? exportOptions);

Input Data Format: List of AbImages
Output Returns a Stream of the ExportType specified

Sixth OverLoad : Multiple Datasets

Stream Export(
ExportType exportType,
List<DataSetBase> reportDataBases,
ExportOptions? exportOption);

Input Data Format: List of DataSetBase (each DataSetBase can be of any DataSet type - ReportDataset, HierarchyDataset, ParamSectionDataset)
Output: Returns a Stream of the ExportType specified


Edit on GitHub