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

Method NodeGetMemoryParameters

remote_protocol.gen.go:13059–13095  ·  view source on GitHub ↗

NodeGetMemoryParameters is the go wrapper for REMOTE_PROC_NODE_GET_MEMORY_PARAMETERS.

(Nparams int32, Flags uint32)

Source from the content-addressed store, hash-verified

13057
13058// NodeGetMemoryParameters is the go wrapper for REMOTE_PROC_NODE_GET_MEMORY_PARAMETERS.
13059func (l *Libvirt) NodeGetMemoryParameters(Nparams int32, Flags uint32) (rParams []TypedParam, rNparams int32, err error) {
13060 var buf []byte
13061
13062 args := NodeGetMemoryParametersArgs {
13063 Nparams: Nparams,
13064 Flags: Flags,
13065 }
13066
13067 buf, err = encode(&args)
13068 if err != nil {
13069 return
13070 }
13071
13072 var r response
13073 r, err = l.requestStream(289, constants.Program, buf, nil, nil)
13074 if err != nil {
13075 return
13076 }
13077
13078 // Return value unmarshaling
13079 tpd := typedParamDecoder{}
13080 ct := map[string]xdr.TypeDecoder{"libvirt.TypedParam": tpd}
13081 rdr := bytes.NewReader(r.Payload)
13082 dec := xdr.NewDecoderCustomTypes(rdr, 0, ct)
13083 // Params: []TypedParam
13084 _, err = dec.Decode(&rParams)
13085 if err != nil {
13086 return
13087 }
13088 // Nparams: int32
13089 _, err = dec.Decode(&rNparams)
13090 if err != nil {
13091 return
13092 }
13093
13094 return
13095}
13096
13097// DomainBlockCommit is the go wrapper for REMOTE_PROC_DOMAIN_BLOCK_COMMIT.
13098func (l *Libvirt) DomainBlockCommit(Dom Domain, Disk string, Base OptString, Top OptString, Bandwidth uint64, Flags DomainBlockCommitFlags) (err error) {

Callers

nothing calls this directly

Calls 3

requestStreamMethod · 0.95
encodeFunction · 0.85
DecodeMethod · 0.65

Tested by

no test coverage detected