Trait PoolExt

Source
pub trait PoolExt: Pool + Sized {
    // Provided method
    fn and<P, SM>(
        self,
        p: P,
        override_weight: Option<f64>,
        _sensor_marker: SM,
    ) -> AndPool<Self, P, SM>
       where P: Pool { ... }
}
Expand description

A trait for convenience methods automatically implemented for all types that conform to Pool.

Provided Methods§

Source

fn and<P, SM>( self, p: P, override_weight: Option<f64>, _sensor_marker: SM, ) -> AndPool<Self, P, SM>
where P: Pool,

Create an AndPool from both Self and P.

§Arguments
  • p is the other pool to combine with self
  • override_weight determines the relative chance of selecting p when the resulting AndPool is asked to provide a test case. If None, p.weight() will be used. The weight of self is always self.weight().
  • _sensor_marker tells whether self and p operate on the same observations or not. If they do, pass SameObservations. Otherwise, pass DifferentObservations. See the documentation of AndPool for more details.

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§

Source§

impl<P> PoolExt for P
where P: Pool,