Class PresentationFreshness
- Namespace
- MailFathom.Application.Discovery.Presentation
- Assembly
- MailFathom.Application.dll
How current the data behind something in a plan was, and when that was established.
public sealed record PresentationFreshness : IEquatable<PresentationFreshness>
- Inheritance
-
PresentationFreshness
- Implements
- Inherited Members
Remarks
The timestamp and the verdict travel together because either alone misleads. A timestamp with no verdict leaves the reader to decide whether four hours is stale, which depends on the mailbox rather than on the clock; a verdict with no timestamp cannot be re-judged later by a screen that has been open since.
The constructor is what holds the two members to the combinations that mean something, and it is also the one deserialization uses — so a plan arriving from a producer this deployment does not control is held to the same rule as one composed in process. The named members below are how a producer states a freshness readably.
Constructors
- PresentationFreshness(PresentationStaleness, DateTimeOffset?)
Initializes the freshness of data behind a block.
Properties
- ObservedAt
Gets when the local copy was last established against the mail server, or null where nothing established it.
- Staleness
Gets how far behind the mail server the data may be.
- Unknown
Gets the freshness of data nothing established, which claims neither currency nor staleness.
Methods
- CurrentAt(DateTimeOffset)
States that the local copy was current when it was read.
- StaleSince(DateTimeOffset)
States that the local copy is known to be behind the mail server.