Method Create
- Namespace
- MailFathom.Application.Emails.Search
- Assembly
- MailFathom.Application.dll
Create(int, int)
Creates bounds from what a deployment configured.
public static EmailSearchSnippetBounds Create(int snippetsPerEmail, int wordsPerSnippet)
Parameters
snippetsPerEmailintHow many extracts one result may carry.
wordsPerSnippetintHow many words one extract may carry.
Returns
- EmailSearchSnippetBounds
The validated bounds.
Remarks
Configuration is checked here as well as by the options validation at startup, because these values are the privacy control rather than a preference: nothing that constructs them may reach a query with a bound nobody checked, whichever path the value arrived by.
Exceptions
- ArgumentOutOfRangeException
Thrown when either value is outside the range this type accepts.