libvirt-go-xml: github.com/libvirt/libvirt-go-xml Index | Files

package libvirtxml

import "github.com/libvirt/libvirt-go-xml"

Package libvirt-go-xml defines structs for parsing libvirt XML schemas

The libvirt API uses XML schemas/documents to describe the configuration of many of its managed objects. Thus when using the libvirt-go package, it is often neccessary to either parse or format XML documents. This package defines a set of Go structs which have been annotated for use with the encoding/xml API to manage libvirt XML documents.

Example creating a domain XML document from configuration:

import (
 "github.com/libvirt/libvirt-go-xml"
)

domcfg := &libvirtxml.Domain{Type: "kvm", Name: "demo",
                             UUID: "8f99e332-06c4-463a-9099-330fb244e1b3",
                             ....}
xmldoc, err := domcfg.Marshal()

Example parsing a domainXML document, in combination with libvirt-go

import (
  "github.com/libvirt/libvirt-go"
  "github.com/libvirt/libvirt-go-xml"
  "fmt"
)

conn, err := libvirt.NewConnect("qemu:///system")
dom := conn.LookupDomainByName("demo")
xmldoc, err := dom.GetXMLDesc(0)

domcfg := &libvirtxml.Domain{}
err := domcfg.Unmarshal(xmldoc)

fmt.Printf("Virt type %s", domcfg.Type)

Index

Package Files

capabilities.go doc.go document.go domain.go domain_snapshot.go network.go node_device.go secret.go storage_encryption.go storage_pool.go storage_vol.go

type Caps Uses

type Caps struct {
    XMLName xml.Name    `xml:"capabilities"`
    Host    CapsHost    `xml:"host"`
    Guests  []CapsGuest `xml:"guest"`
}

func (*Caps) Marshal Uses

func (c *Caps) Marshal() (string, error)

func (*Caps) Unmarshal Uses

func (c *Caps) Unmarshal(doc string) error

type CapsGuest Uses

type CapsGuest struct {
    OSType   string             `xml:"os_type"`
    Arch     CapsGuestArch      `xml:"arch"`
    Features *CapsGuestFeatures `xml:"features"`
}

type CapsGuestArch Uses

type CapsGuestArch struct {
    Name     string             `xml:"name,attr"`
    WordSize string             `xml:"wordsize"`
    Emulator string             `xml:"emulator"`
    Machines []CapsGuestMachine `xml:"machine"`
    Domains  []CapsGuestDomain  `xml:"domain"`
}

type CapsGuestDomain Uses

type CapsGuestDomain struct {
    Type     string             `xml:"type,attr"`
    Emulator string             `xml:"emulator"`
    Machines []CapsGuestMachine `xml:"machine"`
}

type CapsGuestFeatures Uses

type CapsGuestFeatures struct {
    CPUSelection *struct{} `xml:"cpuselection"`
    DeviceBoot   *struct{} `xml:"deviceboot"`
}

type CapsGuestMachine Uses

type CapsGuestMachine struct {
    Name      string  `xml:",chardata"`
    MaxCPUs   int     `xml:"maxCpus,attr"`
    Canonical *string `xml:"canonical,attr"`
}

type CapsHost Uses

type CapsHost struct {
    UUID     string                `xml:"uuid"`
    CPU      *CapsHostCPU          `xml:"cpu"`
    NUMA     *CapsHostNUMATopology `xml:"topology"`
    SecModel []CapsHostSecModel    `xml:"secmodel"`
}

type CapsHostCPU Uses

type CapsHostCPU struct {
    Arch      string                `xml:"arch"`
    Model     string                `xml:"model"`
    Vendor    string                `xml:"vendor"`
    Topology  CapsHostCPUTopology   `xml:"topology"`
    Features  []CapsHostCPUFeature  `xml:"feature"`
    PageSizes []CapsHostCPUPageSize `xml:"pages"`
}

type CapsHostCPUFeature Uses

type CapsHostCPUFeature struct {
    Name string `xml:"name,attr"`
}

type CapsHostCPUPageSize Uses

type CapsHostCPUPageSize struct {
    Size int    `xml:"size,attr"`
    Unit string `xml:"unit,attr"`
}

type CapsHostCPUTopology Uses

type CapsHostCPUTopology struct {
    Sockets int `xml:"sockets,attr"`
    Cores   int `xml:"cores,attr"`
    Threads int `xml:"threads,attr"`
}

type CapsHostNUMACPU Uses

type CapsHostNUMACPU struct {
    ID       int    `xml:"id,attr"`
    SocketID int    `xml:"socket_id,attr"`
    CoreID   int    `xml:"core_id,attr"`
    Siblings string `xml:"siblings,attr"`
}

type CapsHostNUMACell Uses

type CapsHostNUMACell struct {
    ID        int                    `xml:"id,attr"`
    Memory    CapsHostNUMAMemory     `xml:"memory"`
    PageInfo  []CapsHostNUMAPageInfo `xml:"pages"`
    Distances []CapsHostNUMADistance `xml:"distances>sibling"`
    CPUS      []CapsHostNUMACPU      `xml:"cpus>cpu"`
}

type CapsHostNUMADistance Uses

type CapsHostNUMADistance struct {
    ID    int `xml:"id,attr"`
    Value int `xml:"value,attr"`
}

type CapsHostNUMAMemory Uses

type CapsHostNUMAMemory struct {
    Size uint64 `xml:"size,attr"`
    Unit string `xml:"unit,attr"`
}

type CapsHostNUMAPageInfo Uses

type CapsHostNUMAPageInfo struct {
    Size  int    `xml:"size,attr"`
    Unit  string `xml:"unit,attr"`
    Count uint64 `xml:",chardata"`
}

type CapsHostNUMATopology Uses

type CapsHostNUMATopology struct {
    Cells []CapsHostNUMACell `xml:"cells>cell"`
}

type CapsHostSecModel Uses

type CapsHostSecModel struct {
    Name   string                  `xml:"model"`
    DOI    string                  `xml:"doi"`
    Labels []CapsHostSecModelLabel `xml:"baselabel"`
}

type CapsHostSecModelLabel Uses

type CapsHostSecModelLabel struct {
    Type  string `xml:"type,attr"`
    Value string `xml:",chardata"`
}

type Document Uses

type Document interface {
    Unmarshal(doc string) error
    Marshal() (string, error)
}

type Domain Uses

type Domain struct {
    XMLName         xml.Name             `xml:"domain"`
    Type            string               `xml:"type,attr,omitempty"`
    Name            string               `xml:"name"`
    UUID            string               `xml:"uuid,omitempty"`
    Memory          *DomainMemory        `xml:"memory"`
    CurrentMemory   *DomainMemory        `xml:"currentMemory"`
    MaximumMemory   *DomainMaxMemory     `xml:"maxMemory"`
    MemoryBacking   *DomainMemoryBacking `xml:"memoryBacking"`
    VCPU            *DomainVCPU          `xml:"vcpu"`
    VCPUs           *DomainVCPUs         `xml:"vcpus"`
    CPUTune         *DomainCPUTune       `xml:"cputune"`
    Bootloader      string               `xml:"bootloader,omitempty"`
    BootloaderArgs  string               `xml:"bootloader_args,omitempty"`
    Resource        *DomainResource      `xml:"resource"`
    SysInfo         *DomainSysInfo       `xml:"sysinfo"`
    OS              *DomainOS            `xml:"os"`
    Features        *DomainFeatureList   `xml:"features"`
    CPU             *DomainCPU           `xml:"cpu"`
    Clock           *DomainClock         `xml:"clock,omitempty"`
    OnPoweroff      string               `xml:"on_poweroff,omitempty"`
    OnReboot        string               `xml:"on_reboot,omitempty"`
    OnCrash         string               `xml:"on_crash,omitempty"`
    Devices         *DomainDeviceList    `xml:"devices"`
    QEMUCommandline *DomainQEMUCommandline
}

NB, try to keep the order of fields in this struct matching the order of XML elements that libvirt will generate when dumping XML.

func (*Domain) Marshal Uses

func (d *Domain) Marshal() (string, error)

func (*Domain) Unmarshal Uses

func (d *Domain) Unmarshal(doc string) error

type DomainAddress Uses

type DomainAddress struct {
    USB   *DomainAddressUSB
    PCI   *DomainAddressPCI
    Drive *DomainAddressDrive
    DIMM  *DomainAddressDIMM
    ISA   *DomainAddressISA
}

func (*DomainAddress) MarshalXML Uses

func (a *DomainAddress) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*DomainAddress) UnmarshalXML Uses

func (a *DomainAddress) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type DomainAddressDIMM Uses

type DomainAddressDIMM struct {
    Slot *uint   `xml:"slot,attr"`
    Base *uint64 `xml:"base,attr"`
}

func (*DomainAddressDIMM) MarshalXML Uses

func (a *DomainAddressDIMM) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*DomainAddressDIMM) UnmarshalXML Uses

