Trait gstreamer::prelude::OptionMul

source ·
pub trait OptionMul<Rhs = Self, InnerRhs = Rhs> {
    type Output;

    // Required method
    fn opt_mul(self, rhs: Rhs) -> Option<Self::Output>;
}
Expand description

Trait for values and Options multiplication.

Implementing this trait leads to the following auto-implementations:

  • OptionMul<Option<InnerRhs>> for T.
  • OptionMul<Rhs> for Option<T>.
  • OptionMul<Option<InnerRhs>> for Option<T>.
  • … and some variants with references.

This trait is auto-implemented for OptionOperations types implementing Mul<Rhs>.

Required Associated Types§

source

type Output

The resulting inner type after applying the multiplication.

Required Methods§

source

fn opt_mul(self, rhs: Rhs) -> Option<Self::Output>

Computes the multiplication.

Returns None if at least one argument is None.

Implementations on Foreign Types§

source§

impl<T, InnerRhs> OptionMul<&Option<InnerRhs>, InnerRhs> for Option<T>
where T: OptionOperations + OptionMul<InnerRhs>, InnerRhs: Copy,

source§

type Output = <T as OptionMul<InnerRhs>>::Output

source§

fn opt_mul( self, rhs: &Option<InnerRhs>, ) -> Option<<Option<T> as OptionMul<&Option<InnerRhs>, InnerRhs>>::Output>

source§

impl<T, InnerRhs> OptionMul<Option<InnerRhs>, InnerRhs> for Option<T>
where T: OptionOperations + OptionMul<InnerRhs>,

source§

type Output = <T as OptionMul<InnerRhs>>::Output

source§

fn opt_mul( self, rhs: Option<InnerRhs>, ) -> Option<<Option<T> as OptionMul<Option<InnerRhs>, InnerRhs>>::Output>

source§

impl<T, Rhs> OptionMul<Rhs> for Option<T>
where T: OptionOperations + OptionMul<Rhs>,

source§

type Output = <T as OptionMul<Rhs>>::Output

source§

fn opt_mul(self, rhs: Rhs) -> Option<<Option<T> as OptionMul<Rhs>>::Output>

Implementors§

source§

impl<T, InnerRhs> OptionMul<&Option<InnerRhs>, InnerRhs> for T
where T: OptionOperations + OptionMul<InnerRhs>, InnerRhs: Copy,

source§

type Output = <T as OptionMul<InnerRhs>>::Output

source§

impl<T, InnerRhs> OptionMul<Option<InnerRhs>, InnerRhs> for T
where T: OptionOperations + OptionMul<InnerRhs>,

source§

type Output = <T as OptionMul<InnerRhs>>::Output

source§

impl<T, Rhs> OptionMul<Rhs> for T
where T: OptionOperations + Mul<Rhs>,

source§

type Output = <T as Mul<Rhs>>::Output