pub trait IntoRawSocket {
// Required method
fn into_raw_socket(self) -> u32;
}
Expand description
A trait to express the ability to consume an object and acquire ownership of
its raw SOCKET
.
Required Methods§
1.4.0 · Sourcefn into_raw_socket(self) -> u32
fn into_raw_socket(self) -> u32
Consumes this object, returning the raw underlying socket.
This function is typically used to transfer ownership of the underlying socket to the caller. When used in this way, callers are then the unique owners of the socket and must close it once it’s no longer needed.
However, transferring ownership is not strictly required. Use a
Into<OwnedSocket>::into
implementation for an API which strictly
transfers ownership.