func (a *DomainAddressDIMM) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type DomainAddressDrive Uses

type DomainAddressDrive struct {
    Controller *uint `xml:"controller,attr"`
    Bus        *uint `xml:"bus,attr"`
    Target     *uint `xml:"target,attr"`
    Unit       *uint `xml:"unit,attr"`
}

func (*DomainAddressDrive) MarshalXML Uses

func (a *DomainAddressDrive) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*DomainAddressDrive) UnmarshalXML Uses

func (a *DomainAddressDrive) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type DomainAddressISA Uses

type DomainAddressISA struct {
    Iobase *uint `xml:"iobase,attr"`
}

func (*DomainAddressISA) MarshalXML Uses

func (a *DomainAddressISA) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*DomainAddressISA) UnmarshalXML Uses

func (a *DomainAddressISA) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type DomainAddressPCI Uses

type DomainAddressPCI struct {
    Domain   *uint `xml:"domain,attr"`
    Bus      *uint `xml:"bus,attr"`
    Slot     *uint `xml:"slot,attr"`
    Function *uint `xml:"function,attr"`
}

func (*DomainAddressPCI) MarshalXML Uses

func (a *DomainAddressPCI) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*DomainAddressPCI) UnmarshalXML Uses

func (a *DomainAddressPCI) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type DomainAddressUSB Uses

type DomainAddressUSB struct {
    Bus  *uint `xml:"bus,attr"`
    Port *uint `xml:"port,attr"`
}

func (*DomainAddressUSB) MarshalXML Uses

func (a *DomainAddressUSB) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*DomainAddressUSB) UnmarshalXML Uses

func (a *DomainAddressUSB) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type DomainAlias Uses

type DomainAlias struct {
    Name string `xml:"name,attr"`
}

type DomainBIOS Uses

type DomainBIOS struct {
    UseSerial     string `xml:"useserial,attr"`
    RebootTimeout string `xml:"rebootTimeout,attr"`
}

type DomainBootDevice Uses

type DomainBootDevice struct {
    Dev string `xml:"dev,attr"`
}

type DomainBootMenu Uses

type DomainBootMenu struct {
    Enabled string `xml:"enabled,attr"`
    Timeout string `xml:"timeout,attr"`
}

type DomainCPU Uses

type DomainCPU struct {
    Match    string             `xml:"match,attr,omitempty"`
    Mode     string             `xml:"mode,attr,omitempty"`
    Model    *DomainCPUModel    `xml:"model"`
    Vendor   string             `xml:"vendor,omitempty"`
    Topology *DomainCPUTopology `xml:"topology"`
    Features []DomainCPUFeature `xml:"feature"`
    Numa     *DomainNuma        `xml:"numa,omitempty"`
}

type DomainCPUFeature Uses

type DomainCPUFeature struct {
    Policy string `xml:"policy,attr,omitempty"`
    Name   string `xml:"name,attr,omitempty"`
}

type DomainCPUModel Uses

type DomainCPUModel struct {
    Fallback string `xml:"fallback,attr,omitempty"`
    Value    string `xml:",chardata"`
}

type DomainCPUTopology Uses

type DomainCPUTopology struct {
    Sockets int `xml:"sockets,attr,omitempty"`
    Cores   int `xml:"cores,attr,omitempty"`
    Threads int `xml:"threads,attr,omitempty"`
}

type DomainCPUTune Uses

type DomainCPUTune struct {
    Shares *DomainCPUTuneShares `xml:"shares"`
    Period *DomainCPUTunePeriod `xml:"period"`
    Quota  *DomainCPUTuneQuota  `xml:"quota"`
}

type DomainCPUTunePeriod Uses

type DomainCPUTunePeriod struct {
    Value uint64 `xml:",chardata"`
}

type DomainCPUTuneQuota Uses

type DomainCPUTuneQuota struct {
    Value int64 `xml:",chardata"`
}

type DomainCPUTuneShares Uses

type DomainCPUTuneShares struct {
    Value uint `xml:",chardata"`
}

type DomainCell Uses

type DomainCell struct {
    ID     string `xml:"id,attr"`
    CPUs   string `xml:"cpus,attr"`
    Memory string `xml:"memory,attr"`
    Unit   string `xml:"unit,attr"`
}

type DomainChannel Uses

type DomainChannel struct {
    XMLName xml.Name             `xml:"channel"`
    Type    string               `xml:"type,attr"`
    Source  *DomainChardevSource `xml:"source"`
    Target  *DomainChannelTarget `xml:"target"`
    Alias   *DomainAlias         `xml:"alias"`
    Address *DomainAddress       `xml:"address"`
}

func (*DomainChannel) Marshal Uses

func (d *DomainChannel) Marshal() (string, error)

func (*DomainChannel) Unmarshal Uses

func (d *DomainChannel) Unmarshal(doc string) error

type DomainChannelTarget Uses

type DomainChannelTarget struct {
    Type  string `xml:"type,attr,omitempty"`
    Name  string `xml:"name,attr,omitempty"`
    State string `xml:"state,attr,omitempty"` // is guest agent connected?
}

type DomainChardevSource Uses

type DomainChardevSource struct {
    Mode    string `xml:"mode,attr,omitempty"`
    Path    string `xml:"path,attr,omitempty"`
    Append  string `xml:"append,attr,omitempty"`
    Host    string `xml:"host,attr,omitempty"`
    Service string `xml:"service,attr,omitempty"`
    TLS     string `xml:"tls,attr,omitempty"`
}

type DomainChardevTarget Uses

type DomainChardevTarget struct {
    Type  string `xml:"type,attr,omitempty"`
    Name  string `xml:"name,attr,omitempty"`
    State string `xml:"state,attr,omitempty"` // is guest agent connected?
    Port  *uint  `xml:"port,attr"`
}

type DomainClock Uses

type DomainClock struct {
    Offset     string        `xml:"offset,attr,omitempty"`
    Basis      string        `xml:"basis,attr,omitempty"`
    Adjustment int           `xml:"adjustment,attr,omitempty"`
    Timer      []DomainTimer `xml:"timer,omitempty"`
}

type DomainConsole Uses

type DomainConsole struct {
    XMLName xml.Name             `xml:"console"`
    Type    string               `xml:"type,attr"`
    Source  *DomainChardevSource `xml:"source"`
    Target  *DomainConsoleTarget `xml:"target"`
    Alias   *DomainAlias         `xml:"alias"`
    Address *DomainAddress       `xml:"address"`
}

func (*DomainConsole) Marshal Uses

func (d *DomainConsole) Marshal() (string, error)

func (*DomainConsole) Unmarshal Uses

func (d *DomainConsole) Unmarshal(doc string) error

type DomainConsoleTarget Uses

type DomainConsoleTarget struct {
    Type string `xml:"type,attr,omitempty"`
    Port *uint  `xml:"port,attr"`
}

type DomainController Uses

type DomainController struct {
    XMLName xml.Name       `xml:"controller"`
    Type    string         `xml:"type,attr"`
    Index   *uint          `xml:"index,attr"`
    Model   string         `xml:"model,attr,omitempty"`
    Address *DomainAddress `xml:"address"`
}

func (*DomainController) Marshal Uses

func (d *DomainController) Marshal() (string, error)

func (*DomainController) Unmarshal Uses

func (d *DomainController) Unmarshal(doc string) error

type DomainDeviceBoot Uses

type DomainDeviceBoot struct {
    Order uint `xml:"order,attr"`
}

type DomainDeviceList Uses

type DomainDeviceList struct {
    Emulator    string             `xml:"emulator,omitempty"`
    Controllers []DomainController `xml:"controller"`
    Disks       []DomainDisk       `xml:"disk"`
    Filesystems []DomainFilesystem `xml:"filesystem"`
    Interfaces  []DomainInterface  `xml:"interface"`
    Serials     []DomainSerial     `xml:"serial"`
    Consoles    []DomainConsole    `xml:"console"`
    Inputs      []DomainInput      `xml:"input"`
    Graphics    []DomainGraphic    `xml:"graphics"`
    Videos      []DomainVideo      `xml:"video"`
    Channels    []DomainChannel    `xml:"channel"`
    MemBalloon  *DomainMemBalloon  `xml:"memballoon"`
    Panics      []DomainPanic      `xml:"panic"`
    Sounds      []DomainSound      `xml:"sound"`
    RNGs        []DomainRNG        `xml:"rng"`
    Hostdevs    []DomainHostdev    `xml:"hostdev"`
    Memorydevs  []DomainMemorydev  `xml:"memory"`
}

type DomainDisk Uses

