Trait forge::Factory

source ·
pub trait Factory {
    // Required methods
    fn versions<'a>(&'a self) -> Box<dyn Iterator<Item = Version> + 'a>;
    fn launch_swarm(
        &self,
        rng: &mut StdRng,
        node_num: NonZeroUsize,
        version: &Version
    ) -> Result<Box<dyn Swarm>>;
}
Expand description

Trait used to represent a interface for constructing a launching new networks

Required Methods§

source

fn versions<'a>(&'a self) -> Box<dyn Iterator<Item = Version> + 'a>

source

fn launch_swarm( &self, rng: &mut StdRng, node_num: NonZeroUsize, version: &Version ) -> Result<Box<dyn Swarm>>

Implementors§