Skip to main content

TrustedGraphView

Struct TrustedGraphView 

Source
pub struct TrustedGraphView<'a> {
    pub graph: &'a RealityGraph,
    /* private fields */
}
Expand description

Filtered, policy-governed view over the reality graph.

Fields§

§graph: &'a RealityGraph

Implementations§

Source§

impl<'a> TrustedGraphView<'a>

Source

pub fn new( graph: &'a RealityGraph, store: &'a Store, stale_paths: &[String], policy: TrustPolicy, ) -> TrustedGraphView<'a>

Source

pub fn policy(&self) -> &TrustPolicy

Source

pub fn is_stale_path(&self, path: &str) -> bool

Source

pub fn stale_paths(&self) -> Vec<String>

Source

pub fn is_stale_evidence(&self, id: &str) -> bool

Source

pub fn is_stale_entity(&self, id: &str) -> bool

Source

pub fn entity(&self, id: &str) -> Option<&Entity>

Trusted entity lookup: None for entities whose evidence is stale.

Source

pub fn name_of(&self, id: &str) -> String

Display name of an entity id; falls back to the id’s last segment. Entity staleness does not hide the name — callers decide whether the entity may appear in trusted sections.

Source

pub fn entities(&self) -> impl Iterator<Item = &Entity>

All entities, staleness-filtered (unfiltered raw map for display helpers that need presence only).

Source

pub fn entities_of_kind(&self, kind: &str) -> Vec<&Entity>

Entities of a kind (staleness-filtered, name-sorted for determinism).

Source

pub fn out_edges(&self, id: &str) -> Vec<&Relationship>

Source

pub fn in_edges(&self, id: &str) -> Vec<&Relationship>

Source

pub fn out_pred(&self, id: &str, predicate: &str) -> Vec<&Relationship>

Source

pub fn in_pred(&self, id: &str, predicate: &str) -> Vec<&Relationship>

Source

pub fn all_rels(&self) -> Vec<&Relationship>

All trusted relationships, sorted by id for determinism.

Source

pub fn flows(&self) -> Vec<Flow>

Staleness + policy filtered flows. A flow is stale when any step’s evidence is stale; steps whose provenance the policy rejects (INFERRED below the confidence floor) are removed, and a flow left with fewer than two steps is dropped — a low-confidence derived interpretation must never reach the atlas as architecture.

Source

pub fn invariants(&self) -> Vec<Invariant>

Staleness + policy filtered invariants.

Source

pub fn components(&self) -> Vec<Entity>

Staleness + policy filtered components: responsibility/ownership/ dependency CLAIMS rejected by the policy are removed from the attributes, so include_low_confidence_inference: false really means low-confidence inferred claims never appear in the atlas.

Source

pub fn stale_warnings(&self) -> Vec<String>

Deterministic stale-fact warnings for pack footers.

Auto Trait Implementations§

§

impl<'a> Freeze for TrustedGraphView<'a>

§

impl<'a> RefUnwindSafe for TrustedGraphView<'a>

§

impl<'a> Send for TrustedGraphView<'a>

§

impl<'a> Sync for TrustedGraphView<'a>

§

impl<'a> Unpin for TrustedGraphView<'a>

§

impl<'a> UnsafeUnpin for TrustedGraphView<'a>

§

impl<'a> UnwindSafe for TrustedGraphView<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.