type DomainDisk struct {
    XMLName   xml.Name             `xml:"disk"`
    Type      string               `xml:"type,attr"`
    Device    string               `xml:"device,attr"`
    Snapshot  string               `xml:"snapshot,attr,omitempty"`
    Driver    *DomainDiskDriver    `xml:"driver"`
    Auth      *DomainDiskAuth      `xml:"auth"`
    Source    *DomainDiskSource    `xml:"source"`
    Target    *DomainDiskTarget    `xml:"target"`
    IOTune    *DomainDiskIOTune    `xml:"iotune"`
    Serial    string               `xml:"serial,omitempty"`
    ReadOnly  *DomainDiskReadOnly  `xml:"readonly"`
    Shareable *DomainDiskShareable `xml:"shareable"`
    Address   *DomainAddress       `xml:"address"`
    Boot      *DomainDeviceBoot    `xml:"boot"`
    WWN       string               `xml:"wwn,omitempty"`
}

func (*DomainDisk) Marshal Uses

func (d *DomainDisk) Marshal() (string, error)

func (*DomainDisk) Unmarshal Uses

func (d *DomainDisk) Unmarshal(doc string) error

type DomainDiskAuth Uses

type DomainDiskAuth struct {
    Username string            `xml:"username,attr,omitempty"`
    Secret   *DomainDiskSecret `xml:"secret"`
}

type DomainDiskDriver Uses

type DomainDiskDriver struct {
    Name        string `xml:"name,attr,omitempty"`
    Type        string `xml:"type,attr,omitempty"`
    Cache       string `xml:"cache,attr,omitempty"`
    IO          string `xml:"io,attr,omitempty"`
    ErrorPolicy string `xml:"error_policy,attr,omitempty"`
    Discard     string `xml:"discard,attr,omitempty"`
}

type DomainDiskIOTune Uses

type DomainDiskIOTune struct {
    TotalBytesSec          uint64 `xml:"total_bytes_sec"`
    ReadBytesSec           uint64 `xml:"read_bytes_sec"`
    WriteBytesSec          uint64 `xml:"write_bytes_sec"`
    TotalIopsSec           uint64 `xml:"total_iops_sec"`
    ReadIopsSec            uint64 `xml:"read_iops_sec"`
    WriteIopsSec           uint64 `xml:"write_iops_sec"`
    TotalBytesSecMax       uint64 `xml:"total_bytes_sec_max"`
    ReadBytesSecMax        uint64 `xml:"read_bytes_sec_max"`
    WriteBytesSecMax       uint64 `xml:"write_bytes_sec_max"`
    TotalIopsSecMax        uint64 `xml:"total_iops_sec_max"`
    ReadIopsSecMax         uint64 `xml:"read_iops_sec_max"`
    WriteIopsSecMax        uint64 `xml:"write_iops_sec_max"`
    TotalBytesSecMaxLength uint64 `xml:"total_bytes_sec_max_length"`
    ReadBytesSecMaxLength  uint64 `xml:"read_bytes_sec_max_length"`
    WriteBytesSecMaxLength uint64 `xml:"write_bytes_sec_max_length"`
    TotalIopsSecMaxLength  uint64 `xml:"total_iops_sec_max_length"`
    ReadIopsSecMaxLength   uint64 `xml:"read_iops_sec_max_length"`
    WriteIopsSecMaxLength  uint64 `xml:"write_iops_sec_max_length"`
    SizeIopsSec            uint64 `xml:"size_iops_sec"`
    GroupName              string `xml:"group_name"`
}

type DomainDiskReadOnly Uses

type DomainDiskReadOnly struct {
}

type DomainDiskSecret Uses

type DomainDiskSecret struct {
    Type  string `xml:"type,attr,omitempty"`
    Usage string `xml:"usage,attr,omitempty"`
    UUID  string `xml:"uuid,attr,omitempty"`
}

type DomainDiskShareable Uses

type DomainDiskShareable struct {
}

type DomainDiskSource Uses

type DomainDiskSource struct {
    File          string                 `xml:"file,attr,omitempty"`
    Device        string                 `xml:"dev,attr,omitempty"`
    Protocol      string                 `xml:"protocol,attr,omitempty"`
    Name          string                 `xml:"name,attr,omitempty"`
    Pool          string                 `xml:"pool,attr,omitempty"`
    Volume        string                 `xml:"volume,attr,omitempty"`
    Hosts         []DomainDiskSourceHost `xml:"host"`
    StartupPolicy string                 `xml:"startupPolicy,attr,omitempty"`
}

type DomainDiskSourceHost Uses

type DomainDiskSourceHost struct {
    Transport string `xml:"transport,attr,omitempty"`
    Name      string `xml:"name,attr,omitempty"`
    Port      string `xml:"port,attr,omitempty"`
    Socket    string `xml:"socket,attr,omitempty"`
}

type DomainDiskTarget Uses

type DomainDiskTarget struct {
    Dev string `xml:"dev,attr,omitempty"`
    Bus string `xml:"bus,attr,omitempty"`
}

type DomainFeature Uses

type DomainFeature struct {
}

type DomainFeatureAPIC Uses

type DomainFeatureAPIC struct {
    EOI string `xml:"eio,attr,omitempty"`
}

type DomainFeatureGIC Uses

type DomainFeatureGIC struct {
    Version string `xml:"version,attr,omitempty"`
}

type DomainFeatureHyperV Uses

type DomainFeatureHyperV struct {
    DomainFeature
    Relaxed   *DomainFeatureState           `xml:"relaxed"`
    VAPIC     *DomainFeatureState           `xml:"vapic"`
    Spinlocks *DomainFeatureHyperVSpinlocks `xml:"spinlocks"`
    VPIndex   *DomainFeatureState           `xml:"vpindex"`
    Runtime   *DomainFeatureState           `xml:"runtime"`
    Synic     *DomainFeatureState           `xml:"synic"`
    STimer    *DomainFeatureState           `xml:"stimer"`
    Reset     *DomainFeatureState           `xml:"reset"`
    VendorId  *DomainFeatureHyperVVendorId  `xml:"vendor_id"`
}

type DomainFeatureHyperVSpinlocks Uses

type DomainFeatureHyperVSpinlocks struct {
    DomainFeatureState
    Retries uint `xml:"retries,attr,omitempty"`
}

type DomainFeatureHyperVVendorId Uses

type DomainFeatureHyperVVendorId struct {
    DomainFeatureState
    Value string `xml:"value,attr,omitempty"`
}

type DomainFeatureKVM Uses

type DomainFeatureKVM struct {
    Hidden *DomainFeatureState `xml:"hidden"`
}

type DomainFeatureList Uses

type DomainFeatureList struct {
    PAE        *DomainFeature       `xml:"pae"`
    ACPI       *DomainFeature       `xml:"acpi"`
    APIC       *DomainFeatureAPIC   `xml:"apic"`
    HAP        *DomainFeatureState  `xml:"hap"`
    Viridian   *DomainFeature       `xml:"viridian"`
    PrivNet    *DomainFeature       `xml:"privnet"`
    HyperV     *DomainFeatureHyperV `xml:"hyperv"`
    KVM        *DomainFeatureKVM    `xml:"kvm"`
    PVSpinlock *DomainFeatureState  `xml:"pvspinlock"`
    PMU        *DomainFeatureState  `xml:"pmu"`
    VMPort     *DomainFeatureState  `xml:"vmport"`
    GIC        *DomainFeatureGIC    `xml:"gic"`
    SMM        *DomainFeatureState  `xml:"smm"`
}

type DomainFeatureState Uses

type DomainFeatureState struct {
    State string `xml:"state,attr,omitempty"`
}

type DomainFilesystem Uses

type DomainFilesystem struct {
    XMLName        xml.Name                        `xml:"filesystem"`
    Type           string                          `xml:"type,attr"`
    AccessMode     string                          `xml:"accessmode,attr"`
    Driver         *DomainFilesystemDriver         `xml:"driver"`
    Source         *DomainFilesystemSource         `xml:"source"`
    Target         *DomainFilesystemTarget         `xml:"target"`
    ReadOnly       *DomainFilesystemReadOnly       `xml:"readonly"`
    SpaceHardLimit *DomainFilesystemSpaceHardLimit `xml:"space_hard_limit"`
    SpaceSoftLimit *DomainFilesystemSpaceSoftLimit `xml:"space_soft_limit"`
    Address        *DomainAddress                  `xml:"address"`
}

func (*DomainFilesystem) Marshal Uses

func (d *DomainFilesystem) Marshal() (string, error)

func (*DomainFilesystem) Unmarshal Uses

func (d *DomainFilesystem) Unmarshal(doc string) error

type DomainFilesystemDriver Uses

type DomainFilesystemDriver struct {
    Type     string `xml:"type,attr"`
    Name     string `xml:"name,attr,omitempty"`
    WRPolicy string `xml:"wrpolicy,attr,omitempty"`
}

type DomainFilesystemReadOnly Uses

type DomainFilesystemReadOnly struct {
}

type DomainFilesystemSource Uses

type DomainFilesystemSource struct {
    Dir  string `xml:"dir,attr,omitempty"`
    File string `xml:"file,attr,omitempty"`
}

