Trait vm_resource::ResourceKind

source ·
pub trait ResourceKind:
    'static
    + Send
    + Sync {
    const NAME: &'static str;
}
Expand description

Trait implemented by resource kinds.

A resource kind defines a family of interchangeable resource types, where each resource type can be resolved to the same output type.

The output type is specified in the CanResolveTo trait.

Typically this trait will be implemented on an uninhabited tag type, e.g.

enum DiskKind {}

trait Disk {};

impl vm_resource::ResourceKind for DiskKind {
    const NAME: &'static str = "disk";
}

Required Associated Constants§

source

const NAME: &'static str

The name of the resource kind. This must be unique amongst resource kinds.

Object Safety§

This trait is not object safe.

Implementors§

source§

impl ResourceKind for ChipsetDeviceHandleKind

source§

const NAME: &'static str = "chipset_device_handle"

source§

impl ResourceKind for DiskHandleKind

source§

const NAME: &'static str = "disk_handle"

source§

impl ResourceKind for FramebufferHandleKind

source§

const NAME: &'static str = "framebuffer"

source§

impl ResourceKind for KeyboardInputHandleKind

source§

const NAME: &'static str = "keyboard_input_handle"

source§

impl ResourceKind for MouseInputHandleKind

source§

const NAME: &'static str = "mouse_input_handle"

source§

impl ResourceKind for NetEndpointHandleKind

source§

const NAME: &'static str = "net_endpoint_handle"

source§

impl ResourceKind for NonVolatileStoreKind

source§

const NAME: &'static str = "nvstore"

source§

impl ResourceKind for PciDeviceHandleKind

source§

const NAME: &'static str = "pci_device_handle"

source§

impl ResourceKind for ScsiDeviceHandleKind

source§

const NAME: &'static str = "scsi_device"

source§

impl ResourceKind for SerialBackendHandle

source§

const NAME: &'static str = "serial_handle"

source§

impl ResourceKind for VirtioDeviceHandle

source§

const NAME: &'static str = "virtio"

source§

impl ResourceKind for VmbusDeviceHandleKind

source§

const NAME: &'static str = "vmbus_device_handle"