pub struct NetworkLsOutput {
pub networks: Vec<NetworkInfo>,
pub raw_output: CommandOutput,
}
Expand description
Output from network ls command
Fields§
§networks: Vec<NetworkInfo>
List of networks
raw_output: CommandOutput
Raw command output
Implementations§
Source§impl NetworkLsOutput
impl NetworkLsOutput
Sourcepub fn is_success(&self) -> bool
pub fn is_success(&self) -> bool
Check if the command was successful
Sourcepub fn get_network(&self, name: &str) -> Option<&NetworkInfo>
pub fn get_network(&self, name: &str) -> Option<&NetworkInfo>
Get network by name
Trait Implementations§
Source§impl Clone for NetworkLsOutput
impl Clone for NetworkLsOutput
Source§fn clone(&self) -> NetworkLsOutput
fn clone(&self) -> NetworkLsOutput
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 NetworkLsOutput
impl Debug for NetworkLsOutput
Source§impl From<CommandOutput> for NetworkLsOutput
impl From<CommandOutput> for NetworkLsOutput
Source§fn from(output: CommandOutput) -> Self
fn from(output: CommandOutput) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for NetworkLsOutput
impl RefUnwindSafe for NetworkLsOutput
impl Send for NetworkLsOutput
impl Sync for NetworkLsOutput
impl Unpin for NetworkLsOutput
impl UnwindSafe for NetworkLsOutput
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