pub trait NetT<T: TapT>:
Vhost
+ AsRawDescriptor
+ Send
+ Sized {
// Required methods
fn new(vhost_net_device_path: &Path) -> Result<Self>;
fn set_backend(
&self,
queue_index: usize,
descriptor: Option<&T>,
) -> Result<()>;
}Required Methods§
Sourcefn set_backend(&self, queue_index: usize, descriptor: Option<&T>) -> Result<()>
fn set_backend(&self, queue_index: usize, descriptor: Option<&T>) -> Result<()>
Set the tap file descriptor that will serve as the VHOST_NET backend. This will start the vhost worker for the given queue.
§Arguments
queue_index- Index of the queue to modify.descriptor- Tap interface that will be used as the backend.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.