type DomainFilesystemSpaceHardLimit Uses

type DomainFilesystemSpaceHardLimit struct {
    Value uint   `xml:",chardata"`
    Unit  string `xml:"unit,attr,omitempty"`
}

type DomainFilesystemSpaceSoftLimit Uses

type DomainFilesystemSpaceSoftLimit struct {
    Value uint   `xml:",chardata"`
    Unit  string `xml:"unit,attr,omitempty"`
}

type DomainFilesystemTarget Uses

type DomainFilesystemTarget struct {
    Dir string `xml:"dir,attr"`
}

type DomainGraphic Uses

type DomainGraphic struct {
    XMLName       xml.Name                `xml:"graphics"`
    Type          string                  `xml:"type,attr"`
    AutoPort      string                  `xml:"autoport,attr,omitempty"`
    Port          int                     `xml:"port,attr,omitempty"`
    TLSPort       int                     `xml:"tlsPort,attr,omitempty"`
    WebSocket     int                     `xml:"websocket,attr,omitempty"`
    Listen        string                  `xml:"listen,attr,omitempty"`
    Socket        string                  `xml:"socket,attr,omitempty"`
    Keymap        string                  `xml:"keymap,attr,omitempty"`
    Passwd        string                  `xml:"passwd,attr,omitempty"`
    PasswdValidTo string                  `xml:"passwdValidTo,attr,omitempty"`
    Connected     string                  `xml:"connected,attr,omitempty"`
    SharePolicy   string                  `xml:"sharePolicy,attr,omitempty"`
    DefaultMode   string                  `xml:"defaultMode,attr,omitempty"`
    Display       string                  `xml:"display,attr,omitempty"`
    XAuth         string                  `xml:"xauth,attr,omitempty"`
    FullScreen    string                  `xml:"fullscreen,attr,omitempty"`
    ReplaceUser   string                  `xml:"replaceUser,attr,omitempty"`
    MultiUser     string                  `xml:"multiUser,attr,omitempty"`
    Listeners     []DomainGraphicListener `xml:"listen"`
}

type DomainGraphicListener Uses

type DomainGraphicListener struct {
    Type    string `xml:"type,attr"`
    Address string `xml:"address,attr,omitempty"`
    Network string `xml:"network,attr,omitempty"`
    Socket  string `xml:"socket,attr,omitempty"`
}

type DomainHostdev Uses

type DomainHostdev struct {
    XMLName xml.Name             `xml:"hostdev"`
    Mode    string               `xml:"mode,attr"`
    Type    string               `xml:"type,attr"`
    SGIO    string               `xml:"sgio,attr,omitempty"`
    RawIO   string               `xml:"rawio,attr,omitempty"`
    Managed string               `xml:"managed,attr,omitempty"`
    Source  *DomainHostdevSource `xml:"source"`
    Address *DomainAddress       `xml:"address"`
}

func (*DomainHostdev) Marshal Uses

func (d *DomainHostdev) Marshal() (string, error)

func (*DomainHostdev) Unmarshal Uses

func (d *DomainHostdev) Unmarshal(doc string) error

type DomainHostdevAdapter Uses

type DomainHostdevAdapter struct {
    Name string `xml:"name,attr,omitempty"`
}

type DomainHostdevSource Uses

type DomainHostdevSource struct {
    Protocol string                `xml:"protocol,attr,omitempty"`
    Name     string                `xml:"name,attr,omitempty"`
    WWPN     string                `xml:"wwpn,attr,omitempty"`
    Adapter  *DomainHostdevAdapter `xml:"adapter"`
    Address  *DomainAddress        `xml:"address"`
}

type DomainInput Uses

type DomainInput struct {
    XMLName xml.Name       `xml:"input"`
    Type    string         `xml:"type,attr"`
    Bus     string         `xml:"bus,attr"`
    Address *DomainAddress `xml:"address"`
}

func (*DomainInput) Marshal Uses

func (d *DomainInput) Marshal() (string, error)

func (*DomainInput) Unmarshal Uses

func (d *DomainInput) Unmarshal(doc string) error

type DomainInterface Uses

type DomainInterface struct {
    XMLName     xml.Name                    `xml:"interface"`
    Type        string                      `xml:"type,attr"`
    MAC         *DomainInterfaceMAC         `xml:"mac"`
    Model       *DomainInterfaceModel       `xml:"model"`
    Source      *DomainInterfaceSource      `xml:"source"`
    Target      *DomainInterfaceTarget      `xml:"target"`
    Alias       *DomainInterfaceAlias       `xml:"alias"`
    Link        *DomainInterfaceLink        `xml:"link"`
    Boot        *DomainDeviceBoot           `xml:"boot"`
    Script      *DomainInterfaceScript      `xml:"script"`
    Driver      *DomainInterfaceDriver      `xml:"driver"`
    Virtualport *DomainInterfaceVirtualport `xml:"virtualport"`
    Bandwidth   *DomainInterfaceBandwidth   `xml:"bandwidth"`
    Address     *DomainAddress              `xml:"address"`
}

func (*DomainInterface) Marshal Uses

func (d *DomainInterface) Marshal() (string, error)

func (*DomainInterface) Unmarshal Uses

func (d *DomainInterface) Unmarshal(doc string) error

type DomainInterfaceAlias Uses

type DomainInterfaceAlias struct {
    Name string `xml:"name,attr"`
}

type DomainInterfaceBandwidth Uses

type DomainInterfaceBandwidth struct {
    Inbound  *DomainInterfaceBandwidthParams `xml:"inbound"`
    Outbound *DomainInterfaceBandwidthParams `xml:"outbound"`
}

type DomainInterfaceBandwidthParams Uses

type DomainInterfaceBandwidthParams struct {
    Average *int `xml:"average,attr,omitempty"`
    Peak    *int `xml:"peak,attr,omitempty"`
    Burst   *int `xml:"burst,attr,omitempty"`
    Floor   *int `xml:"floor,attr,omitempty"`
}

type DomainInterfaceDriver Uses

type DomainInterfaceDriver struct {
    Name   string `xml:"name,attr"`
    Queues uint   `xml:"queues,attr,omitempty"`
}
type DomainInterfaceLink struct {
    State string `xml:"state,attr"`
}

type DomainInterfaceMAC Uses

type DomainInterfaceMAC struct {
    Address string `xml:"address,attr"`
}

type DomainInterfaceModel Uses

type DomainInterfaceModel struct {
    Type string `xml:"type,attr"`
}

type DomainInterfaceScript Uses

type DomainInterfaceScript struct {
    Path string `xml:"path,attr"`
}

type DomainInterfaceSource Uses

type DomainInterfaceSource struct {
    Bridge  string                      `xml:"bridge,attr,omitempty"`
    Dev     string                      `xml:"dev,attr,omitempty"`
    Network string                      `xml:"network,attr,omitempty"`
    Address string                      `xml:"address,attr,omitempty"`
    Type    string                      `xml:"type,attr,omitempty"`
    Path    string                      `xml:"path,attr,omitempty"`
    Mode    string                      `xml:"mode,attr,omitempty"`
    Port    uint                        `xml:"port,attr,omitempty"`
    Service string                      `xml:"service,attr,omitempty"`
    Host    string                      `xml:"host,attr,omitempty"`
    Local   *DomainInterfaceSourceLocal `xml:"local"`
}

type DomainInterfaceSourceLocal Uses

type DomainInterfaceSourceLocal struct {
    Address string `xml:"address,attr,omitempty"`
    Port    uint   `xml:"port,attr,omitempty"`
}

type DomainInterfaceTarget Uses

type DomainInterfaceTarget struct {
    Dev string `xml:"dev,attr"`
}

type DomainInterfaceVirtualport Uses

type DomainInterfaceVirtualport struct {
    Type string `xml:"type,attr"`
}

type DomainLoader Uses

type DomainLoader struct {
    Path     string `xml:",chardata"`
    Readonly string `xml:"readonly,attr"`
    Secure   string `xml:"secure,attr"`
    Type     string `xml:"type,attr"`
}

type DomainMaxMemory Uses

type DomainMaxMemory struct {
    Value uint   `xml:",chardata"`
    Unit  string `xml:"unit,attr,omitempty"`
    Slots uint   `xml:"slots,attr,omitempty"`
}

type DomainMemBalloon Uses

type DomainMemBalloon struct {
    XMLName xml.Name       `xml:"memballoon"`
    Model   string         `xml:"model,attr"`
    Address *DomainAddress `xml:"address"`
}

func (*DomainMemBalloon) Marshal Uses

func (d *DomainMemBalloon) Marshal() (string, error)

func (*DomainMemBalloon) Unmarshal Uses

func (d *DomainMemBalloon) Unmarshal(doc string) error

type DomainMemory Uses

type DomainMemory struct {
    Value uint   `xml:",chardata"`
    Unit  string `xml:"unit,attr,omitempty"`
}

