Tnef Property ReaderRead Property Set Async Method
Asynchronously read the remaining properties.
Definition
Namespace: MimeKit.Tnef
Assembly: MimeKit.Core (in MimeKit.Core.dll) Version: 5.0.0
The properties.
Assembly: MimeKit.Core (in MimeKit.Core.dll) Version: 5.0.0
C#
public Task<TnefPropertySet> ReadPropertySetAsync(
CancellationToken cancellationToken = default
)Parameters
- cancellationToken CancellationToken (Optional)
- The cancellation token.
Return Value
TaskTnefPropertySetThe properties.
Remarks
Reads all of the properties that follow the current property (or, if the reader has not yet been positioned on a property, all of the properties) into a TnefPropertySet.
For a RecipientTable attribute, only the properties of the current row are read. Use ReadRowsAsPropertySetsAsync(CancellationToken) to read every row.
Binary values are read into memory. Use OpenValueStream to read large values, such as attachment data, without buffering them.
If any value is larger than MaxPropertyValueLength or the remaining MaxTotalDataBytes allow, a DataSizeLimitExceeded issue is reported and the property is returned without any values (its Count is 0).
Exceptions
| ObjectDisposedException | The TnefReader has been disposed. |
| InvalidOperationException | The TnefReader has been advanced to another attribute. |
| OperationCanceledException | The operation was canceled via the cancellation token. |
| IOException | An I/O error occurred. |