pub struct Mapping {
pub script: String,
pub maps: Vec<String>,
}
Expand description
Represents a mapping
stanza in the /etc/network/interfaces
file.
The Mapping
struct holds the script and map entries associated with a
mapping configuration.
§Examples
Creating a new Mapping
:
use interface_rs::interface::Mapping;
let mapping = Mapping {
script: "/usr/local/bin/map-scripts".to_string(),
maps: vec!["eth0".to_string(), "eth1".to_string()],
};
Fields§
§script: String
The script to be used for mapping.
maps: Vec<String>
A list of map entries.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Mapping
impl RefUnwindSafe for Mapping
impl Send for Mapping
impl Sync for Mapping
impl Unpin for Mapping
impl UnwindSafe for Mapping
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