Table of Contents

Struct ConfigurationStorageRoute

Namespace
MailFathom.Application.Configuration
Assembly
MailFathom.Application.dll

Names the store a writable configuration path is persisted in.

public readonly record struct ConfigurationStorageRoute : IEquatable<ConfigurationStorageRoute>
Implements
Inherited Members

Remarks

The type is a closed enumeration rather than a C# enum because a route carries the name a refusal, a projection, and a record are written against, and that name has to survive a rename of the member. What it deliberately does not carry is a table: which relation a store lives in is the persistence adapter's decision and is named where the adapter maps it, so no application-layer value has to be kept in step with a migration.

The set is closed because the deployment's settings must have exactly one home each. A path with no special route is persisted in RootDocument, a path a special route names is persisted in that store and excluded from the root document, and there is no third answer for a reader to choose between.

Unlike the repository's other closed enumerations this one publishes no parser and no JSON converter, and the absence is the point rather than an omission: a route named by a configuration value or by an API argument is exactly what ConfigurationStorageCatalog exists to refuse, so the only way to reach a route is to resolve a configuration path against the compiled catalog. Being a struct, default is reachable and is not a route; IsSpecified reports it, and ConfigurationWriteTarget is where it means a refused write rather than a store.

Properties

All

Gets every store this build persists configuration into.

IsSpecified

Gets whether this value names a store rather than the unusable struct default.

Name

Gets the route's name, which is stable across a rename of the member and reaches an operator's record.

RootDocument

Gets the store holding the deployment's single persisted configuration document.

UserAccounts

Gets the store holding one configuration document per user.

Methods

ToString()

Returns the fully qualified type name of this instance.