Skip to main content

Invocation

Struct Invocation 

Source
pub struct Invocation {
    pub monitor: Option<OsString>,
    pub monitor_long: Option<OsString>,
    pub background: bool,
    pub version: bool,
    pub help: bool,
    pub dry_run: bool,
    pub list: bool,
    pub session: Option<String>,
    pub config: Option<PathBuf>,
    pub ssh_args: Vec<OsString>,
    pub inject_at: usize,
}
Expand description

What rash was asked to do, before any environment or config file is consulted.

Fields§

§monitor: Option<OsString>

Raw -M spec, exactly as given. Validated later, by config.

§monitor_long: Option<OsString>

--monitor SPEC, which outranks both -M and the environment.

§background: bool§version: bool§help: bool§dry_run: bool§list: bool

--list: print the config file’s session names and exit.

§session: Option<String>

--session NAME: take settings from [session.NAME] in the config file.

§config: Option<PathBuf>

--config PATH: use this config file rather than the default one.

§ssh_args: Vec<OsString>

Arguments for ssh, in order, with -M, -f and -V removed.

§inject_at: usize

Where the -L/-R monitor forwards belong: the position -M occupied, or 0 when the port came from the environment instead (autossh parity, autossh.c:420-427).

Trait Implementations§

Source§

impl Debug for Invocation

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Invocation

Source§

fn default() -> Invocation

Returns the “default value” for a type. Read more
Source§

impl Eq for Invocation

Source§

impl PartialEq for Invocation

Source§

fn eq(&self, other: &Invocation) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for Invocation

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

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

Performs the conversion.