pub enum PropValue<'a> {
StaticStr(&'static str),
BoundedStr(&'a str),
U32(u32),
I64(i64),
F64Bucket(F64Bucket),
Bool(bool),
Enum {
variant: &'static str,
},
HistogramStrU32(&'a [(&'static str, u32)]),
}Expand description
Closed enum of allowlisted property values. There is no String
variant — anything dynamic must be length-bounded by the schema or
pre-bucketed. This is the type-system enforcement of the data-
minimisation rule: an app author physically cannot pass a runtime
String from a TextField because the codegen’d emit signature
won’t accept one.
Variants§
StaticStr(&'static str)
&'static str — for dev_static schema properties (intent
names, source enums, etc.).
BoundedStr(&'a str)
&'a str — for properties the schema marks as bounded-length
(locale code, app version). The caller is responsible for the
length bound; codegen enforces it at the emit-fn signature.
U32(u32)
I64(i64)
F64Bucket(F64Bucket)
Pre-bucketed float. Raw f64 is intentionally absent — high-
entropy floats are a fingerprinting risk and must be bucketed
at the call site.
Bool(bool)
Enum
Type-erased enum variant — the variant’s &'static str name.
HistogramStrU32(&'a [(&'static str, u32)])
Histogram of (static_key, count). Used by widget.census.