IWorkbookFormatProvider
Defines a common interface for workbook import and export format providers, enabling serialization and deserialization of workbooks to and from various file formats.
Definition
Namespace:Telerik.Windows.Documents.Spreadsheet.FormatProviders
Assembly:Telerik.Windows.Documents.Spreadsheet.dll
Syntax:
public interface IWorkbookFormatProvider
Derived Classes:
Methods
Exports the specified workbook to the output stream with an optional timeout in the provider's format.
void Export(Workbook workbook, Stream output, TimeSpan? timeout)
The workbook.
outputStreamThe output.
timeoutTimeSpan?The timeout after which the operation will be cancelled.
Exceptions:The exception that is thrown when timeout is less than -1 or greater than Int32.MaxValue. Note that this upper bound is more restrictive than TimeSpan.MaxValue.
Imports a workbook from the specified stream with an optional timeout and returns the deserialized workbook instance.
Workbook Import(Stream input, TimeSpan? timeout)
The input.
timeoutTimeSpan?The timeout after which the operation will be cancelled.
Returns:The imported workbook.
Exceptions:The exception that is thrown when timeout is less than -1 or greater than Int32.MaxValue. Note that this upper bound is more restrictive than TimeSpan.MaxValue.
Properties
Gets a value indicating whether this provider supports exporting workbooks to streams.
bool CanExport { get; }
The value indicating whether can export.
Gets a value indicating whether this provider supports importing workbooks from streams.
bool CanImport { get; }
The value indicating whether can import.
Gets the human-readable description of files supported by this provider, suitable for display in file dialogs.
string FilesDescription { get; }
The files description.
Gets the unique identifier name of this format provider.
string Name { get; }
The name of the provider.
Gets the collection of file extensions supported by this provider, each including the leading dot (e.g., ".xlsx").
IEnumerable<string> SupportedExtensions { get; }
The supported extensions.