pub struct Invocation {
pub args: Vec<String>,
pub concurrency: Concurrency,
pub timeout: Duration,
pub stdin: Option<Vec<u8>>,
}Expand description
One invocation of the CLI.
The argument list is a list. It is never joined into a string and never handed to a shell, which is what makes an argument containing a space, a quote or a semicolon uninteresting.
Fields§
§args: Vec<String>§concurrency: Concurrency§timeout: Duration§stdin: Option<Vec<u8>>Bytes to write to the child’s standard input, for the few commands that read a document rather than a flag.
Implementations§
Source§impl Invocation
impl Invocation
A mutation that cannot race the node’s configuration: it changes the
filesystem, or a peer, but never what tailscale set and tailscale up
contend over.
It runs in the shared lane because the lock exists to keep two configuration writes apart, and these are not that. Queueing them would buy no safety and cost a great deal: a ten-minute file transfer holding the exclusive lock stalls every concurrent read for its whole duration.
pub fn with_timeout(self, timeout: Duration) -> Self
pub fn with_stdin(self, stdin: impl Into<Vec<u8>>) -> Self
Trait Implementations§
Source§impl Clone for Invocation
impl Clone for Invocation
Source§fn clone(&self) -> Invocation
fn clone(&self) -> Invocation
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for Invocation
impl RefUnwindSafe for Invocation
impl Send for Invocation
impl Sync for Invocation
impl Unpin for Invocation
impl UnsafeUnpin for Invocation
impl UnwindSafe for Invocation
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more