Trait conch_runtime::eval::RedirectEval
[−]
[src]
pub trait RedirectEval<E: ?Sized> { type Handle; type Error; type EvalFuture: EnvFuture<E, Item = RedirectAction<Self::Handle>, Error = Self::Error>; fn eval(self, env: &E) -> Self::EvalFuture; }
A trait for evaluating file descriptor redirections.
Associated Types
type Handle
The type of handle that should be added to the environment.
type Error
An error that can arise during evaluation.
type EvalFuture: EnvFuture<E, Item = RedirectAction<Self::Handle>, Error = Self::Error>
A future which will carry out the evaluation (but will not update the environment with the result).
Required Methods
fn eval(self, env: &E) -> Self::EvalFuture
Evaluates a redirection path and opens the appropriate redirect.
Newly opened/closed/duplicated/heredoc file descriptors are NOT updated in the environment, and thus it is up to the caller to update the environment as appropriate.
Implementations on Foreign Types
impl<W, E: ?Sized> RedirectEval<E> for Redirect<W> where
W: WordEval<E>,
W::Error: From<RedirectionError>,
E: FileDescEnvironment + IsInteractiveEnvironment + WorkingDirectoryEnvironment,
E::FileHandle: Clone + From<FileDesc>,
[src]
W: WordEval<E>,
W::Error: From<RedirectionError>,
E: FileDescEnvironment + IsInteractiveEnvironment + WorkingDirectoryEnvironment,
E::FileHandle: Clone + From<FileDesc>,
type Handle = E::FileHandle
type Error = W::Error
type EvalFuture = Redirect<W::EvalFuture>
fn eval(self, env: &E) -> Self::EvalFuture
[src]
impl<'a, W, E: ?Sized> RedirectEval<E> for &'a Redirect<W> where
&'a W: WordEval<E>,
<&'a W as WordEval<E>>::Error: From<RedirectionError>,
E: FileDescEnvironment + IsInteractiveEnvironment + WorkingDirectoryEnvironment,
E::FileHandle: Clone + From<FileDesc>,
[src]
&'a W: WordEval<E>,
<&'a W as WordEval<E>>::Error: From<RedirectionError>,
E: FileDescEnvironment + IsInteractiveEnvironment + WorkingDirectoryEnvironment,
E::FileHandle: Clone + From<FileDesc>,