pub trait SnapshotSource {
// Required method
fn topology_snapshot(&self) -> TopologySnapshot;
}Available on crate feature
topology only.Expand description
A source of TopologySnapshot data.
Implemented by Graph so external observers can read the
current topology as serializable metadata. The method takes &self, so it
is safe to call from a read-only context — but note that a &self borrow
cannot coexist with the &mut self that
Graph::process_cycle requires, so the
borrow checker prevents concurrent snapshot reads and RT processing on the
same Graph.
Required Methods§
Sourcefn topology_snapshot(&self) -> TopologySnapshot
fn topology_snapshot(&self) -> TopologySnapshot
Returns a serializable, metadata-only snapshot of the current topology.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".