Method CollectFromAsync
- Namespace
- MailFathom.Application.Contacts.Collection
- Assembly
- MailFathom.Application.dll
CollectFromAsync(ExtractedEmailMetadata, ContactCollectionRun, CancellationToken)
Records whoever one committed message says the account corresponds with.
public Task CollectFromAsync(ExtractedEmailMetadata metadata, ContactCollectionRun run, CancellationToken cancellationToken)
Parameters
metadataExtractedEmailMetadataWhat was read out of the message that was just stored.
runContactCollectionRunThe account, the folder role, and the remaining bound of the run the message reached this pass in. The account is the run's rather than the message's, so it is what selects the collection settings and whose correspondents the addresses are recorded as — handing a message a run opened for another account attributes them to that one.
cancellationTokenCancellationTokenCancels the collection.
Returns
- Task
A task that completes once every candidate has been decided, or at once where the account collects nothing.
Remarks
An account with collection switched off performs one property read and reaches neither the book nor the tally, which is the shape every switched-off feature in this system has.
Exceptions
- ArgumentNullException
Thrown when a required argument is null.