Struct xo_api_client::api::vm::Vm[][src]

pub struct Vm<O> {
    pub id: VmId,
    pub name_label: String,
    pub name_description: String,
    pub power_state: PowerState,
    pub pool: String,
    pub tags: Vec<String>,
    pub os_version: BTreeMap<String, String>,
    pub other: O,
    // some fields omitted
}
Expand description

Type representing a VM

Note that the “other” property contains a lot of different data. In the Xen Orchestra the user may even add additional values. For this reason the struct is made generic over the type O. See the trait OtherInfo for more info

Also see https://github.com/vatesfr/xen-orchestra/blob/a505cd9567233aab7ca6488b2fb8a0b6c610fa08/packages/xo-server/src/xapi-object-to-xo.mjs#L273

Fields

id: VmIdname_label: Stringname_description: Stringpower_state: PowerStatepool: Stringtags: Vec<String>os_version: BTreeMap<String, String>other: O

Implementations

Check if VM is running.

Try to guess OS distro of VM

Note: This only works for running VMs, returns None when distro can not be determined.

Get iterator of all valid IPv4 addresses for VM.

Note: This only works for running VMs, returns empty iterator otherwise

Trait Implementations

Formats the value using the given formatter. Read more

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

Should always be Self

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.