Trait sp_std::iter::Product

1.12.0 · source ·
pub trait Product<A = Self>: Sized {
    fn product<I>(iter: I) -> Self
    where
        I: Iterator<Item = A>
; }
Expand description

Trait to represent types that can be created by multiplying elements of an iterator.

This trait is used to implement Iterator::product(). Types which implement this trait can be generated by using the product() method on an iterator. Like FromIterator, this trait should rarely be called directly.

Required Methods§

Method which takes an iterator and generates Self from the elements by multiplying the items.

Implementors§

impl<T> Product<T> for Scalarwhere
    T: Borrow<Scalar>,

impl<Frac: LeEqU8> Product<FixedU8<Frac>> for FixedU8<Frac>

impl<'a, Frac: 'a + LeEqU8> Product<&'a FixedU8<Frac>> for FixedU8<Frac>

impl<Frac: LeEqU16> Product<FixedU16<Frac>> for FixedU16<Frac>

impl<'a, Frac: 'a + LeEqU16> Product<&'a FixedU16<Frac>> for FixedU16<Frac>

impl<Frac: LeEqU32> Product<FixedU32<Frac>> for FixedU32<Frac>

impl<'a, Frac: 'a + LeEqU32> Product<&'a FixedU32<Frac>> for FixedU32<Frac>

impl<Frac: LeEqU64> Product<FixedU64<Frac>> for FixedU64<Frac>

impl<'a, Frac: 'a + LeEqU64> Product<&'a FixedU64<Frac>> for FixedU64<Frac>

impl<Frac: LeEqU128> Product<FixedU128<Frac>> for FixedU128<Frac>

impl<'a, Frac: 'a + LeEqU128> Product<&'a FixedU128<Frac>> for FixedU128<Frac>

impl<Frac: LeEqU8> Product<FixedI8<Frac>> for FixedI8<Frac>

impl<'a, Frac: 'a + LeEqU8> Product<&'a FixedI8<Frac>> for FixedI8<Frac>

impl<Frac: LeEqU16> Product<FixedI16<Frac>> for FixedI16<Frac>

impl<'a, Frac: 'a + LeEqU16> Product<&'a FixedI16<Frac>> for FixedI16<Frac>

impl<Frac: LeEqU32> Product<FixedI32<Frac>> for FixedI32<Frac>

impl<'a, Frac: 'a + LeEqU32> Product<&'a FixedI32<Frac>> for FixedI32<Frac>

impl<Frac: LeEqU64> Product<FixedI64<Frac>> for FixedI64<Frac>

impl<'a, Frac: 'a + LeEqU64> Product<&'a FixedI64<Frac>> for FixedI64<Frac>

impl<Frac: LeEqU128> Product<FixedI128<Frac>> for FixedI128<Frac>

impl<'a, Frac: 'a + LeEqU128> Product<&'a FixedI128<Frac>> for FixedI128<Frac>

impl<F: Fixed> Product<Unwrapped<F>> for Unwrapped<F>

impl<'a, F: 'a + Fixed> Product<&'a Unwrapped<F>> for Unwrapped<F>

impl<F: Fixed> Product<Wrapping<F>> for Wrapping<F>

impl<'a, F: 'a + Fixed> Product<&'a Wrapping<F>> for Wrapping<F>

impl Product<bf16> for bf16

impl<'a> Product<&'a bf16> for bf16

impl Product<f16> for f16

impl<'a> Product<&'a f16> for f16

impl<'a> Product<&'a BigInt> for BigInt

impl<'a> Product<&'a Number> for Number

impl<T, D: DimName> Product<Matrix<T, D, D, <DefaultAllocator as Allocator<T, D, D>>::Buffer>> for OMatrix<T, D, D>where
    T: Scalar + Zero + One + ClosedMul + ClosedAdd,
    DefaultAllocator: Allocator<T, D, D>,

impl<'a, T, D: DimName> Product<&'a Matrix<T, D, D, <DefaultAllocator as Allocator<T, D, D>>::Buffer>> for OMatrix<T, D, D>where
    T: Scalar + Zero + One + ClosedMul + ClosedAdd,
    DefaultAllocator: Allocator<T, D, D>,

impl<T> Product<T> for BigIntwhere
    BigInt: Mul<T, Output = BigInt>,

impl<T> Product<T> for BigUintwhere
    BigUint: Mul<T, Output = BigUint>,

impl<T: Num + Clone> Product<Complex<T>> for Complex<T>

impl<'a, T: 'a + Num + Clone> Product<&'a Complex<T>> for Complex<T>

impl<T: Integer + Clone> Product<Ratio<T>> for Ratio<T>

impl<'a, T: Integer + Clone> Product<&'a Ratio<T>> for Ratio<T>

impl<T: Float + Product> Product<NotNan<T>> for NotNan<T>

impl<'a, T: Float + Product> Product<&'a NotNan<T>> for NotNan<T>