type DomainMemoryAccess Uses

type DomainMemoryAccess struct {
    Mode string `xml:"mode,attr,omitempty"`
}

type DomainMemoryAllocation Uses

type DomainMemoryAllocation struct {
    Mode string `xml:"mode,attr,omitempty"`
}

type DomainMemoryBacking Uses

type DomainMemoryBacking struct {
    MemoryHugePages    *DomainMemoryHugepages    `xml:"hugepages"`
    MemoryNosharepages *DomainMemoryNosharepages `xml:"nosharepages"`
    MemoryLocked       *DomainMemoryLocked       `xml:"locked"`
    MemorySource       *DomainMemorySource       `xml:"source"`
    MemoryAccess       *DomainMemoryAccess       `xml:"access"`
    MemoryAllocation   *DomainMemoryAllocation   `xml:"allocation"`
}

type DomainMemoryHugepage Uses

type DomainMemoryHugepage struct {
    Size    uint   `xml:"size,attr"`
    Unit    string `xml:"unit,attr,omitempty"`
    Nodeset string `xml:"nodeset,attr,omitempty"`
}

type DomainMemoryHugepages Uses

type DomainMemoryHugepages struct {
    Hugepages []DomainMemoryHugepage `xml:"page"`
}

type DomainMemoryLocked Uses

type DomainMemoryLocked struct {
}

type DomainMemoryNosharepages Uses

type DomainMemoryNosharepages struct {
}

type DomainMemorySource Uses

type DomainMemorySource struct {
    Type string `xml:"type,attr,omitempty"`
}

type DomainMemorydev Uses

type DomainMemorydev struct {
    XMLName xml.Name               `xml:"memory"`
    Model   string                 `xml:"model,attr"`
    Access  string                 `xml:"access,attr"`
    Target  *DomainMemorydevTarget `xml:"target"`
    Address *DomainAddress         `xml:"address"`
}

func (*DomainMemorydev) Marshal Uses

func (d *DomainMemorydev) Marshal() (string, error)

func (*DomainMemorydev) Unmarshal Uses

func (d *DomainMemorydev) Unmarshal(doc string) error

type DomainMemorydevTarget Uses

type DomainMemorydevTarget struct {
    Size *DomainMemory              `xml:"size"`
    Node *DomainMemorydevTargetNode `xml:"node"`
}

type DomainMemorydevTargetNode Uses

type DomainMemorydevTargetNode struct {
    Value uint `xml:",chardata"`
}

type DomainNVRam Uses

type DomainNVRam struct {
    NVRam    string `xml:",chardata"`
    Template string `xml:"template,attr"`
}

type DomainNuma Uses

type DomainNuma struct {
    Cell []DomainCell `xml:"cell"`
}

type DomainOS Uses

type DomainOS struct {
    Type        *DomainOSType      `xml:"type"`
    Loader      *DomainLoader      `xml:"loader"`
    NVRam       *DomainNVRam       `xml:"nvram"`
    Kernel      string             `xml:"kernel,omitempty"`
    Initrd      string             `xml:"initrd,omitempty"`
    KernelArgs  string             `xml:"cmdline,omitempty"`
    BootDevices []DomainBootDevice `xml:"boot"`
    BootMenu    *DomainBootMenu    `xml:"bootmenu"`
    SMBios      *DomainSMBios      `xml:"smbios"`
    BIOS        *DomainBIOS        `xml:"bios"`
    Init        string             `xml:"init,omitempty"`
    InitArgs    []string           `xml:"initarg"`
}

type DomainOSType Uses

type DomainOSType struct {
    Arch    string `xml:"arch,attr,omitempty"`
    Machine string `xml:"machine,attr,omitempty"`
    Type    string `xml:",chardata"`
}

type DomainPanic Uses

type DomainPanic struct {
    XMLName xml.Name       `xml:"panic"`
    Model   string         `xml:"model,attr"`
    Address *DomainAddress `xml:"address"`
}

type DomainQEMUCommandline Uses

type DomainQEMUCommandline struct {
    XMLName xml.Name                   `xml:"http://libvirt.org/schemas/domain/qemu/1.0 commandline"`
    Args    []DomainQEMUCommandlineArg `xml:"arg"`
    Envs    []DomainQEMUCommandlineEnv `xml:"env"`
}

type DomainQEMUCommandlineArg Uses

type DomainQEMUCommandlineArg struct {
    Value string `xml:"value,attr"`
}

type DomainQEMUCommandlineEnv Uses

type DomainQEMUCommandlineEnv struct {
    Name  string `xml:"name,attr"`
    Value string `xml:"value,attr,omitempty"`
}

type DomainRNG Uses

type DomainRNG struct {
    XMLName xml.Name          `xml:"rng"`
    Model   string            `xml:"model,attr"`
    Rate    *DomainRNGRate    `xml:"rate"`
    Backend *DomainRNGBackend `xml:"backend"`
}

func (*DomainRNG) Marshal Uses

func (d *DomainRNG) Marshal() (string, error)

func (*DomainRNG) Unmarshal Uses

func (d *DomainRNG) Unmarshal(doc string) error

type DomainRNGBackend Uses

type DomainRNGBackend struct {
    Device  string                  `xml:",chardata"`
    Model   string                  `xml:"model,attr"`
    Type    string                  `xml:"type,attr,omitempty"`
    Sources []DomainInterfaceSource `xml:"source"`
}

type DomainRNGRate Uses

type DomainRNGRate struct {
    Bytes  uint `xml:"bytes,attr"`
    Period uint `xml:"period,attr,omitempty"`
}

type DomainResource Uses

type DomainResource struct {
    Partition string `xml:"partition,omitempty"`
}

type DomainSMBios Uses

type DomainSMBios struct {
    Mode string `xml:"mode,attr"`
}

type DomainSerial Uses

type DomainSerial struct {
    XMLName  xml.Name              `xml:"serial"`
    Type     string                `xml:"type,attr"`
    Source   *DomainChardevSource  `xml:"source"`
    Protocol *DomainSerialProtocol `xml:"protocol"`
    Target   *DomainSerialTarget   `xml:"target"`
    Alias    *DomainAlias          `xml:"alias"`
    Address  *DomainAddress        `xml:"address"`
}

func (*DomainSerial) Marshal Uses

func (d *DomainSerial) Marshal() (string, error)

func (*DomainSerial) Unmarshal Uses

func (d *DomainSerial) Unmarshal(doc string) error

type DomainSerialProtocol Uses

type DomainSerialProtocol struct {
    Type string `xml:"type,attr"`
}

type DomainSerialTarget Uses

type DomainSerialTarget struct {
    Type string `xml:"type,attr,omitempty"`
    Port *uint  `xml:"port,attr"`
}

type DomainSnapshot Uses

type DomainSnapshot struct {
    XMLName      xml.Name              `xml:"domainsnapshot"`
    Name         string                `xml:"name,omitempty"`
    Description  string                `xml:"description,omitempty"`
    State        string                `xml:"state,omitempty"`
    CreationTime string                `xml:"creationTime,omitempty"`
    Parent       *DomainSnapshotParent `xml:"parent"`
    Memory       *DomainSnapshotMemory `xml:"memory"`
    Disks        *DomainSnapshotDisks  `xml:"disks"`
    Domain       *Domain               `xml:"domain"`
}

func (*DomainSnapshot) Marshal Uses

func (s *DomainSnapshot) Marshal() (string, error)

func (*DomainSnapshot) Unmarshal Uses

func (s *DomainSnapshot) Unmarshal(doc string) error

type DomainSnapshotDisk Uses

type DomainSnapshotDisk struct {
    Name     string                    `xml:"name,attr"`
    Snapshot string                    `xml:"snapshot,attr,omitempty"`
    Driver   *DomainSnapshotDiskDriver `xml:"driver"`
    Source   *DomainSnapshotDiskSource `xml:"source"`
}

type DomainSnapshotDiskDriver Uses

type DomainSnapshotDiskDriver struct {
    Type string `xml:"type,attr"`
}

type DomainSnapshotDiskSource Uses

type DomainSnapshotDiskSource struct {
    File string `xml:"file,attr"`
}

type DomainSnapshotDisks Uses

type DomainSnapshotDisks struct {
    Disks []DomainSnapshotDisk `xml:"disk"`
}

type DomainSnapshotMemory Uses

type DomainSnapshotMemory struct {
    Snapshot string `xml:"snapshot,attr"`
}

type DomainSnapshotParent Uses

type DomainSnapshotParent struct {
    Name string `xml:"name"`
}

type DomainSound Uses

type DomainSound struct {
    XMLName xml.Name          `xml:"sound"`
    Model   string            `xml:"model,attr"`
    Codec   *DomainSoundCodec `xml:"codec"`
    Address *DomainAddress    `xml:"address"`
}

func (*DomainSound) Marshal Uses

func (d *DomainSound) Marshal() (string, error)

