Struct Wcag2Measurement
Holds a WCAG 2 measurement together with its validity state.
struct Wcag2Measurement(T)
if (is(T == float) || is(T == double));
Read valid before using value when input may be outside the WCAG
domain. Valid measurements expose their numeric result through value;
invalid input produces an invalid measurement whose value is NaN.
Callers receive this type from the WCAG measurement functions rather than constructing validated measurements directly.
The natural floating-point state is NaN and is therefore invalid.
Properties
| Name | Type | Description |
|---|---|---|
valid[get]
|
bool | Whether this object contains a valid WCAG 2 measurement. |
value[get]
|
T | Measurement value. Invalid measurements return NaN here. |
Aliases
| Name | Description |
|---|---|
Scalar
|
Scalar type used by the measurement. |