Func

Trait Func 

pub trait Func<Args: Tuple>: FuncMut<Args> {
    // Required method
    fn call(&self, args: Args) -> Self::Output;

    // Provided method
    fn bind_ref<B>(self, arg: B) -> BindFnRef<B, Self>
       where Self: Sized { ... }
}
Available on crate feature func only.

Required Methods§

fn call(&self, args: Args) -> Self::Output

Provided Methods§

fn bind_ref<B>(self, arg: B) -> BindFnRef<B, Self>
where Self: Sized,

Available on crate feature func-bind only.

Implementors§

§

impl<'a, B: ?Sized + 'a, F, O, T> Func<(T₁, T₂, …, Tₙ)> for BindFn<&'a B, F>
where F: Func<(&'a B, T), Output = O>,

Available on crate feature func-bind only.

This trait is implemented for argument lists up to 20 items long

§

impl<B, F, O, T> Func<(T₁, T₂, …, Tₙ)> for BindFnRef<B, F>
where for<'b> F: Func<(&'b B, T), Output = O>,

Available on crate feature func-bind only.

This trait is implemented for argument lists up to 20 items long

§

impl<F, O, T> Func<(T₁, T₂, …, Tₙ)> for F
where F: Fn(T) -> O,

This trait is implemented for argument lists up to 20 items long