func (*DomainSound) Unmarshal Uses

func (d *DomainSound) Unmarshal(doc string) error

type DomainSoundCodec Uses

type DomainSoundCodec struct {
    Type string `xml:"type,attr"`
}

type DomainSysInfo Uses

type DomainSysInfo struct {
    Type      string               `xml:"type,attr"`
    System    []DomainSysInfoEntry `xml:"system>entry"`
    BIOS      []DomainSysInfoEntry `xml:"bios>entry"`
    BaseBoard []DomainSysInfoEntry `xml:"baseBoard>entry"`
}

type DomainSysInfoEntry Uses

type DomainSysInfoEntry struct {
    Name  string `xml:"name,attr"`
    Value string `xml:",chardata"`
}

type DomainTimer Uses

type DomainTimer struct {
    Name       string              `xml:"name,attr"`
    Track      string              `xml:"track,attr,omitempty"`
    TickPolicy string              `xml:"tickpolicy,attr,omitempty"`
    CatchUp    *DomainTimerCatchUp `xml:"catchup,omitempty"`
    Frequency  uint32              `xml:"frequency,attr,omitempty"`
    Mode       string              `xml:"mode,attr,omitempty"`
    Present    string              `xml:"present,attr,omitempty"`
}

type DomainTimerCatchUp Uses

type DomainTimerCatchUp struct {
    Threshold uint `xml:"threshold,attr,omitempty"`
    Slew      uint `xml:"slew,attr,omitempty"`
    Limit     uint `xml:"limit,attr,omitempty"`
}

type DomainVCPU Uses

type DomainVCPU struct {
    Placement string `xml:"placement,attr,omitempty"`
    CPUSet    string `xml:"cpuset,attr,omitempty"`
    Current   string `xml:"current,attr,omitempty"`
    Value     int    `xml:",chardata"`
}

type DomainVCPUs Uses

type DomainVCPUs struct {
    VCPU []DomainVCPUsVCPU `xml:"vcpu"`
}

type DomainVCPUsVCPU Uses

type DomainVCPUsVCPU struct {
    Id           *uint  `xml:"id,attr,omitempty"`
    Enabled      string `xml:"enabled,attr,omitempty"`
    Hotpluggable string `xml:"hotpluggable,attr,omitempty"`
    Order        *uint  `xml:"order,attr,omitempty"`
}

type DomainVideo Uses

type DomainVideo struct {
    XMLName xml.Name         `xml:"video"`
    Model   DomainVideoModel `xml:"model"`
    Address *DomainAddress   `xml:"address"`
}

func (*DomainVideo) Marshal Uses

func (d *DomainVideo) Marshal() (string, error)

func (*DomainVideo) Unmarshal Uses

func (d *DomainVideo) Unmarshal(doc string) error

type DomainVideoModel Uses

type DomainVideoModel struct {
    Type   string `xml:"type,attr"`
    Heads  uint   `xml:"heads,attr,omitempty"`
    Ram    uint   `xml:"ram,attr,omitempty"`
    VRam   uint   `xml:"vram,attr,omitempty"`
    VGAMem uint   `xml:"vgamem,attr,omitempty"`
}

type Network Uses

type Network struct {
    XMLName             xml.Name        `xml:"network"`
    IPv6                string          `xml:"ipv6,attr,omitempty"`
    TrustGuestRxFilters string          `xml:"trustGuestRxFilters,attr,omitempty"`
    Name                string          `xml:"name,omitempty"`
    UUID                string          `xml:"uuid,omitempty"`
    MAC                 *NetworkMAC     `xml:"mac"`
    Bridge              *NetworkBridge  `xml:"bridge"`
    VirtualPort         *VirtualPort    `xml:"virtualport"`
    Forward             *NetworkForward `xml:"forward"`
    Domain              *NetworkDomain  `xml:"domain"`
    IPs                 []NetworkIP     `xml:"ip"`
    Routes              []NetworkRoute  `xml:"route"`
    DNS                 *NetworkDNS     `xml:"dns"`
}

func (*Network) Marshal Uses

func (s *Network) Marshal() (string, error)

func (*Network) Unmarshal Uses

func (s *Network) Unmarshal(doc string) error

type NetworkBootp Uses

type NetworkBootp struct {
    File   string `xml:"file,attr,omitempty"`
    Server string `xml:"server,attr,omitempty"`
}

type NetworkBridge Uses

type NetworkBridge struct {
    Name            string `xml:"name,attr,omitempty"`
    STP             string `xml:"stp,attr,omitempty"`
    Delay           string `xml:"delay,attr,omitempty"`
    MACTableManager string `xml:"macTableManager,attr,omitempty"`
}

type NetworkDHCP Uses

type NetworkDHCP struct {
    Ranges []NetworkDHCPRange `xml:"range"`
    Hosts  []NetworkDHCPHost  `xml:"host"`
    Bootp  []NetworkBootp     `xml:"bootp"`
}

type NetworkDHCPHost Uses

type NetworkDHCPHost struct {
    ID   string `xml:"id,attr,omitempty"`
    MAC  string `xml:"mac,attr,omitempty"`
    Name string `xml:"name,attr,omitempty"`
    IP   string `xml:"ip,attr,omitempty"`
}

type NetworkDHCPRange Uses

type NetworkDHCPRange struct {
    Start string `xml:"start,attr,omitempty"`
    End   string `xml:"end,attr,omitempty"`
}

type NetworkDNS Uses

type NetworkDNS struct {
    Enable            string                `xml:"enable,attr,omitempty"`
    ForwardPlainNames string                `xml:"forwardPlainNames,attr,omitempty"`
    Forwarders        []NetworkDNSForwarder `xml:"forwarder"`
    TXTs              []NetworkDNSTXT       `xml:"txt"`
    Host              *NetworkDNSHost       `xml:"host"`
    SRVs              []NetworkDNSSRV       `xml:"srv"`
}

type NetworkDNSForwarder Uses

type NetworkDNSForwarder struct {
    Domain string `xml:"domain,attr,omitempty"`
    Addr   string `xml:"addr,attr,omitempty"`
}

type NetworkDNSHost Uses

type NetworkDNSHost struct {
    IP        string                   `xml:"ip,attr"`
    Hostnames []NetworkDNSHostHostname `xml:"hostname"`
}

type NetworkDNSHostHostname Uses

type NetworkDNSHostHostname struct {
    Hostname string `xml:",chardata"`
}

type NetworkDNSSRV Uses

type NetworkDNSSRV struct {
    Service  string `xml:"service,attr"`
    Protocol string `xml:"protocol,attr"`
    Target   string `xml:"target,attr,omitempty"`
    Port     uint   `xml:"port,attr,omitempty"`
    Priority uint   `xml:"priority,attr,omitempty"`
    Weight   uint   `xml:"weight,attr,omitempty"`
    Domain   string `xml:"domain,attr,omitempty"`
}

type NetworkDNSTXT Uses

type NetworkDNSTXT struct {
    Name  string `xml:"name,attr"`
    Value string `xml:"value,attr"`
}

type NetworkDomain Uses

type NetworkDomain struct {
    Name      string `xml:"name,attr,omitempty"`
    LocalOnly string `xml:"localOnly,attr,omitempty"`
}

type NetworkForward Uses

type NetworkForward struct {
    Mode string             `xml:"mode,attr,omitempty"`
    Dev  string             `xml:"dev,attr,omitempty"`
    NAT  *NetworkForwardNAT `xml:"nat"`
}

type NetworkForwardNAT Uses

type NetworkForwardNAT struct {
    Addresses []NetworkForwardNATAddress `xml:"address"`
    Ports     []NetworkForwardNATPort    `xml:"port"`
}

type NetworkForwardNATAddress Uses

type NetworkForwardNATAddress struct {
    Start string `xml:"start,attr"`
    End   string `xml:"end,attr"`
}

type NetworkForwardNATPort Uses

type NetworkForwardNATPort struct {
    Start uint `xml:"start,attr"`
    End   uint `xml:"end,attr"`
}

type NetworkIP Uses

type NetworkIP struct {
    Address  string       `xml:"address,attr,omitempty"`
    Family   string       `xml:"family,attr,omitempty"`
    Netmask  string       `xml:"netmask,attr,omitempty"`
    Prefix   string       `xml:"prefix,attr,omitempty"`
    LocalPtr string       `xml:"localPtr,attr,omitempty"`
    DHCP     *NetworkDHCP `xml:"dhcp"`
}

type NetworkMAC Uses

type NetworkMAC struct {
    Address string `xml:"address,attr,omitempty"`
}

type NetworkRoute Uses

type NetworkRoute struct {
    Address string `xml:"address,attr,omitempty"`
    Family  string `xml:"family,attr,omitempty"`
    Prefix  string `xml:"prefix,attr,omitempty"`
    Metric  string `xml:"metric,attr,omitempty"`
    Gateway string `xml:"gateway,attr,omitempty"`
}

