Trait FactorIterator

Source
pub trait FactorIterator<W: Semiring>:
    Debug
    + PartialEq
    + Clone
    + Iterator<Item = (W, W)>
    + Sync {
    // Required methods
    fn new(weight: W) -> Self;
    fn done(&self) -> bool;
}
Expand description

A factor iterator takes as argument a weight w and returns a sequence of pairs of weights (xi, yi) such that the sum of the products xi times yi is equal to w. If w is fully factored, the iterator should return nothing.

Required Methods§

Source

fn new(weight: W) -> Self

Source

fn done(&self) -> bool

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§