pub struct Device {
pub basic: Option<BasicDevice>,
pub name: String,
}Expand description
Device represents one individual hardware instance that can be selected based on its attributes. Besides the name, exactly one field must be set.
Fields§
§basic: Option<BasicDevice>Basic defines one device instance.
name: StringName is unique identifier among all devices managed by the driver in the pool. It must be a DNS label.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Device
impl<'de> Deserialize<'de> for Device
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl JsonSchema for Device
Available on crate feature schemars only.
impl JsonSchema for Device
Available on crate feature
schemars only.Source§fn json_schema(__gen: &mut SchemaGenerator) -> Schema
fn json_schema(__gen: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreimpl StructuralPartialEq for Device
Auto Trait Implementations§
impl Freeze for Device
impl RefUnwindSafe for Device
impl Send for Device
impl Sync for Device
impl Unpin for Device
impl UnwindSafe for Device
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