Struct rtnetlink::RouteHandle
source · pub struct RouteHandle(_);
Implementations§
source§impl RouteHandle
impl RouteHandle
pub fn new(handle: Handle) -> Self
sourcepub fn get(&self, ip_version: IpVersion) -> RouteGetRequest
pub fn get(&self, ip_version: IpVersion) -> RouteGetRequest
Retrieve the list of routing table entries (equivalent to ip route show
)
sourcepub fn add(&self) -> RouteAddRequest
pub fn add(&self) -> RouteAddRequest
Add an routing table entry (equivalent to ip route add
)
sourcepub fn del(&self, route: RouteMessage) -> RouteDelRequest
pub fn del(&self, route: RouteMessage) -> RouteDelRequest
Delete the given routing table entry (equivalent to ip route del
)