MCPcopy Create free account
hub / github.com/digitalocean/go-libvirt / DomainCreateWithFiles

Method DomainCreateWithFiles

remote_protocol.gen.go:13717–13748  ·  view source on GitHub ↗

DomainCreateWithFiles is the go wrapper for REMOTE_PROC_DOMAIN_CREATE_WITH_FILES.

(Dom Domain, Flags DomainCreateFlags)

Source from the content-addressed store, hash-verified

13715
13716// DomainCreateWithFiles is the go wrapper for REMOTE_PROC_DOMAIN_CREATE_WITH_FILES.
13717func (l *Libvirt) DomainCreateWithFiles(Dom Domain, Flags DomainCreateFlags) (rDom Domain, err error) {
13718 var buf []byte
13719
13720 args := DomainCreateWithFilesArgs {
13721 Dom: Dom,
13722 Flags: Flags,
13723 }
13724
13725 buf, err = encode(&args)
13726 if err != nil {
13727 return
13728 }
13729
13730 var r response
13731 r, err = l.requestStream(310, constants.Program, buf, nil, nil)
13732 if err != nil {
13733 return
13734 }
13735
13736 // Return value unmarshaling
13737 tpd := typedParamDecoder{}
13738 ct := map[string]xdr.TypeDecoder{"libvirt.TypedParam": tpd}
13739 rdr := bytes.NewReader(r.Payload)
13740 dec := xdr.NewDecoderCustomTypes(rdr, 0, ct)
13741 // Dom: Domain
13742 _, err = dec.Decode(&rDom)
13743 if err != nil {
13744 return
13745 }
13746
13747 return
13748}
13749
13750// DomainEventDeviceRemoved is the go wrapper for REMOTE_PROC_DOMAIN_EVENT_DEVICE_REMOVED.
13751func (l *Libvirt) DomainEventDeviceRemoved() (err error) {

Callers

nothing calls this directly

Calls 3

requestStreamMethod · 0.95
encodeFunction · 0.85
DecodeMethod · 0.65

Tested by

no test coverage detected