Class HasDokumentExtensions
- Namespace
- BpNexT.NET.Extensions.Data
- Assembly
- BpNexT.NET.dll
Provides extension methods for the IHasDokumente interface.
public static class HasDokumentExtensions
- Inheritance
-
objectHasDokumentExtensions
Methods
AddDokument<T>(IHasDokumente, byte[], string)
Adds a new Dokument to the specified IHasDokumente instance.
public static IDokumente AddDokument<T>(this IHasDokumente t, byte[] data, string fileName) where T : IHasAutoDataSet, IDokumente, new()
Parameters
tIHasDokumenteThe IHasDokumente instance to which the Dokument will be added.
databyte[]The byte array containing the data of the Dokument.
fileNamestringThe name of the file associated with the Dokument.
Returns
- IDokumente
The newly added Dokumente instance.
Type Parameters
T
Exceptions
- InvalidOperationException
Thrown when the IHasDokumente instance is not attached to a DataSet.
- Exception
Thrown when the Application is not set in the DataSet.
GetDokumente<T>(IHasDokumente)
Gets all Dokumente associated with the specified IHasDokumente instance.
public static IEnumerable<T> GetDokumente<T>(this IHasDokumente t) where T : IDokumente, new()
Parameters
Returns
- IEnumerable<T>
Type Parameters
T