pub trait GraphManager<G>: Send + Sync{
// Required methods
fn initialize_graph(
&mut self,
components: &HashMap<ComponentId, Vec<Address>>,
);
fn graph(&self) -> &G;
}Expand description
Trait for managing graph representations.
Graph managers are stateful - they maintain the graph internally and update it based on market events.
Required Methods§
Sourcefn initialize_graph(&mut self, components: &HashMap<ComponentId, Vec<Address>>)
fn initialize_graph(&mut self, components: &HashMap<ComponentId, Vec<Address>>)
Initializes the graph from the market topology.
Arguments:
- components: A map of component IDs to their tokens addresses.