pub struct NetworkLsCommand {
pub executor: CommandExecutor,
/* private fields */
}
Expand description
Docker network ls command builder
Fields§
§executor: CommandExecutor
Command executor
Implementations§
Source§impl NetworkLsCommand
impl NetworkLsCommand
Sourcepub fn driver_filter(self, driver: impl Into<String>) -> Self
pub fn driver_filter(self, driver: impl Into<String>) -> Self
Filter by driver
Sourcepub fn label_filter(self, label: impl Into<String>) -> Self
pub fn label_filter(self, label: impl Into<String>) -> Self
Filter by label
Sourcepub fn name_filter(self, name: impl Into<String>) -> Self
pub fn name_filter(self, name: impl Into<String>) -> Self
Filter by name
Sourcepub fn scope_filter(self, scope: impl Into<String>) -> Self
pub fn scope_filter(self, scope: impl Into<String>) -> Self
Filter by scope
Sourcepub fn type_filter(self, typ: impl Into<String>) -> Self
pub fn type_filter(self, typ: impl Into<String>) -> Self
Filter by type (custom or builtin)
Sourcepub fn format_json(self) -> Self
pub fn format_json(self) -> Self
Format output as JSON
Sourcepub async fn run(&self) -> Result<NetworkLsOutput>
pub async fn run(&self) -> Result<NetworkLsOutput>
Execute the command
§Errors
Returns an error if the Docker daemon is not running or the command fails
Trait Implementations§
Source§impl Clone for NetworkLsCommand
impl Clone for NetworkLsCommand
Source§fn clone(&self) -> NetworkLsCommand
fn clone(&self) -> NetworkLsCommand
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for NetworkLsCommand
impl Debug for NetworkLsCommand
Source§impl Default for NetworkLsCommand
impl Default for NetworkLsCommand
Source§impl DockerCommand for NetworkLsCommand
impl DockerCommand for NetworkLsCommand
Source§type Output = CommandOutput
type Output = CommandOutput
The output type this command produces
Source§fn build_command_args(&self) -> Vec<String>
fn build_command_args(&self) -> Vec<String>
Build the complete command arguments including subcommands
Source§fn get_executor(&self) -> &CommandExecutor
fn get_executor(&self) -> &CommandExecutor
Get the command executor for extensibility
Source§fn get_executor_mut(&mut self) -> &mut CommandExecutor
fn get_executor_mut(&mut self) -> &mut CommandExecutor
Get mutable command executor for extensibility
Source§fn execute<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Self::Output>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn execute<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Self::Output>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Execute the command and return the typed output
Source§fn execute_command<'life0, 'async_trait>(
&'life0 self,
command_args: Vec<String>,
) -> Pin<Box<dyn Future<Output = Result<CommandOutput>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn execute_command<'life0, 'async_trait>(
&'life0 self,
command_args: Vec<String>,
) -> Pin<Box<dyn Future<Output = Result<CommandOutput>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Helper method to execute the command with proper error handling
Source§fn arg<S: AsRef<OsStr>>(&mut self, arg: S) -> &mut Self
fn arg<S: AsRef<OsStr>>(&mut self, arg: S) -> &mut Self
Add a raw argument to the command (escape hatch)
Auto Trait Implementations§
impl Freeze for NetworkLsCommand
impl RefUnwindSafe for NetworkLsCommand
impl Send for NetworkLsCommand
impl Sync for NetworkLsCommand
impl Unpin for NetworkLsCommand
impl UnwindSafe for NetworkLsCommand
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