type NodeDevice Uses

type NodeDevice struct {
    XMLName    xml.Name             `xml:"device"`
    Name       string               `xml:"name"`
    Path       string               `xml:"path,omitempty"`
    Parent     string               `xml:"parent,omitempty"`
    Driver     string               `xml:"driver>name,omitempty"`
    Capability NodeDeviceCapability `xml:"capability"`
}

func (*NodeDevice) Marshal Uses

func (c *NodeDevice) Marshal() (string, error)

func (*NodeDevice) Unmarshal Uses

func (c *NodeDevice) Unmarshal(doc string) error

type NodeDeviceCapability Uses

type NodeDeviceCapability struct {
    System    *NodeDeviceSystemCapability
    PCI       *NodeDevicePCICapability
    USB       *NodeDeviceUSBCapability
    USBDevice *NodeDeviceUSBDeviceCapability
    Net       *NodeDeviceNetCapability
    SCSIHost  *NodeDeviceSCSIHostCapability
    SCSI      *NodeDeviceSCSICapability
    Storage   *NodeDeviceStorageCapability
    DRM       *NodeDeviceDRMCapability
}

func (*NodeDeviceCapability) MarshalXML Uses

func (c *NodeDeviceCapability) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*NodeDeviceCapability) UnmarshalXML Uses

func (c *NodeDeviceCapability) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type NodeDeviceDRMCapability Uses

type NodeDeviceDRMCapability struct {
    Type string `xml:"type"`
}

type NodeDeviceIDName Uses

type NodeDeviceIDName struct {
    ID   string `xml:"id,attr"`
    Name string `xml:",chardata"`
}

type NodeDeviceIOMMUGroup Uses

type NodeDeviceIOMMUGroup struct {
    Number int `xml:"number,attr"`
}

type NodeDeviceNUMA Uses

type NodeDeviceNUMA struct {
    Node int `xml:"node,attr"`
}

type NodeDeviceNetCapability Uses

type NodeDeviceNetCapability struct {
    Interface  string                         `xml:"interface"`
    Address    string                         `xml:"address"`
    Link       *NodeDeviceNetLink             `xml:"link"`
    Features   []NodeDeviceNetOffloadFeatures `xml:"feature,omitempty"`
    Capability *NodeDeviceNetSubCapability    `xml:"capability"`
}
type NodeDeviceNetLink struct {
    State string `xml:"state,attr"`
    Speed string `xml:"speed,attr,omitempty"`
}

type NodeDeviceNetOffloadFeatures Uses

type NodeDeviceNetOffloadFeatures struct {
    Name string `xml:"number"`
}

type NodeDeviceNetSubCapability Uses

type NodeDeviceNetSubCapability struct {
    Type string `xml:"type,attr"`
}

type NodeDevicePCIAddress Uses

type NodeDevicePCIAddress struct {
    Domain   string `xml:"domain,attr"`
    Bus      string `xml:"bus,attr"`
    Slot     string `xml:"slot,attr"`
    Function string `xml:"function,attr"`
}

type NodeDevicePCICapability Uses

type NodeDevicePCICapability struct {
    Domain       int                          `xml:"domain,omitempty"`
    Bus          int                          `xml:"bus,omitempty"`
    Slot         int                          `xml:"slot,omitempty"`
    Function     int                          `xml:"function,omitempty"`
    Product      NodeDeviceIDName             `xml:"product,omitempty"`
    Vendor       NodeDeviceIDName             `xml:"vendor,omitempty"`
    IOMMUGroup   *NodeDeviceIOMMUGroup        `xml:"iommuGroup"`
    NUMA         *NodeDeviceNUMA              `xml:"numa"`
    PCIExpress   *NodeDevicePCIExpress        `xml:"pci-express"`
    Capabilities []NodeDevicePCISubCapability `xml:"capability,omitempty"`
}

type NodeDevicePCIExpress Uses

type NodeDevicePCIExpress struct {
    Links []NodeDevicePCIExpressLink `xml:"link"`
}
type NodeDevicePCIExpressLink struct {
    Validity string  `xml:"validity,attr,omitempty"`
    Speed    float64 `xml:"speed,attr,omitempty"`
    Port     int     `xml:"port,attr,omitempty"`
    Width    int     `xml:"width,attr,omitempty"`
}

type NodeDevicePCISubCapability Uses

type NodeDevicePCISubCapability struct {
    Type     string                 `xml:"type,attr"`
    Address  []NodeDevicePCIAddress `xml:"address,omitempty"`
    MaxCount int                    `xml:"maxCount,attr,omitempty"`
}

type NodeDeviceSCSICapability Uses

type NodeDeviceSCSICapability struct {
    Host   int    `xml:"host"`
    Bus    int    `xml:"bus"`
    Target int    `xml:"target"`
    Lun    int    `xml:"lun"`
    Type   string `xml:"type"`
}

type NodeDeviceSCSIFCHost Uses

type NodeDeviceSCSIFCHost struct {
    WWNN      string `xml:"wwnn,omitempty"`
    WWPN      string `xml:"wwpn,omitempty"`
    FabricWWN string `xml:"fabric_wwn,omitempty"`
}

type NodeDeviceSCSIHostCapability Uses

type NodeDeviceSCSIHostCapability struct {
    Host       int                              `xml:"host"`
    UniqueID   int                              `xml:"unique_id"`
    Capability *NodeDeviceSCSIHostSubCapability `xml:"capability"`
}

type NodeDeviceSCSIHostSubCapability Uses

type NodeDeviceSCSIHostSubCapability struct {
    VportsOPS *NodeDeviceSCSIVportsOPS `xml:"vports_ops"`
    FCHost    *NodeDeviceSCSIFCHost    `xml:"fc_host"`
}

type NodeDeviceSCSIVportsOPS Uses

type NodeDeviceSCSIVportsOPS struct {
    Vports    int `xml:"vports,omitempty"`
    MaxVports int `xml:"maxvports,,omitempty"`
}

type NodeDeviceStorageCapability Uses

type NodeDeviceStorageCapability struct {
    Block        string                          `xml:"block"`
    Bus          string                          `xml:"bus"`
    DriverType   string                          `xml:"drive_type"`
    Model        string                          `xml:"model"`
    Vendor       string                          `xml:"vendor"`
    Serial       string                          `xml:"serial"`
    Size         int                             `xml:"size"`
    Capatibility *NodeDeviceStorageSubCapability `xml:"capability,omitempty"`
}

type NodeDeviceStorageSubCapability Uses

type NodeDeviceStorageSubCapability struct {
    Type           string `xml:"match,attr"`
    MediaAvailable int    `xml:"media_available,omitempty"`
    MediaSize      int    `xml:"media_size,omitempty"`
    MediaLable     int    `xml:"media_label,omitempty"`
}

type NodeDeviceSystemCapability Uses

type NodeDeviceSystemCapability struct {
    Product  string                    `xml:"product"`
    Hardware *NodeDeviceSystemHardware `xml:"hardware"`
    Firmware *NodeDeviceSystemFirmware `xml:"firmware"`
}

type NodeDeviceSystemFirmware Uses

type NodeDeviceSystemFirmware struct {
    Vendor      string `xml:"vendor"`
    Version     string `xml:"version"`
    ReleaseData string `xml:"release_date"`
}

type NodeDeviceSystemHardware Uses

type NodeDeviceSystemHardware struct {
    Vendor  string `xml:"vendor"`
    Version string `xml:"version"`
    Serial  string `xml:"serial"`
    UUID    string `xml:"uuid"`
}

type NodeDeviceUSBCapability Uses

type NodeDeviceUSBCapability struct {
    Number      int    `xml:"number"`
    Class       int    `xml:"class"`
    Subclass    int    `xml:"subclass"`
    Protocol    int    `xml:"protocol"`
    Description string `xml:"description,omitempty"`
}

type NodeDeviceUSBDeviceCapability Uses

type NodeDeviceUSBDeviceCapability struct {
    Bus     int              `xml:"bus"`
    Device  int              `xml:"device"`
    Product NodeDeviceIDName `xml:"product,omitempty"`
    Vendor  NodeDeviceIDName `xml:"vendor,omitempty"`
}

type Secret Uses

type Secret struct {
    XMLName     xml.Name     `xml:"secret"`
    Ephemeral   string       `xml:"ephemeral,attr,omitempty"`
    Private     string       `xml:"private,attr,omitempty"`
    Description string       `xml:"description,omitempty"`
    UUID        string       `xml:"uuid,omitempty"`
    Usage       *SecretUsage `xml:"usage"`
}

func (*Secret) Marshal Uses

func (s *Secret) Marshal() (string, error)

func (*Secret) Unmarshal Uses

func (s *Secret) Unmarshal(doc string) error

type SecretUsage Uses

type SecretUsage struct {
    Type   string `xml:"type,attr"`
    Volume string `xml:"volume,omitempty"`
    Name   string `xml:"name,omitempty"`
    Target string `xml:"target,omitempty"`
}

