[−][src]Struct conch_runtime::env::FnEnv
An environment module for setting and getting shell functions.
Uses Rc
internally. For a possible Send
and Sync
implementation,
see env::atomic::FnEnv
.
Methods
impl<N: Hash + Eq, F> FnEnv<N, F>
[src]
Trait Implementations
impl<N, F> FunctionEnvironment for FnEnv<N, F> where
N: Clone + Hash + Eq,
F: Clone,
[src]
N: Clone + Hash + Eq,
F: Clone,
type FnName = N
The name to be associated with a function.
type Fn = F
The type of the function.
fn function(&self, name: &Self::FnName) -> Option<&Self::Fn>
[src]
fn set_function(&mut self, name: Self::FnName, func: Self::Fn)
[src]
fn has_function(&self, name: &Self::FnName) -> bool
[src]
Check if a particularly named function was registered.
impl<N, F> UnsetFunctionEnvironment for FnEnv<N, F> where
N: Clone + Hash + Eq,
F: Clone,
[src]
N: Clone + Hash + Eq,
F: Clone,
fn unset_function(&mut self, name: &Self::FnName)
[src]
impl<N: Hash + Eq, F> SubEnvironment for FnEnv<N, F>
[src]
impl<N: Hash + Eq, F> Default for FnEnv<N, F>
[src]
impl<N: Hash + Eq, F> Clone for FnEnv<N, F>
[src]
fn clone(&self) -> Self
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<N: PartialEq + Hash + Eq, F: PartialEq> PartialEq<FnEnv<N, F>> for FnEnv<N, F>
[src]
impl<N: Eq + Hash + Eq, F: Eq> Eq for FnEnv<N, F>
[src]
impl<N, F> Debug for FnEnv<N, F> where
N: Hash + Eq + Debug + Ord,
F: Debug,
[src]
N: Hash + Eq + Debug + Ord,
F: Debug,
Auto Trait Implementations
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,