isGoverned property
Indicates whether this pulse is subject to explicit governance.
When to use
- Governance Awareness: This is mostly informational — you might use it to conditionally apply stricter handling in custom code.
- Conditional logic based on governance status.
- Debugging to know if a pulse has a context or policy.
- Applying stricter handling to governed pulses.
How it works
A pulse is governed if it was created with a non‑default PulseContext
and/or a PulseEphemeralPolicy. The isGoverned flag is set in the
record at construction time and resolved by walking up the parent chain
if not found locally.
Returns:
true if the pulse has explicit governance (Context or Policy),
false otherwise.
Implementation
@override
bool get isGoverned {
if ((_shape & _kGoverned) != 0) {
return _record.root.primary.isGoverned || (_parent?.isGoverned ?? false);
}
return _parent?.isGoverned ?? false;
}