Struct rsgenetic::sim::seq::Simulator [] [src]

pub struct Simulator<T: Phenotype> {
    // some fields omitted
}

A sequential implementation of ::sim::Simulation. The genetic algorithm is run in a single thread.

Trait Implementations

impl<T: Phenotype> Simulation<T> for Simulator<T>
[src]

type B = SimulatorBuilder<T>

A Builder is used to create instances of a Simulation.

fn builder() -> SimulatorBuilder<T>

Create builder.

fn step(&mut self) -> StepResult

Make one step in the simulation. This function returns a StepResult: Read more

fn run(&mut self) -> RunResult

Run.

fn get(&self) -> SimResult<T>

Get the result of the latest step or of a complete run. Read more

fn iterations(&self) -> u64

Get the number of iterations the Simulator has executed so far. Read more

fn time(&self) -> Option<NanoSecond>

Get the number of nanoseconds spent running, or None in case of an overflow. Read more