pub struct Netlink<P: SenderReceiverProvider> { /* private fields */ }
Expand description
The implementation of the Netlink protocol suite.
Implementations§
source§impl<P: SenderReceiverProvider> Netlink<P>
impl<P: SenderReceiverProvider> Netlink<P>
sourcepub fn new<H: InterfacesHandler>(
interfaces_handler: H
) -> (Self, impl Future<Output = ()> + Send)
pub fn new<H: InterfacesHandler>( interfaces_handler: H ) -> (Self, impl Future<Output = ()> + Send)
sourcepub fn new_route_client(
&self,
sender: P::Sender<RouteNetlinkMessage>,
receiver: P::Receiver<RouteNetlinkMessage>
) -> Result<NetlinkRouteClient, NewClientError>
pub fn new_route_client( &self, sender: P::Sender<RouteNetlinkMessage>, receiver: P::Receiver<RouteNetlinkMessage> ) -> Result<NetlinkRouteClient, NewClientError>
Creates a new client of the NETLINK_ROUTE
protocol family.
sender
is used by Netlink to send messages to the client.
receiver
is used by Netlink to receive messages from the client.
Closing the receiver
will close this client, disconnecting sender
.
Auto Trait Implementations§
impl<P> !Freeze for Netlink<P>
impl<P> !RefUnwindSafe for Netlink<P>
impl<P> Send for Netlink<P>
impl<P> Sync for Netlink<P>
impl<P> Unpin for Netlink<P>
impl<P> !UnwindSafe for Netlink<P>
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
§impl<T> Encode<Ambiguous1> for T
impl<T> Encode<Ambiguous1> for T
§impl<T> Encode<Ambiguous2> for T
impl<T> Encode<Ambiguous2> for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> IntoAny for T
impl<T> IntoAny for T
§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T, U> TryIntoExt<U> for Twhere
U: TryFromExt<T>,
impl<T, U> TryIntoExt<U> for Twhere
U: TryFromExt<T>,
type Error = <U as TryFromExt<T>>::Error
§fn try_into_ext(self) -> Result<U, <T as TryIntoExt<U>>::Error>
fn try_into_ext(self) -> Result<U, <T as TryIntoExt<U>>::Error>
Tries to perform the conversion.