Skip to main content
Table of Contents

Class SettingDefinition

Namespace
Stratara.Abstractions.Settings
Assembly
Stratara.Abstractions.dll

One entry of the application's setting vocabulary: a dotted name, its code-declared default, and its behavioral flags. Definitions are declared once at startup in the SettingCatalog; values are stored separately per SettingScope.

[ExcludeFromCodeCoverage]
public sealed record SettingDefinition : IEquatable<SettingDefinition>
Inheritance
SettingDefinition
Implements
Inherited Members
Extension Methods

Constructors

SettingDefinition(string, string?, bool, bool)

One entry of the application's setting vocabulary: a dotted name, its code-declared default, and its behavioral flags. Definitions are declared once at startup in the SettingCatalog; values are stored separately per SettingScope.

public SettingDefinition(string Name, string? DefaultValue = null, bool IsInherited = true, bool IsEncrypted = false)

Parameters

Name string

The setting's unique dotted name (for example "Notifications.Email.Enabled"); namespacing is purely conventional via the dots.

DefaultValue string

The value returned when no scope in the fallback chain (and no configuration entry) carries one; null when the setting has no default.

IsInherited bool

true (default): reads fall back through the scope chain (user-in-tenant → user → tenant → global). false: reads consult only the most specific scope for the current session, then configuration/default — a narrower scope never inherits a broader scope's value.

IsEncrypted bool

true to store the value AES-GCM-encrypted at rest (scope-bound associated data via the security plane's blob encryptor); requires an ISecureBlobEncryptor registration.

Properties

DefaultValue

The value returned when no scope in the fallback chain (and no configuration entry) carries one; null when the setting has no default.

public string? DefaultValue { get; init; }

Property Value

string

IsEncrypted

true to store the value AES-GCM-encrypted at rest (scope-bound associated data via the security plane's blob encryptor); requires an ISecureBlobEncryptor registration.

public bool IsEncrypted { get; init; }

Property Value

bool

IsInherited

true (default): reads fall back through the scope chain (user-in-tenant → user → tenant → global). false: reads consult only the most specific scope for the current session, then configuration/default — a narrower scope never inherits a broader scope's value.

public bool IsInherited { get; init; }

Property Value

bool

Name

The setting's unique dotted name (for example "Notifications.Email.Enabled"); namespacing is purely conventional via the dots.

public string Name { get; init; }

Property Value

string