Skip to main content

Module value

Module value 

Source
Expand description

What a setting holds, at runtime and as a declared default.

Two types rather than one, because they answer to different masters. Value is owned: it comes from a file or an environment variable while the process runs, so it has to be allocated. Const is what a declared default is, and every field of it is const-constructible so a generated registry costs nothing to load — no parsing, no allocation, nothing done per process start for a setting nobody reads.

Enums§

Const
A declared default, in the form a generated registry can hold as a const.
Value
A resolved configuration value.