pub struct AuthorityDerivation {
pub inputs: Vec<AuthorityInput>,
pub rules_applied: Vec<AppliedRule>,
pub output: AuthorityOutput,
}Expand description
The complete ADG sub-object. Serializable for downstream events.
Construction does not validate; callers must invoke Self::validate (or
go through one of the typed-authority try_new constructors which call
validate for them).
Fields§
§inputs: Vec<AuthorityInput>Inputs consumed by the derivation. Must be non-empty.
rules_applied: Vec<AppliedRule>Rules applied to those inputs. Must be non-empty.
output: AuthorityOutputThe derivation’s output tuple.
Implementations§
Source§impl AuthorityDerivation
impl AuthorityDerivation
Sourcepub fn validate(&self) -> Result<(), ValidationError>
pub fn validate(&self) -> Result<(), ValidationError>
Run all six §9 invariants over this derivation. Returns Ok(()) on
success or the first violation as a ValidationError.
This is a pure function — no I/O, no allocations beyond the rule-class set deduplication.
Trait Implementations§
Source§impl Clone for AuthorityDerivation
impl Clone for AuthorityDerivation
Source§fn clone(&self) -> AuthorityDerivation
fn clone(&self) -> AuthorityDerivation
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AuthorityDerivation
impl Debug for AuthorityDerivation
Source§impl<'de> Deserialize<'de> for AuthorityDerivation
impl<'de> Deserialize<'de> for AuthorityDerivation
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for AuthorityDerivation
impl PartialEq for AuthorityDerivation
Source§fn eq(&self, other: &AuthorityDerivation) -> bool
fn eq(&self, other: &AuthorityDerivation) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for AuthorityDerivation
impl Serialize for AuthorityDerivation
impl StructuralPartialEq for AuthorityDerivation
Auto Trait Implementations§
impl Freeze for AuthorityDerivation
impl RefUnwindSafe for AuthorityDerivation
impl Send for AuthorityDerivation
impl Sync for AuthorityDerivation
impl Unpin for AuthorityDerivation
impl UnsafeUnpin for AuthorityDerivation
impl UnwindSafe for AuthorityDerivation
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more