Method Create
- Namespace
- MailFathom.Application.Emails.AttachmentText.Limits
- Assembly
- MailFathom.Application.dll
Create(long, long, long, long, TimeSpan)
Builds a budget from what a deployment declared.
public static AttachmentDerivationBudget Create(long maxInputOctetsPerPeriod, long maxInputOctetsPerPeriodPerUser, long maxDescriptionsPerPeriod, long maxDescriptionsPerPeriodPerUser, TimeSpan period)
Parameters
maxInputOctetsPerPeriodlongThe octets one period may read in total, or zero for no ceiling.
maxInputOctetsPerPeriodPerUserlongThe octets one period may read for any one user, or zero for no ceiling.
maxDescriptionsPerPeriodlongThe descriptions one period may ask for in total, or zero for no ceiling.
maxDescriptionsPerPeriodPerUserlongThe descriptions one period may ask for per user, or zero for no ceiling.
periodTimeSpanThe window the ceilings are counted over.
Returns
- AttachmentDerivationBudget
The budget.
Exceptions
- ArgumentOutOfRangeException
Thrown when any ceiling is negative, or the period is not positive.