Method Create
- Namespace
- MailFathom.Domain.Delivery.Governance
- Assembly
- MailFathom.Domain.dll
Create(TimeSpan, long, long, long, long)
Builds the ceilings from what a deployment declared.
public static OutgoingMailCeilings Create(TimeSpan period, long maxMessagesPerAccount, long maxRecipientsPerAccount, long maxMessagesPerDeployment, long maxRecipientsPerDeployment)
Parameters
periodTimeSpanThe window every count is taken over.
maxMessagesPerAccountlongThe messages one account may be asked for in a period, or zero for no ceiling.
maxRecipientsPerAccountlongThe recipients one account may be asked to write to in a period, or zero for no ceiling.
maxMessagesPerDeploymentlongThe messages this deployment may be asked for in a period, or zero for no ceiling.
maxRecipientsPerDeploymentlongThe recipients this deployment may be asked to write to in a period, or zero for no ceiling.
Returns
- OutgoingMailCeilings
The ceilings.
Exceptions
- ArgumentOutOfRangeException
Thrown when the period is not positive, or a ceiling is negative.