Method Admit
- Namespace
- MailFathom.Application.Mail.Delivery.Governance
- Assembly
- MailFathom.Application.dll
Admit(string, OutgoingEmailRequest)
Weighs one send against the caller's period and charges it to that caller in the same operation.
public AuthoredSendCeiling? Admit(string caller, OutgoingEmailRequest request)
Parameters
callerstringThe identity the calling principal was admitted under.
requestOutgoingEmailRequestThe send being asked for, which carries both its idempotency identity and its recipients.
Returns
- AuthoredSendCeiling?
The ceiling the send reached, which is when nothing was charged, or null when it was admitted.
Remarks
A caller arriving in a period that is already counting the greatest number of them is refused rather than admitted uncounted: the ledger reports what it can hold rather than growing to hold whatever it is handed.
Exceptions
- ArgumentException
Thrown when
calleris empty or white space, which is a principal nothing can be counted against.- ArgumentNullException
Thrown when
requestis null.