Struct dominator::RefFn[][src]

pub struct RefFn<A, B, C> where
    B: ?Sized,
    C: Fn(&A) -> &B, 
{ /* fields omitted */ }

Implementations

impl<A, B, C> RefFn<A, B, C> where
    B: ?Sized,
    C: Fn(&A) -> &B, 
[src]

pub fn new(value: A, callback: C) -> Self[src]

pub fn call_ref(&self) -> &B[src]

Trait Implementations

impl<A, C> AsStr for RefFn<A, str, C> where
    C: Fn(&A) -> &str
[src]

fn as_str(&self) -> &str[src]

impl<'a, A, C> MultiStr for RefFn<A, [&'a str], C> where
    C: Fn(&A) -> &[&'a str]
[src]

fn find_map<B, F>(&self, f: F) -> Option<B> where
    F: FnMut(&str) -> Option<B>, 
[src]

fn each<F>(&self, f: F) where
    F: FnMut(&str), 
[src]

Auto Trait Implementations

impl<A, B: ?Sized, C> RefUnwindSafe for RefFn<A, B, C> where
    A: RefUnwindSafe,
    C: RefUnwindSafe

impl<A, B: ?Sized, C> Send for RefFn<A, B, C> where
    A: Send,
    C: Send

impl<A, B: ?Sized, C> Sync for RefFn<A, B, C> where
    A: Sync,
    C: Sync

impl<A, B: ?Sized, C> Unpin for RefFn<A, B, C> where
    A: Unpin,
    C: Unpin

impl<A, B: ?Sized, C> UnwindSafe for RefFn<A, B, C> where
    A: UnwindSafe,
    C: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<A> MultiStr for A where
    A: AsStr
[src]

pub fn find_map<B, F>(&Self, F) -> Option<B> where
    F: FnMut(&str) -> Option<B>, 
[src]

fn each<F>(&self, f: F) where
    F: FnMut(&str), 
[src]

impl<A> OptionStr for A where
    A: MultiStr
[src]

type Output = A

pub fn into_option(Self) -> Option<A>[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.