type StorageEncryption Uses

type StorageEncryption struct {
    Format string                   `xml:"format,attr"`
    Secret *StorageEncryptionSecret `xml:"secret"`
    Cipher *StorageEncryptionCipher `xml:"cipher"`
    Ivgen  *StorageEncryptionIvgen  `xml:"ivgen"`
}

type StorageEncryptionCipher Uses

type StorageEncryptionCipher struct {
    Name string `xml:"name,attr"`
    Size uint64 `xml:"size,attr"`
    Mode string `xml:"mode,attr"`
    Hash string `xml:"hash,attr"`
}

type StorageEncryptionIvgen Uses

type StorageEncryptionIvgen struct {
    Name string `xml:"name,attr"`
    Hash string `xml:"hash,attr"`
}

type StorageEncryptionSecret Uses

type StorageEncryptionSecret struct {
    Type string `xml:"type,attr"`
    UUID string `xml:"uuid,attr"`
}

type StoragePool Uses

type StoragePool struct {
    XMLName    xml.Name           `xml:"pool"`
    Type       string             `xml:"type,attr"`
    Name       string             `xml:"name"`
    UUID       string             `xml:"uuid,omitempty"`
    Allocation *StoragePoolSize   `xml:"allocation,omitempty"`
    Capacity   *StoragePoolSize   `xml:"capacity,omitempty"`
    Available  *StoragePoolSize   `xml:"available,omitempty"`
    Target     *StoragePoolTarget `xml:"target"`
    Source     *StoragePoolSource `xml:"source"`
}

func (*StoragePool) Marshal Uses

func (s *StoragePool) Marshal() (string, error)

func (*StoragePool) Unmarshal Uses

func (s *StoragePool) Unmarshal(doc string) error

type StoragePoolSize Uses

type StoragePoolSize struct {
    Unit  string `xml:"unit,attr,omitempty"`
    Value uint64 `xml:",chardata"`
}

type StoragePoolSource Uses

type StoragePoolSource struct {
    Host    *StoragePoolSourceHost    `xml:"host"`
    Device  *StoragePoolSourceDevice  `xml:"device"`
    Auth    *StoragePoolSourceAuth    `xml:"auth"`
    Vendor  *StoragePoolSourceVendor  `xml:"vendor"`
    Product *StoragePoolSourceProduct `xml:"product"`
    Format  *StoragePoolSourceFormat  `xml:"format"`
    Adapter *StoragePoolSourceAdapter `xml:"adapter"`
}

type StoragePoolSourceAdapter Uses

type StoragePoolSourceAdapter struct {
    Type       string                              `xml:"type,attr"`
    Name       string                              `xml:"name,attr,omitempty"`
    Parent     string                              `xml:"parent,attr,omitempty"`
    WWNN       string                              `xml:"wwnn,attr,omitempty"`
    WWPN       string                              `xml:"wwpn,attr,omitempty"`
    ParentAddr *StoragePoolSourceAdapterParentAddr `xml:"parentaddr"`
}

type StoragePoolSourceAdapterParentAddr Uses

type StoragePoolSourceAdapterParentAddr struct {
    UniqueID uint64                                     `xml:"unique_id,attr"`
    Address  *StoragePoolSourceAdapterParentAddrAddress `xml:"address"`
}

type StoragePoolSourceAdapterParentAddrAddress Uses

type StoragePoolSourceAdapterParentAddrAddress struct {
    Domain string `xml:"domain,attr"`
    Bus    string `xml:"bus,attr"`
    Slot   string `xml:"slot,attr"`
    Addr   string `xml:"addr,attr"`
}

type StoragePoolSourceAuth Uses

type StoragePoolSourceAuth struct {
    Type     string                       `xml:"type,attr"`
    Username string                       `xml:"username,attr"`
    Secret   *StoragePoolSourceAuthSecret `xml:"secret"`
}

type StoragePoolSourceAuthSecret Uses

type StoragePoolSourceAuthSecret struct {
    Usage string `xml:"usage,attr"`
}

type StoragePoolSourceDevice Uses

type StoragePoolSourceDevice struct {
    Path          string `xml:"path,attr"`
    PartSeparator string `xml:"part_separator,attr,omitempty"`
}

type StoragePoolSourceFormat Uses

type StoragePoolSourceFormat struct {
    Type string `xml:"type,attr"`
}

type StoragePoolSourceHost Uses

type StoragePoolSourceHost struct {
    Name string `xml:"name,attr"`
}

type StoragePoolSourceProduct Uses

type StoragePoolSourceProduct struct {
    Name string `xml:"name,attr"`
}

type StoragePoolSourceVendor Uses

type StoragePoolSourceVendor struct {
    Name string `xml:"name,attr"`
}

type StoragePoolTarget Uses

type StoragePoolTarget struct {
    Path        string                        `xml:"path,omitempty"`
    Permissions *StoragePoolTargetPermissions `xml:"permissions"`
    Timestamps  *StoragePoolTargetTimestamps  `xml:"timestamps"`
    Encryption  *StorageEncryption            `xml:"encryption"`
}

type StoragePoolTargetPermissions Uses

type StoragePoolTargetPermissions struct {
    Owner string `xml:"owner,omitempty"`
    Group string `xml:"group,omitempty"`
    Mode  string `xml:"mode,omitempty"`
    Label string `xml:"label,omitempty"`
}

type StoragePoolTargetTimestamps Uses

type StoragePoolTargetTimestamps struct {
    Atime string `xml:"atime"`
    Mtime string `xml:"mtime"`
    Ctime string `xml:"ctime"`
}

type StorageVolume Uses

type StorageVolume struct {
    XMLName      xml.Name                   `xml:"volume"`
    Type         string                     `xml:"type,attr,omitempty"`
    Name         string                     `xml:"name"`
    Key          string                     `xml:"key,omitempty"`
    Allocation   *StorageVolumeSize         `xml:"allocation"`
    Capacity     *StorageVolumeSize         `xml:"capacity"`
    Physical     *StorageVolumeSize         `xml:"physical"`
    Target       *StorageVolumeTarget       `xml:"target"`
    BackingStore *StorageVolumeBackingStore `xml:"backingStore"`
}

func (*StorageVolume) Marshal Uses

func (s *StorageVolume) Marshal() (string, error)

func (*StorageVolume) Unmarshal Uses

func (s *StorageVolume) Unmarshal(doc string) error

type StorageVolumeBackingStore Uses

type StorageVolumeBackingStore struct {
    Path        string                          `xml:"path"`
    Format      *StorageVolumeTargetFormat      `xml:"format"`
    Permissions *StorageVolumeTargetPermissions `xml:"permissions"`
}

type StorageVolumeSize Uses

type StorageVolumeSize struct {
    Unit  string `xml:"unit,attr,omitempty"`
    Value uint64 `xml:",chardata"`
}

type StorageVolumeTarget Uses

type StorageVolumeTarget struct {
    Path        string                          `xml:"path,omitempty"`
    Format      *StorageVolumeTargetFormat      `xml:"format"`
    Permissions *StorageVolumeTargetPermissions `xml:"permissions"`
    Timestamps  *StorageVolumeTargetTimestamps  `xml:"timestamps"`
    Compat      string                          `xml:"compat,omitempty"`
    NoCOW       *struct{}                       `xml:"nocow"`
    Features    []StorageVolumeTargetFeature    `xml:"features"`
    Encryption  *StorageEncryption              `xml:"encryption"`
}

type StorageVolumeTargetFeature Uses

type StorageVolumeTargetFeature struct {
    LazyRefcounts *struct{} `xml:"lazy_refcounts"`
}

type StorageVolumeTargetFormat Uses

type StorageVolumeTargetFormat struct {
    Type string `xml:"type,attr"`
}

type StorageVolumeTargetPermissions Uses

type StorageVolumeTargetPermissions struct {
    Owner string `xml:"owner,omitempty"`
    Group string `xml:"group,omitempty"`
    Mode  string `xml:"mode,omitempty"`
    Label string `xml:"label,omitempty"`
}

type StorageVolumeTargetTimestamps Uses

type StorageVolumeTargetTimestamps struct {
    Atime string `xml:"atime"`
    Mtime string `xml:"mtime"`
    Ctime string `xml:"ctime"`
}

type VirtualPort Uses

type VirtualPort struct {
    Type       string                  `xml:"type,attr,omitempty"`
    Parameters []VirtualPortParameters `xml:"parameters,omitempty"`
}

type VirtualPortParameters Uses

type VirtualPortParameters struct {
    InterfaceID string `xml:"interfaceid,attr,omitempty"`
    ProfileID   string `xml:"profileid,attr,omitempty"`
}

Package libvirtxml imports 3 packages (graph) and is imported by 4 packages. Updated 2017-11-18. Refresh now. Tools for package owners.