[−][src]Trait poldercast::Layer
Required methods
fn alias(&self) -> &'static str
alias to the layer, for information purpose
fn reset(&mut self)
reset the layer state
fn populate(&mut self, identity: &NodeProfile, all_nodes: &Nodes)
populate the Layer
based on all the nodes.
The NodeProfile
is given as the identity of the local node, allowing access
to the local PublicId
or Subscriptions
(for example, used in the Rings
or Vicinity
module).
fn view(&mut self, view: &mut ViewBuilder, all_nodes: &mut Nodes)
based on the populated layer, provide nodes to the ViewBuilder
.
fn gossips(
&mut self,
identity: &NodeProfile,
gossips: &mut GossipsBuilder,
all_nodes: &Nodes
)
&mut self,
identity: &NodeProfile,
gossips: &mut GossipsBuilder,
all_nodes: &Nodes
)
update the GossipsBuilder
, effectively preparing the list of gossips
to share with the recipient (see GossipsBuilder
). To build the gossips
the Layer
has access to the whole list of known Node
s.
Implementors
impl Layer for RandomDirectConnections
[src]
fn alias(&self) -> &'static str
[src]
fn reset(&mut self)
[src]
fn populate(&mut self, _identity: &NodeProfile, all_nodes: &Nodes)
[src]
fn gossips(
&mut self,
_identity: &NodeProfile,
_gossips_builder: &mut GossipsBuilder,
_all_nodes: &Nodes
)
[src]
&mut self,
_identity: &NodeProfile,
_gossips_builder: &mut GossipsBuilder,
_all_nodes: &Nodes
)
fn view(&mut self, view_builder: &mut ViewBuilder, all_nodes: &mut Nodes)
[src]
impl Layer for Cyclon
[src]
fn alias(&self) -> &'static str
[src]
fn reset(&mut self)
[src]
fn populate(&mut self, _identity: &NodeProfile, all_nodes: &Nodes)
[src]
fn gossips(
&mut self,
_identity: &NodeProfile,
gossips_builder: &mut GossipsBuilder,
all_nodes: &Nodes
)
[src]
&mut self,
_identity: &NodeProfile,
gossips_builder: &mut GossipsBuilder,
all_nodes: &Nodes
)
fn view(&mut self, view_builder: &mut ViewBuilder, all_nodes: &mut Nodes)
[src]
impl Layer for Rings
[src]
fn alias(&self) -> &'static str
[src]
fn reset(&mut self)
[src]
fn populate(&mut self, identity: &NodeProfile, all_nodes: &Nodes)
[src]
fn gossips(
&mut self,
identity: &NodeProfile,
gossips: &mut GossipsBuilder,
all_nodes: &Nodes
)
[src]
&mut self,
identity: &NodeProfile,
gossips: &mut GossipsBuilder,
all_nodes: &Nodes
)
fn view(&mut self, view: &mut ViewBuilder, all_nodes: &mut Nodes)
[src]
impl Layer for Vicinity
[src]
fn alias(&self) -> &'static str
[src]
fn reset(&mut self)
[src]
fn populate(&mut self, identity: &NodeProfile, all_nodes: &Nodes)
[src]
fn gossips(
&mut self,
_identity: &NodeProfile,
gossips_builder: &mut GossipsBuilder,
all_nodes: &Nodes
)
[src]
&mut self,
_identity: &NodeProfile,
gossips_builder: &mut GossipsBuilder,
all_nodes: &Nodes
)