diff --git a/cmd/podman/kube/play.go b/cmd/podman/kube/play.go index 107d66f5190..10003c10718 100644 --- a/cmd/podman/kube/play.go +++ b/cmd/podman/kube/play.go @@ -40,6 +40,7 @@ type playKubeOptionsWrapper struct { BuildCLI bool annotations []string macs []string + labels []string } const yamlFileSeparator = "\n---\n" @@ -109,6 +110,10 @@ func playFlags(cmd *cobra.Command) { "Add Podman-specific annotations to containers and pods created by Podman (key=value)", ) _ = cmd.RegisterFlagCompletionFunc(annotationFlagName, completion.AutocompleteNone) + + labelFlagName := "label" + flags.StringArrayVarP(&playOptions.labels, labelFlagName, "l", []string{}, "Add labels to resources created by podman kube play (key=value)") + _ = cmd.RegisterFlagCompletionFunc(labelFlagName, completion.AutocompleteNone) credsFlagName := "creds" flags.StringVar(&playOptions.CredentialsCLI, credsFlagName, "", "`Credentials` (USERNAME:PASSWORD) to use for authenticating to a registry") _ = cmd.RegisterFlagCompletionFunc(credsFlagName, completion.AutocompleteNone) @@ -265,6 +270,15 @@ func play(cmd *cobra.Command, args []string) error { playOptions.Annotations[key] = val } + // parse labels provided on CLI and attach to PlayKubeOptions + if len(playOptions.labels) > 0 { + labelMap, err := parse.GetAllLabels([]string{}, playOptions.labels) + if err != nil { + return err + } + playOptions.Labels = labelMap + } + if err := annotations.ValidateAnnotations(playOptions.Annotations); err != nil { return err } diff --git a/pkg/api/handlers/libpod/kube.go b/pkg/api/handlers/libpod/kube.go index 1f8274e866a..9cf6e952cc6 100644 --- a/pkg/api/handlers/libpod/kube.go +++ b/pkg/api/handlers/libpod/kube.go @@ -106,6 +106,7 @@ func KubePlay(w http.ResponseWriter, r *http.Request) { decoder := r.Context().Value(api.DecoderKey).(*schema.Decoder) query := struct { Annotations map[string]string `schema:"annotations"` + Labels map[string]string `schema:"labels"` LogDriver string `schema:"logDriver"` LogOptions []string `schema:"logOptions"` Network []string `schema:"network"` @@ -179,6 +180,7 @@ func KubePlay(w http.ResponseWriter, r *http.Request) { containerEngine := abi.ContainerEngine{Libpod: runtime} options := entities.PlayKubeOptions{ Annotations: query.Annotations, + Labels: query.Labels, Authfile: authfile, IsRemote: true, LogDriver: logDriver, diff --git a/pkg/bindings/kube/types.go b/pkg/bindings/kube/types.go index 38c22b1c607..056c842b163 100644 --- a/pkg/bindings/kube/types.go +++ b/pkg/bindings/kube/types.go @@ -10,6 +10,8 @@ import ( type PlayOptions struct { // Annotations - Annotations to add to Pods Annotations map[string]string + // Labels - labels to add to created resources + Labels map[string]string // Authfile - path to an authentication file. Authfile *string // CertDir - to a directory containing TLS certifications and keys. diff --git a/pkg/bindings/kube/types_play_options.go b/pkg/bindings/kube/types_play_options.go index 0afe3220337..914002742e0 100644 --- a/pkg/bindings/kube/types_play_options.go +++ b/pkg/bindings/kube/types_play_options.go @@ -18,6 +18,21 @@ func (o *PlayOptions) ToParams() (url.Values, error) { return util.ToParams(o) } +// WithLabels set field Labels to given value +func (o *PlayOptions) WithLabels(value map[string]string) *PlayOptions { + o.Labels = value + return o +} + +// GetLabels returns value of field Labels +func (o *PlayOptions) GetLabels() map[string]string { + if o.Labels == nil { + var z map[string]string + return z + } + return o.Labels +} + // WithAnnotations set field Annotations to given value func (o *PlayOptions) WithAnnotations(value map[string]string) *PlayOptions { o.Annotations = value diff --git a/pkg/domain/entities/play.go b/pkg/domain/entities/play.go index 1e434378ca0..b3abd82793b 100644 --- a/pkg/domain/entities/play.go +++ b/pkg/domain/entities/play.go @@ -11,6 +11,8 @@ import ( type PlayKubeOptions struct { // Annotations - Annotations to add to Pods Annotations map[string]string + // Labels - Labels to add to created resources + Labels map[string]string // Authfile - path to an authentication file. Authfile string // Indicator to build all images with Containerfile or Dockerfile diff --git a/pkg/domain/infra/abi/play.go b/pkg/domain/infra/abi/play.go index ae4b425d4f8..8b4b00305e8 100644 --- a/pkg/domain/infra/abi/play.go +++ b/pkg/domain/infra/abi/play.go @@ -368,6 +368,14 @@ func (ic *ContainerEngine) PlayKube(ctx context.Context, body io.Reader, options podYAML.Annotations[name] = val } + // Merge CLI-specified labels into pod YAML labels so they are applied to created resources + for name, val := range options.Labels { + if podYAML.Labels == nil { + podYAML.Labels = make(map[string]string) + } + podYAML.Labels[name] = val + } + if err := annotations.ValidateAnnotations(podYAML.Annotations); err != nil { return nil, err } @@ -443,6 +451,14 @@ func (ic *ContainerEngine) PlayKube(ctx context.Context, body io.Reader, options pvcYAML.Annotations[name] = val } + // Merge CLI-provided labels into PVC labels so created volumes get them + for name, val := range options.Labels { + if pvcYAML.Labels == nil { + pvcYAML.Labels = make(map[string]string) + } + pvcYAML.Labels[name] = val + } + if options.IsRemote { if _, ok := pvcYAML.Annotations[util.VolumeImportSourceAnnotation]; ok { return nil, fmt.Errorf("importing volumes is not supported for remote requests") @@ -470,7 +486,15 @@ func (ic *ContainerEngine) PlayKube(ctx context.Context, body io.Reader, options return nil, fmt.Errorf("unable to read YAML as kube secret: %w", err) } - r, err := ic.playKubeSecret(&secret) + // Merge CLI-provided labels into secret labels + for name, val := range options.Labels { + if secret.ObjectMeta.Labels == nil { + secret.ObjectMeta.Labels = make(map[string]string) + } + secret.ObjectMeta.Labels[name] = val + } + + r, err := ic.playKubeSecret(&secret, options) if err != nil { return nil, err } @@ -1837,7 +1861,7 @@ func (ic *ContainerEngine) PlayKubeDown(ctx context.Context, body io.Reader, opt } // playKubeSecret allows users to create and store a kubernetes secret as a podman secret -func (ic *ContainerEngine) playKubeSecret(secret *v1.Secret) (*entities.SecretCreateReport, error) { +func (ic *ContainerEngine) playKubeSecret(secret *v1.Secret, options entities.PlayKubeOptions) (*entities.SecretCreateReport, error) { r := &entities.SecretCreateReport{} // Create the secret manager before hand @@ -1854,9 +1878,6 @@ func (ic *ContainerEngine) playKubeSecret(secret *v1.Secret) (*entities.SecretCr secretsPath := ic.Libpod.GetSecretsStorageDir() opts := make(map[string]string) opts["path"] = filepath.Join(secretsPath, "filedriver") - // maybe k8sName(data)... - // using this does not allow the user to use the name given to the secret - // but keeping secret.Name as the ID can lead to a collision. s, err := secretsManager.Lookup(secret.Name) if err == nil { @@ -1879,9 +1900,23 @@ func (ic *ContainerEngine) playKubeSecret(secret *v1.Secret) (*entities.SecretCr meta["immutable"] = "true" } + // Merge labels from the secret YAML and CLI-provided options + mergedLabels := make(map[string]string) + if secret.ObjectMeta.Labels != nil { + for k, v := range secret.ObjectMeta.Labels { + mergedLabels[k] = v + } + } + if options.Labels != nil { + for k, v := range options.Labels { + mergedLabels[k] = v + } + } + storeOpts := secrets.StoreOptions{ DriverOpts: opts, Metadata: meta, + Labels: mergedLabels, } secretID, err := secretsManager.Store(secret.Name, data, "file", storeOpts) diff --git a/test/tools/vendor/github.com/Masterminds/goutils/cryptorandomstringutils.go b/test/tools/vendor/github.com/Masterminds/goutils/cryptorandomstringutils.go index 8dbd9248583..79ab473403b 100644 --- a/test/tools/vendor/github.com/Masterminds/goutils/cryptorandomstringutils.go +++ b/test/tools/vendor/github.com/Masterminds/goutils/cryptorandomstringutils.go @@ -29,9 +29,11 @@ CryptoRandomNonAlphaNumeric creates a random string whose length is the number o Characters will be chosen from the set of all characters (ASCII/Unicode values between 0 to 2,147,483,647 (math.MaxInt32)). Parameter: + count - the length of random string to create Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, CryptoRandom(...) */ @@ -44,9 +46,11 @@ CryptoRandomAscii creates a random string whose length is the number of characte Characters will be chosen from the set of characters whose ASCII value is between 32 and 126 (inclusive). Parameter: + count - the length of random string to create Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, CryptoRandom(...) */ @@ -59,9 +63,11 @@ CryptoRandomNumeric creates a random string whose length is the number of charac Characters will be chosen from the set of numeric characters. Parameter: + count - the length of random string to create Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, CryptoRandom(...) */ @@ -74,11 +80,13 @@ CryptoRandomAlphabetic creates a random string whose length is the number of cha Characters will be chosen from the set of alpha-numeric characters as indicated by the arguments. Parameters: + count - the length of random string to create letters - if true, generated string may include alphabetic characters numbers - if true, generated string may include numeric characters Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, CryptoRandom(...) */ @@ -91,9 +99,11 @@ CryptoRandomAlphaNumeric creates a random string whose length is the number of c Characters will be chosen from the set of alpha-numeric characters. Parameter: + count - the length of random string to create Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, CryptoRandom(...) */ @@ -106,11 +116,13 @@ CryptoRandomAlphaNumericCustom creates a random string whose length is the numbe Characters will be chosen from the set of alpha-numeric characters as indicated by the arguments. Parameters: + count - the length of random string to create letters - if true, generated string may include alphabetic characters numbers - if true, generated string may include numeric characters Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, CryptoRandom(...) */ @@ -125,6 +137,7 @@ unless letters and numbers are both false, in which case, start and end are set If chars is not nil, characters stored in chars that are between start and end are chosen. Parameters: + count - the length of random string to create start - the position in set of chars (ASCII/Unicode int) to start at end - the position in set of chars (ASCII/Unicode int) to end before @@ -133,6 +146,7 @@ Parameters: chars - the set of chars to choose randoms from. If nil, then it will use the set of all chars. Returns: + string - the random string error - an error stemming from invalid parameters: if count < 0; or the provided chars array is empty; or end <= start; or end > len(chars) */ diff --git a/test/tools/vendor/github.com/Masterminds/goutils/randomstringutils.go b/test/tools/vendor/github.com/Masterminds/goutils/randomstringutils.go index 272670231ab..7ee8bc3f2e5 100644 --- a/test/tools/vendor/github.com/Masterminds/goutils/randomstringutils.go +++ b/test/tools/vendor/github.com/Masterminds/goutils/randomstringutils.go @@ -32,9 +32,11 @@ RandomNonAlphaNumeric creates a random string whose length is the number of char Characters will be chosen from the set of all characters (ASCII/Unicode values between 0 to 2,147,483,647 (math.MaxInt32)). Parameter: + count - the length of random string to create Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, RandomSeed(...) */ @@ -47,9 +49,11 @@ RandomAscii creates a random string whose length is the number of characters spe Characters will be chosen from the set of characters whose ASCII value is between 32 and 126 (inclusive). Parameter: + count - the length of random string to create Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, RandomSeed(...) */ @@ -62,9 +66,11 @@ RandomNumeric creates a random string whose length is the number of characters s Characters will be chosen from the set of numeric characters. Parameter: + count - the length of random string to create Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, RandomSeed(...) */ @@ -77,9 +83,11 @@ RandomAlphabetic creates a random string whose length is the number of character Characters will be chosen from the set of alphabetic characters. Parameters: + count - the length of random string to create Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, RandomSeed(...) */ @@ -92,9 +100,11 @@ RandomAlphaNumeric creates a random string whose length is the number of charact Characters will be chosen from the set of alpha-numeric characters. Parameter: + count - the length of random string to create Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, RandomSeed(...) */ @@ -107,11 +117,13 @@ RandomAlphaNumericCustom creates a random string whose length is the number of c Characters will be chosen from the set of alpha-numeric characters as indicated by the arguments. Parameters: + count - the length of random string to create letters - if true, generated string may include alphabetic characters numbers - if true, generated string may include numeric characters Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, RandomSeed(...) */ @@ -125,6 +137,7 @@ This method has exactly the same semantics as RandomSeed(int, int, int, bool, bo instead of using an externally supplied source of randomness, it uses the internal *rand.Rand instance. Parameters: + count - the length of random string to create start - the position in set of chars (ASCII/Unicode int) to start at end - the position in set of chars (ASCII/Unicode int) to end before @@ -133,6 +146,7 @@ Parameters: chars - the set of chars to choose randoms from. If nil, then it will use the set of all chars. Returns: + string - the random string error - an error stemming from an invalid parameter within underlying function, RandomSeed(...) */ @@ -149,6 +163,7 @@ This method accepts a user-supplied *rand.Rand instance to use as a source of ra with a fixed seed and using it for each call, the same random sequence of strings can be generated repeatedly and predictably. Parameters: + count - the length of random string to create start - the position in set of chars (ASCII/Unicode decimals) to start at end - the position in set of chars (ASCII/Unicode decimals) to end before @@ -158,6 +173,7 @@ Parameters: random - a source of randomness. Returns: + string - the random string error - an error stemming from invalid parameters: if count < 0; or the provided chars array is empty; or end <= start; or end > len(chars) */ diff --git a/test/tools/vendor/github.com/Masterminds/goutils/stringutils.go b/test/tools/vendor/github.com/Masterminds/goutils/stringutils.go index 741bb530e8a..3d47f09db26 100644 --- a/test/tools/vendor/github.com/Masterminds/goutils/stringutils.go +++ b/test/tools/vendor/github.com/Masterminds/goutils/stringutils.go @@ -31,18 +31,20 @@ Abbreviate abbreviates a string using ellipses. This will turn the string "Now Specifically, the algorithm is as follows: - - If str is less than maxWidth characters long, return it. - - Else abbreviate it to (str[0:maxWidth - 3] + "..."). - - If maxWidth is less than 4, return an illegal argument error. - - In no case will it return a string of length greater than maxWidth. + - If str is less than maxWidth characters long, return it. + - Else abbreviate it to (str[0:maxWidth - 3] + "..."). + - If maxWidth is less than 4, return an illegal argument error. + - In no case will it return a string of length greater than maxWidth. Parameters: - str - the string to check - maxWidth - maximum length of result string, must be at least 4 + + str - the string to check + maxWidth - maximum length of result string, must be at least 4 Returns: - string - abbreviated string - error - if the width is too small + + string - abbreviated string + error - if the width is too small */ func Abbreviate(str string, maxWidth int) (string, error) { return AbbreviateFull(str, 0, maxWidth) @@ -56,13 +58,15 @@ somewhere in the result. In no case will it return a string of length greater than maxWidth. Parameters: - str - the string to check - offset - left edge of source string - maxWidth - maximum length of result string, must be at least 4 + + str - the string to check + offset - left edge of source string + maxWidth - maximum length of result string, must be at least 4 Returns: - string - abbreviated string - error - if the width is too small + + string - abbreviated string + error - if the width is too small */ func AbbreviateFull(str string, offset int, maxWidth int) (string, error) { if str == "" { @@ -101,10 +105,12 @@ DeleteWhiteSpace deletes all whitespaces from a string as defined by unicode.IsS It returns the string without whitespaces. Parameter: - str - the string to delete whitespace from, may be nil + + str - the string to delete whitespace from, may be nil Returns: - the string without whitespaces + + the string without whitespaces */ func DeleteWhiteSpace(str string) string { if str == "" { @@ -130,11 +136,13 @@ func DeleteWhiteSpace(str string) string { IndexOfDifference compares two strings, and returns the index at which the strings begin to differ. Parameters: - str1 - the first string - str2 - the second string + + str1 - the first string + str2 - the second string Returns: - the index where str1 and str2 begin to differ; -1 if they are equal + + the index where str1 and str2 begin to differ; -1 if they are equal */ func IndexOfDifference(str1 string, str2 string) int { if str1 == str2 { @@ -158,16 +166,18 @@ func IndexOfDifference(str1 string, str2 string) int { /* IsBlank checks if a string is whitespace or empty (""). Observe the following behavior: - goutils.IsBlank("") = true - goutils.IsBlank(" ") = true - goutils.IsBlank("bob") = false - goutils.IsBlank(" bob ") = false + goutils.IsBlank("") = true + goutils.IsBlank(" ") = true + goutils.IsBlank("bob") = false + goutils.IsBlank(" bob ") = false Parameter: - str - the string to check + + str - the string to check Returns: - true - if the string is whitespace or empty ("") + + true - if the string is whitespace or empty ("") */ func IsBlank(str string) bool { strLen := len(str) @@ -190,12 +200,14 @@ An empty string ("") will return -1 (INDEX_NOT_FOUND). A negative start position A start position greater than the string length returns -1. Parameters: - str - the string to check - sub - the substring to find - start - the start position; negative treated as zero + + str - the string to check + sub - the substring to find + start - the start position; negative treated as zero Returns: - the first index where the sub string was found (always >= start) + + the first index where the sub string was found (always >= start) */ func IndexOf(str string, sub string, start int) int { diff --git a/test/tools/vendor/github.com/Masterminds/goutils/wordutils.go b/test/tools/vendor/github.com/Masterminds/goutils/wordutils.go index 034cad8e210..8e9ee337a28 100644 --- a/test/tools/vendor/github.com/Masterminds/goutils/wordutils.go +++ b/test/tools/vendor/github.com/Masterminds/goutils/wordutils.go @@ -21,29 +21,29 @@ errors while others do not, so usage would vary as a result. Example: - package main + package main - import ( - "fmt" - "github.com/aokoli/goutils" - ) + import ( + "fmt" + "github.com/aokoli/goutils" + ) - func main() { + func main() { - // EXAMPLE 1: A goutils function which returns no errors - fmt.Println (goutils.Initials("John Doe Foo")) // Prints out "JDF" + // EXAMPLE 1: A goutils function which returns no errors + fmt.Println (goutils.Initials("John Doe Foo")) // Prints out "JDF" - // EXAMPLE 2: A goutils function which returns an error - rand1, err1 := goutils.Random (-1, 0, 0, true, true) + // EXAMPLE 2: A goutils function which returns an error + rand1, err1 := goutils.Random (-1, 0, 0, true, true) - if err1 != nil { - fmt.Println(err1) // Prints out error message because -1 was entered as the first parameter in goutils.Random(...) - } else { - fmt.Println(rand1) - } - } + if err1 != nil { + fmt.Println(err1) // Prints out error message because -1 was entered as the first parameter in goutils.Random(...) + } else { + fmt.Println(rand1) + } + } */ package goutils @@ -62,11 +62,13 @@ New lines will be separated by '\n'. Very long words, such as URLs will not be w Leading spaces on a new line are stripped. Trailing spaces are not stripped. Parameters: - str - the string to be word wrapped - wrapLength - the column (a column can fit only one character) to wrap the words at, less than 1 is treated as 1 + + str - the string to be word wrapped + wrapLength - the column (a column can fit only one character) to wrap the words at, less than 1 is treated as 1 Returns: - a line with newlines inserted + + a line with newlines inserted */ func Wrap(str string, wrapLength int) string { return WrapCustom(str, wrapLength, "", false) @@ -77,13 +79,15 @@ WrapCustom wraps a single line of text, identifying words by ' '. Leading spaces on a new line are stripped. Trailing spaces are not stripped. Parameters: - str - the string to be word wrapped - wrapLength - the column number (a column can fit only one character) to wrap the words at, less than 1 is treated as 1 - newLineStr - the string to insert for a new line, "" uses '\n' - wrapLongWords - true if long words (such as URLs) should be wrapped + + str - the string to be word wrapped + wrapLength - the column number (a column can fit only one character) to wrap the words at, less than 1 is treated as 1 + newLineStr - the string to insert for a new line, "" uses '\n' + wrapLongWords - true if long words (such as URLs) should be wrapped Returns: - a line with newlines inserted + + a line with newlines inserted */ func WrapCustom(str string, wrapLength int, newLineStr string, wrapLongWords bool) string { @@ -157,11 +161,13 @@ and the first non-delimiter character after a delimiter will be capitalized. A " Capitalization uses the Unicode title case, normally equivalent to upper case. Parameters: - str - the string to capitalize - delimiters - set of characters to determine capitalization, exclusion of this parameter means whitespace would be delimeter + + str - the string to capitalize + delimiters - set of characters to determine capitalization, exclusion of this parameter means whitespace would be delimeter Returns: - capitalized string + + capitalized string */ func Capitalize(str string, delimiters ...rune) string { @@ -199,11 +205,13 @@ to separate words. The first string character and the first non-delimiter charac Capitalization uses the Unicode title case, normally equivalent to upper case. Parameters: - str - the string to capitalize fully - delimiters - set of characters to determine capitalization, exclusion of this parameter means whitespace would be delimeter + + str - the string to capitalize fully + delimiters - set of characters to determine capitalization, exclusion of this parameter means whitespace would be delimeter Returns: - capitalized string + + capitalized string */ func CapitalizeFully(str string, delimiters ...rune) string { @@ -228,11 +236,13 @@ The delimiters represent a set of characters understood to separate words. The f character after a delimiter will be uncapitalized. Whitespace is defined by unicode.IsSpace(char). Parameters: - str - the string to uncapitalize fully - delimiters - set of characters to determine capitalization, exclusion of this parameter means whitespace would be delimeter + + str - the string to uncapitalize fully + delimiters - set of characters to determine capitalization, exclusion of this parameter means whitespace would be delimeter Returns: - uncapitalized string + + uncapitalized string */ func Uncapitalize(str string, delimiters ...rune) string { @@ -267,17 +277,19 @@ SwapCase swaps the case of a string using a word based algorithm. Conversion algorithm: - Upper case character converts to Lower case - Title case character converts to Lower case - Lower case character after Whitespace or at start converts to Title case - Other Lower case character converts to Upper case - Whitespace is defined by unicode.IsSpace(char). + Upper case character converts to Lower case + Title case character converts to Lower case + Lower case character after Whitespace or at start converts to Title case + Other Lower case character converts to Upper case + Whitespace is defined by unicode.IsSpace(char). Parameters: - str - the string to swap case + + str - the string to swap case Returns: - the changed string + + the changed string */ func SwapCase(str string) string { if str == "" { @@ -315,10 +327,13 @@ letters after the defined delimiters are returned as a new string. Their case is parameter is excluded, then Whitespace is used. Whitespace is defined by unicode.IsSpacea(char). An empty delimiter array returns an empty string. Parameters: - str - the string to get initials from - delimiters - set of characters to determine words, exclusion of this parameter means whitespace would be delimeter + + str - the string to get initials from + delimiters - set of characters to determine words, exclusion of this parameter means whitespace would be delimeter + Returns: - string of initial letters + + string of initial letters */ func Initials(str string, delimiters ...rune) string { if str == "" { diff --git a/test/tools/vendor/github.com/Masterminds/sprig/v3/functions.go b/test/tools/vendor/github.com/Masterminds/sprig/v3/functions.go index 57fcec1d9ea..e8001ccf3e3 100644 --- a/test/tools/vendor/github.com/Masterminds/sprig/v3/functions.go +++ b/test/tools/vendor/github.com/Masterminds/sprig/v3/functions.go @@ -22,8 +22,7 @@ import ( // // Use this to pass the functions into the template engine: // -// tpl := template.New("foo").Funcs(sprig.FuncMap())) -// +// tpl := template.New("foo").Funcs(sprig.FuncMap())) func FuncMap() template.FuncMap { return HtmlFuncMap() } @@ -336,20 +335,20 @@ var genericMap = map[string]interface{}{ "mustChunk": mustChunk, // Crypto: - "bcrypt": bcrypt, - "htpasswd": htpasswd, - "genPrivateKey": generatePrivateKey, - "derivePassword": derivePassword, - "buildCustomCert": buildCustomCertificate, - "genCA": generateCertificateAuthority, - "genCAWithKey": generateCertificateAuthorityWithPEMKey, - "genSelfSignedCert": generateSelfSignedCertificate, + "bcrypt": bcrypt, + "htpasswd": htpasswd, + "genPrivateKey": generatePrivateKey, + "derivePassword": derivePassword, + "buildCustomCert": buildCustomCertificate, + "genCA": generateCertificateAuthority, + "genCAWithKey": generateCertificateAuthorityWithPEMKey, + "genSelfSignedCert": generateSelfSignedCertificate, "genSelfSignedCertWithKey": generateSelfSignedCertificateWithPEMKey, - "genSignedCert": generateSignedCertificate, - "genSignedCertWithKey": generateSignedCertificateWithPEMKey, - "encryptAES": encryptAES, - "decryptAES": decryptAES, - "randBytes": randBytes, + "genSignedCert": generateSignedCertificate, + "genSignedCertWithKey": generateSignedCertificateWithPEMKey, + "encryptAES": encryptAES, + "decryptAES": decryptAES, + "randBytes": randBytes, // UUIDs: "uuidv4": uuidv4, diff --git a/test/tools/vendor/github.com/Masterminds/sprig/v3/numeric.go b/test/tools/vendor/github.com/Masterminds/sprig/v3/numeric.go index f68e4182ee6..84fe18de087 100644 --- a/test/tools/vendor/github.com/Masterminds/sprig/v3/numeric.go +++ b/test/tools/vendor/github.com/Masterminds/sprig/v3/numeric.go @@ -6,8 +6,8 @@ import ( "strconv" "strings" - "github.com/spf13/cast" "github.com/shopspring/decimal" + "github.com/spf13/cast" ) // toFloat64 converts 64-bit floats diff --git a/test/tools/vendor/github.com/asaskevich/govalidator/types.go b/test/tools/vendor/github.com/asaskevich/govalidator/types.go index c573abb51af..e846711696d 100644 --- a/test/tools/vendor/github.com/asaskevich/govalidator/types.go +++ b/test/tools/vendor/github.com/asaskevich/govalidator/types.go @@ -177,7 +177,7 @@ type ISO3166Entry struct { Numeric string } -//ISO3166List based on https://www.iso.org/obp/ui/#search/code/ Code Type "Officially Assigned Codes" +// ISO3166List based on https://www.iso.org/obp/ui/#search/code/ Code Type "Officially Assigned Codes" var ISO3166List = []ISO3166Entry{ {"Afghanistan", "Afghanistan (l')", "AF", "AFG", "004"}, {"Albania", "Albanie (l')", "AL", "ALB", "008"}, @@ -467,7 +467,7 @@ type ISO693Entry struct { English string } -//ISO693List based on http://data.okfn.org/data/core/language-codes/r/language-codes-3b2.json +// ISO693List based on http://data.okfn.org/data/core/language-codes/r/language-codes-3b2.json var ISO693List = []ISO693Entry{ {Alpha3bCode: "aar", Alpha2Code: "aa", English: "Afar"}, {Alpha3bCode: "abk", Alpha2Code: "ab", English: "Abkhazian"}, diff --git a/test/tools/vendor/github.com/asaskevich/govalidator/validator.go b/test/tools/vendor/github.com/asaskevich/govalidator/validator.go index c9c4fac0655..4779e820e35 100644 --- a/test/tools/vendor/github.com/asaskevich/govalidator/validator.go +++ b/test/tools/vendor/github.com/asaskevich/govalidator/validator.go @@ -37,25 +37,32 @@ const rfc3339WithoutZone = "2006-01-02T15:04:05" // SetFieldsRequiredByDefault causes validation to fail when struct fields // do not include validations or are not explicitly marked as exempt (using `valid:"-"` or `valid:"email,optional"`). // This struct definition will fail govalidator.ValidateStruct() (and the field values do not matter): -// type exampleStruct struct { -// Name string `` -// Email string `valid:"email"` +// +// type exampleStruct struct { +// Name string `` +// Email string `valid:"email"` +// // This, however, will only fail when Email is empty or an invalid email address: -// type exampleStruct2 struct { -// Name string `valid:"-"` -// Email string `valid:"email"` +// +// type exampleStruct2 struct { +// Name string `valid:"-"` +// Email string `valid:"email"` +// // Lastly, this will only fail when Email is an invalid email address but not when it's empty: -// type exampleStruct2 struct { -// Name string `valid:"-"` -// Email string `valid:"email,optional"` +// +// type exampleStruct2 struct { +// Name string `valid:"-"` +// Email string `valid:"email,optional"` func SetFieldsRequiredByDefault(value bool) { fieldsRequiredByDefault = value } // SetNilPtrAllowedByRequired causes validation to pass for nil ptrs when a field is set to required. // The validation will still reject ptr fields in their zero value state. Example with this enabled: -// type exampleStruct struct { -// Name *string `valid:"required"` +// +// type exampleStruct struct { +// Name *string `valid:"required"` +// // With `Name` set to "", this will be considered invalid input and will cause a validation error. // With `Name` set to nil, this will be considered valid by validation. // By default this is disabled. @@ -154,8 +161,8 @@ func IsAlpha(str string) bool { return rxAlpha.MatchString(str) } -//IsUTFLetter checks if the string contains only unicode letter characters. -//Similar to IsAlpha but for all languages. Empty string is valid. +// IsUTFLetter checks if the string contains only unicode letter characters. +// Similar to IsAlpha but for all languages. Empty string is valid. func IsUTFLetter(str string) bool { if IsNull(str) { return true @@ -398,8 +405,8 @@ const ulidEncodedSize = 26 // IsULID checks if the string is a ULID. // // Implementation got from: -// https://github.com/oklog/ulid (Apache-2.0 License) // +// https://github.com/oklog/ulid (Apache-2.0 License) func IsULID(str string) bool { // Check if a base32 encoded ULID is the right length. if len(str) != ulidEncodedSize { @@ -454,26 +461,26 @@ func IsCreditCard(str string) bool { if !rxCreditCard.MatchString(sanitized) { return false } - + number, _ := ToInt(sanitized) - number, lastDigit := number / 10, number % 10 + number, lastDigit := number/10, number%10 var sum int64 - for i:=0; number > 0; i++ { + for i := 0; number > 0; i++ { digit := number % 10 - - if i % 2 == 0 { + + if i%2 == 0 { digit *= 2 if digit > 9 { digit -= 9 } } - + sum += digit number = number / 10 } - - return (sum + lastDigit) % 10 == 0 + + return (sum+lastDigit)%10 == 0 } // IsISBN10 checks if the string is an ISBN version 10. @@ -595,7 +602,7 @@ func IsFilePath(str string) (bool, int) { return false, Unknown } -//IsWinFilePath checks both relative & absolute paths in Windows +// IsWinFilePath checks both relative & absolute paths in Windows func IsWinFilePath(str string) bool { if rxARWinPath.MatchString(str) { //check windows path limit see: @@ -608,7 +615,7 @@ func IsWinFilePath(str string) bool { return false } -//IsUnixFilePath checks both relative & absolute paths in Unix +// IsUnixFilePath checks both relative & absolute paths in Unix func IsUnixFilePath(str string) bool { if rxARUnixPath.MatchString(str) { return true @@ -1000,7 +1007,8 @@ func ValidateArray(array []interface{}, iterator ConditionIterator) bool { // result will be equal to `false` if there are any errors. // s is the map containing the data to be validated. // m is the validation map in the form: -// map[string]interface{}{"name":"required,alpha","address":map[string]interface{}{"line1":"required,alphanum"}} +// +// map[string]interface{}{"name":"required,alpha","address":map[string]interface{}{"line1":"required,alphanum"}} func ValidateMap(s map[string]interface{}, m map[string]interface{}) (bool, error) { if s == nil { return true, nil diff --git a/test/tools/vendor/github.com/felixge/httpsnoop/wrap_generated_gteq_1.8.go b/test/tools/vendor/github.com/felixge/httpsnoop/wrap_generated_gteq_1.8.go index 101cedde674..cffd3d0526c 100644 --- a/test/tools/vendor/github.com/felixge/httpsnoop/wrap_generated_gteq_1.8.go +++ b/test/tools/vendor/github.com/felixge/httpsnoop/wrap_generated_gteq_1.8.go @@ -1,4 +1,6 @@ +//go:build go1.8 // +build go1.8 + // Code generated by "httpsnoop/codegen"; DO NOT EDIT. package httpsnoop diff --git a/test/tools/vendor/github.com/felixge/httpsnoop/wrap_generated_lt_1.8.go b/test/tools/vendor/github.com/felixge/httpsnoop/wrap_generated_lt_1.8.go index e0951df1527..c5ae196621a 100644 --- a/test/tools/vendor/github.com/felixge/httpsnoop/wrap_generated_lt_1.8.go +++ b/test/tools/vendor/github.com/felixge/httpsnoop/wrap_generated_lt_1.8.go @@ -1,4 +1,6 @@ +//go:build !go1.8 // +build !go1.8 + // Code generated by "httpsnoop/codegen"; DO NOT EDIT. package httpsnoop diff --git a/test/tools/vendor/github.com/google/uuid/dce.go b/test/tools/vendor/github.com/google/uuid/dce.go index fa820b9d309..9302a1c1bb5 100644 --- a/test/tools/vendor/github.com/google/uuid/dce.go +++ b/test/tools/vendor/github.com/google/uuid/dce.go @@ -42,7 +42,7 @@ func NewDCESecurity(domain Domain, id uint32) (UUID, error) { // NewDCEPerson returns a DCE Security (Version 2) UUID in the person // domain with the id returned by os.Getuid. // -// NewDCESecurity(Person, uint32(os.Getuid())) +// NewDCESecurity(Person, uint32(os.Getuid())) func NewDCEPerson() (UUID, error) { return NewDCESecurity(Person, uint32(os.Getuid())) } @@ -50,7 +50,7 @@ func NewDCEPerson() (UUID, error) { // NewDCEGroup returns a DCE Security (Version 2) UUID in the group // domain with the id returned by os.Getgid. // -// NewDCESecurity(Group, uint32(os.Getgid())) +// NewDCESecurity(Group, uint32(os.Getgid())) func NewDCEGroup() (UUID, error) { return NewDCESecurity(Group, uint32(os.Getgid())) } diff --git a/test/tools/vendor/github.com/google/uuid/hash.go b/test/tools/vendor/github.com/google/uuid/hash.go index dc60082d3b3..cee37578b3c 100644 --- a/test/tools/vendor/github.com/google/uuid/hash.go +++ b/test/tools/vendor/github.com/google/uuid/hash.go @@ -45,7 +45,7 @@ func NewHash(h hash.Hash, space UUID, data []byte, version int) UUID { // NewMD5 returns a new MD5 (Version 3) UUID based on the // supplied name space and data. It is the same as calling: // -// NewHash(md5.New(), space, data, 3) +// NewHash(md5.New(), space, data, 3) func NewMD5(space UUID, data []byte) UUID { return NewHash(md5.New(), space, data, 3) } @@ -53,7 +53,7 @@ func NewMD5(space UUID, data []byte) UUID { // NewSHA1 returns a new SHA1 (Version 5) UUID based on the // supplied name space and data. It is the same as calling: // -// NewHash(sha1.New(), space, data, 5) +// NewHash(sha1.New(), space, data, 5) func NewSHA1(space UUID, data []byte) UUID { return NewHash(sha1.New(), space, data, 5) } diff --git a/test/tools/vendor/github.com/google/uuid/node_js.go b/test/tools/vendor/github.com/google/uuid/node_js.go index b2a0bc8711b..f745d7017fc 100644 --- a/test/tools/vendor/github.com/google/uuid/node_js.go +++ b/test/tools/vendor/github.com/google/uuid/node_js.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build js // +build js package uuid diff --git a/test/tools/vendor/github.com/google/uuid/node_net.go b/test/tools/vendor/github.com/google/uuid/node_net.go index 0cbbcddbd6e..e91358f7d9e 100644 --- a/test/tools/vendor/github.com/google/uuid/node_net.go +++ b/test/tools/vendor/github.com/google/uuid/node_net.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build !js // +build !js package uuid diff --git a/test/tools/vendor/github.com/google/uuid/null.go b/test/tools/vendor/github.com/google/uuid/null.go index d7fcbf28651..06ecf9de2af 100644 --- a/test/tools/vendor/github.com/google/uuid/null.go +++ b/test/tools/vendor/github.com/google/uuid/null.go @@ -17,15 +17,14 @@ var jsonNull = []byte("null") // NullUUID implements the SQL driver.Scanner interface so // it can be used as a scan destination: // -// var u uuid.NullUUID -// err := db.QueryRow("SELECT name FROM foo WHERE id=?", id).Scan(&u) -// ... -// if u.Valid { -// // use u.UUID -// } else { -// // NULL value -// } -// +// var u uuid.NullUUID +// err := db.QueryRow("SELECT name FROM foo WHERE id=?", id).Scan(&u) +// ... +// if u.Valid { +// // use u.UUID +// } else { +// // NULL value +// } type NullUUID struct { UUID UUID Valid bool // Valid is true if UUID is not NULL diff --git a/test/tools/vendor/github.com/google/uuid/uuid.go b/test/tools/vendor/github.com/google/uuid/uuid.go index 5232b486780..1051192bc51 100644 --- a/test/tools/vendor/github.com/google/uuid/uuid.go +++ b/test/tools/vendor/github.com/google/uuid/uuid.go @@ -187,10 +187,12 @@ func Must(uuid UUID, err error) UUID { } // Validate returns an error if s is not a properly formatted UUID in one of the following formats: -// xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx -// urn:uuid:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx -// xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx -// {xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx} +// +// xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx +// urn:uuid:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx +// xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +// {xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx} +// // It returns an error if the format is invalid, otherwise nil. func Validate(s string) error { switch len(s) { diff --git a/test/tools/vendor/github.com/google/uuid/version4.go b/test/tools/vendor/github.com/google/uuid/version4.go index 7697802e4d1..62ac273815c 100644 --- a/test/tools/vendor/github.com/google/uuid/version4.go +++ b/test/tools/vendor/github.com/google/uuid/version4.go @@ -9,7 +9,7 @@ import "io" // New creates a new random UUID or panics. New is equivalent to // the expression // -// uuid.Must(uuid.NewRandom()) +// uuid.Must(uuid.NewRandom()) func New() UUID { return Must(NewRandom()) } @@ -17,7 +17,7 @@ func New() UUID { // NewString creates a new random UUID and returns it as a string or panics. // NewString is equivalent to the expression // -// uuid.New().String() +// uuid.New().String() func NewString() string { return Must(NewRandom()).String() } @@ -31,11 +31,11 @@ func NewString() string { // // A note about uniqueness derived from the UUID Wikipedia entry: // -// Randomly generated UUIDs have 122 random bits. One's annual risk of being -// hit by a meteorite is estimated to be one chance in 17 billion, that -// means the probability is about 0.00000000006 (6 × 10−11), -// equivalent to the odds of creating a few tens of trillions of UUIDs in a -// year and having one duplicate. +// Randomly generated UUIDs have 122 random bits. One's annual risk of being +// hit by a meteorite is estimated to be one chance in 17 billion, that +// means the probability is about 0.00000000006 (6 × 10−11), +// equivalent to the odds of creating a few tens of trillions of UUIDs in a +// year and having one duplicate. func NewRandom() (UUID, error) { if !poolEnabled { return NewRandomFromReader(rander) diff --git a/test/tools/vendor/github.com/hashicorp/hcl/hcl/printer/nodes.go b/test/tools/vendor/github.com/hashicorp/hcl/hcl/printer/nodes.go index 7c038d12a23..f207bf92d7f 100644 --- a/test/tools/vendor/github.com/hashicorp/hcl/hcl/printer/nodes.go +++ b/test/tools/vendor/github.com/hashicorp/hcl/hcl/printer/nodes.go @@ -721,10 +721,9 @@ func (p *printer) heredocIndent(buf []byte) []byte { // // A single line object: // -// * has no lead comments (hence multi-line) -// * has no assignment -// * has no values in the stanza (within {}) -// +// - has no lead comments (hence multi-line) +// - has no assignment +// - has no values in the stanza (within {}) func (p *printer) isSingleLineObject(val *ast.ObjectItem) bool { // If there is a lead comment, can't be one line if val.LeadComment != nil { diff --git a/test/tools/vendor/github.com/imdario/mergo/doc.go b/test/tools/vendor/github.com/imdario/mergo/doc.go index fcd985f995d..6c8fb45d41b 100644 --- a/test/tools/vendor/github.com/imdario/mergo/doc.go +++ b/test/tools/vendor/github.com/imdario/mergo/doc.go @@ -8,11 +8,11 @@ A helper to merge structs and maps in Golang. Useful for configuration default v Mergo merges same-type structs and maps by setting default values in zero-value fields. Mergo won't merge unexported (private) fields. It will do recursively any exported one. It also won't merge structs inside maps (because they are not addressable using Go reflection). -Status +# Status It is ready for production use. It is used in several projects by Docker, Google, The Linux Foundation, VMWare, Shopify, etc. -Important note +# Important note Please keep in mind that a problematic PR broke 0.3.9. We reverted it in 0.3.10. We consider 0.3.10 as stable but not bug-free. . Also, this version adds suppot for go modules. @@ -20,18 +20,18 @@ Keep in mind that in 0.3.2, Mergo changed Merge() and Map() signatures to suppor If you were using Mergo before April 6th, 2015, please check your project works as intended after updating your local copy with go get -u github.com/imdario/mergo. I apologize for any issue caused by its previous behavior and any future bug that Mergo could cause in existing projects after the change (release 0.2.0). -Install +# Install Do your usual installation procedure: - go get github.com/imdario/mergo + go get github.com/imdario/mergo - // use in your .go code - import ( - "github.com/imdario/mergo" - ) + // use in your .go code + import ( + "github.com/imdario/mergo" + ) -Usage +# Usage You can only merge same-type structs with exported fields initialized as zero value of their type and same-types maps. Mergo won't merge unexported (private) fields but will do recursively any exported one. It won't merge empty structs value as they are zero values too. Also, maps will be merged recursively except for structs inside maps (because they are not addressable using Go reflection). @@ -81,7 +81,7 @@ Here is a nice example: // {two 2} } -Transformers +# Transformers Transformers allow to merge specific types differently than in the default behavior. In other words, now you can customize how some types are merged. For example, time.Time is a struct; it doesn't have zero value but IsZero can return true because it has fields with zero value. How can we merge a non-zero time.Time? @@ -127,17 +127,16 @@ Transformers allow to merge specific types differently than in the default behav // { 2018-01-12 01:15:00 +0000 UTC m=+0.000000001 } } -Contact me +# Contact me If I can help you, you have an idea or you are using Mergo in your projects, don't hesitate to drop me a line (or a pull request): https://twitter.com/im_dario -About +# About Written by Dario Castañé: https://da.rio.hn -License +# License BSD 3-Clause license, as Go language. - */ package mergo diff --git a/test/tools/vendor/github.com/jessevdk/go-flags/flags.go b/test/tools/vendor/github.com/jessevdk/go-flags/flags.go index ac2157dd604..a6acf1be1f3 100644 --- a/test/tools/vendor/github.com/jessevdk/go-flags/flags.go +++ b/test/tools/vendor/github.com/jessevdk/go-flags/flags.go @@ -8,46 +8,45 @@ The flags package is similar in functionality to the go built-in flag package but provides more options and uses reflection to provide a convenient and succinct way of specifying command line options. - -Supported features +# Supported features The following features are supported in go-flags: - Options with short names (-v) - Options with long names (--verbose) - Options with and without arguments (bool v.s. other type) - Options with optional arguments and default values - Option default values from ENVIRONMENT_VARIABLES, including slice and map values - Multiple option groups each containing a set of options - Generate and print well-formatted help message - Passing remaining command line arguments after -- (optional) - Ignoring unknown command line options (optional) - Supports -I/usr/include -I=/usr/include -I /usr/include option argument specification - Supports multiple short options -aux - Supports all primitive go types (string, int{8..64}, uint{8..64}, float) - Supports same option multiple times (can store in slice or last option counts) - Supports maps - Supports function callbacks - Supports namespaces for (nested) option groups + Options with short names (-v) + Options with long names (--verbose) + Options with and without arguments (bool v.s. other type) + Options with optional arguments and default values + Option default values from ENVIRONMENT_VARIABLES, including slice and map values + Multiple option groups each containing a set of options + Generate and print well-formatted help message + Passing remaining command line arguments after -- (optional) + Ignoring unknown command line options (optional) + Supports -I/usr/include -I=/usr/include -I /usr/include option argument specification + Supports multiple short options -aux + Supports all primitive go types (string, int{8..64}, uint{8..64}, float) + Supports same option multiple times (can store in slice or last option counts) + Supports maps + Supports function callbacks + Supports namespaces for (nested) option groups Additional features specific to Windows: - Options with short names (/v) - Options with long names (/verbose) - Windows-style options with arguments use a colon as the delimiter - Modify generated help message with Windows-style / options - Windows style options can be disabled at build time using the "forceposix" - build tag + Options with short names (/v) + Options with long names (/verbose) + Windows-style options with arguments use a colon as the delimiter + Modify generated help message with Windows-style / options + Windows style options can be disabled at build time using the "forceposix" + build tag -Basic usage +# Basic usage The flags package uses structs, reflection and struct field tags to allow users to specify command line options. This results in very simple and concise specification of your application options. For example: - type Options struct { - Verbose []bool `short:"v" long:"verbose" description:"Show verbose debug information"` - } + type Options struct { + Verbose []bool `short:"v" long:"verbose" description:"Show verbose debug information"` + } This specifies one option with a short name -v and a long name --verbose. When either -v or --verbose is found on the command line, a 'true' value @@ -60,9 +59,9 @@ whenever the option is encountered, a value is appended to the slice. Map options from string to primitive type are also supported. On the command line, you specify the value for such an option as key:value. For example - type Options struct { - AuthorInfo string[string] `short:"a"` - } + type Options struct { + AuthorInfo string[string] `short:"a"` + } Then, the AuthorInfo map can be filled with something like -a name:Jesse -a "surname:van den Kieboom". @@ -71,96 +70,94 @@ Finally, for full control over the conversion between command line argument values and options, user defined types can choose to implement the Marshaler and Unmarshaler interfaces. - -Available field tags +# Available field tags The following is a list of tags for struct fields supported by go-flags: - short: the short name of the option (single character) - long: the long name of the option - required: if non empty, makes the option required to appear on the command - line. If a required option is not present, the parser will - return ErrRequired (optional) - description: the description of the option (optional) - long-description: the long description of the option. Currently only - displayed in generated man pages (optional) - no-flag: if non-empty, this field is ignored as an option (optional) - - optional: if non-empty, makes the argument of the option optional. When an - argument is optional it can only be specified using - --option=argument (optional) - optional-value: the value of an optional option when the option occurs - without an argument. This tag can be specified multiple - times in the case of maps or slices (optional) - default: the default value of an option. This tag can be specified - multiple times in the case of slices or maps (optional) - default-mask: when specified, this value will be displayed in the help - instead of the actual default value. This is useful - mostly for hiding otherwise sensitive information from - showing up in the help. If default-mask takes the special - value "-", then no default value will be shown at all - (optional) - env: the default value of the option is overridden from the - specified environment variable, if one has been defined. - (optional) - env-delim: the 'env' default value from environment is split into - multiple values with the given delimiter string, use with - slices and maps (optional) - value-name: the name of the argument value (to be shown in the help) - (optional) - choice: limits the values for an option to a set of values. - Repeat this tag once for each allowable value. - e.g. `long:"animal" choice:"cat" choice:"dog"` - hidden: if non-empty, the option is not visible in the help or man page. - - base: a base (radix) used to convert strings to integer values, the - default base is 10 (i.e. decimal) (optional) - - ini-name: the explicit ini option name (optional) - no-ini: if non-empty this field is ignored as an ini option - (optional) - - group: when specified on a struct field, makes the struct - field a separate group with the given name (optional) - namespace: when specified on a group struct field, the namespace - gets prepended to every option's long name and - subgroup's namespace of this group, separated by - the parser's namespace delimiter (optional) - env-namespace: when specified on a group struct field, the env-namespace - gets prepended to every option's env key and - subgroup's env-namespace of this group, separated by - the parser's env-namespace delimiter (optional) - command: when specified on a struct field, makes the struct - field a (sub)command with the given name (optional) - subcommands-optional: when specified on a command struct field, makes - any subcommands of that command optional (optional) - alias: when specified on a command struct field, adds the - specified name as an alias for the command. Can be - be specified multiple times to add more than one - alias (optional) - positional-args: when specified on a field with a struct type, - uses the fields of that struct to parse remaining - positional command line arguments into (in order - of the fields). If a field has a slice type, - then all remaining arguments will be added to it. - Positional arguments are optional by default, - unless the "required" tag is specified together - with the "positional-args" tag. The "required" tag - can also be set on the individual rest argument - fields, to require only the first N positional - arguments. If the "required" tag is set on the - rest arguments slice, then its value determines - the minimum amount of rest arguments that needs to - be provided (e.g. `required:"2"`) (optional) - positional-arg-name: used on a field in a positional argument struct; name - of the positional argument placeholder to be shown in - the help (optional) + short: the short name of the option (single character) + long: the long name of the option + required: if non empty, makes the option required to appear on the command + line. If a required option is not present, the parser will + return ErrRequired (optional) + description: the description of the option (optional) + long-description: the long description of the option. Currently only + displayed in generated man pages (optional) + no-flag: if non-empty, this field is ignored as an option (optional) + + optional: if non-empty, makes the argument of the option optional. When an + argument is optional it can only be specified using + --option=argument (optional) + optional-value: the value of an optional option when the option occurs + without an argument. This tag can be specified multiple + times in the case of maps or slices (optional) + default: the default value of an option. This tag can be specified + multiple times in the case of slices or maps (optional) + default-mask: when specified, this value will be displayed in the help + instead of the actual default value. This is useful + mostly for hiding otherwise sensitive information from + showing up in the help. If default-mask takes the special + value "-", then no default value will be shown at all + (optional) + env: the default value of the option is overridden from the + specified environment variable, if one has been defined. + (optional) + env-delim: the 'env' default value from environment is split into + multiple values with the given delimiter string, use with + slices and maps (optional) + value-name: the name of the argument value (to be shown in the help) + (optional) + choice: limits the values for an option to a set of values. + Repeat this tag once for each allowable value. + e.g. `long:"animal" choice:"cat" choice:"dog"` + hidden: if non-empty, the option is not visible in the help or man page. + + base: a base (radix) used to convert strings to integer values, the + default base is 10 (i.e. decimal) (optional) + + ini-name: the explicit ini option name (optional) + no-ini: if non-empty this field is ignored as an ini option + (optional) + + group: when specified on a struct field, makes the struct + field a separate group with the given name (optional) + namespace: when specified on a group struct field, the namespace + gets prepended to every option's long name and + subgroup's namespace of this group, separated by + the parser's namespace delimiter (optional) + env-namespace: when specified on a group struct field, the env-namespace + gets prepended to every option's env key and + subgroup's env-namespace of this group, separated by + the parser's env-namespace delimiter (optional) + command: when specified on a struct field, makes the struct + field a (sub)command with the given name (optional) + subcommands-optional: when specified on a command struct field, makes + any subcommands of that command optional (optional) + alias: when specified on a command struct field, adds the + specified name as an alias for the command. Can be + be specified multiple times to add more than one + alias (optional) + positional-args: when specified on a field with a struct type, + uses the fields of that struct to parse remaining + positional command line arguments into (in order + of the fields). If a field has a slice type, + then all remaining arguments will be added to it. + Positional arguments are optional by default, + unless the "required" tag is specified together + with the "positional-args" tag. The "required" tag + can also be set on the individual rest argument + fields, to require only the first N positional + arguments. If the "required" tag is set on the + rest arguments slice, then its value determines + the minimum amount of rest arguments that needs to + be provided (e.g. `required:"2"`) (optional) + positional-arg-name: used on a field in a positional argument struct; name + of the positional argument placeholder to be shown in + the help (optional) Either the `short:` tag or the `long:` must be specified to make the field eligible as an option. - -Option groups +# Option groups Option groups are a simple way to semantically separate your options. All options in a particular group are shown together in the help under the name @@ -169,14 +166,12 @@ precisely and emphasize the options affiliation to their group. There are currently three ways to specify option groups. - 1. Use NewNamedParser specifying the various option groups. - 2. Use AddGroup to add a group to an existing parser. - 3. Add a struct field to the top-level options annotated with the - group:"group-name" tag. + 1. Use NewNamedParser specifying the various option groups. + 2. Use AddGroup to add a group to an existing parser. + 3. Add a struct field to the top-level options annotated with the + group:"group-name" tag. - - -Commands +# Commands The flags package also has basic support for commands. Commands are often used in monolithic applications that support various commands or actions. @@ -186,9 +181,9 @@ application. There are currently two ways to specify a command. - 1. Use AddCommand on an existing parser. - 2. Add a struct field to your options struct annotated with the - command:"command-name" tag. + 1. Use AddCommand on an existing parser. + 2. Add a struct field to your options struct annotated with the + command:"command-name" tag. The most common, idiomatic way to implement commands is to define a global parser instance and implement each command in a separate file. These @@ -204,15 +199,14 @@ command has been specified on the command line, in addition to the options of all the parent commands. I.e. considering a -v flag on the parser and an add command, the following are equivalent: - ./app -v add - ./app add -v + ./app -v add + ./app add -v However, if the -v flag is defined on the add command, then the first of the two examples above would fail since the -v flag is not defined before the add command. - -Completion +# Completion go-flags has builtin support to provide bash completion of flags, commands and argument values. To use completion, the binary which uses go-flags @@ -226,7 +220,7 @@ by replacing the argument parsing routine with the completion routine which outputs completions for the passed arguments. The basic invocation to complete a set of arguments is therefore: - GO_FLAGS_COMPLETION=1 ./completion-example arg1 arg2 arg3 + GO_FLAGS_COMPLETION=1 ./completion-example arg1 arg2 arg3 where `completion-example` is the binary, `arg1` and `arg2` are the current arguments, and `arg3` (the last argument) is the argument @@ -237,20 +231,20 @@ are more than 1 completion items. To use this with bash completion, a simple file can be written which calls the binary which supports go-flags completion: - _completion_example() { - # All arguments except the first one - args=("${COMP_WORDS[@]:1:$COMP_CWORD}") + _completion_example() { + # All arguments except the first one + args=("${COMP_WORDS[@]:1:$COMP_CWORD}") - # Only split on newlines - local IFS=$'\n' + # Only split on newlines + local IFS=$'\n' - # Call completion (note that the first element of COMP_WORDS is - # the executable itself) - COMPREPLY=($(GO_FLAGS_COMPLETION=1 ${COMP_WORDS[0]} "${args[@]}")) - return 0 - } + # Call completion (note that the first element of COMP_WORDS is + # the executable itself) + COMPREPLY=($(GO_FLAGS_COMPLETION=1 ${COMP_WORDS[0]} "${args[@]}")) + return 0 + } - complete -F _completion_example completion-example + complete -F _completion_example completion-example Completion requires the parser option PassDoubleDash and is therefore enforced if the environment variable GO_FLAGS_COMPLETION is set. diff --git a/test/tools/vendor/github.com/jessevdk/go-flags/ini.go b/test/tools/vendor/github.com/jessevdk/go-flags/ini.go index 60b36c79c44..9c721ec77af 100644 --- a/test/tools/vendor/github.com/jessevdk/go-flags/ini.go +++ b/test/tools/vendor/github.com/jessevdk/go-flags/ini.go @@ -113,18 +113,18 @@ func (i *IniParser) ParseFile(filename string) error { // // The format of the ini file is as follows: // -// [Option group name] -// option = value +// [Option group name] +// option = value // // Each section in the ini file represents an option group or command in the // flags parser. The default flags parser option group (i.e. when using // flags.Parse) is named 'Application Options'. The ini option name is matched // in the following order: // -// 1. Compared to the ini-name tag on the option struct field (if present) -// 2. Compared to the struct field name -// 3. Compared to the option long name (if present) -// 4. Compared to the option short name (if present) +// 1. Compared to the ini-name tag on the option struct field (if present) +// 2. Compared to the struct field name +// 3. Compared to the option long name (if present) +// 4. Compared to the option short name (if present) // // Sections for nested groups and commands can be addressed using a dot `.' // namespacing notation (i.e [subcommand.Options]). Group section names are diff --git a/test/tools/vendor/github.com/jessevdk/go-flags/optstyle_other.go b/test/tools/vendor/github.com/jessevdk/go-flags/optstyle_other.go index 56dfdae1286..f84b69746d3 100644 --- a/test/tools/vendor/github.com/jessevdk/go-flags/optstyle_other.go +++ b/test/tools/vendor/github.com/jessevdk/go-flags/optstyle_other.go @@ -1,3 +1,4 @@ +//go:build !windows || forceposix // +build !windows forceposix package flags diff --git a/test/tools/vendor/github.com/jessevdk/go-flags/optstyle_windows.go b/test/tools/vendor/github.com/jessevdk/go-flags/optstyle_windows.go index f3f28aeeff4..e80290420ac 100644 --- a/test/tools/vendor/github.com/jessevdk/go-flags/optstyle_windows.go +++ b/test/tools/vendor/github.com/jessevdk/go-flags/optstyle_windows.go @@ -1,3 +1,4 @@ +//go:build !forceposix // +build !forceposix package flags diff --git a/test/tools/vendor/github.com/jessevdk/go-flags/termsize.go b/test/tools/vendor/github.com/jessevdk/go-flags/termsize.go index 829e477addf..91582e4c72d 100644 --- a/test/tools/vendor/github.com/jessevdk/go-flags/termsize.go +++ b/test/tools/vendor/github.com/jessevdk/go-flags/termsize.go @@ -1,3 +1,4 @@ +//go:build !windows && !plan9 && !appengine && !wasm // +build !windows,!plan9,!appengine,!wasm package flags diff --git a/test/tools/vendor/github.com/jessevdk/go-flags/termsize_nosysioctl.go b/test/tools/vendor/github.com/jessevdk/go-flags/termsize_nosysioctl.go index c1ff18673b1..9b51b72ec3b 100644 --- a/test/tools/vendor/github.com/jessevdk/go-flags/termsize_nosysioctl.go +++ b/test/tools/vendor/github.com/jessevdk/go-flags/termsize_nosysioctl.go @@ -1,3 +1,4 @@ +//go:build plan9 || appengine || wasm // +build plan9 appengine wasm package flags diff --git a/test/tools/vendor/github.com/jessevdk/go-flags/termsize_windows.go b/test/tools/vendor/github.com/jessevdk/go-flags/termsize_windows.go index 5c0fa6ba272..189a1b3fafe 100644 --- a/test/tools/vendor/github.com/jessevdk/go-flags/termsize_windows.go +++ b/test/tools/vendor/github.com/jessevdk/go-flags/termsize_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package flags diff --git a/test/tools/vendor/github.com/kr/pretty/formatter.go b/test/tools/vendor/github.com/kr/pretty/formatter.go index 8e6969c5908..c794ec045c7 100644 --- a/test/tools/vendor/github.com/kr/pretty/formatter.go +++ b/test/tools/vendor/github.com/kr/pretty/formatter.go @@ -21,7 +21,7 @@ type formatter struct { // breaks and tabs. Object f responds to the "%v" formatting verb when both the // "#" and " " (space) flags are set, for example: // -// fmt.Sprintf("%# v", Formatter(x)) +// fmt.Sprintf("%# v", Formatter(x)) // // If one of these two flags is not set, or any other verb is used, f will // format x according to the usual rules of package fmt. diff --git a/test/tools/vendor/github.com/magefile/mage/mg/deps.go b/test/tools/vendor/github.com/magefile/mage/mg/deps.go index f0c2509b833..b00aca3e3ec 100644 --- a/test/tools/vendor/github.com/magefile/mage/mg/deps.go +++ b/test/tools/vendor/github.com/magefile/mage/mg/deps.go @@ -72,10 +72,12 @@ func SerialCtxDeps(ctx context.Context, fns ...interface{}) { // CtxDeps runs the given functions as dependencies of the calling function. // Dependencies must only be of type: -// func() -// func() error -// func(context.Context) -// func(context.Context) error +// +// func() +// func() error +// func(context.Context) +// func(context.Context) error +// // Or a similar method on a mg.Namespace type. // Or an mg.Fn interface. // @@ -148,10 +150,12 @@ func checkFns(fns []interface{}) []Fn { // Deps runs the given functions in parallel, exactly once. Dependencies must // only be of type: -// func() -// func() error -// func(context.Context) -// func(context.Context) error +// +// func() +// func() error +// func(context.Context) +// func(context.Context) error +// // Or a similar method on a mg.Namespace type. // Or an mg.Fn interface. // diff --git a/test/tools/vendor/github.com/mailru/easyjson/jlexer/bytestostr.go b/test/tools/vendor/github.com/mailru/easyjson/jlexer/bytestostr.go index ff7b27c5b20..87f7fb7a445 100644 --- a/test/tools/vendor/github.com/mailru/easyjson/jlexer/bytestostr.go +++ b/test/tools/vendor/github.com/mailru/easyjson/jlexer/bytestostr.go @@ -2,8 +2,8 @@ // easyjson_nounsafe nor appengine build tag is set. See README notes // for more details. -//+build !easyjson_nounsafe -//+build !appengine +//go:build !easyjson_nounsafe && !appengine +// +build !easyjson_nounsafe,!appengine package jlexer diff --git a/test/tools/vendor/github.com/mailru/easyjson/jlexer/bytestostr_nounsafe.go b/test/tools/vendor/github.com/mailru/easyjson/jlexer/bytestostr_nounsafe.go index 864d1be6763..5c24365ccdb 100644 --- a/test/tools/vendor/github.com/mailru/easyjson/jlexer/bytestostr_nounsafe.go +++ b/test/tools/vendor/github.com/mailru/easyjson/jlexer/bytestostr_nounsafe.go @@ -1,7 +1,8 @@ // This file is included to the build if any of the buildtags below // are defined. Refer to README notes for more details. -//+build easyjson_nounsafe appengine +//go:build easyjson_nounsafe || appengine +// +build easyjson_nounsafe appengine package jlexer diff --git a/test/tools/vendor/github.com/mattn/go-isatty/isatty_windows.go b/test/tools/vendor/github.com/mattn/go-isatty/isatty_windows.go index 8e3c99171bf..367adab9971 100644 --- a/test/tools/vendor/github.com/mattn/go-isatty/isatty_windows.go +++ b/test/tools/vendor/github.com/mattn/go-isatty/isatty_windows.go @@ -42,7 +42,8 @@ func IsTerminal(fd uintptr) bool { // Check pipe name is used for cygwin/msys2 pty. // Cygwin/MSYS2 PTY has a name like: -// \{cygwin,msys}-XXXXXXXXXXXXXXXX-ptyN-{from,to}-master +// +// \{cygwin,msys}-XXXXXXXXXXXXXXXX-ptyN-{from,to}-master func isCygwinPipeName(name string) bool { token := strings.Split(name, "-") if len(token) < 5 { diff --git a/test/tools/vendor/github.com/mitchellh/copystructure/copystructure.go b/test/tools/vendor/github.com/mitchellh/copystructure/copystructure.go index 8089e6670a3..bf4b5df811f 100644 --- a/test/tools/vendor/github.com/mitchellh/copystructure/copystructure.go +++ b/test/tools/vendor/github.com/mitchellh/copystructure/copystructure.go @@ -18,20 +18,19 @@ const tagKey = "copy" // // For structs, copy behavior can be controlled with struct tags. For example: // -// struct { -// Name string -// Data *bytes.Buffer `copy:"shallow"` -// } +// struct { +// Name string +// Data *bytes.Buffer `copy:"shallow"` +// } // // The available tag values are: // -// * "ignore" - The field will be ignored, effectively resulting in it being -// assigned the zero value in the copy. -// -// * "shallow" - The field will be be shallow copied. This means that references -// values such as pointers, maps, slices, etc. will be directly assigned -// versus deep copied. +// - "ignore" - The field will be ignored, effectively resulting in it being +// assigned the zero value in the copy. // +// - "shallow" - The field will be be shallow copied. This means that references +// values such as pointers, maps, slices, etc. will be directly assigned +// versus deep copied. func Copy(v interface{}) (interface{}, error) { return Config{}.Copy(v) } diff --git a/test/tools/vendor/github.com/mitchellh/mapstructure/mapstructure.go b/test/tools/vendor/github.com/mitchellh/mapstructure/mapstructure.go index 1efb22ac361..fadccc4ab8d 100644 --- a/test/tools/vendor/github.com/mitchellh/mapstructure/mapstructure.go +++ b/test/tools/vendor/github.com/mitchellh/mapstructure/mapstructure.go @@ -9,84 +9,84 @@ // // The simplest function to start with is Decode. // -// Field Tags +// # Field Tags // // When decoding to a struct, mapstructure will use the field name by // default to perform the mapping. For example, if a struct has a field // "Username" then mapstructure will look for a key in the source value // of "username" (case insensitive). // -// type User struct { -// Username string -// } +// type User struct { +// Username string +// } // // You can change the behavior of mapstructure by using struct tags. // The default struct tag that mapstructure looks for is "mapstructure" // but you can customize it using DecoderConfig. // -// Renaming Fields +// # Renaming Fields // // To rename the key that mapstructure looks for, use the "mapstructure" // tag and set a value directly. For example, to change the "username" example // above to "user": // -// type User struct { -// Username string `mapstructure:"user"` -// } +// type User struct { +// Username string `mapstructure:"user"` +// } // -// Embedded Structs and Squashing +// # Embedded Structs and Squashing // // Embedded structs are treated as if they're another field with that name. // By default, the two structs below are equivalent when decoding with // mapstructure: // -// type Person struct { -// Name string -// } +// type Person struct { +// Name string +// } // -// type Friend struct { -// Person -// } +// type Friend struct { +// Person +// } // -// type Friend struct { -// Person Person -// } +// type Friend struct { +// Person Person +// } // // This would require an input that looks like below: // -// map[string]interface{}{ -// "person": map[string]interface{}{"name": "alice"}, -// } +// map[string]interface{}{ +// "person": map[string]interface{}{"name": "alice"}, +// } // // If your "person" value is NOT nested, then you can append ",squash" to // your tag value and mapstructure will treat it as if the embedded struct // were part of the struct directly. Example: // -// type Friend struct { -// Person `mapstructure:",squash"` -// } +// type Friend struct { +// Person `mapstructure:",squash"` +// } // // Now the following input would be accepted: // -// map[string]interface{}{ -// "name": "alice", -// } +// map[string]interface{}{ +// "name": "alice", +// } // // When decoding from a struct to a map, the squash tag squashes the struct // fields into a single map. Using the example structs from above: // -// Friend{Person: Person{Name: "alice"}} +// Friend{Person: Person{Name: "alice"}} // // Will be decoded into a map: // -// map[string]interface{}{ -// "name": "alice", -// } +// map[string]interface{}{ +// "name": "alice", +// } // // DecoderConfig has a field that changes the behavior of mapstructure // to always squash embedded structs. // -// Remainder Values +// # Remainder Values // // If there are any unmapped keys in the source value, mapstructure by // default will silently ignore them. You can error by setting ErrorUnused @@ -98,20 +98,20 @@ // probably be a "map[string]interface{}" or "map[interface{}]interface{}". // See example below: // -// type Friend struct { -// Name string -// Other map[string]interface{} `mapstructure:",remain"` -// } +// type Friend struct { +// Name string +// Other map[string]interface{} `mapstructure:",remain"` +// } // // Given the input below, Other would be populated with the other // values that weren't used (everything but "name"): // -// map[string]interface{}{ -// "name": "bob", -// "address": "123 Maple St.", -// } +// map[string]interface{}{ +// "name": "bob", +// "address": "123 Maple St.", +// } // -// Omit Empty Values +// # Omit Empty Values // // When decoding from a struct to any other value, you may use the // ",omitempty" suffix on your tag to omit that value if it equates to @@ -122,37 +122,37 @@ // field value is zero and a numeric type, the field is empty, and it won't // be encoded into the destination type. // -// type Source struct { -// Age int `mapstructure:",omitempty"` -// } +// type Source struct { +// Age int `mapstructure:",omitempty"` +// } // -// Unexported fields +// # Unexported fields // // Since unexported (private) struct fields cannot be set outside the package // where they are defined, the decoder will simply skip them. // // For this output type definition: // -// type Exported struct { -// private string // this unexported field will be skipped -// Public string -// } +// type Exported struct { +// private string // this unexported field will be skipped +// Public string +// } // // Using this map as input: // -// map[string]interface{}{ -// "private": "I will be ignored", -// "Public": "I made it through!", -// } +// map[string]interface{}{ +// "private": "I will be ignored", +// "Public": "I made it through!", +// } // // The following struct will be decoded: // -// type Exported struct { -// private: "" // field is left with an empty string (zero value) -// Public: "I made it through!" -// } +// type Exported struct { +// private: "" // field is left with an empty string (zero value) +// Public: "I made it through!" +// } // -// Other Configuration +// # Other Configuration // // mapstructure is highly configurable. See the DecoderConfig struct // for other features and options that are supported. diff --git a/test/tools/vendor/github.com/mitchellh/reflectwalk/reflectwalk.go b/test/tools/vendor/github.com/mitchellh/reflectwalk/reflectwalk.go index 7fee7b050ba..2f7a976d693 100644 --- a/test/tools/vendor/github.com/mitchellh/reflectwalk/reflectwalk.go +++ b/test/tools/vendor/github.com/mitchellh/reflectwalk/reflectwalk.go @@ -81,7 +81,6 @@ type PointerValueWalker interface { // // - Struct: skips all fields from being walked // - StructField: skips walking the struct value -// var SkipEntry = errors.New("skip this entry") // Walk takes an arbitrary value and an interface and traverses the diff --git a/test/tools/vendor/github.com/oklog/ulid/ulid.go b/test/tools/vendor/github.com/oklog/ulid/ulid.go index c5d0d66fd2a..03e62d4831d 100644 --- a/test/tools/vendor/github.com/oklog/ulid/ulid.go +++ b/test/tools/vendor/github.com/oklog/ulid/ulid.go @@ -376,7 +376,8 @@ func MaxTime() uint64 { return maxTime } // Now is a convenience function that returns the current // UTC time in Unix milliseconds. Equivalent to: -// Timestamp(time.Now().UTC()) +// +// Timestamp(time.Now().UTC()) func Now() uint64 { return Timestamp(time.Now().UTC()) } // Timestamp converts a time.Time to Unix milliseconds. @@ -457,7 +458,7 @@ func (id *ULID) Scan(src interface{}) error { // type can be created that calls String(). // // // stringValuer wraps a ULID as a string-based driver.Valuer. -// type stringValuer ULID +// type stringValuer ULID // // func (id stringValuer) Value() (driver.Value, error) { // return ULID(id).String(), nil diff --git a/test/tools/vendor/github.com/russross/blackfriday/v2/doc.go b/test/tools/vendor/github.com/russross/blackfriday/v2/doc.go index 57ff152a056..2a5cc5b6784 100644 --- a/test/tools/vendor/github.com/russross/blackfriday/v2/doc.go +++ b/test/tools/vendor/github.com/russross/blackfriday/v2/doc.go @@ -16,7 +16,7 @@ // If you're interested in calling Blackfriday from command line, see // https://github.com/russross/blackfriday-tool. // -// Sanitized Anchor Names +// # Sanitized Anchor Names // // Blackfriday includes an algorithm for creating sanitized anchor names // corresponding to a given input text. This algorithm is used to create diff --git a/test/tools/vendor/github.com/russross/blackfriday/v2/inline.go b/test/tools/vendor/github.com/russross/blackfriday/v2/inline.go index d45bd941726..e13d425720f 100644 --- a/test/tools/vendor/github.com/russross/blackfriday/v2/inline.go +++ b/test/tools/vendor/github.com/russross/blackfriday/v2/inline.go @@ -735,7 +735,9 @@ func linkEndsWithEntity(data []byte, linkEnd int) bool { } // hasPrefixCaseInsensitive is a custom implementation of -// strings.HasPrefix(strings.ToLower(s), prefix) +// +// strings.HasPrefix(strings.ToLower(s), prefix) +// // we rolled our own because ToLower pulls in a huge machinery of lowercasing // anything from Unicode and that's very slow. Since this func will only be // used on ASCII protocol prefixes, we can take shortcuts. diff --git a/test/tools/vendor/github.com/russross/blackfriday/v2/markdown.go b/test/tools/vendor/github.com/russross/blackfriday/v2/markdown.go index 58d2e4538c6..382db9e9d23 100644 --- a/test/tools/vendor/github.com/russross/blackfriday/v2/markdown.go +++ b/test/tools/vendor/github.com/russross/blackfriday/v2/markdown.go @@ -345,8 +345,8 @@ func WithNoExtensions() Option { // In Markdown, the link reference syntax can be made to resolve a link to // a reference instead of an inline URL, in one of the following ways: // -// * [link text][refid] -// * [refid][] +// - [link text][refid] +// - [refid][] // // Usually, the refid is defined at the bottom of the Markdown document. If // this override function is provided, the refid is passed to the override @@ -363,7 +363,9 @@ func WithRefOverride(o ReferenceOverrideFunc) Option { // block of markdown-encoded text. // // The simplest invocation of Run takes one argument, input: -// output := Run(input) +// +// output := Run(input) +// // This will parse the input with CommonExtensions enabled and render it with // the default HTMLRenderer (with CommonHTMLFlags). // @@ -371,13 +373,15 @@ func WithRefOverride(o ReferenceOverrideFunc) Option { // type does not contain exported fields, you can not use it directly. Instead, // use the With* functions. For example, this will call the most basic // functionality, with no extensions: -// output := Run(input, WithNoExtensions()) +// +// output := Run(input, WithNoExtensions()) // // You can use any number of With* arguments, even contradicting ones. They // will be applied in order of appearance and the latter will override the // former: -// output := Run(input, WithNoExtensions(), WithExtensions(exts), -// WithRenderer(yourRenderer)) +// +// output := Run(input, WithNoExtensions(), WithExtensions(exts), +// WithRenderer(yourRenderer)) func Run(input []byte, opts ...Option) []byte { r := NewHTMLRenderer(HTMLRendererParameters{ Flags: CommonHTMLFlags, @@ -491,35 +495,35 @@ func (p *Markdown) parseRefsToAST() { // // Consider this markdown with reference-style links: // -// [link][ref] +// [link][ref] // -// [ref]: /url/ "tooltip title" +// [ref]: /url/ "tooltip title" // // It will be ultimately converted to this HTML: // -//

link

+//

link

// // And a reference structure will be populated as follows: // -// p.refs["ref"] = &reference{ -// link: "/url/", -// title: "tooltip title", -// } +// p.refs["ref"] = &reference{ +// link: "/url/", +// title: "tooltip title", +// } // // Alternatively, reference can contain information about a footnote. Consider // this markdown: // -// Text needing a footnote.[^a] +// Text needing a footnote.[^a] // -// [^a]: This is the note +// [^a]: This is the note // // A reference structure will be populated as follows: // -// p.refs["a"] = &reference{ -// link: "a", -// title: "This is the note", -// noteID: , -// } +// p.refs["a"] = &reference{ +// link: "a", +// title: "This is the note", +// noteID: , +// } // // TODO: As you can see, it begs for splitting into two dedicated structures // for refs and for footnotes. diff --git a/test/tools/vendor/github.com/shopspring/decimal/decimal.go b/test/tools/vendor/github.com/shopspring/decimal/decimal.go index 84405ec1cf0..458ded93ff8 100644 --- a/test/tools/vendor/github.com/shopspring/decimal/decimal.go +++ b/test/tools/vendor/github.com/shopspring/decimal/decimal.go @@ -4,14 +4,14 @@ // // The best way to create a new Decimal is to use decimal.NewFromString, ex: // -// n, err := decimal.NewFromString("-123.4567") -// n.String() // output: "-123.4567" +// n, err := decimal.NewFromString("-123.4567") +// n.String() // output: "-123.4567" // // To use Decimal as part of a struct: // -// type Struct struct { -// Number Decimal -// } +// type Struct struct { +// Number Decimal +// } // // Note: This can "only" represent numbers with a maximum of 2^31 digits after the decimal point. package decimal @@ -32,16 +32,15 @@ import ( // // Example: // -// d1 := decimal.NewFromFloat(2).Div(decimal.NewFromFloat(3)) -// d1.String() // output: "0.6666666666666667" -// d2 := decimal.NewFromFloat(2).Div(decimal.NewFromFloat(30000)) -// d2.String() // output: "0.0000666666666667" -// d3 := decimal.NewFromFloat(20000).Div(decimal.NewFromFloat(3)) -// d3.String() // output: "6666.6666666666666667" -// decimal.DivisionPrecision = 3 -// d4 := decimal.NewFromFloat(2).Div(decimal.NewFromFloat(3)) -// d4.String() // output: "0.667" -// +// d1 := decimal.NewFromFloat(2).Div(decimal.NewFromFloat(3)) +// d1.String() // output: "0.6666666666666667" +// d2 := decimal.NewFromFloat(2).Div(decimal.NewFromFloat(30000)) +// d2.String() // output: "0.0000666666666667" +// d3 := decimal.NewFromFloat(20000).Div(decimal.NewFromFloat(3)) +// d3.String() // output: "6666.6666666666666667" +// decimal.DivisionPrecision = 3 +// d4 := decimal.NewFromFloat(2).Div(decimal.NewFromFloat(3)) +// d4.String() // output: "0.667" var DivisionPrecision = 16 // MarshalJSONWithoutQuotes should be set to true if you want the decimal to @@ -95,8 +94,8 @@ func New(value int64, exp int32) Decimal { // // Example: // -// NewFromInt(123).String() // output: "123" -// NewFromInt(-10).String() // output: "-10" +// NewFromInt(123).String() // output: "123" +// NewFromInt(-10).String() // output: "-10" func NewFromInt(value int64) Decimal { return Decimal{ value: big.NewInt(value), @@ -108,8 +107,8 @@ func NewFromInt(value int64) Decimal { // // Example: // -// NewFromInt(123).String() // output: "123" -// NewFromInt(-10).String() // output: "-10" +// NewFromInt(123).String() // output: "123" +// NewFromInt(-10).String() // output: "-10" func NewFromInt32(value int32) Decimal { return Decimal{ value: big.NewInt(int64(value)), @@ -130,10 +129,9 @@ func NewFromBigInt(value *big.Int, exp int32) Decimal { // // Example: // -// d, err := NewFromString("-123.45") -// d2, err := NewFromString(".0001") -// d3, err := NewFromString("1.47000") -// +// d, err := NewFromString("-123.45") +// d2, err := NewFromString(".0001") +// d3, err := NewFromString("1.47000") func NewFromString(value string) (Decimal, error) { originalInput := value var intString string @@ -211,15 +209,14 @@ func NewFromString(value string) (Decimal, error) { // // Example: // -// r := regexp.MustCompile("[$,]") -// d1, err := NewFromFormattedString("$5,125.99", r) +// r := regexp.MustCompile("[$,]") +// d1, err := NewFromFormattedString("$5,125.99", r) // -// r2 := regexp.MustCompile("[_]") -// d2, err := NewFromFormattedString("1_000_000", r2) -// -// r3 := regexp.MustCompile("[USD\\s]") -// d3, err := NewFromFormattedString("5000 USD", r3) +// r2 := regexp.MustCompile("[_]") +// d2, err := NewFromFormattedString("1_000_000", r2) // +// r3 := regexp.MustCompile("[USD\\s]") +// d3, err := NewFromFormattedString("5000 USD", r3) func NewFromFormattedString(value string, replRegexp *regexp.Regexp) (Decimal, error) { parsedValue := replRegexp.ReplaceAllString(value, "") d, err := NewFromString(parsedValue) @@ -234,9 +231,8 @@ func NewFromFormattedString(value string, replRegexp *regexp.Regexp) (Decimal, e // // Example: // -// d := RequireFromString("-123.45") -// d2 := RequireFromString(".0001") -// +// d := RequireFromString("-123.45") +// d2 := RequireFromString(".0001") func RequireFromString(value string) Decimal { dec, err := NewFromString(value) if err != nil { @@ -332,8 +328,7 @@ func newFromFloat(val float64, bits uint64, flt *floatInfo) Decimal { // // Example: // -// NewFromFloatWithExponent(123.456, -2).String() // output: "123.46" -// +// NewFromFloatWithExponent(123.456, -2).String() // output: "123.46" func NewFromFloatWithExponent(value float64, exp int32) Decimal { if math.IsNaN(value) || math.IsInf(value, 0) { panic(fmt.Sprintf("Cannot create a Decimal from %v", value)) @@ -430,7 +425,7 @@ func (d Decimal) Copy() Decimal { // // Example: // -// d := New(12345, -4) +// d := New(12345, -4) // d2 := d.rescale(-1) // d3 := d2.rescale(-4) // println(d1) @@ -442,7 +437,6 @@ func (d Decimal) Copy() Decimal { // 1.2345 // 1.2 // 1.2000 -// func (d Decimal) rescale(exp int32) Decimal { d.ensureInitialized() @@ -554,9 +548,11 @@ func (d Decimal) Div(d2 Decimal) Decimal { // QuoRem does divsion with remainder // d.QuoRem(d2,precision) returns quotient q and remainder r such that -// d = d2 * q + r, q an integer multiple of 10^(-precision) -// 0 <= r < abs(d2) * 10 ^(-precision) if d>=0 -// 0 >= r > -abs(d2) * 10 ^(-precision) if d<0 +// +// d = d2 * q + r, q an integer multiple of 10^(-precision) +// 0 <= r < abs(d2) * 10 ^(-precision) if d>=0 +// 0 >= r > -abs(d2) * 10 ^(-precision) if d<0 +// // Note that precision<0 is allowed as input. func (d Decimal) QuoRem(d2 Decimal, precision int32) (Decimal, Decimal) { d.ensureInitialized() @@ -599,8 +595,10 @@ func (d Decimal) QuoRem(d2 Decimal, precision int32) (Decimal, Decimal) { // DivRound divides and rounds to a given precision // i.e. to an integer multiple of 10^(-precision) -// for a positive quotient digit 5 is rounded up, away from 0 -// if the quotient is negative then digit 5 is rounded down, away from 0 +// +// for a positive quotient digit 5 is rounded up, away from 0 +// if the quotient is negative then digit 5 is rounded down, away from 0 +// // Note that precision<0 is allowed as input. func (d Decimal) DivRound(d2 Decimal, precision int32) Decimal { // QuoRem already checks initialization @@ -655,9 +653,8 @@ func (d Decimal) Pow(d2 Decimal) Decimal { // // Example: // -// NewFromFloat(26.1).ExpHullAbrham(2).String() // output: "220000000000" -// NewFromFloat(26.1).ExpHullAbrham(20).String() // output: "216314672147.05767284" -// +// NewFromFloat(26.1).ExpHullAbrham(2).String() // output: "220000000000" +// NewFromFloat(26.1).ExpHullAbrham(20).String() // output: "216314672147.05767284" func (d Decimal) ExpHullAbrham(overallPrecision uint32) (Decimal, error) { // Algorithm based on Variable precision exponential function. // ACM Transactions on Mathematical Software by T. E. Hull & A. Abrham. @@ -747,15 +744,14 @@ func (d Decimal) ExpHullAbrham(overallPrecision uint32) (Decimal, error) { // // Example: // -// d, err := NewFromFloat(26.1).ExpTaylor(2).String() -// d.String() // output: "216314672147.06" -// -// NewFromFloat(26.1).ExpTaylor(20).String() -// d.String() // output: "216314672147.05767284062928674083" +// d, err := NewFromFloat(26.1).ExpTaylor(2).String() +// d.String() // output: "216314672147.06" // -// NewFromFloat(26.1).ExpTaylor(-10).String() -// d.String() // output: "220000000000" +// NewFromFloat(26.1).ExpTaylor(20).String() +// d.String() // output: "216314672147.05767284062928674083" // +// NewFromFloat(26.1).ExpTaylor(-10).String() +// d.String() // output: "220000000000" func (d Decimal) ExpTaylor(precision int32) (Decimal, error) { // Note(mwoss): Implementation can be optimized by exclusively using big.Int API only if d.IsZero() { @@ -851,10 +847,9 @@ func abs(n int32) int32 { // Cmp compares the numbers represented by d and d2 and returns: // -// -1 if d < d2 -// 0 if d == d2 -// +1 if d > d2 -// +// -1 if d < d2 +// 0 if d == d2 +// +1 if d > d2 func (d Decimal) Cmp(d2 Decimal) int { d.ensureInitialized() d2.ensureInitialized() @@ -905,7 +900,6 @@ func (d Decimal) LessThanOrEqual(d2 Decimal) bool { // -1 if d < 0 // 0 if d == 0 // +1 if d > 0 -// func (d Decimal) Sign() int { if d.value == nil { return 0 @@ -1014,13 +1008,12 @@ func (d Decimal) InexactFloat64() float64 { // // Example: // -// d := New(-12345, -3) -// println(d.String()) +// d := New(-12345, -3) +// println(d.String()) // // Output: // -// -12.345 -// +// -12.345 func (d Decimal) String() string { return d.string(true) } @@ -1030,14 +1023,13 @@ func (d Decimal) String() string { // // Example: // -// NewFromFloat(0).StringFixed(2) // output: "0.00" -// NewFromFloat(0).StringFixed(0) // output: "0" -// NewFromFloat(5.45).StringFixed(0) // output: "5" -// NewFromFloat(5.45).StringFixed(1) // output: "5.5" -// NewFromFloat(5.45).StringFixed(2) // output: "5.45" -// NewFromFloat(5.45).StringFixed(3) // output: "5.450" -// NewFromFloat(545).StringFixed(-1) // output: "550" -// +// NewFromFloat(0).StringFixed(2) // output: "0.00" +// NewFromFloat(0).StringFixed(0) // output: "0" +// NewFromFloat(5.45).StringFixed(0) // output: "5" +// NewFromFloat(5.45).StringFixed(1) // output: "5.5" +// NewFromFloat(5.45).StringFixed(2) // output: "5.45" +// NewFromFloat(5.45).StringFixed(3) // output: "5.450" +// NewFromFloat(545).StringFixed(-1) // output: "550" func (d Decimal) StringFixed(places int32) string { rounded := d.Round(places) return rounded.string(false) @@ -1048,14 +1040,13 @@ func (d Decimal) StringFixed(places int32) string { // // Example: // -// NewFromFloat(0).StringFixedBank(2) // output: "0.00" -// NewFromFloat(0).StringFixedBank(0) // output: "0" -// NewFromFloat(5.45).StringFixedBank(0) // output: "5" -// NewFromFloat(5.45).StringFixedBank(1) // output: "5.4" -// NewFromFloat(5.45).StringFixedBank(2) // output: "5.45" -// NewFromFloat(5.45).StringFixedBank(3) // output: "5.450" -// NewFromFloat(545).StringFixedBank(-1) // output: "540" -// +// NewFromFloat(0).StringFixedBank(2) // output: "0.00" +// NewFromFloat(0).StringFixedBank(0) // output: "0" +// NewFromFloat(5.45).StringFixedBank(0) // output: "5" +// NewFromFloat(5.45).StringFixedBank(1) // output: "5.4" +// NewFromFloat(5.45).StringFixedBank(2) // output: "5.45" +// NewFromFloat(5.45).StringFixedBank(3) // output: "5.450" +// NewFromFloat(545).StringFixedBank(-1) // output: "540" func (d Decimal) StringFixedBank(places int32) string { rounded := d.RoundBank(places) return rounded.string(false) @@ -1073,9 +1064,8 @@ func (d Decimal) StringFixedCash(interval uint8) string { // // Example: // -// NewFromFloat(5.45).Round(1).String() // output: "5.5" -// NewFromFloat(545).Round(-1).String() // output: "550" -// +// NewFromFloat(5.45).Round(1).String() // output: "5.5" +// NewFromFloat(545).Round(-1).String() // output: "550" func (d Decimal) Round(places int32) Decimal { if d.exp == -places { return d @@ -1104,11 +1094,10 @@ func (d Decimal) Round(places int32) Decimal { // // Example: // -// NewFromFloat(545).RoundCeil(-2).String() // output: "600" -// NewFromFloat(500).RoundCeil(-2).String() // output: "500" -// NewFromFloat(1.1001).RoundCeil(2).String() // output: "1.11" -// NewFromFloat(-1.454).RoundCeil(1).String() // output: "-1.5" -// +// NewFromFloat(545).RoundCeil(-2).String() // output: "600" +// NewFromFloat(500).RoundCeil(-2).String() // output: "500" +// NewFromFloat(1.1001).RoundCeil(2).String() // output: "1.11" +// NewFromFloat(-1.454).RoundCeil(1).String() // output: "-1.5" func (d Decimal) RoundCeil(places int32) Decimal { if d.exp >= -places { return d @@ -1130,11 +1119,10 @@ func (d Decimal) RoundCeil(places int32) Decimal { // // Example: // -// NewFromFloat(545).RoundFloor(-2).String() // output: "500" -// NewFromFloat(-500).RoundFloor(-2).String() // output: "-500" -// NewFromFloat(1.1001).RoundFloor(2).String() // output: "1.1" -// NewFromFloat(-1.454).RoundFloor(1).String() // output: "-1.4" -// +// NewFromFloat(545).RoundFloor(-2).String() // output: "500" +// NewFromFloat(-500).RoundFloor(-2).String() // output: "-500" +// NewFromFloat(1.1001).RoundFloor(2).String() // output: "1.1" +// NewFromFloat(-1.454).RoundFloor(1).String() // output: "-1.4" func (d Decimal) RoundFloor(places int32) Decimal { if d.exp >= -places { return d @@ -1156,11 +1144,10 @@ func (d Decimal) RoundFloor(places int32) Decimal { // // Example: // -// NewFromFloat(545).RoundUp(-2).String() // output: "600" -// NewFromFloat(500).RoundUp(-2).String() // output: "500" -// NewFromFloat(1.1001).RoundUp(2).String() // output: "1.11" -// NewFromFloat(-1.454).RoundUp(1).String() // output: "-1.4" -// +// NewFromFloat(545).RoundUp(-2).String() // output: "600" +// NewFromFloat(500).RoundUp(-2).String() // output: "500" +// NewFromFloat(1.1001).RoundUp(2).String() // output: "1.11" +// NewFromFloat(-1.454).RoundUp(1).String() // output: "-1.4" func (d Decimal) RoundUp(places int32) Decimal { if d.exp >= -places { return d @@ -1184,11 +1171,10 @@ func (d Decimal) RoundUp(places int32) Decimal { // // Example: // -// NewFromFloat(545).RoundDown(-2).String() // output: "500" -// NewFromFloat(-500).RoundDown(-2).String() // output: "-500" -// NewFromFloat(1.1001).RoundDown(2).String() // output: "1.1" -// NewFromFloat(-1.454).RoundDown(1).String() // output: "-1.5" -// +// NewFromFloat(545).RoundDown(-2).String() // output: "500" +// NewFromFloat(-500).RoundDown(-2).String() // output: "-500" +// NewFromFloat(1.1001).RoundDown(2).String() // output: "1.1" +// NewFromFloat(-1.454).RoundDown(1).String() // output: "-1.5" func (d Decimal) RoundDown(places int32) Decimal { if d.exp >= -places { return d @@ -1209,13 +1195,12 @@ func (d Decimal) RoundDown(places int32) Decimal { // // Examples: // -// NewFromFloat(5.45).RoundBank(1).String() // output: "5.4" -// NewFromFloat(545).RoundBank(-1).String() // output: "540" -// NewFromFloat(5.46).RoundBank(1).String() // output: "5.5" -// NewFromFloat(546).RoundBank(-1).String() // output: "550" -// NewFromFloat(5.55).RoundBank(1).String() // output: "5.6" -// NewFromFloat(555).RoundBank(-1).String() // output: "560" -// +// NewFromFloat(5.45).RoundBank(1).String() // output: "5.4" +// NewFromFloat(545).RoundBank(-1).String() // output: "540" +// NewFromFloat(5.46).RoundBank(1).String() // output: "5.5" +// NewFromFloat(546).RoundBank(-1).String() // output: "550" +// NewFromFloat(5.55).RoundBank(1).String() // output: "5.6" +// NewFromFloat(555).RoundBank(-1).String() // output: "560" func (d Decimal) RoundBank(places int32) Decimal { round := d.Round(places) @@ -1237,11 +1222,13 @@ func (d Decimal) RoundBank(places int32) Decimal { // interval. The amount payable for a cash transaction is rounded to the nearest // multiple of the minimum currency unit available. The following intervals are // available: 5, 10, 25, 50 and 100; any other number throws a panic. -// 5: 5 cent rounding 3.43 => 3.45 -// 10: 10 cent rounding 3.45 => 3.50 (5 gets rounded up) -// 25: 25 cent rounding 3.41 => 3.50 -// 50: 50 cent rounding 3.75 => 4.00 -// 100: 100 cent rounding 3.50 => 4.00 +// +// 5: 5 cent rounding 3.43 => 3.45 +// 10: 10 cent rounding 3.45 => 3.50 (5 gets rounded up) +// 25: 25 cent rounding 3.41 => 3.50 +// 50: 50 cent rounding 3.75 => 4.00 +// 100: 100 cent rounding 3.50 => 4.00 +// // For more details: https://en.wikipedia.org/wiki/Cash_rounding func (d Decimal) RoundCash(interval uint8) Decimal { var iVal *big.Int @@ -1310,8 +1297,7 @@ func (d Decimal) Ceil() Decimal { // // Example: // -// decimal.NewFromString("123.456").Truncate(2).String() // "123.45" -// +// decimal.NewFromString("123.456").Truncate(2).String() // "123.45" func (d Decimal) Truncate(precision int32) Decimal { d.ensureInitialized() if precision >= 0 && -precision > d.exp { @@ -1515,7 +1501,7 @@ func (d *Decimal) ensureInitialized() { // // To call this function with an array, you must do: // -// Min(arr[0], arr[1:]...) +// Min(arr[0], arr[1:]...) // // This makes it harder to accidentally call Min with 0 arguments. func Min(first Decimal, rest ...Decimal) Decimal { @@ -1532,7 +1518,7 @@ func Min(first Decimal, rest ...Decimal) Decimal { // // To call this function with an array, you must do: // -// Max(arr[0], arr[1:]...) +// Max(arr[0], arr[1:]...) // // This makes it harder to accidentally call Max with 0 arguments. func Max(first Decimal, rest ...Decimal) Decimal { diff --git a/test/tools/vendor/github.com/sirupsen/logrus/doc.go b/test/tools/vendor/github.com/sirupsen/logrus/doc.go index da67aba06de..51392be8f6e 100644 --- a/test/tools/vendor/github.com/sirupsen/logrus/doc.go +++ b/test/tools/vendor/github.com/sirupsen/logrus/doc.go @@ -1,25 +1,25 @@ /* Package logrus is a structured logger for Go, completely API compatible with the standard library logger. - The simplest way to use Logrus is simply the package-level exported logger: - package main + package main - import ( - log "github.com/sirupsen/logrus" - ) + import ( + log "github.com/sirupsen/logrus" + ) - func main() { - log.WithFields(log.Fields{ - "animal": "walrus", - "number": 1, - "size": 10, - }).Info("A walrus appears") - } + func main() { + log.WithFields(log.Fields{ + "animal": "walrus", + "number": 1, + "size": 10, + }).Info("A walrus appears") + } Output: - time="2015-09-07T08:48:33Z" level=info msg="A walrus appears" animal=walrus number=1 size=10 + + time="2015-09-07T08:48:33Z" level=info msg="A walrus appears" animal=walrus number=1 size=10 For a full guide visit https://github.com/sirupsen/logrus */ diff --git a/test/tools/vendor/github.com/sirupsen/logrus/formatter.go b/test/tools/vendor/github.com/sirupsen/logrus/formatter.go index 408883773eb..8c76155154e 100644 --- a/test/tools/vendor/github.com/sirupsen/logrus/formatter.go +++ b/test/tools/vendor/github.com/sirupsen/logrus/formatter.go @@ -30,12 +30,12 @@ type Formatter interface { // This is to not silently overwrite `time`, `msg`, `func` and `level` fields when // dumping it. If this code wasn't there doing: // -// logrus.WithField("level", 1).Info("hello") +// logrus.WithField("level", 1).Info("hello") // // Would just silently drop the user provided level. Instead with this code // it'll logged as: // -// {"level": "info", "fields.level": 1, "msg": "hello", "time": "..."} +// {"level": "info", "fields.level": 1, "msg": "hello", "time": "..."} // // It's not exported because it's still using Data in an opinionated way. It's to // avoid code duplication between the two default formatters. diff --git a/test/tools/vendor/github.com/sirupsen/logrus/logger.go b/test/tools/vendor/github.com/sirupsen/logrus/logger.go index 5ff0aef6d3f..df059412e93 100644 --- a/test/tools/vendor/github.com/sirupsen/logrus/logger.go +++ b/test/tools/vendor/github.com/sirupsen/logrus/logger.go @@ -76,12 +76,12 @@ func (mw *MutexWrap) Disable() { // `Out` and `Hooks` directly on the default logger instance. You can also just // instantiate your own: // -// var log = &logrus.Logger{ -// Out: os.Stderr, -// Formatter: new(logrus.TextFormatter), -// Hooks: make(logrus.LevelHooks), -// Level: logrus.DebugLevel, -// } +// var log = &logrus.Logger{ +// Out: os.Stderr, +// Formatter: new(logrus.TextFormatter), +// Hooks: make(logrus.LevelHooks), +// Level: logrus.DebugLevel, +// } // // It's recommended to make this a global instance called `log`. func New() *Logger { @@ -347,9 +347,9 @@ func (logger *Logger) Exit(code int) { logger.ExitFunc(code) } -//When file is opened with appending mode, it's safe to -//write concurrently to a file (within 4k message on Linux). -//In these cases user can choose to disable the lock. +// When file is opened with appending mode, it's safe to +// write concurrently to a file (within 4k message on Linux). +// In these cases user can choose to disable the lock. func (logger *Logger) SetNoLock() { logger.mu.Disable() } diff --git a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_appengine.go b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_appengine.go index 2403de98192..45de3e2b676 100644 --- a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_appengine.go +++ b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_appengine.go @@ -1,3 +1,4 @@ +//go:build appengine // +build appengine package logrus diff --git a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_bsd.go b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_bsd.go index 499789984d2..e3fa38b7100 100644 --- a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_bsd.go +++ b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_bsd.go @@ -1,3 +1,4 @@ +//go:build (darwin || dragonfly || freebsd || netbsd || openbsd) && !js // +build darwin dragonfly freebsd netbsd openbsd // +build !js diff --git a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_js.go b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_js.go index ebdae3ec626..9e951f1b42f 100644 --- a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_js.go +++ b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_js.go @@ -1,3 +1,4 @@ +//go:build js // +build js package logrus diff --git a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_no_terminal.go b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_no_terminal.go index 97af92c68ea..04232da1919 100644 --- a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_no_terminal.go +++ b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_no_terminal.go @@ -1,3 +1,4 @@ +//go:build js || nacl || plan9 // +build js nacl plan9 package logrus diff --git a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_notappengine.go b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_notappengine.go index 3293fb3caad..1b4a99e325e 100644 --- a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_notappengine.go +++ b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_notappengine.go @@ -1,3 +1,4 @@ +//go:build !appengine && !js && !windows && !nacl && !plan9 // +build !appengine,!js,!windows,!nacl,!plan9 package logrus diff --git a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_unix.go b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_unix.go index 04748b8515f..f3154b17fc5 100644 --- a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_unix.go +++ b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_unix.go @@ -1,3 +1,4 @@ +//go:build (linux || aix || zos) && !js // +build linux aix zos // +build !js diff --git a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_windows.go b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_windows.go index 2879eb50ea6..893c62410c5 100644 --- a/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_windows.go +++ b/test/tools/vendor/github.com/sirupsen/logrus/terminal_check_windows.go @@ -1,3 +1,4 @@ +//go:build !appengine && !js && windows // +build !appengine,!js,windows package logrus diff --git a/test/tools/vendor/github.com/spf13/pflag/flag.go b/test/tools/vendor/github.com/spf13/pflag/flag.go index 24a5036e95b..e368aaf1ced 100644 --- a/test/tools/vendor/github.com/spf13/pflag/flag.go +++ b/test/tools/vendor/github.com/spf13/pflag/flag.go @@ -27,23 +27,32 @@ unaffected. Define flags using flag.String(), Bool(), Int(), etc. This declares an integer flag, -flagname, stored in the pointer ip, with type *int. + var ip = flag.Int("flagname", 1234, "help message for flagname") + If you like, you can bind the flag to a variable using the Var() functions. + var flagvar int func init() { flag.IntVar(&flagvar, "flagname", 1234, "help message for flagname") } + Or you can create custom flags that satisfy the Value interface (with pointer receivers) and couple them to flag parsing by + flag.Var(&flagVal, "name", "help message for flagname") + For such flags, the default value is just the initial value of the variable. After all flags are defined, call + flag.Parse() + to parse the command line into the defined flags. Flags may then be used directly. If you're using the flags themselves, they are all pointers; if you bind to variables, they're values. + fmt.Println("ip has value ", *ip) fmt.Println("flagvar has value ", flagvar) @@ -54,22 +63,26 @@ The arguments are indexed from 0 through flag.NArg()-1. The pflag package also defines some new functions that are not in flag, that give one-letter shorthands for flags. You can use these by appending 'P' to the name of any function that defines a flag. + var ip = flag.IntP("flagname", "f", 1234, "help message") var flagvar bool func init() { flag.BoolVarP(&flagvar, "boolname", "b", true, "help message") } flag.VarP(&flagval, "varname", "v", "help message") + Shorthand letters can be used with single dashes on the command line. Boolean shorthand flags can be combined with other shorthand flags. Command line flag syntax: + --flag // boolean flags only --flag=x Unlike the flag package, a single dash before an option means something different than a double dash. Single dashes signify a series of shorthand letters for flags. All but the last shorthand letter must be boolean flags. + // boolean flags -f -abc @@ -927,9 +940,9 @@ func (f *FlagSet) usage() { } } -//--unknown (args will be empty) -//--unknown --next-flag ... (args will be --next-flag ...) -//--unknown arg ... (args will be arg ...) +// --unknown (args will be empty) +// --unknown --next-flag ... (args will be --next-flag ...) +// --unknown arg ... (args will be arg ...) func stripUnknownFlagValue(args []string) []string { if len(args) == 0 { //--unknown diff --git a/test/tools/vendor/github.com/spf13/pflag/string_slice.go b/test/tools/vendor/github.com/spf13/pflag/string_slice.go index 3cb2e69dba0..d421887e867 100644 --- a/test/tools/vendor/github.com/spf13/pflag/string_slice.go +++ b/test/tools/vendor/github.com/spf13/pflag/string_slice.go @@ -98,9 +98,12 @@ func (f *FlagSet) GetStringSlice(name string) ([]string, error) { // The argument p points to a []string variable in which to store the value of the flag. // Compared to StringArray flags, StringSlice flags take comma-separated value as arguments and split them accordingly. // For example: -// --ss="v1,v2" --ss="v3" +// +// --ss="v1,v2" --ss="v3" +// // will result in -// []string{"v1", "v2", "v3"} +// +// []string{"v1", "v2", "v3"} func (f *FlagSet) StringSliceVar(p *[]string, name string, value []string, usage string) { f.VarP(newStringSliceValue(value, p), name, "", usage) } @@ -114,9 +117,12 @@ func (f *FlagSet) StringSliceVarP(p *[]string, name, shorthand string, value []s // The argument p points to a []string variable in which to store the value of the flag. // Compared to StringArray flags, StringSlice flags take comma-separated value as arguments and split them accordingly. // For example: -// --ss="v1,v2" --ss="v3" +// +// --ss="v1,v2" --ss="v3" +// // will result in -// []string{"v1", "v2", "v3"} +// +// []string{"v1", "v2", "v3"} func StringSliceVar(p *[]string, name string, value []string, usage string) { CommandLine.VarP(newStringSliceValue(value, p), name, "", usage) } @@ -130,9 +136,12 @@ func StringSliceVarP(p *[]string, name, shorthand string, value []string, usage // The return value is the address of a []string variable that stores the value of the flag. // Compared to StringArray flags, StringSlice flags take comma-separated value as arguments and split them accordingly. // For example: -// --ss="v1,v2" --ss="v3" +// +// --ss="v1,v2" --ss="v3" +// // will result in -// []string{"v1", "v2", "v3"} +// +// []string{"v1", "v2", "v3"} func (f *FlagSet) StringSlice(name string, value []string, usage string) *[]string { p := []string{} f.StringSliceVarP(&p, name, "", value, usage) @@ -150,9 +159,12 @@ func (f *FlagSet) StringSliceP(name, shorthand string, value []string, usage str // The return value is the address of a []string variable that stores the value of the flag. // Compared to StringArray flags, StringSlice flags take comma-separated value as arguments and split them accordingly. // For example: -// --ss="v1,v2" --ss="v3" +// +// --ss="v1,v2" --ss="v3" +// // will result in -// []string{"v1", "v2", "v3"} +// +// []string{"v1", "v2", "v3"} func StringSlice(name string, value []string, usage string) *[]string { return CommandLine.StringSliceP(name, "", value, usage) } diff --git a/test/tools/vendor/gopkg.in/yaml.v2/apic.go b/test/tools/vendor/gopkg.in/yaml.v2/apic.go index acf71402cf3..fb2821e1e66 100644 --- a/test/tools/vendor/gopkg.in/yaml.v2/apic.go +++ b/test/tools/vendor/gopkg.in/yaml.v2/apic.go @@ -143,7 +143,7 @@ func yaml_emitter_set_canonical(emitter *yaml_emitter_t, canonical bool) { emitter.canonical = canonical } -//// Set the indentation increment. +// // Set the indentation increment. func yaml_emitter_set_indent(emitter *yaml_emitter_t, indent int) { if indent < 2 || indent > 9 { indent = 2 diff --git a/test/tools/vendor/gopkg.in/yaml.v2/emitterc.go b/test/tools/vendor/gopkg.in/yaml.v2/emitterc.go index a1c2cc52627..638a268c79b 100644 --- a/test/tools/vendor/gopkg.in/yaml.v2/emitterc.go +++ b/test/tools/vendor/gopkg.in/yaml.v2/emitterc.go @@ -130,10 +130,9 @@ func yaml_emitter_emit(emitter *yaml_emitter_t, event *yaml_event_t) bool { // Check if we need to accumulate more events before emitting. // // We accumulate extra -// - 1 event for DOCUMENT-START -// - 2 events for SEQUENCE-START -// - 3 events for MAPPING-START -// +// - 1 event for DOCUMENT-START +// - 2 events for SEQUENCE-START +// - 3 events for MAPPING-START func yaml_emitter_need_more_events(emitter *yaml_emitter_t) bool { if emitter.events_head == len(emitter.events) { return true diff --git a/test/tools/vendor/gopkg.in/yaml.v2/parserc.go b/test/tools/vendor/gopkg.in/yaml.v2/parserc.go index 81d05dfe573..2883e5c58fa 100644 --- a/test/tools/vendor/gopkg.in/yaml.v2/parserc.go +++ b/test/tools/vendor/gopkg.in/yaml.v2/parserc.go @@ -170,7 +170,8 @@ func yaml_parser_state_machine(parser *yaml_parser_t, event *yaml_event_t) bool // Parse the production: // stream ::= STREAM-START implicit_document? explicit_document* STREAM-END -// ************ +// +// ************ func yaml_parser_parse_stream_start(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -192,9 +193,12 @@ func yaml_parser_parse_stream_start(parser *yaml_parser_t, event *yaml_event_t) // Parse the productions: // implicit_document ::= block_node DOCUMENT-END* -// * +// +// * +// // explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* -// ************************* +// +// ************************* func yaml_parser_parse_document_start(parser *yaml_parser_t, event *yaml_event_t, implicit bool) bool { token := peek_token(parser) @@ -277,8 +281,8 @@ func yaml_parser_parse_document_start(parser *yaml_parser_t, event *yaml_event_t // Parse the productions: // explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* -// *********** // +// *********** func yaml_parser_parse_document_content(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -299,9 +303,10 @@ func yaml_parser_parse_document_content(parser *yaml_parser_t, event *yaml_event // Parse the productions: // implicit_document ::= block_node DOCUMENT-END* -// ************* -// explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* // +// ************* +// +// explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* func yaml_parser_parse_document_end(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -332,30 +337,41 @@ func yaml_parser_parse_document_end(parser *yaml_parser_t, event *yaml_event_t) // Parse the productions: // block_node_or_indentless_sequence ::= -// ALIAS -// ***** -// | properties (block_content | indentless_block_sequence)? -// ********** * -// | block_content | indentless_block_sequence -// * +// +// ALIAS +// ***** +// | properties (block_content | indentless_block_sequence)? +// ********** * +// | block_content | indentless_block_sequence +// * +// // block_node ::= ALIAS -// ***** -// | properties block_content? -// ********** * -// | block_content -// * +// +// ***** +// | properties block_content? +// ********** * +// | block_content +// * +// // flow_node ::= ALIAS -// ***** -// | properties flow_content? -// ********** * -// | flow_content -// * +// +// ***** +// | properties flow_content? +// ********** * +// | flow_content +// * +// // properties ::= TAG ANCHOR? | ANCHOR TAG? -// ************************* +// +// ************************* +// // block_content ::= block_collection | flow_collection | SCALAR -// ****** +// +// ****** +// // flow_content ::= flow_collection | SCALAR -// ****** +// +// ****** func yaml_parser_parse_node(parser *yaml_parser_t, event *yaml_event_t, block, indentless_sequence bool) bool { //defer trace("yaml_parser_parse_node", "block:", block, "indentless_sequence:", indentless_sequence)() @@ -574,8 +590,8 @@ func yaml_parser_parse_node(parser *yaml_parser_t, event *yaml_event_t, block, i // Parse the productions: // block_sequence ::= BLOCK-SEQUENCE-START (BLOCK-ENTRY block_node?)* BLOCK-END -// ******************** *********** * ********* // +// ******************** *********** * ********* func yaml_parser_parse_block_sequence_entry(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -627,7 +643,8 @@ func yaml_parser_parse_block_sequence_entry(parser *yaml_parser_t, event *yaml_e // Parse the productions: // indentless_sequence ::= (BLOCK-ENTRY block_node?)+ -// *********** * +// +// *********** * func yaml_parser_parse_indentless_sequence_entry(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -664,14 +681,14 @@ func yaml_parser_parse_indentless_sequence_entry(parser *yaml_parser_t, event *y // Parse the productions: // block_mapping ::= BLOCK-MAPPING_START -// ******************* -// ((KEY block_node_or_indentless_sequence?)? -// *** * -// (VALUE block_node_or_indentless_sequence?)?)* // -// BLOCK-END -// ********* +// ******************* +// ((KEY block_node_or_indentless_sequence?)? +// *** * +// (VALUE block_node_or_indentless_sequence?)?)* // +// BLOCK-END +// ********* func yaml_parser_parse_block_mapping_key(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -723,13 +740,11 @@ func yaml_parser_parse_block_mapping_key(parser *yaml_parser_t, event *yaml_even // Parse the productions: // block_mapping ::= BLOCK-MAPPING_START // -// ((KEY block_node_or_indentless_sequence?)? -// -// (VALUE block_node_or_indentless_sequence?)?)* -// ***** * -// BLOCK-END -// +// ((KEY block_node_or_indentless_sequence?)? // +// (VALUE block_node_or_indentless_sequence?)?)* +// ***** * +// BLOCK-END func yaml_parser_parse_block_mapping_value(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -757,16 +772,18 @@ func yaml_parser_parse_block_mapping_value(parser *yaml_parser_t, event *yaml_ev // Parse the productions: // flow_sequence ::= FLOW-SEQUENCE-START -// ******************* -// (flow_sequence_entry FLOW-ENTRY)* -// * ********** -// flow_sequence_entry? -// * -// FLOW-SEQUENCE-END -// ***************** +// +// ******************* +// (flow_sequence_entry FLOW-ENTRY)* +// * ********** +// flow_sequence_entry? +// * +// FLOW-SEQUENCE-END +// ***************** +// // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * // +// * func yaml_parser_parse_flow_sequence_entry(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -825,11 +842,10 @@ func yaml_parser_parse_flow_sequence_entry(parser *yaml_parser_t, event *yaml_ev return true } -// // Parse the productions: // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// *** * // +// *** * func yaml_parser_parse_flow_sequence_entry_mapping_key(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -849,8 +865,8 @@ func yaml_parser_parse_flow_sequence_entry_mapping_key(parser *yaml_parser_t, ev // Parse the productions: // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// ***** * // +// ***** * func yaml_parser_parse_flow_sequence_entry_mapping_value(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -873,8 +889,8 @@ func yaml_parser_parse_flow_sequence_entry_mapping_value(parser *yaml_parser_t, // Parse the productions: // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * // +// * func yaml_parser_parse_flow_sequence_entry_mapping_end(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -891,16 +907,17 @@ func yaml_parser_parse_flow_sequence_entry_mapping_end(parser *yaml_parser_t, ev // Parse the productions: // flow_mapping ::= FLOW-MAPPING-START -// ****************** -// (flow_mapping_entry FLOW-ENTRY)* -// * ********** -// flow_mapping_entry? -// ****************** -// FLOW-MAPPING-END -// **************** -// flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * *** * // +// ****************** +// (flow_mapping_entry FLOW-ENTRY)* +// * ********** +// flow_mapping_entry? +// ****************** +// FLOW-MAPPING-END +// **************** +// +// flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? +// - *** * func yaml_parser_parse_flow_mapping_key(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -965,8 +982,7 @@ func yaml_parser_parse_flow_mapping_key(parser *yaml_parser_t, event *yaml_event // Parse the productions: // flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * ***** * -// +// - ***** * func yaml_parser_parse_flow_mapping_value(parser *yaml_parser_t, event *yaml_event_t, empty bool) bool { token := peek_token(parser) if token == nil { diff --git a/test/tools/vendor/gopkg.in/yaml.v2/readerc.go b/test/tools/vendor/gopkg.in/yaml.v2/readerc.go index 7c1f5fac3db..b0c436c4a84 100644 --- a/test/tools/vendor/gopkg.in/yaml.v2/readerc.go +++ b/test/tools/vendor/gopkg.in/yaml.v2/readerc.go @@ -95,7 +95,7 @@ func yaml_parser_update_buffer(parser *yaml_parser_t, length int) bool { // [Go] This function was changed to guarantee the requested length size at EOF. // The fact we need to do this is pretty awful, but the description above implies - // for that to be the case, and there are tests + // for that to be the case, and there are tests // If the EOF flag is set and the raw buffer is empty, do nothing. if parser.eof && parser.raw_buffer_pos == len(parser.raw_buffer) { diff --git a/test/tools/vendor/gopkg.in/yaml.v2/resolve.go b/test/tools/vendor/gopkg.in/yaml.v2/resolve.go index 4120e0c9160..e29c364b339 100644 --- a/test/tools/vendor/gopkg.in/yaml.v2/resolve.go +++ b/test/tools/vendor/gopkg.in/yaml.v2/resolve.go @@ -180,7 +180,7 @@ func resolve(tag string, in string) (rtag string, out interface{}) { return yaml_INT_TAG, uintv } } else if strings.HasPrefix(plain, "-0b") { - intv, err := strconv.ParseInt("-" + plain[3:], 2, 64) + intv, err := strconv.ParseInt("-"+plain[3:], 2, 64) if err == nil { if true || intv == int64(int(intv)) { return yaml_INT_TAG, int(intv) diff --git a/test/tools/vendor/gopkg.in/yaml.v2/scannerc.go b/test/tools/vendor/gopkg.in/yaml.v2/scannerc.go index 0b9bb6030a0..d634dca4b04 100644 --- a/test/tools/vendor/gopkg.in/yaml.v2/scannerc.go +++ b/test/tools/vendor/gopkg.in/yaml.v2/scannerc.go @@ -1500,11 +1500,11 @@ func yaml_parser_scan_to_next_token(parser *yaml_parser_t) bool { // Scan a YAML-DIRECTIVE or TAG-DIRECTIVE token. // // Scope: -// %YAML 1.1 # a comment \n -// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -// %TAG !yaml! tag:yaml.org,2002: \n -// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ // +// %YAML 1.1 # a comment \n +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +// %TAG !yaml! tag:yaml.org,2002: \n +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ func yaml_parser_scan_directive(parser *yaml_parser_t, token *yaml_token_t) bool { // Eat '%'. start_mark := parser.mark @@ -1601,11 +1601,11 @@ func yaml_parser_scan_directive(parser *yaml_parser_t, token *yaml_token_t) bool // Scan the directive name. // // Scope: -// %YAML 1.1 # a comment \n -// ^^^^ -// %TAG !yaml! tag:yaml.org,2002: \n -// ^^^ // +// %YAML 1.1 # a comment \n +// ^^^^ +// %TAG !yaml! tag:yaml.org,2002: \n +// ^^^ func yaml_parser_scan_directive_name(parser *yaml_parser_t, start_mark yaml_mark_t, name *[]byte) bool { // Consume the directive name. if parser.unread < 1 && !yaml_parser_update_buffer(parser, 1) { @@ -1640,8 +1640,9 @@ func yaml_parser_scan_directive_name(parser *yaml_parser_t, start_mark yaml_mark // Scan the value of VERSION-DIRECTIVE. // // Scope: -// %YAML 1.1 # a comment \n -// ^^^^^^ +// +// %YAML 1.1 # a comment \n +// ^^^^^^ func yaml_parser_scan_version_directive_value(parser *yaml_parser_t, start_mark yaml_mark_t, major, minor *int8) bool { // Eat whitespaces. if parser.unread < 1 && !yaml_parser_update_buffer(parser, 1) { @@ -1679,10 +1680,11 @@ const max_number_length = 2 // Scan the version number of VERSION-DIRECTIVE. // // Scope: -// %YAML 1.1 # a comment \n -// ^ -// %YAML 1.1 # a comment \n -// ^ +// +// %YAML 1.1 # a comment \n +// ^ +// %YAML 1.1 # a comment \n +// ^ func yaml_parser_scan_version_directive_number(parser *yaml_parser_t, start_mark yaml_mark_t, number *int8) bool { // Repeat while the next character is digit. @@ -1716,9 +1718,9 @@ func yaml_parser_scan_version_directive_number(parser *yaml_parser_t, start_mark // Scan the value of a TAG-DIRECTIVE token. // // Scope: -// %TAG !yaml! tag:yaml.org,2002: \n -// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ // +// %TAG !yaml! tag:yaml.org,2002: \n +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ func yaml_parser_scan_tag_directive_value(parser *yaml_parser_t, start_mark yaml_mark_t, handle, prefix *[]byte) bool { var handle_value, prefix_value []byte diff --git a/test/tools/vendor/gopkg.in/yaml.v2/sorter.go b/test/tools/vendor/gopkg.in/yaml.v2/sorter.go index 4c45e660a8f..2edd734055f 100644 --- a/test/tools/vendor/gopkg.in/yaml.v2/sorter.go +++ b/test/tools/vendor/gopkg.in/yaml.v2/sorter.go @@ -52,7 +52,7 @@ func (l keyList) Less(i, j int) bool { var ai, bi int var an, bn int64 if ar[i] == '0' || br[i] == '0' { - for j := i-1; j >= 0 && unicode.IsDigit(ar[j]); j-- { + for j := i - 1; j >= 0 && unicode.IsDigit(ar[j]); j-- { if ar[j] != '0' { an = 1 bn = 1 diff --git a/test/tools/vendor/gopkg.in/yaml.v2/yaml.go b/test/tools/vendor/gopkg.in/yaml.v2/yaml.go index 30813884c06..03756f6bbbc 100644 --- a/test/tools/vendor/gopkg.in/yaml.v2/yaml.go +++ b/test/tools/vendor/gopkg.in/yaml.v2/yaml.go @@ -2,8 +2,7 @@ // // Source code and other details for the project are available at GitHub: // -// https://github.com/go-yaml/yaml -// +// https://github.com/go-yaml/yaml package yaml import ( @@ -67,16 +66,15 @@ type Marshaler interface { // // For example: // -// type T struct { -// F int `yaml:"a,omitempty"` -// B int -// } -// var t T -// yaml.Unmarshal([]byte("a: 1\nb: 2"), &t) +// type T struct { +// F int `yaml:"a,omitempty"` +// B int +// } +// var t T +// yaml.Unmarshal([]byte("a: 1\nb: 2"), &t) // // See the documentation of Marshal for the format of tags and a list of // supported tag options. -// func Unmarshal(in []byte, out interface{}) (err error) { return unmarshal(in, out, false) } @@ -166,36 +164,35 @@ func unmarshal(in []byte, out interface{}, strict bool) (err error) { // // The field tag format accepted is: // -// `(...) yaml:"[][,[,]]" (...)` +// `(...) yaml:"[][,[,]]" (...)` // // The following flags are currently supported: // -// omitempty Only include the field if it's not set to the zero -// value for the type or to empty slices or maps. -// Zero valued structs will be omitted if all their public -// fields are zero, unless they implement an IsZero -// method (see the IsZeroer interface type), in which -// case the field will be excluded if IsZero returns true. +// omitempty Only include the field if it's not set to the zero +// value for the type or to empty slices or maps. +// Zero valued structs will be omitted if all their public +// fields are zero, unless they implement an IsZero +// method (see the IsZeroer interface type), in which +// case the field will be excluded if IsZero returns true. // -// flow Marshal using a flow style (useful for structs, -// sequences and maps). +// flow Marshal using a flow style (useful for structs, +// sequences and maps). // -// inline Inline the field, which must be a struct or a map, -// causing all of its fields or keys to be processed as if -// they were part of the outer struct. For maps, keys must -// not conflict with the yaml keys of other struct fields. +// inline Inline the field, which must be a struct or a map, +// causing all of its fields or keys to be processed as if +// they were part of the outer struct. For maps, keys must +// not conflict with the yaml keys of other struct fields. // // In addition, if the key is "-", the field is ignored. // // For example: // -// type T struct { -// F int `yaml:"a,omitempty"` -// B int -// } -// yaml.Marshal(&T{B: 2}) // Returns "b: 2\n" -// yaml.Marshal(&T{F: 1}} // Returns "a: 1\nb: 0\n" -// +// type T struct { +// F int `yaml:"a,omitempty"` +// B int +// } +// yaml.Marshal(&T{B: 2}) // Returns "b: 2\n" +// yaml.Marshal(&T{F: 1}} // Returns "a: 1\nb: 0\n" func Marshal(in interface{}) (out []byte, err error) { defer handleErr(&err) e := newEncoder() diff --git a/test/tools/vendor/gopkg.in/yaml.v2/yamlh.go b/test/tools/vendor/gopkg.in/yaml.v2/yamlh.go index f6a9c8e34b1..640f9d95de9 100644 --- a/test/tools/vendor/gopkg.in/yaml.v2/yamlh.go +++ b/test/tools/vendor/gopkg.in/yaml.v2/yamlh.go @@ -408,7 +408,9 @@ type yaml_document_t struct { // The number of written bytes should be set to the size_read variable. // // [in,out] data A pointer to an application data specified by -// yaml_parser_set_input(). +// +// yaml_parser_set_input(). +// // [out] buffer The buffer to write the data from the source. // [in] size The size of the buffer. // [out] size_read The actual number of bytes read from the source. @@ -604,13 +606,14 @@ type yaml_parser_t struct { // @a buffer to the output. // // @param[in,out] data A pointer to an application data specified by -// yaml_emitter_set_output(). +// +// yaml_emitter_set_output(). +// // @param[in] buffer The buffer with bytes to be written. // @param[in] size The size of the buffer. // // @returns On success, the handler should return @c 1. If the handler failed, // the returned value should be @c 0. -// type yaml_write_handler_t func(emitter *yaml_emitter_t, buffer []byte) error type yaml_emitter_state_t int diff --git a/test/tools/vendor/gopkg.in/yaml.v3/apic.go b/test/tools/vendor/gopkg.in/yaml.v3/apic.go index ae7d049f182..05fd305da16 100644 --- a/test/tools/vendor/gopkg.in/yaml.v3/apic.go +++ b/test/tools/vendor/gopkg.in/yaml.v3/apic.go @@ -1,17 +1,17 @@ -// +// // Copyright (c) 2011-2019 Canonical Ltd // Copyright (c) 2006-2010 Kirill Simonov -// +// // Permission is hereby granted, free of charge, to any person obtaining a copy of // this software and associated documentation files (the "Software"), to deal in // the Software without restriction, including without limitation the rights to // use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies // of the Software, and to permit persons to whom the Software is furnished to do // so, subject to the following conditions: -// +// // The above copyright notice and this permission notice shall be included in all // copies or substantial portions of the Software. -// +// // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE diff --git a/test/tools/vendor/gopkg.in/yaml.v3/emitterc.go b/test/tools/vendor/gopkg.in/yaml.v3/emitterc.go index 0f47c9ca8ad..dde20e5079d 100644 --- a/test/tools/vendor/gopkg.in/yaml.v3/emitterc.go +++ b/test/tools/vendor/gopkg.in/yaml.v3/emitterc.go @@ -162,10 +162,9 @@ func yaml_emitter_emit(emitter *yaml_emitter_t, event *yaml_event_t) bool { // Check if we need to accumulate more events before emitting. // // We accumulate extra -// - 1 event for DOCUMENT-START -// - 2 events for SEQUENCE-START -// - 3 events for MAPPING-START -// +// - 1 event for DOCUMENT-START +// - 2 events for SEQUENCE-START +// - 3 events for MAPPING-START func yaml_emitter_need_more_events(emitter *yaml_emitter_t) bool { if emitter.events_head == len(emitter.events) { return true @@ -241,7 +240,7 @@ func yaml_emitter_increase_indent(emitter *yaml_emitter_t, flow, indentless bool emitter.indent += 2 } else { // Everything else aligns to the chosen indentation. - emitter.indent = emitter.best_indent*((emitter.indent+emitter.best_indent)/emitter.best_indent) + emitter.indent = emitter.best_indent * ((emitter.indent + emitter.best_indent) / emitter.best_indent) } } return true diff --git a/test/tools/vendor/gopkg.in/yaml.v3/parserc.go b/test/tools/vendor/gopkg.in/yaml.v3/parserc.go index 268558a0d63..25fe823637a 100644 --- a/test/tools/vendor/gopkg.in/yaml.v3/parserc.go +++ b/test/tools/vendor/gopkg.in/yaml.v3/parserc.go @@ -227,7 +227,8 @@ func yaml_parser_state_machine(parser *yaml_parser_t, event *yaml_event_t) bool // Parse the production: // stream ::= STREAM-START implicit_document? explicit_document* STREAM-END -// ************ +// +// ************ func yaml_parser_parse_stream_start(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -249,9 +250,12 @@ func yaml_parser_parse_stream_start(parser *yaml_parser_t, event *yaml_event_t) // Parse the productions: // implicit_document ::= block_node DOCUMENT-END* -// * +// +// * +// // explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* -// ************************* +// +// ************************* func yaml_parser_parse_document_start(parser *yaml_parser_t, event *yaml_event_t, implicit bool) bool { token := peek_token(parser) @@ -356,8 +360,8 @@ func yaml_parser_parse_document_start(parser *yaml_parser_t, event *yaml_event_t // Parse the productions: // explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* -// *********** // +// *********** func yaml_parser_parse_document_content(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -379,9 +383,10 @@ func yaml_parser_parse_document_content(parser *yaml_parser_t, event *yaml_event // Parse the productions: // implicit_document ::= block_node DOCUMENT-END* -// ************* -// explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* // +// ************* +// +// explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* func yaml_parser_parse_document_end(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -428,30 +433,41 @@ func yaml_parser_set_event_comments(parser *yaml_parser_t, event *yaml_event_t) // Parse the productions: // block_node_or_indentless_sequence ::= -// ALIAS -// ***** -// | properties (block_content | indentless_block_sequence)? -// ********** * -// | block_content | indentless_block_sequence -// * +// +// ALIAS +// ***** +// | properties (block_content | indentless_block_sequence)? +// ********** * +// | block_content | indentless_block_sequence +// * +// // block_node ::= ALIAS -// ***** -// | properties block_content? -// ********** * -// | block_content -// * +// +// ***** +// | properties block_content? +// ********** * +// | block_content +// * +// // flow_node ::= ALIAS -// ***** -// | properties flow_content? -// ********** * -// | flow_content -// * +// +// ***** +// | properties flow_content? +// ********** * +// | flow_content +// * +// // properties ::= TAG ANCHOR? | ANCHOR TAG? -// ************************* +// +// ************************* +// // block_content ::= block_collection | flow_collection | SCALAR -// ****** +// +// ****** +// // flow_content ::= flow_collection | SCALAR -// ****** +// +// ****** func yaml_parser_parse_node(parser *yaml_parser_t, event *yaml_event_t, block, indentless_sequence bool) bool { //defer trace("yaml_parser_parse_node", "block:", block, "indentless_sequence:", indentless_sequence)() @@ -682,8 +698,8 @@ func yaml_parser_parse_node(parser *yaml_parser_t, event *yaml_event_t, block, i // Parse the productions: // block_sequence ::= BLOCK-SEQUENCE-START (BLOCK-ENTRY block_node?)* BLOCK-END -// ******************** *********** * ********* // +// ******************** *********** * ********* func yaml_parser_parse_block_sequence_entry(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -740,7 +756,8 @@ func yaml_parser_parse_block_sequence_entry(parser *yaml_parser_t, event *yaml_e // Parse the productions: // indentless_sequence ::= (BLOCK-ENTRY block_node?)+ -// *********** * +// +// *********** * func yaml_parser_parse_indentless_sequence_entry(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -805,14 +822,14 @@ func yaml_parser_split_stem_comment(parser *yaml_parser_t, stem_len int) { // Parse the productions: // block_mapping ::= BLOCK-MAPPING_START -// ******************* -// ((KEY block_node_or_indentless_sequence?)? -// *** * -// (VALUE block_node_or_indentless_sequence?)?)* // -// BLOCK-END -// ********* +// ******************* +// ((KEY block_node_or_indentless_sequence?)? +// *** * +// (VALUE block_node_or_indentless_sequence?)?)* // +// BLOCK-END +// ********* func yaml_parser_parse_block_mapping_key(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -881,13 +898,11 @@ func yaml_parser_parse_block_mapping_key(parser *yaml_parser_t, event *yaml_even // Parse the productions: // block_mapping ::= BLOCK-MAPPING_START // -// ((KEY block_node_or_indentless_sequence?)? -// -// (VALUE block_node_or_indentless_sequence?)?)* -// ***** * -// BLOCK-END -// +// ((KEY block_node_or_indentless_sequence?)? // +// (VALUE block_node_or_indentless_sequence?)?)* +// ***** * +// BLOCK-END func yaml_parser_parse_block_mapping_value(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -915,16 +930,18 @@ func yaml_parser_parse_block_mapping_value(parser *yaml_parser_t, event *yaml_ev // Parse the productions: // flow_sequence ::= FLOW-SEQUENCE-START -// ******************* -// (flow_sequence_entry FLOW-ENTRY)* -// * ********** -// flow_sequence_entry? -// * -// FLOW-SEQUENCE-END -// ***************** +// +// ******************* +// (flow_sequence_entry FLOW-ENTRY)* +// * ********** +// flow_sequence_entry? +// * +// FLOW-SEQUENCE-END +// ***************** +// // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * // +// * func yaml_parser_parse_flow_sequence_entry(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -987,11 +1004,10 @@ func yaml_parser_parse_flow_sequence_entry(parser *yaml_parser_t, event *yaml_ev return true } -// // Parse the productions: // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// *** * // +// *** * func yaml_parser_parse_flow_sequence_entry_mapping_key(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -1011,8 +1027,8 @@ func yaml_parser_parse_flow_sequence_entry_mapping_key(parser *yaml_parser_t, ev // Parse the productions: // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// ***** * // +// ***** * func yaml_parser_parse_flow_sequence_entry_mapping_value(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -1035,8 +1051,8 @@ func yaml_parser_parse_flow_sequence_entry_mapping_value(parser *yaml_parser_t, // Parse the productions: // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * // +// * func yaml_parser_parse_flow_sequence_entry_mapping_end(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -1053,16 +1069,17 @@ func yaml_parser_parse_flow_sequence_entry_mapping_end(parser *yaml_parser_t, ev // Parse the productions: // flow_mapping ::= FLOW-MAPPING-START -// ****************** -// (flow_mapping_entry FLOW-ENTRY)* -// * ********** -// flow_mapping_entry? -// ****************** -// FLOW-MAPPING-END -// **************** -// flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * *** * // +// ****************** +// (flow_mapping_entry FLOW-ENTRY)* +// * ********** +// flow_mapping_entry? +// ****************** +// FLOW-MAPPING-END +// **************** +// +// flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? +// - *** * func yaml_parser_parse_flow_mapping_key(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -1128,8 +1145,7 @@ func yaml_parser_parse_flow_mapping_key(parser *yaml_parser_t, event *yaml_event // Parse the productions: // flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * ***** * -// +// - ***** * func yaml_parser_parse_flow_mapping_value(parser *yaml_parser_t, event *yaml_event_t, empty bool) bool { token := peek_token(parser) if token == nil { diff --git a/test/tools/vendor/gopkg.in/yaml.v3/readerc.go b/test/tools/vendor/gopkg.in/yaml.v3/readerc.go index b7de0a89c46..56af245366f 100644 --- a/test/tools/vendor/gopkg.in/yaml.v3/readerc.go +++ b/test/tools/vendor/gopkg.in/yaml.v3/readerc.go @@ -1,17 +1,17 @@ -// +// // Copyright (c) 2011-2019 Canonical Ltd // Copyright (c) 2006-2010 Kirill Simonov -// +// // Permission is hereby granted, free of charge, to any person obtaining a copy of // this software and associated documentation files (the "Software"), to deal in // the Software without restriction, including without limitation the rights to // use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies // of the Software, and to permit persons to whom the Software is furnished to do // so, subject to the following conditions: -// +// // The above copyright notice and this permission notice shall be included in all // copies or substantial portions of the Software. -// +// // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE diff --git a/test/tools/vendor/gopkg.in/yaml.v3/scannerc.go b/test/tools/vendor/gopkg.in/yaml.v3/scannerc.go index ca0070108f4..30b1f08920a 100644 --- a/test/tools/vendor/gopkg.in/yaml.v3/scannerc.go +++ b/test/tools/vendor/gopkg.in/yaml.v3/scannerc.go @@ -1614,11 +1614,11 @@ func yaml_parser_scan_to_next_token(parser *yaml_parser_t) bool { // Scan a YAML-DIRECTIVE or TAG-DIRECTIVE token. // // Scope: -// %YAML 1.1 # a comment \n -// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -// %TAG !yaml! tag:yaml.org,2002: \n -// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ // +// %YAML 1.1 # a comment \n +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +// %TAG !yaml! tag:yaml.org,2002: \n +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ func yaml_parser_scan_directive(parser *yaml_parser_t, token *yaml_token_t) bool { // Eat '%'. start_mark := parser.mark @@ -1719,11 +1719,11 @@ func yaml_parser_scan_directive(parser *yaml_parser_t, token *yaml_token_t) bool // Scan the directive name. // // Scope: -// %YAML 1.1 # a comment \n -// ^^^^ -// %TAG !yaml! tag:yaml.org,2002: \n -// ^^^ // +// %YAML 1.1 # a comment \n +// ^^^^ +// %TAG !yaml! tag:yaml.org,2002: \n +// ^^^ func yaml_parser_scan_directive_name(parser *yaml_parser_t, start_mark yaml_mark_t, name *[]byte) bool { // Consume the directive name. if parser.unread < 1 && !yaml_parser_update_buffer(parser, 1) { @@ -1758,8 +1758,9 @@ func yaml_parser_scan_directive_name(parser *yaml_parser_t, start_mark yaml_mark // Scan the value of VERSION-DIRECTIVE. // // Scope: -// %YAML 1.1 # a comment \n -// ^^^^^^ +// +// %YAML 1.1 # a comment \n +// ^^^^^^ func yaml_parser_scan_version_directive_value(parser *yaml_parser_t, start_mark yaml_mark_t, major, minor *int8) bool { // Eat whitespaces. if parser.unread < 1 && !yaml_parser_update_buffer(parser, 1) { @@ -1797,10 +1798,11 @@ const max_number_length = 2 // Scan the version number of VERSION-DIRECTIVE. // // Scope: -// %YAML 1.1 # a comment \n -// ^ -// %YAML 1.1 # a comment \n -// ^ +// +// %YAML 1.1 # a comment \n +// ^ +// %YAML 1.1 # a comment \n +// ^ func yaml_parser_scan_version_directive_number(parser *yaml_parser_t, start_mark yaml_mark_t, number *int8) bool { // Repeat while the next character is digit. @@ -1834,9 +1836,9 @@ func yaml_parser_scan_version_directive_number(parser *yaml_parser_t, start_mark // Scan the value of a TAG-DIRECTIVE token. // // Scope: -// %TAG !yaml! tag:yaml.org,2002: \n -// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ // +// %TAG !yaml! tag:yaml.org,2002: \n +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ func yaml_parser_scan_tag_directive_value(parser *yaml_parser_t, start_mark yaml_mark_t, handle, prefix *[]byte) bool { var handle_value, prefix_value []byte @@ -2847,7 +2849,7 @@ func yaml_parser_scan_line_comment(parser *yaml_parser_t, token_mark yaml_mark_t continue } if parser.buffer[parser.buffer_pos+peek] == '#' { - seen := parser.mark.index+peek + seen := parser.mark.index + peek for { if parser.unread < 1 && !yaml_parser_update_buffer(parser, 1) { return false @@ -2876,7 +2878,7 @@ func yaml_parser_scan_line_comment(parser *yaml_parser_t, token_mark yaml_mark_t parser.comments = append(parser.comments, yaml_comment_t{ token_mark: token_mark, start_mark: start_mark, - line: text, + line: text, }) } return true @@ -2910,7 +2912,7 @@ func yaml_parser_scan_comments(parser *yaml_parser_t, scan_mark yaml_mark_t) boo // the foot is the line below it. var foot_line = -1 if scan_mark.line > 0 { - foot_line = parser.mark.line-parser.newlines+1 + foot_line = parser.mark.line - parser.newlines + 1 if parser.newlines == 0 && parser.mark.column > 1 { foot_line++ } @@ -2996,7 +2998,7 @@ func yaml_parser_scan_comments(parser *yaml_parser_t, scan_mark yaml_mark_t) boo recent_empty = false // Consume until after the consumed comment line. - seen := parser.mark.index+peek + seen := parser.mark.index + peek for { if parser.unread < 1 && !yaml_parser_update_buffer(parser, 1) { return false diff --git a/test/tools/vendor/gopkg.in/yaml.v3/writerc.go b/test/tools/vendor/gopkg.in/yaml.v3/writerc.go index b8a116bf9a2..266d0b092c0 100644 --- a/test/tools/vendor/gopkg.in/yaml.v3/writerc.go +++ b/test/tools/vendor/gopkg.in/yaml.v3/writerc.go @@ -1,17 +1,17 @@ -// +// // Copyright (c) 2011-2019 Canonical Ltd // Copyright (c) 2006-2010 Kirill Simonov -// +// // Permission is hereby granted, free of charge, to any person obtaining a copy of // this software and associated documentation files (the "Software"), to deal in // the Software without restriction, including without limitation the rights to // use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies // of the Software, and to permit persons to whom the Software is furnished to do // so, subject to the following conditions: -// +// // The above copyright notice and this permission notice shall be included in all // copies or substantial portions of the Software. -// +// // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE diff --git a/test/tools/vendor/gopkg.in/yaml.v3/yaml.go b/test/tools/vendor/gopkg.in/yaml.v3/yaml.go index 8cec6da48d3..f0bedf3d63c 100644 --- a/test/tools/vendor/gopkg.in/yaml.v3/yaml.go +++ b/test/tools/vendor/gopkg.in/yaml.v3/yaml.go @@ -17,8 +17,7 @@ // // Source code and other details for the project are available at GitHub: // -// https://github.com/go-yaml/yaml -// +// https://github.com/go-yaml/yaml package yaml import ( @@ -75,16 +74,15 @@ type Marshaler interface { // // For example: // -// type T struct { -// F int `yaml:"a,omitempty"` -// B int -// } -// var t T -// yaml.Unmarshal([]byte("a: 1\nb: 2"), &t) +// type T struct { +// F int `yaml:"a,omitempty"` +// B int +// } +// var t T +// yaml.Unmarshal([]byte("a: 1\nb: 2"), &t) // // See the documentation of Marshal for the format of tags and a list of // supported tag options. -// func Unmarshal(in []byte, out interface{}) (err error) { return unmarshal(in, out, false) } @@ -185,36 +183,35 @@ func unmarshal(in []byte, out interface{}, strict bool) (err error) { // // The field tag format accepted is: // -// `(...) yaml:"[][,[,]]" (...)` +// `(...) yaml:"[][,[,]]" (...)` // // The following flags are currently supported: // -// omitempty Only include the field if it's not set to the zero -// value for the type or to empty slices or maps. -// Zero valued structs will be omitted if all their public -// fields are zero, unless they implement an IsZero -// method (see the IsZeroer interface type), in which -// case the field will be excluded if IsZero returns true. +// omitempty Only include the field if it's not set to the zero +// value for the type or to empty slices or maps. +// Zero valued structs will be omitted if all their public +// fields are zero, unless they implement an IsZero +// method (see the IsZeroer interface type), in which +// case the field will be excluded if IsZero returns true. // -// flow Marshal using a flow style (useful for structs, -// sequences and maps). +// flow Marshal using a flow style (useful for structs, +// sequences and maps). // -// inline Inline the field, which must be a struct or a map, -// causing all of its fields or keys to be processed as if -// they were part of the outer struct. For maps, keys must -// not conflict with the yaml keys of other struct fields. +// inline Inline the field, which must be a struct or a map, +// causing all of its fields or keys to be processed as if +// they were part of the outer struct. For maps, keys must +// not conflict with the yaml keys of other struct fields. // // In addition, if the key is "-", the field is ignored. // // For example: // -// type T struct { -// F int `yaml:"a,omitempty"` -// B int -// } -// yaml.Marshal(&T{B: 2}) // Returns "b: 2\n" -// yaml.Marshal(&T{F: 1}} // Returns "a: 1\nb: 0\n" -// +// type T struct { +// F int `yaml:"a,omitempty"` +// B int +// } +// yaml.Marshal(&T{B: 2}) // Returns "b: 2\n" +// yaml.Marshal(&T{F: 1}} // Returns "a: 1\nb: 0\n" func Marshal(in interface{}) (out []byte, err error) { defer handleErr(&err) e := newEncoder() @@ -358,22 +355,21 @@ const ( // // For example: // -// var person struct { -// Name string -// Address yaml.Node -// } -// err := yaml.Unmarshal(data, &person) -// -// Or by itself: +// var person struct { +// Name string +// Address yaml.Node +// } +// err := yaml.Unmarshal(data, &person) // -// var person Node -// err := yaml.Unmarshal(data, &person) +// Or by itself: // +// var person Node +// err := yaml.Unmarshal(data, &person) type Node struct { // Kind defines whether the node is a document, a mapping, a sequence, // a scalar value, or an alias to another node. The specific data type of // scalar nodes may be obtained via the ShortTag and LongTag methods. - Kind Kind + Kind Kind // Style allows customizing the apperance of the node in the tree. Style Style @@ -421,7 +417,6 @@ func (n *Node) IsZero() bool { n.HeadComment == "" && n.LineComment == "" && n.FootComment == "" && n.Line == 0 && n.Column == 0 } - // LongTag returns the long form of the tag that indicates the data type for // the node. If the Tag field isn't explicitly defined, one will be computed // based on the node properties. diff --git a/test/tools/vendor/gopkg.in/yaml.v3/yamlh.go b/test/tools/vendor/gopkg.in/yaml.v3/yamlh.go index 7c6d0077061..ddcd5513ba7 100644 --- a/test/tools/vendor/gopkg.in/yaml.v3/yamlh.go +++ b/test/tools/vendor/gopkg.in/yaml.v3/yamlh.go @@ -438,7 +438,9 @@ type yaml_document_t struct { // The number of written bytes should be set to the size_read variable. // // [in,out] data A pointer to an application data specified by -// yaml_parser_set_input(). +// +// yaml_parser_set_input(). +// // [out] buffer The buffer to write the data from the source. // [in] size The size of the buffer. // [out] size_read The actual number of bytes read from the source. @@ -639,7 +641,6 @@ type yaml_parser_t struct { } type yaml_comment_t struct { - scan_mark yaml_mark_t // Position where scanning for comments started token_mark yaml_mark_t // Position after which tokens will be associated with this comment start_mark yaml_mark_t // Position of '#' comment mark @@ -659,13 +660,14 @@ type yaml_comment_t struct { // @a buffer to the output. // // @param[in,out] data A pointer to an application data specified by -// yaml_emitter_set_output(). +// +// yaml_emitter_set_output(). +// // @param[in] buffer The buffer with bytes to be written. // @param[in] size The size of the buffer. // // @returns On success, the handler should return @c 1. If the handler failed, // the returned value should be @c 0. -// type yaml_write_handler_t func(emitter *yaml_emitter_t, buffer []byte) error type yaml_emitter_state_t int diff --git a/test/tools/vendor/gopkg.in/yaml.v3/yamlprivateh.go b/test/tools/vendor/gopkg.in/yaml.v3/yamlprivateh.go index e88f9c54aec..dea1ba9610d 100644 --- a/test/tools/vendor/gopkg.in/yaml.v3/yamlprivateh.go +++ b/test/tools/vendor/gopkg.in/yaml.v3/yamlprivateh.go @@ -1,17 +1,17 @@ -// +// // Copyright (c) 2011-2019 Canonical Ltd // Copyright (c) 2006-2010 Kirill Simonov -// +// // Permission is hereby granted, free of charge, to any person obtaining a copy of // this software and associated documentation files (the "Software"), to deal in // the Software without restriction, including without limitation the rights to // use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies // of the Software, and to permit persons to whom the Software is furnished to do // so, subject to the following conditions: -// +// // The above copyright notice and this permission notice shall be included in all // copies or substantial portions of the Software. -// +// // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE @@ -137,8 +137,8 @@ func is_crlf(b []byte, i int) bool { func is_breakz(b []byte, i int) bool { //return is_break(b, i) || is_z(b, i) return ( - // is_break: - b[i] == '\r' || // CR (#xD) + // is_break: + b[i] == '\r' || // CR (#xD) b[i] == '\n' || // LF (#xA) b[i] == 0xC2 && b[i+1] == 0x85 || // NEL (#x85) b[i] == 0xE2 && b[i+1] == 0x80 && b[i+2] == 0xA8 || // LS (#x2028) @@ -151,8 +151,8 @@ func is_breakz(b []byte, i int) bool { func is_spacez(b []byte, i int) bool { //return is_space(b, i) || is_breakz(b, i) return ( - // is_space: - b[i] == ' ' || + // is_space: + b[i] == ' ' || // is_breakz: b[i] == '\r' || // CR (#xD) b[i] == '\n' || // LF (#xA) @@ -166,8 +166,8 @@ func is_spacez(b []byte, i int) bool { func is_blankz(b []byte, i int) bool { //return is_blank(b, i) || is_breakz(b, i) return ( - // is_blank: - b[i] == ' ' || b[i] == '\t' || + // is_blank: + b[i] == ' ' || b[i] == '\t' || // is_breakz: b[i] == '\r' || // CR (#xD) b[i] == '\n' || // LF (#xA) diff --git a/vendor/github.com/Azure/go-ansiterm/winterm/ansi.go b/vendor/github.com/Azure/go-ansiterm/winterm/ansi.go index 5599082ae9c..bf71684f456 100644 --- a/vendor/github.com/Azure/go-ansiterm/winterm/ansi.go +++ b/vendor/github.com/Azure/go-ansiterm/winterm/ansi.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winterm diff --git a/vendor/github.com/Azure/go-ansiterm/winterm/api.go b/vendor/github.com/Azure/go-ansiterm/winterm/api.go index 6055e33b912..2f297601b56 100644 --- a/vendor/github.com/Azure/go-ansiterm/winterm/api.go +++ b/vendor/github.com/Azure/go-ansiterm/winterm/api.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winterm diff --git a/vendor/github.com/Azure/go-ansiterm/winterm/attr_translation.go b/vendor/github.com/Azure/go-ansiterm/winterm/attr_translation.go index cbec8f728f4..644d8b2b482 100644 --- a/vendor/github.com/Azure/go-ansiterm/winterm/attr_translation.go +++ b/vendor/github.com/Azure/go-ansiterm/winterm/attr_translation.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winterm diff --git a/vendor/github.com/Azure/go-ansiterm/winterm/cursor_helpers.go b/vendor/github.com/Azure/go-ansiterm/winterm/cursor_helpers.go index 3ee06ea7282..6b4b8a1ef16 100644 --- a/vendor/github.com/Azure/go-ansiterm/winterm/cursor_helpers.go +++ b/vendor/github.com/Azure/go-ansiterm/winterm/cursor_helpers.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winterm diff --git a/vendor/github.com/Azure/go-ansiterm/winterm/erase_helpers.go b/vendor/github.com/Azure/go-ansiterm/winterm/erase_helpers.go index 244b5fa25ef..1298544a332 100644 --- a/vendor/github.com/Azure/go-ansiterm/winterm/erase_helpers.go +++ b/vendor/github.com/Azure/go-ansiterm/winterm/erase_helpers.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winterm diff --git a/vendor/github.com/Azure/go-ansiterm/winterm/scroll_helper.go b/vendor/github.com/Azure/go-ansiterm/winterm/scroll_helper.go index 2d27fa1d028..03ab280c183 100644 --- a/vendor/github.com/Azure/go-ansiterm/winterm/scroll_helper.go +++ b/vendor/github.com/Azure/go-ansiterm/winterm/scroll_helper.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winterm diff --git a/vendor/github.com/Azure/go-ansiterm/winterm/utilities.go b/vendor/github.com/Azure/go-ansiterm/winterm/utilities.go index afa7635d77b..3535349f0ed 100644 --- a/vendor/github.com/Azure/go-ansiterm/winterm/utilities.go +++ b/vendor/github.com/Azure/go-ansiterm/winterm/utilities.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winterm diff --git a/vendor/github.com/Azure/go-ansiterm/winterm/win_event_handler.go b/vendor/github.com/Azure/go-ansiterm/winterm/win_event_handler.go index 2d40fb75ad0..1e19ea0c377 100644 --- a/vendor/github.com/Azure/go-ansiterm/winterm/win_event_handler.go +++ b/vendor/github.com/Azure/go-ansiterm/winterm/win_event_handler.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winterm diff --git a/vendor/github.com/blang/semver/v4/range.go b/vendor/github.com/blang/semver/v4/range.go index 95f7139b977..b6ee1d8bcb8 100644 --- a/vendor/github.com/blang/semver/v4/range.go +++ b/vendor/github.com/blang/semver/v4/range.go @@ -67,8 +67,8 @@ func (vr *versionRange) rangeFunc() Range { // Range represents a range of versions. // A Range can be used to check if a Version satisfies it: // -// range, err := semver.ParseRange(">1.0.0 <2.0.0") -// range(semver.MustParse("1.1.1") // returns true +// range, err := semver.ParseRange(">1.0.0 <2.0.0") +// range(semver.MustParse("1.1.1") // returns true type Range func(Version) bool // OR combines the existing Range with another Range using logical OR. @@ -108,7 +108,7 @@ func (rf Range) AND(f Range) Range { // // Ranges can be combined by both AND and OR // -// - `>1.0.0 <2.0.0 || >3.0.0 !4.2.1` would match `1.2.3`, `1.9.9`, `3.1.1`, but not `4.2.1`, `2.1.1` +// - `>1.0.0 <2.0.0 || >3.0.0 !4.2.1` would match `1.2.3`, `1.9.9`, `3.1.1`, but not `4.2.1`, `2.1.1` func ParseRange(s string) (Range, error) { parts := splitAndTrim(s) orParts, err := splitORParts(parts) diff --git a/vendor/github.com/chzyer/readline/ansi_windows.go b/vendor/github.com/chzyer/readline/ansi_windows.go index 63b908c187a..b574d06e497 100644 --- a/vendor/github.com/chzyer/readline/ansi_windows.go +++ b/vendor/github.com/chzyer/readline/ansi_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package readline diff --git a/vendor/github.com/chzyer/readline/rawreader_windows.go b/vendor/github.com/chzyer/readline/rawreader_windows.go index 073ef150a59..b0b2db4f51b 100644 --- a/vendor/github.com/chzyer/readline/rawreader_windows.go +++ b/vendor/github.com/chzyer/readline/rawreader_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package readline diff --git a/vendor/github.com/chzyer/readline/readline.go b/vendor/github.com/chzyer/readline/readline.go index 63b9171012e..065e1d63abd 100644 --- a/vendor/github.com/chzyer/readline/readline.go +++ b/vendor/github.com/chzyer/readline/readline.go @@ -1,20 +1,20 @@ // Readline is a pure go implementation for GNU-Readline kind library. // // example: -// rl, err := readline.New("> ") -// if err != nil { -// panic(err) -// } -// defer rl.Close() // -// for { -// line, err := rl.Readline() -// if err != nil { // io.EOF -// break -// } -// println(line) -// } +// rl, err := readline.New("> ") +// if err != nil { +// panic(err) +// } +// defer rl.Close() // +// for { +// line, err := rl.Readline() +// if err != nil { // io.EOF +// break +// } +// println(line) +// } package readline import ( @@ -301,9 +301,10 @@ func (i *Instance) Write(b []byte) (int, error) { // WriteStdin prefill the next Stdin fetch // Next time you call ReadLine() this value will be writen before the user input // ie : -// i := readline.New() -// i.WriteStdin([]byte("test")) -// _, _= i.Readline() +// +// i := readline.New() +// i.WriteStdin([]byte("test")) +// _, _= i.Readline() // // gives // diff --git a/vendor/github.com/chzyer/readline/std_windows.go b/vendor/github.com/chzyer/readline/std_windows.go index b10f91bcb7e..f7ba47006d1 100644 --- a/vendor/github.com/chzyer/readline/std_windows.go +++ b/vendor/github.com/chzyer/readline/std_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package readline diff --git a/vendor/github.com/chzyer/readline/term.go b/vendor/github.com/chzyer/readline/term.go index ea5db9346e8..429593cda8e 100644 --- a/vendor/github.com/chzyer/readline/term.go +++ b/vendor/github.com/chzyer/readline/term.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build aix || darwin || dragonfly || freebsd || (linux && !appengine) || netbsd || openbsd || os400 || solaris // +build aix darwin dragonfly freebsd linux,!appengine netbsd openbsd os400 solaris // Package terminal provides support functions for dealing with terminals, as @@ -9,11 +10,11 @@ // // Putting a terminal into raw mode is the most common requirement: // -// oldState, err := terminal.MakeRaw(0) -// if err != nil { -// panic(err) -// } -// defer terminal.Restore(0, oldState) +// oldState, err := terminal.MakeRaw(0) +// if err != nil { +// panic(err) +// } +// defer terminal.Restore(0, oldState) package readline import ( diff --git a/vendor/github.com/chzyer/readline/term_bsd.go b/vendor/github.com/chzyer/readline/term_bsd.go index 68b56ea6ba7..1558000ebcf 100644 --- a/vendor/github.com/chzyer/readline/term_bsd.go +++ b/vendor/github.com/chzyer/readline/term_bsd.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build darwin || dragonfly || freebsd || netbsd || openbsd // +build darwin dragonfly freebsd netbsd openbsd package readline diff --git a/vendor/github.com/chzyer/readline/term_nosyscall6.go b/vendor/github.com/chzyer/readline/term_nosyscall6.go index df923393790..a1018dad7b6 100644 --- a/vendor/github.com/chzyer/readline/term_nosyscall6.go +++ b/vendor/github.com/chzyer/readline/term_nosyscall6.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build aix || os400 || solaris // +build aix os400 solaris package readline diff --git a/vendor/github.com/chzyer/readline/term_unix.go b/vendor/github.com/chzyer/readline/term_unix.go index d3ea242448d..55372f59f7e 100644 --- a/vendor/github.com/chzyer/readline/term_unix.go +++ b/vendor/github.com/chzyer/readline/term_unix.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build darwin || dragonfly || freebsd || (linux && !appengine) || netbsd || openbsd // +build darwin dragonfly freebsd linux,!appengine netbsd openbsd package readline diff --git a/vendor/github.com/chzyer/readline/term_windows.go b/vendor/github.com/chzyer/readline/term_windows.go index 1290e00bc14..5a3252c8b07 100644 --- a/vendor/github.com/chzyer/readline/term_windows.go +++ b/vendor/github.com/chzyer/readline/term_windows.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build windows // +build windows // Package terminal provides support functions for dealing with terminals, as @@ -9,11 +10,11 @@ // // Putting a terminal into raw mode is the most common requirement: // -// oldState, err := terminal.MakeRaw(0) -// if err != nil { -// panic(err) -// } -// defer terminal.Restore(0, oldState) +// oldState, err := terminal.MakeRaw(0) +// if err != nil { +// panic(err) +// } +// defer terminal.Restore(0, oldState) package readline import ( diff --git a/vendor/github.com/chzyer/readline/utils_unix.go b/vendor/github.com/chzyer/readline/utils_unix.go index fc49492326e..d4499d6081b 100644 --- a/vendor/github.com/chzyer/readline/utils_unix.go +++ b/vendor/github.com/chzyer/readline/utils_unix.go @@ -1,3 +1,4 @@ +//go:build aix || darwin || dragonfly || freebsd || (linux && !appengine) || netbsd || openbsd || os400 || solaris // +build aix darwin dragonfly freebsd linux,!appengine netbsd openbsd os400 solaris package readline diff --git a/vendor/github.com/chzyer/readline/utils_windows.go b/vendor/github.com/chzyer/readline/utils_windows.go index 5bfa55dcce8..83662638c1f 100644 --- a/vendor/github.com/chzyer/readline/utils_windows.go +++ b/vendor/github.com/chzyer/readline/utils_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package readline diff --git a/vendor/github.com/chzyer/readline/windows_api.go b/vendor/github.com/chzyer/readline/windows_api.go index 63f4f7b78fc..4e94f91d40e 100644 --- a/vendor/github.com/chzyer/readline/windows_api.go +++ b/vendor/github.com/chzyer/readline/windows_api.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package readline diff --git a/vendor/github.com/containers/conmon/runner/config/config_unix.go b/vendor/github.com/containers/conmon/runner/config/config_unix.go index 5caaca7ccd0..2c7462b74fa 100644 --- a/vendor/github.com/containers/conmon/runner/config/config_unix.go +++ b/vendor/github.com/containers/conmon/runner/config/config_unix.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package config diff --git a/vendor/github.com/containers/conmon/runner/config/config_windows.go b/vendor/github.com/containers/conmon/runner/config/config_windows.go index 2161b94411c..123c37b1138 100644 --- a/vendor/github.com/containers/conmon/runner/config/config_windows.go +++ b/vendor/github.com/containers/conmon/runner/config/config_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package config diff --git a/vendor/github.com/containers/libtrust/ec_key_no_openssl.go b/vendor/github.com/containers/libtrust/ec_key_no_openssl.go index d6cdaca3f8d..90d0e21f4b0 100644 --- a/vendor/github.com/containers/libtrust/ec_key_no_openssl.go +++ b/vendor/github.com/containers/libtrust/ec_key_no_openssl.go @@ -1,3 +1,4 @@ +//go:build !libtrust_openssl // +build !libtrust_openssl package libtrust diff --git a/vendor/github.com/containers/libtrust/ec_key_openssl.go b/vendor/github.com/containers/libtrust/ec_key_openssl.go index 4137511f119..42bc2e4d445 100644 --- a/vendor/github.com/containers/libtrust/ec_key_openssl.go +++ b/vendor/github.com/containers/libtrust/ec_key_openssl.go @@ -1,3 +1,4 @@ +//go:build libtrust_openssl // +build libtrust_openssl package libtrust diff --git a/vendor/github.com/coreos/go-oidc/v3/oidc/oidc.go b/vendor/github.com/coreos/go-oidc/v3/oidc/oidc.go index f6a7ea8a580..e06286c6fe7 100644 --- a/vendor/github.com/coreos/go-oidc/v3/oidc/oidc.go +++ b/vendor/github.com/coreos/go-oidc/v3/oidc/oidc.go @@ -162,7 +162,7 @@ var supportedAlgorithms = map[string]bool{ // parsing. // // // Directly fetch the metadata document. -// resp, err := http.Get("https://login.example.com/custom-metadata-path") +// resp, err := http.Get("https://login.example.com/custom-metadata-path") // if err != nil { // // ... // } diff --git a/vendor/github.com/cyberphone/json-canonicalization/go/src/webpki.org/jsoncanonicalizer/es6numfmt.go b/vendor/github.com/cyberphone/json-canonicalization/go/src/webpki.org/jsoncanonicalizer/es6numfmt.go index 92574a3f4f3..ae17f3d9858 100644 --- a/vendor/github.com/cyberphone/json-canonicalization/go/src/webpki.org/jsoncanonicalizer/es6numfmt.go +++ b/vendor/github.com/cyberphone/json-canonicalization/go/src/webpki.org/jsoncanonicalizer/es6numfmt.go @@ -13,7 +13,7 @@ // See the License for the specific language governing permissions and // limitations under the License. // - + // This package converts numbers in IEEE-754 double precision into the // format specified for JSON in EcmaScript Version 6 and forward. // The core application for this is canonicalization: @@ -22,50 +22,50 @@ package jsoncanonicalizer import ( - "errors" - "math" - "strconv" - "strings" + "errors" + "math" + "strconv" + "strings" ) const invalidPattern uint64 = 0x7ff0000000000000 func NumberToJSON(ieeeF64 float64) (res string, err error) { - ieeeU64 := math.Float64bits(ieeeF64) + ieeeU64 := math.Float64bits(ieeeF64) - // Special case: NaN and Infinity are invalid in JSON - if (ieeeU64 & invalidPattern) == invalidPattern { - return "null", errors.New("Invalid JSON number: " + strconv.FormatUint(ieeeU64, 16)) - } + // Special case: NaN and Infinity are invalid in JSON + if (ieeeU64 & invalidPattern) == invalidPattern { + return "null", errors.New("Invalid JSON number: " + strconv.FormatUint(ieeeU64, 16)) + } - // Special case: eliminate "-0" as mandated by the ES6-JSON/JCS specifications - if ieeeF64 == 0 { // Right, this line takes both -0 and 0 - return "0", nil - } + // Special case: eliminate "-0" as mandated by the ES6-JSON/JCS specifications + if ieeeF64 == 0 { // Right, this line takes both -0 and 0 + return "0", nil + } - // Deal with the sign separately - var sign string = "" - if ieeeF64 < 0 { - ieeeF64 =-ieeeF64 - sign = "-" - } + // Deal with the sign separately + var sign string = "" + if ieeeF64 < 0 { + ieeeF64 = -ieeeF64 + sign = "-" + } - // ES6 has a unique "g" format - var format byte = 'e' - if ieeeF64 < 1e+21 && ieeeF64 >= 1e-6 { - format = 'f' - } + // ES6 has a unique "g" format + var format byte = 'e' + if ieeeF64 < 1e+21 && ieeeF64 >= 1e-6 { + format = 'f' + } - // The following should do the trick: - es6Formatted := strconv.FormatFloat(ieeeF64, format, -1, 64) + // The following should do the trick: + es6Formatted := strconv.FormatFloat(ieeeF64, format, -1, 64) - // Minor cleanup - exponent := strings.IndexByte(es6Formatted, 'e') - if exponent > 0 { - // Go outputs "1e+09" which must be rewritten as "1e+9" - if es6Formatted[exponent + 2] == '0' { - es6Formatted = es6Formatted[:exponent + 2] + es6Formatted[exponent + 3:] - } - } - return sign + es6Formatted, nil + // Minor cleanup + exponent := strings.IndexByte(es6Formatted, 'e') + if exponent > 0 { + // Go outputs "1e+09" which must be rewritten as "1e+9" + if es6Formatted[exponent+2] == '0' { + es6Formatted = es6Formatted[:exponent+2] + es6Formatted[exponent+3:] + } + } + return sign + es6Formatted, nil } diff --git a/vendor/github.com/cyberphone/json-canonicalization/go/src/webpki.org/jsoncanonicalizer/jsoncanonicalizer.go b/vendor/github.com/cyberphone/json-canonicalization/go/src/webpki.org/jsoncanonicalizer/jsoncanonicalizer.go index 661f41055e4..ab7a1be4794 100644 --- a/vendor/github.com/cyberphone/json-canonicalization/go/src/webpki.org/jsoncanonicalizer/jsoncanonicalizer.go +++ b/vendor/github.com/cyberphone/json-canonicalization/go/src/webpki.org/jsoncanonicalizer/jsoncanonicalizer.go @@ -13,366 +13,366 @@ // See the License for the specific language governing permissions and // limitations under the License. // - + // This package transforms JSON data in UTF-8 according to: // https://tools.ietf.org/html/draft-rundgren-json-canonicalization-scheme-02 package jsoncanonicalizer import ( - "errors" - "container/list" - "fmt" - "strconv" - "strings" - "unicode/utf16" + "container/list" + "errors" + "fmt" + "strconv" + "strings" + "unicode/utf16" ) type nameValueType struct { - name string - sortKey []uint16 - value string + name string + sortKey []uint16 + value string } // JSON standard escapes (modulo \u) -var asciiEscapes = []byte{'\\', '"', 'b', 'f', 'n', 'r', 't'} +var asciiEscapes = []byte{'\\', '"', 'b', 'f', 'n', 'r', 't'} var binaryEscapes = []byte{'\\', '"', '\b', '\f', '\n', '\r', '\t'} // JSON literals -var literals = []string{"true", "false", "null"} - +var literals = []string{"true", "false", "null"} + func Transform(jsonData []byte) (result []byte, e error) { - // JSON data MUST be UTF-8 encoded - var jsonDataLength int = len(jsonData) + // JSON data MUST be UTF-8 encoded + var jsonDataLength int = len(jsonData) - // Current pointer in jsonData - var index int = 0 + // Current pointer in jsonData + var index int = 0 - // "Forward" declarations are needed for closures referring each other - var parseElement func() string - var parseSimpleType func() string - var parseQuotedString func() string - var parseObject func() string - var parseArray func() string + // "Forward" declarations are needed for closures referring each other + var parseElement func() string + var parseSimpleType func() string + var parseQuotedString func() string + var parseObject func() string + var parseArray func() string - var globalError error = nil + var globalError error = nil - checkError := func(e error) { - // We only honor the first reported error - if globalError == nil { - globalError = e - } - } - - setError := func(msg string) { - checkError(errors.New(msg)) - } + checkError := func(e error) { + // We only honor the first reported error + if globalError == nil { + globalError = e + } + } - isWhiteSpace := func(c byte) bool { - return c == 0x20 || c == 0x0a || c == 0x0d || c == 0x09 - } + setError := func(msg string) { + checkError(errors.New(msg)) + } - nextChar := func() byte { - if index < jsonDataLength { - c := jsonData[index] - if c > 0x7f { - setError("Unexpected non-ASCII character") - } - index++ - return c - } - setError("Unexpected EOF reached") - return '"' - } + isWhiteSpace := func(c byte) bool { + return c == 0x20 || c == 0x0a || c == 0x0d || c == 0x09 + } - scan := func() byte { - for { - c := nextChar() - if isWhiteSpace(c) { - continue; - } - return c - } - } + nextChar := func() byte { + if index < jsonDataLength { + c := jsonData[index] + if c > 0x7f { + setError("Unexpected non-ASCII character") + } + index++ + return c + } + setError("Unexpected EOF reached") + return '"' + } - scanFor := func(expected byte) { - c := scan() - if c != expected { - setError("Expected '" + string(expected) + "' but got '" + string(c) + "'") - } - } + scan := func() byte { + for { + c := nextChar() + if isWhiteSpace(c) { + continue + } + return c + } + } - getUEscape := func() rune { - start := index - nextChar() - nextChar() - nextChar() - nextChar() - if globalError != nil { - return 0 - } - u16, err := strconv.ParseUint(string(jsonData[start:index]), 16, 64) - checkError(err) - return rune(u16) - } + scanFor := func(expected byte) { + c := scan() + if c != expected { + setError("Expected '" + string(expected) + "' but got '" + string(c) + "'") + } + } - testNextNonWhiteSpaceChar := func() byte { - save := index - c := scan() - index = save - return c - } + getUEscape := func() rune { + start := index + nextChar() + nextChar() + nextChar() + nextChar() + if globalError != nil { + return 0 + } + u16, err := strconv.ParseUint(string(jsonData[start:index]), 16, 64) + checkError(err) + return rune(u16) + } - decorateString := func(rawUTF8 string) string { - var quotedString strings.Builder - quotedString.WriteByte('"') - CoreLoop: - for _, c := range []byte(rawUTF8) { - // Is this within the JSON standard escapes? - for i, esc := range binaryEscapes { - if esc == c { - quotedString.WriteByte('\\') - quotedString.WriteByte(asciiEscapes[i]) - continue CoreLoop - } - } - if c < 0x20 { - // Other ASCII control characters must be escaped with \uhhhh - quotedString.WriteString(fmt.Sprintf("\\u%04x", c)) - } else { - quotedString.WriteByte(c) - } - } - quotedString.WriteByte('"') - return quotedString.String() - } + testNextNonWhiteSpaceChar := func() byte { + save := index + c := scan() + index = save + return c + } - parseQuotedString = func() string { - var rawString strings.Builder - CoreLoop: - for globalError == nil { - var c byte - if index < jsonDataLength { - c = jsonData[index] - index++ - } else { - nextChar() - break - } - if (c == '"') { - break; - } - if c < ' ' { - setError("Unterminated string literal") - } else if c == '\\' { - // Escape sequence - c = nextChar() - if c == 'u' { - // The \u escape - firstUTF16 := getUEscape() - if utf16.IsSurrogate(firstUTF16) { - // If the first UTF-16 code unit has a certain value there must be - // another succeeding UTF-16 code unit as well - if nextChar() != '\\' || nextChar() != 'u' { - setError("Missing surrogate") - } else { - // Output the UTF-32 code point as UTF-8 - rawString.WriteRune(utf16.DecodeRune(firstUTF16, getUEscape())) - } - } else { - // Single UTF-16 code identical to UTF-32. Output as UTF-8 - rawString.WriteRune(firstUTF16) - } - } else if c == '/' { - // Benign but useless escape - rawString.WriteByte('/') - } else { - // The JSON standard escapes - for i, esc := range asciiEscapes { - if esc == c { - rawString.WriteByte(binaryEscapes[i]) - continue CoreLoop - } - } - setError("Unexpected escape: \\" + string(c)) - } - } else { - // Just an ordinary ASCII character alternatively a UTF-8 byte - // outside of ASCII. - // Note that properly formatted UTF-8 never clashes with ASCII - // making byte per byte search for ASCII break characters work - // as expected. - rawString.WriteByte(c) - } - } - return rawString.String() - } + decorateString := func(rawUTF8 string) string { + var quotedString strings.Builder + quotedString.WriteByte('"') + CoreLoop: + for _, c := range []byte(rawUTF8) { + // Is this within the JSON standard escapes? + for i, esc := range binaryEscapes { + if esc == c { + quotedString.WriteByte('\\') + quotedString.WriteByte(asciiEscapes[i]) + continue CoreLoop + } + } + if c < 0x20 { + // Other ASCII control characters must be escaped with \uhhhh + quotedString.WriteString(fmt.Sprintf("\\u%04x", c)) + } else { + quotedString.WriteByte(c) + } + } + quotedString.WriteByte('"') + return quotedString.String() + } - parseSimpleType = func() string { - var token strings.Builder - index-- - for globalError == nil { - c := testNextNonWhiteSpaceChar() - if c == ',' || c == ']' || c == '}' { - break; - } - c = nextChar() - if isWhiteSpace(c) { - break - } - token.WriteByte(c) - } - if token.Len() == 0 { - setError("Missing argument") - } - value := token.String() - // Is it a JSON literal? - for _, literal := range literals { - if literal == value { - return literal - } - } - // Apparently not so we assume that it is a I-JSON number - ieeeF64, err := strconv.ParseFloat(value, 64) - checkError(err) - value, err = NumberToJSON(ieeeF64) - checkError(err) - return value - } + parseQuotedString = func() string { + var rawString strings.Builder + CoreLoop: + for globalError == nil { + var c byte + if index < jsonDataLength { + c = jsonData[index] + index++ + } else { + nextChar() + break + } + if c == '"' { + break + } + if c < ' ' { + setError("Unterminated string literal") + } else if c == '\\' { + // Escape sequence + c = nextChar() + if c == 'u' { + // The \u escape + firstUTF16 := getUEscape() + if utf16.IsSurrogate(firstUTF16) { + // If the first UTF-16 code unit has a certain value there must be + // another succeeding UTF-16 code unit as well + if nextChar() != '\\' || nextChar() != 'u' { + setError("Missing surrogate") + } else { + // Output the UTF-32 code point as UTF-8 + rawString.WriteRune(utf16.DecodeRune(firstUTF16, getUEscape())) + } + } else { + // Single UTF-16 code identical to UTF-32. Output as UTF-8 + rawString.WriteRune(firstUTF16) + } + } else if c == '/' { + // Benign but useless escape + rawString.WriteByte('/') + } else { + // The JSON standard escapes + for i, esc := range asciiEscapes { + if esc == c { + rawString.WriteByte(binaryEscapes[i]) + continue CoreLoop + } + } + setError("Unexpected escape: \\" + string(c)) + } + } else { + // Just an ordinary ASCII character alternatively a UTF-8 byte + // outside of ASCII. + // Note that properly formatted UTF-8 never clashes with ASCII + // making byte per byte search for ASCII break characters work + // as expected. + rawString.WriteByte(c) + } + } + return rawString.String() + } - parseElement = func() string { - switch scan() { - case '{': - return parseObject() - case '"': - return decorateString(parseQuotedString()) - case '[': - return parseArray() - default: - return parseSimpleType() - } - } + parseSimpleType = func() string { + var token strings.Builder + index-- + for globalError == nil { + c := testNextNonWhiteSpaceChar() + if c == ',' || c == ']' || c == '}' { + break + } + c = nextChar() + if isWhiteSpace(c) { + break + } + token.WriteByte(c) + } + if token.Len() == 0 { + setError("Missing argument") + } + value := token.String() + // Is it a JSON literal? + for _, literal := range literals { + if literal == value { + return literal + } + } + // Apparently not so we assume that it is a I-JSON number + ieeeF64, err := strconv.ParseFloat(value, 64) + checkError(err) + value, err = NumberToJSON(ieeeF64) + checkError(err) + return value + } - parseArray = func() string { - var arrayData strings.Builder - arrayData.WriteByte('[') - var next bool = false - for globalError == nil && testNextNonWhiteSpaceChar() != ']' { - if next { - scanFor(',') - arrayData.WriteByte(',') - } else { - next = true - } - arrayData.WriteString(parseElement()) - } - scan() - arrayData.WriteByte(']') - return arrayData.String() - } + parseElement = func() string { + switch scan() { + case '{': + return parseObject() + case '"': + return decorateString(parseQuotedString()) + case '[': + return parseArray() + default: + return parseSimpleType() + } + } - lexicographicallyPrecedes := func(sortKey []uint16, e *list.Element) bool { - // Find the minimum length of the sortKeys - oldSortKey := e.Value.(nameValueType).sortKey - minLength := len(oldSortKey) - if minLength > len(sortKey) { - minLength = len(sortKey) - } - for q := 0; q < minLength; q++ { - diff := int(sortKey[q]) - int(oldSortKey[q]) - if diff < 0 { - // Smaller => Precedes - return true - } else if diff > 0 { - // Bigger => No match - return false - } - // Still equal => Continue - } - // The sortKeys compared equal up to minLength - if len(sortKey) < len(oldSortKey) { - // Shorter => Precedes - return true - } - if len(sortKey) == len(oldSortKey) { - setError("Duplicate key: " + e.Value.(nameValueType).name) - } - // Longer => No match - return false - } + parseArray = func() string { + var arrayData strings.Builder + arrayData.WriteByte('[') + var next bool = false + for globalError == nil && testNextNonWhiteSpaceChar() != ']' { + if next { + scanFor(',') + arrayData.WriteByte(',') + } else { + next = true + } + arrayData.WriteString(parseElement()) + } + scan() + arrayData.WriteByte(']') + return arrayData.String() + } - parseObject = func() string { - nameValueList := list.New() - var next bool = false - CoreLoop: - for globalError == nil && testNextNonWhiteSpaceChar() != '}' { - if next { - scanFor(',') - } - next = true - scanFor('"') - rawUTF8 := parseQuotedString() - if globalError != nil { - break; - } - // Sort keys on UTF-16 code units - // Since UTF-8 doesn't have endianess this is just a value transformation - // In the Go case the transformation is UTF-8 => UTF-32 => UTF-16 - sortKey := utf16.Encode([]rune(rawUTF8)) - scanFor(':') - nameValue := nameValueType{rawUTF8, sortKey, parseElement()} - for e := nameValueList.Front(); e != nil; e = e.Next() { - // Check if the key is smaller than a previous key - if lexicographicallyPrecedes(sortKey, e) { - // Precedes => Insert before and exit sorting - nameValueList.InsertBefore(nameValue, e) - continue CoreLoop - } - // Continue searching for a possibly succeeding sortKey - // (which is straightforward since the list is ordered) - } - // The sortKey is either the first or is succeeding all previous sortKeys - nameValueList.PushBack(nameValue) - } - // Scan away '}' - scan() - // Now everything is sorted so we can properly serialize the object - var objectData strings.Builder - objectData.WriteByte('{') - next = false - for e := nameValueList.Front(); e != nil; e = e.Next() { - if next { - objectData.WriteByte(',') - } - next = true - nameValue := e.Value.(nameValueType) - objectData.WriteString(decorateString(nameValue.name)) - objectData.WriteByte(':') - objectData.WriteString(nameValue.value) - } - objectData.WriteByte('}') - return objectData.String() - } + lexicographicallyPrecedes := func(sortKey []uint16, e *list.Element) bool { + // Find the minimum length of the sortKeys + oldSortKey := e.Value.(nameValueType).sortKey + minLength := len(oldSortKey) + if minLength > len(sortKey) { + minLength = len(sortKey) + } + for q := 0; q < minLength; q++ { + diff := int(sortKey[q]) - int(oldSortKey[q]) + if diff < 0 { + // Smaller => Precedes + return true + } else if diff > 0 { + // Bigger => No match + return false + } + // Still equal => Continue + } + // The sortKeys compared equal up to minLength + if len(sortKey) < len(oldSortKey) { + // Shorter => Precedes + return true + } + if len(sortKey) == len(oldSortKey) { + setError("Duplicate key: " + e.Value.(nameValueType).name) + } + // Longer => No match + return false + } - ///////////////////////////////////////////////// - // This is where Transform actually begins... // - ///////////////////////////////////////////////// - var transformed string + parseObject = func() string { + nameValueList := list.New() + var next bool = false + CoreLoop: + for globalError == nil && testNextNonWhiteSpaceChar() != '}' { + if next { + scanFor(',') + } + next = true + scanFor('"') + rawUTF8 := parseQuotedString() + if globalError != nil { + break + } + // Sort keys on UTF-16 code units + // Since UTF-8 doesn't have endianess this is just a value transformation + // In the Go case the transformation is UTF-8 => UTF-32 => UTF-16 + sortKey := utf16.Encode([]rune(rawUTF8)) + scanFor(':') + nameValue := nameValueType{rawUTF8, sortKey, parseElement()} + for e := nameValueList.Front(); e != nil; e = e.Next() { + // Check if the key is smaller than a previous key + if lexicographicallyPrecedes(sortKey, e) { + // Precedes => Insert before and exit sorting + nameValueList.InsertBefore(nameValue, e) + continue CoreLoop + } + // Continue searching for a possibly succeeding sortKey + // (which is straightforward since the list is ordered) + } + // The sortKey is either the first or is succeeding all previous sortKeys + nameValueList.PushBack(nameValue) + } + // Scan away '}' + scan() + // Now everything is sorted so we can properly serialize the object + var objectData strings.Builder + objectData.WriteByte('{') + next = false + for e := nameValueList.Front(); e != nil; e = e.Next() { + if next { + objectData.WriteByte(',') + } + next = true + nameValue := e.Value.(nameValueType) + objectData.WriteString(decorateString(nameValue.name)) + objectData.WriteByte(':') + objectData.WriteString(nameValue.value) + } + objectData.WriteByte('}') + return objectData.String() + } - if testNextNonWhiteSpaceChar() == '[' { - scan() - transformed = parseArray() - } else { - scanFor('{') - transformed = parseObject() - } - for index < jsonDataLength { - if !isWhiteSpace(jsonData[index]) { - setError("Improperly terminated JSON object") - break; - } - index++ - } - return []byte(transformed), globalError -} \ No newline at end of file + ///////////////////////////////////////////////// + // This is where Transform actually begins... // + ///////////////////////////////////////////////// + var transformed string + + if testNextNonWhiteSpaceChar() == '[' { + scan() + transformed = parseArray() + } else { + scanFor('{') + transformed = parseObject() + } + for index < jsonDataLength { + if !isWhiteSpace(jsonData[index]) { + setError("Improperly terminated JSON object") + break + } + index++ + } + return []byte(transformed), globalError +} diff --git a/vendor/github.com/davecgh/go-spew/spew/bypass.go b/vendor/github.com/davecgh/go-spew/spew/bypass.go index 792994785e3..70ddeaad3e5 100644 --- a/vendor/github.com/davecgh/go-spew/spew/bypass.go +++ b/vendor/github.com/davecgh/go-spew/spew/bypass.go @@ -18,6 +18,7 @@ // tag is deprecated and thus should not be used. // Go versions prior to 1.4 are disabled because they use a different layout // for interfaces which make the implementation of unsafeReflectValue more complex. +//go:build !js && !appengine && !safe && !disableunsafe && go1.4 // +build !js,!appengine,!safe,!disableunsafe,go1.4 package spew diff --git a/vendor/github.com/davecgh/go-spew/spew/bypasssafe.go b/vendor/github.com/davecgh/go-spew/spew/bypasssafe.go index 205c28d68c4..5e2d890d6ac 100644 --- a/vendor/github.com/davecgh/go-spew/spew/bypasssafe.go +++ b/vendor/github.com/davecgh/go-spew/spew/bypasssafe.go @@ -16,6 +16,7 @@ // when the code is running on Google App Engine, compiled by GopherJS, or // "-tags safe" is added to the go build command line. The "disableunsafe" // tag is deprecated and thus should not be used. +//go:build js || appengine || safe || disableunsafe || !go1.4 // +build js appengine safe disableunsafe !go1.4 package spew diff --git a/vendor/github.com/davecgh/go-spew/spew/config.go b/vendor/github.com/davecgh/go-spew/spew/config.go index 2e3d22f3120..161895fc6db 100644 --- a/vendor/github.com/davecgh/go-spew/spew/config.go +++ b/vendor/github.com/davecgh/go-spew/spew/config.go @@ -254,15 +254,15 @@ pointer addresses used to indirect to the final value. It provides the following features over the built-in printing facilities provided by the fmt package: - * Pointers are dereferenced and followed - * Circular data structures are detected and handled properly - * Custom Stringer/error interfaces are optionally invoked, including - on unexported types - * Custom types which only implement the Stringer/error interfaces via - a pointer receiver are optionally invoked when passing non-pointer - variables - * Byte arrays and slices are dumped like the hexdump -C command which - includes offsets, byte values in hex, and ASCII output + - Pointers are dereferenced and followed + - Circular data structures are detected and handled properly + - Custom Stringer/error interfaces are optionally invoked, including + on unexported types + - Custom types which only implement the Stringer/error interfaces via + a pointer receiver are optionally invoked when passing non-pointer + variables + - Byte arrays and slices are dumped like the hexdump -C command which + includes offsets, byte values in hex, and ASCII output The configuration options are controlled by modifying the public members of c. See ConfigState for options documentation. @@ -295,12 +295,12 @@ func (c *ConfigState) convertArgs(args []interface{}) (formatters []interface{}) // NewDefaultConfig returns a ConfigState with the following default settings. // -// Indent: " " -// MaxDepth: 0 -// DisableMethods: false -// DisablePointerMethods: false -// ContinueOnMethod: false -// SortKeys: false +// Indent: " " +// MaxDepth: 0 +// DisableMethods: false +// DisablePointerMethods: false +// ContinueOnMethod: false +// SortKeys: false func NewDefaultConfig() *ConfigState { return &ConfigState{Indent: " "} } diff --git a/vendor/github.com/davecgh/go-spew/spew/doc.go b/vendor/github.com/davecgh/go-spew/spew/doc.go index aacaac6f1e1..722e9aa7912 100644 --- a/vendor/github.com/davecgh/go-spew/spew/doc.go +++ b/vendor/github.com/davecgh/go-spew/spew/doc.go @@ -21,35 +21,36 @@ debugging. A quick overview of the additional features spew provides over the built-in printing facilities for Go data types are as follows: - * Pointers are dereferenced and followed - * Circular data structures are detected and handled properly - * Custom Stringer/error interfaces are optionally invoked, including - on unexported types - * Custom types which only implement the Stringer/error interfaces via - a pointer receiver are optionally invoked when passing non-pointer - variables - * Byte arrays and slices are dumped like the hexdump -C command which - includes offsets, byte values in hex, and ASCII output (only when using - Dump style) + - Pointers are dereferenced and followed + - Circular data structures are detected and handled properly + - Custom Stringer/error interfaces are optionally invoked, including + on unexported types + - Custom types which only implement the Stringer/error interfaces via + a pointer receiver are optionally invoked when passing non-pointer + variables + - Byte arrays and slices are dumped like the hexdump -C command which + includes offsets, byte values in hex, and ASCII output (only when using + Dump style) There are two different approaches spew allows for dumping Go data structures: - * Dump style which prints with newlines, customizable indentation, - and additional debug information such as types and all pointer addresses - used to indirect to the final value - * A custom Formatter interface that integrates cleanly with the standard fmt - package and replaces %v, %+v, %#v, and %#+v to provide inline printing - similar to the default %v while providing the additional functionality - outlined above and passing unsupported format verbs such as %x and %q - along to fmt + - Dump style which prints with newlines, customizable indentation, + and additional debug information such as types and all pointer addresses + used to indirect to the final value + - A custom Formatter interface that integrates cleanly with the standard fmt + package and replaces %v, %+v, %#v, and %#+v to provide inline printing + similar to the default %v while providing the additional functionality + outlined above and passing unsupported format verbs such as %x and %q + along to fmt -Quick Start +# Quick Start This section demonstrates how to quickly get started with spew. See the sections below for further details on formatting and configuration options. To dump a variable with full newlines, indentation, type, and pointer information use Dump, Fdump, or Sdump: + spew.Dump(myVar1, myVar2, ...) spew.Fdump(someWriter, myVar1, myVar2, ...) str := spew.Sdump(myVar1, myVar2, ...) @@ -58,12 +59,13 @@ Alternatively, if you would prefer to use format strings with a compacted inline printing style, use the convenience wrappers Printf, Fprintf, etc with %v (most compact), %+v (adds pointer addresses), %#v (adds types), or %#+v (adds types and pointer addresses): + spew.Printf("myVar1: %v -- myVar2: %+v", myVar1, myVar2) spew.Printf("myVar3: %#v -- myVar4: %#+v", myVar3, myVar4) spew.Fprintf(someWriter, "myVar1: %v -- myVar2: %+v", myVar1, myVar2) spew.Fprintf(someWriter, "myVar3: %#v -- myVar4: %#+v", myVar3, myVar4) -Configuration Options +# Configuration Options Configuration of spew is handled by fields in the ConfigState type. For convenience, all of the top-level functions use a global state available @@ -74,51 +76,52 @@ equivalent to the top-level functions. This allows concurrent configuration options. See the ConfigState documentation for more details. The following configuration options are available: - * Indent - String to use for each indentation level for Dump functions. - It is a single space by default. A popular alternative is "\t". - - * MaxDepth - Maximum number of levels to descend into nested data structures. - There is no limit by default. - - * DisableMethods - Disables invocation of error and Stringer interface methods. - Method invocation is enabled by default. - - * DisablePointerMethods - Disables invocation of error and Stringer interface methods on types - which only accept pointer receivers from non-pointer variables. - Pointer method invocation is enabled by default. - - * DisablePointerAddresses - DisablePointerAddresses specifies whether to disable the printing of - pointer addresses. This is useful when diffing data structures in tests. - - * DisableCapacities - DisableCapacities specifies whether to disable the printing of - capacities for arrays, slices, maps and channels. This is useful when - diffing data structures in tests. - - * ContinueOnMethod - Enables recursion into types after invoking error and Stringer interface - methods. Recursion after method invocation is disabled by default. - - * SortKeys - Specifies map keys should be sorted before being printed. Use - this to have a more deterministic, diffable output. Note that - only native types (bool, int, uint, floats, uintptr and string) - and types which implement error or Stringer interfaces are - supported with other types sorted according to the - reflect.Value.String() output which guarantees display - stability. Natural map order is used by default. - - * SpewKeys - Specifies that, as a last resort attempt, map keys should be - spewed to strings and sorted by those strings. This is only - considered if SortKeys is true. - -Dump Usage + + - Indent + String to use for each indentation level for Dump functions. + It is a single space by default. A popular alternative is "\t". + + - MaxDepth + Maximum number of levels to descend into nested data structures. + There is no limit by default. + + - DisableMethods + Disables invocation of error and Stringer interface methods. + Method invocation is enabled by default. + + - DisablePointerMethods + Disables invocation of error and Stringer interface methods on types + which only accept pointer receivers from non-pointer variables. + Pointer method invocation is enabled by default. + + - DisablePointerAddresses + DisablePointerAddresses specifies whether to disable the printing of + pointer addresses. This is useful when diffing data structures in tests. + + - DisableCapacities + DisableCapacities specifies whether to disable the printing of + capacities for arrays, slices, maps and channels. This is useful when + diffing data structures in tests. + + - ContinueOnMethod + Enables recursion into types after invoking error and Stringer interface + methods. Recursion after method invocation is disabled by default. + + - SortKeys + Specifies map keys should be sorted before being printed. Use + this to have a more deterministic, diffable output. Note that + only native types (bool, int, uint, floats, uintptr and string) + and types which implement error or Stringer interfaces are + supported with other types sorted according to the + reflect.Value.String() output which guarantees display + stability. Natural map order is used by default. + + - SpewKeys + Specifies that, as a last resort attempt, map keys should be + spewed to strings and sorted by those strings. This is only + considered if SortKeys is true. + +# Dump Usage Simply call spew.Dump with a list of variables you want to dump: @@ -133,7 +136,7 @@ A third option is to call spew.Sdump to get the formatted output as a string: str := spew.Sdump(myVar1, myVar2, ...) -Sample Dump Output +# Sample Dump Output See the Dump example for details on the setup of the types and variables being shown here. @@ -150,13 +153,14 @@ shown here. Byte (and uint8) arrays and slices are displayed uniquely like the hexdump -C command as shown. + ([]uint8) (len=32 cap=32) { 00000000 11 12 13 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f 20 |............... | 00000010 21 22 23 24 25 26 27 28 29 2a 2b 2c 2d 2e 2f 30 |!"#$%&'()*+,-./0| 00000020 31 32 |12| } -Custom Formatter +# Custom Formatter Spew provides a custom formatter that implements the fmt.Formatter interface so that it integrates cleanly with standard fmt package printing functions. The @@ -170,7 +174,7 @@ standard fmt package for formatting. In addition, the custom formatter ignores the width and precision arguments (however they will still work on the format specifiers not handled by the custom formatter). -Custom Formatter Usage +# Custom Formatter Usage The simplest way to make use of the spew custom formatter is to call one of the convenience functions such as spew.Printf, spew.Println, or spew.Printf. The @@ -184,15 +188,17 @@ functions have syntax you are most likely already familiar with: See the Index for the full list convenience functions. -Sample Formatter Output +# Sample Formatter Output Double pointer to a uint8: + %v: <**>5 %+v: <**>(0xf8400420d0->0xf8400420c8)5 %#v: (**uint8)5 %#+v: (**uint8)(0xf8400420d0->0xf8400420c8)5 Pointer to circular struct with a uint8 field and a pointer to itself: + %v: <*>{1 <*>} %+v: <*>(0xf84003e260){ui8:1 c:<*>(0xf84003e260)} %#v: (*main.circular){ui8:(uint8)1 c:(*main.circular)} @@ -201,7 +207,7 @@ Pointer to circular struct with a uint8 field and a pointer to itself: See the Printf example for details on the setup of variables being shown here. -Errors +# Errors Since it is possible for custom Stringer/error interfaces to panic, spew detects them and handles them internally by printing the panic information diff --git a/vendor/github.com/davecgh/go-spew/spew/dump.go b/vendor/github.com/davecgh/go-spew/spew/dump.go index f78d89fc1f6..8323041a481 100644 --- a/vendor/github.com/davecgh/go-spew/spew/dump.go +++ b/vendor/github.com/davecgh/go-spew/spew/dump.go @@ -488,15 +488,15 @@ pointer addresses used to indirect to the final value. It provides the following features over the built-in printing facilities provided by the fmt package: - * Pointers are dereferenced and followed - * Circular data structures are detected and handled properly - * Custom Stringer/error interfaces are optionally invoked, including - on unexported types - * Custom types which only implement the Stringer/error interfaces via - a pointer receiver are optionally invoked when passing non-pointer - variables - * Byte arrays and slices are dumped like the hexdump -C command which - includes offsets, byte values in hex, and ASCII output + - Pointers are dereferenced and followed + - Circular data structures are detected and handled properly + - Custom Stringer/error interfaces are optionally invoked, including + on unexported types + - Custom types which only implement the Stringer/error interfaces via + a pointer receiver are optionally invoked when passing non-pointer + variables + - Byte arrays and slices are dumped like the hexdump -C command which + includes offsets, byte values in hex, and ASCII output The configuration options are controlled by an exported package global, spew.Config. See ConfigState for options documentation. diff --git a/vendor/github.com/digitalocean/go-libvirt/internal/constants/qemu_protocol.gen.go b/vendor/github.com/digitalocean/go-libvirt/internal/constants/qemu_protocol.gen.go index 208986dee04..c10057b71f1 100644 --- a/vendor/github.com/digitalocean/go-libvirt/internal/constants/qemu_protocol.gen.go +++ b/vendor/github.com/digitalocean/go-libvirt/internal/constants/qemu_protocol.gen.go @@ -38,7 +38,6 @@ const ( // QEMUProcDomainMonitorEvent is libvirt's QEMU_PROC_DOMAIN_MONITOR_EVENT QEMUProcDomainMonitorEvent = 6 - // From consts: // QEMUProgram is libvirt's QEMU_PROGRAM QEMUProgram = 0x20008087 diff --git a/vendor/github.com/digitalocean/go-libvirt/internal/constants/remote_protocol.gen.go b/vendor/github.com/digitalocean/go-libvirt/internal/constants/remote_protocol.gen.go index ce46cde2c78..375071c6ec3 100644 --- a/vendor/github.com/digitalocean/go-libvirt/internal/constants/remote_protocol.gen.go +++ b/vendor/github.com/digitalocean/go-libvirt/internal/constants/remote_protocol.gen.go @@ -884,7 +884,6 @@ const ( // ProcDomainGetMessages is libvirt's REMOTE_PROC_DOMAIN_GET_MESSAGES ProcDomainGetMessages = 426 - // From consts: // StringMax is libvirt's REMOTE_STRING_MAX StringMax = 4194304 diff --git a/vendor/github.com/digitalocean/go-libvirt/internal/go-xdr/xdr2/decode.go b/vendor/github.com/digitalocean/go-libvirt/internal/go-xdr/xdr2/decode.go index 7f33f7d32be..9ade6e60513 100644 --- a/vendor/github.com/digitalocean/go-libvirt/internal/go-xdr/xdr2/decode.go +++ b/vendor/github.com/digitalocean/go-libvirt/internal/go-xdr/xdr2/decode.go @@ -61,12 +61,12 @@ by v and performs a mapping of underlying XDR types to Go types as follows: Notes and Limitations: - * Automatic unmarshalling of variable and fixed-length arrays of uint8s - requires a special struct tag `xdropaque:"false"` since byte slices - and byte arrays are assumed to be opaque data and byte is a Go alias - for uint8 thus indistinguishable under reflection - * Cyclic data structures are not supported and will result in infinite - loops + - Automatic unmarshalling of variable and fixed-length arrays of uint8s + requires a special struct tag `xdropaque:"false"` since byte slices + and byte arrays are assumed to be opaque data and byte is a Go alias + for uint8 thus indistinguishable under reflection + - Cyclic data structures are not supported and will result in infinite + loops If any issues are encountered during the unmarshalling process, an UnmarshalError is returned with a human readable description as well as @@ -119,8 +119,9 @@ type Decoder struct { // An UnmarshalError is returned if there are insufficient bytes remaining. // // Reference: -// RFC Section 4.1 - Integer -// 32-bit big-endian signed integer in range [-2147483648, 2147483647] +// +// RFC Section 4.1 - Integer +// 32-bit big-endian signed integer in range [-2147483648, 2147483647] func (d *Decoder) DecodeInt() (int32, int, error) { var buf [4]byte n, err := io.ReadFull(d.r, buf[:]) @@ -141,8 +142,9 @@ func (d *Decoder) DecodeInt() (int32, int, error) { // An UnmarshalError is returned if there are insufficient bytes remaining. // // Reference: -// RFC Section 4.2 - Unsigned Integer -// 32-bit big-endian unsigned integer in range [0, 4294967295] +// +// RFC Section 4.2 - Unsigned Integer +// 32-bit big-endian unsigned integer in range [0, 4294967295] func (d *Decoder) DecodeUint() (uint32, int, error) { var buf [4]byte n, err := io.ReadFull(d.r, buf[:]) @@ -166,8 +168,9 @@ func (d *Decoder) DecodeUint() (uint32, int, error) { // the parsed enumeration value is not one of the provided valid values. // // Reference: -// RFC Section 4.3 - Enumeration -// Represented as an XDR encoded signed integer +// +// RFC Section 4.3 - Enumeration +// Represented as an XDR encoded signed integer func (d *Decoder) DecodeEnum(validEnums map[int32]bool) (int32, int, error) { val, n, err := d.DecodeInt() if err != nil { @@ -189,8 +192,9 @@ func (d *Decoder) DecodeEnum(validEnums map[int32]bool) (int32, int, error) { // the parsed value is not a 0 or 1. // // Reference: -// RFC Section 4.4 - Boolean -// Represented as an XDR encoded enumeration where 0 is false and 1 is true +// +// RFC Section 4.4 - Boolean +// Represented as an XDR encoded enumeration where 0 is false and 1 is true func (d *Decoder) DecodeBool() (bool, int, error) { val, n, err := d.DecodeInt() if err != nil { @@ -214,8 +218,9 @@ func (d *Decoder) DecodeBool() (bool, int, error) { // An UnmarshalError is returned if there are insufficient bytes remaining. // // Reference: -// RFC Section 4.5 - Hyper Integer -// 64-bit big-endian signed integer in range [-9223372036854775808, 9223372036854775807] +// +// RFC Section 4.5 - Hyper Integer +// 64-bit big-endian signed integer in range [-9223372036854775808, 9223372036854775807] func (d *Decoder) DecodeHyper() (int64, int, error) { var buf [8]byte n, err := io.ReadFull(d.r, buf[:]) @@ -239,8 +244,9 @@ func (d *Decoder) DecodeHyper() (int64, int, error) { // An UnmarshalError is returned if there are insufficient bytes remaining. // // Reference: -// RFC Section 4.5 - Unsigned Hyper Integer -// 64-bit big-endian unsigned integer in range [0, 18446744073709551615] +// +// RFC Section 4.5 - Unsigned Hyper Integer +// 64-bit big-endian unsigned integer in range [0, 18446744073709551615] func (d *Decoder) DecodeUhyper() (uint64, int, error) { var buf [8]byte n, err := io.ReadFull(d.r, buf[:]) @@ -263,8 +269,9 @@ func (d *Decoder) DecodeUhyper() (uint64, int, error) { // An UnmarshalError is returned if there are insufficient bytes remaining. // // Reference: -// RFC Section 4.6 - Floating Point -// 32-bit single-precision IEEE 754 floating point +// +// RFC Section 4.6 - Floating Point +// 32-bit single-precision IEEE 754 floating point func (d *Decoder) DecodeFloat() (float32, int, error) { var buf [4]byte n, err := io.ReadFull(d.r, buf[:]) @@ -286,8 +293,9 @@ func (d *Decoder) DecodeFloat() (float32, int, error) { // An UnmarshalError is returned if there are insufficient bytes remaining. // // Reference: -// RFC Section 4.7 - Double-Precision Floating Point -// 64-bit double-precision IEEE 754 floating point +// +// RFC Section 4.7 - Double-Precision Floating Point +// 64-bit double-precision IEEE 754 floating point func (d *Decoder) DecodeDouble() (float64, int, error) { var buf [8]byte n, err := io.ReadFull(d.r, buf[:]) @@ -317,8 +325,9 @@ func (d *Decoder) DecodeDouble() (float64, int, error) { // multiple of 4. // // Reference: -// RFC Section 4.9 - Fixed-Length Opaque Data -// Fixed-length uninterpreted data zero-padded to a multiple of four +// +// RFC Section 4.9 - Fixed-Length Opaque Data +// Fixed-length uninterpreted data zero-padded to a multiple of four func (d *Decoder) DecodeFixedOpaque(size int32) ([]byte, int, error) { // Nothing to do if size is 0. if size == 0 { @@ -352,8 +361,9 @@ func (d *Decoder) DecodeFixedOpaque(size int32) ([]byte, int, error) { // the opaque data is larger than the max length of a Go slice. // // Reference: -// RFC Section 4.10 - Variable-Length Opaque Data -// Unsigned integer length followed by fixed opaque data of that length +// +// RFC Section 4.10 - Variable-Length Opaque Data +// Unsigned integer length followed by fixed opaque data of that length func (d *Decoder) DecodeOpaque() ([]byte, int, error) { dataLen, n, err := d.DecodeUint() if err != nil { @@ -385,9 +395,10 @@ func (d *Decoder) DecodeOpaque() ([]byte, int, error) { // the string data is larger than the max length of a Go slice. // // Reference: -// RFC Section 4.11 - String -// Unsigned integer length followed by bytes zero-padded to a multiple of -// four +// +// RFC Section 4.11 - String +// Unsigned integer length followed by bytes zero-padded to a multiple of +// four func (d *Decoder) DecodeString() (string, int, error) { dataLen, n, err := d.DecodeUint() if err != nil { @@ -418,8 +429,9 @@ func (d *Decoder) DecodeString() (string, int, error) { // the array elements. // // Reference: -// RFC Section 4.12 - Fixed-Length Array -// Individually XDR encoded array elements +// +// RFC Section 4.12 - Fixed-Length Array +// Individually XDR encoded array elements func (d *Decoder) decodeFixedArray(v reflect.Value, ignoreOpaque bool) (int, error) { // Treat [#]byte (byte is alias for uint8) as opaque data unless // ignored. @@ -456,9 +468,10 @@ func (d *Decoder) decodeFixedArray(v reflect.Value, ignoreOpaque bool) (int, err // the array elements. // // Reference: -// RFC Section 4.13 - Variable-Length Array -// Unsigned integer length followed by individually XDR encoded array -// elements +// +// RFC Section 4.13 - Variable-Length Array +// Unsigned integer length followed by individually XDR encoded array +// elements func (d *Decoder) decodeArray(v reflect.Value, ignoreOpaque bool) (int, error) { dataLen, n, err := d.DecodeUint() if err != nil { @@ -512,8 +525,9 @@ func (d *Decoder) decodeArray(v reflect.Value, ignoreOpaque bool) (int, error) { // the elements. // // Reference: -// RFC Section 4.14 - Structure -// XDR encoded elements in the order of their declaration in the struct +// +// RFC Section 4.14 - Structure +// XDR encoded elements in the order of their declaration in the struct func (d *Decoder) decodeStruct(v reflect.Value) (int, error) { var n int vt := v.Type() diff --git a/vendor/github.com/digitalocean/go-libvirt/internal/go-xdr/xdr2/doc.go b/vendor/github.com/digitalocean/go-libvirt/internal/go-xdr/xdr2/doc.go index 8823d62f369..d167f7fe093 100644 --- a/vendor/github.com/digitalocean/go-libvirt/internal/go-xdr/xdr2/doc.go +++ b/vendor/github.com/digitalocean/go-libvirt/internal/go-xdr/xdr2/doc.go @@ -31,8 +31,8 @@ of Go as described below. This package provides two approaches for encoding and decoding XDR data: - 1) Marshal/Unmarshal functions which automatically map between XDR and Go types - 2) Individual Encoder/Decoder objects to manually work with XDR primitives + 1. Marshal/Unmarshal functions which automatically map between XDR and Go types + 2. Individual Encoder/Decoder objects to manually work with XDR primitives For the Marshal/Unmarshal functions, Go reflection capabilities are used to choose the type of the underlying XDR data based upon the Go type to encode or @@ -45,7 +45,7 @@ automatically encode / decode the XDR data thereby eliminating the need to write a lot of boilerplate code to encode/decode and error check each piece of XDR data as is typically required with C based XDR libraries. -Go Type to XDR Type Mappings +# Go Type to XDR Type Mappings The following chart shows an overview of how Go types are mapped to XDR types for automatic marshalling and unmarshalling. The documentation for the Marshal @@ -72,22 +72,22 @@ and Unmarshal functions has specific details of how the mapping proceeds. Notes and Limitations: - * Automatic marshalling and unmarshalling of variable and fixed-length - arrays of uint8s require a special struct tag `xdropaque:"false"` - since byte slices and byte arrays are assumed to be opaque data and - byte is a Go alias for uint8 thus indistinguishable under reflection - * Channel, complex, and function types cannot be encoded - * Interfaces without a concrete value cannot be encoded - * Cyclic data structures are not supported and will result in infinite - loops - * Strings are marshalled and unmarshalled with UTF-8 character encoding - which differs from the XDR specification of ASCII, however UTF-8 is - backwards compatible with ASCII so this should rarely cause issues + - Automatic marshalling and unmarshalling of variable and fixed-length + arrays of uint8s require a special struct tag `xdropaque:"false"` + since byte slices and byte arrays are assumed to be opaque data and + byte is a Go alias for uint8 thus indistinguishable under reflection + - Channel, complex, and function types cannot be encoded + - Interfaces without a concrete value cannot be encoded + - Cyclic data structures are not supported and will result in infinite + loops + - Strings are marshalled and unmarshalled with UTF-8 character encoding + which differs from the XDR specification of ASCII, however UTF-8 is + backwards compatible with ASCII so this should rarely cause issues - -Encoding +# Encoding To encode XDR data, use the Marshal function. + func Marshal(w io.Writer, v interface{}) (int, error) For example, given the following code snippet: @@ -112,17 +112,16 @@ sequence: 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0A - In addition, while the automatic marshalling discussed above will work for the vast majority of cases, an Encoder object is provided that can be used to manually encode XDR primitives for complex scenarios where automatic reflection-based encoding won't work. The included examples provide a sample of manual usage via an Encoder. - -Decoding +# Decoding To decode XDR data, use the Unmarshal function. + func Unmarshal(r io.Reader, v interface{}) (int, error) For example, given the following code snippet: @@ -159,7 +158,7 @@ manually decode XDR primitives for complex scenarios where automatic reflection-based decoding won't work. The included examples provide a sample of manual usage via a Decoder. -Errors +# Errors All errors are either of type UnmarshalError or MarshalError. Both provide human-readable output as well as an ErrorCode field which can be inspected by diff --git a/vendor/github.com/digitalocean/go-libvirt/internal/go-xdr/xdr2/encode.go b/vendor/github.com/digitalocean/go-libvirt/internal/go-xdr/xdr2/encode.go index 7bac2681d71..11375396ea3 100644 --- a/vendor/github.com/digitalocean/go-libvirt/internal/go-xdr/xdr2/encode.go +++ b/vendor/github.com/digitalocean/go-libvirt/internal/go-xdr/xdr2/encode.go @@ -55,16 +55,16 @@ v and performs a mapping of Go types to the underlying XDR types as follows: Notes and Limitations: - * Automatic marshalling of variable and fixed-length arrays of uint8s - requires a special struct tag `xdropaque:"false"` since byte slices and - byte arrays are assumed to be opaque data and byte is a Go alias for uint8 - thus indistinguishable under reflection - * Channel, complex, and function types cannot be encoded - * Interfaces without a concrete value cannot be encoded - * Cyclic data structures are not supported and will result in infinite loops - * Strings are marshalled with UTF-8 character encoding which differs from - the XDR specification of ASCII, however UTF-8 is backwards compatible with - ASCII so this should rarely cause issues + - Automatic marshalling of variable and fixed-length arrays of uint8s + requires a special struct tag `xdropaque:"false"` since byte slices and + byte arrays are assumed to be opaque data and byte is a Go alias for uint8 + thus indistinguishable under reflection + - Channel, complex, and function types cannot be encoded + - Interfaces without a concrete value cannot be encoded + - Cyclic data structures are not supported and will result in infinite loops + - Strings are marshalled with UTF-8 character encoding which differs from + the XDR specification of ASCII, however UTF-8 is backwards compatible with + ASCII so this should rarely cause issues If any issues are encountered during the marshalling process, a MarshalError is returned with a human readable description as well as an ErrorCode value for @@ -90,8 +90,9 @@ type Encoder struct { // fails. // // Reference: -// RFC Section 4.1 - Integer -// 32-bit big-endian signed integer in range [-2147483648, 2147483647] +// +// RFC Section 4.1 - Integer +// 32-bit big-endian signed integer in range [-2147483648, 2147483647] func (enc *Encoder) EncodeInt(v int32) (int, error) { var b [4]byte b[0] = byte(v >> 24) @@ -117,8 +118,9 @@ func (enc *Encoder) EncodeInt(v int32) (int, error) { // fails. // // Reference: -// RFC Section 4.2 - Unsigned Integer -// 32-bit big-endian unsigned integer in range [0, 4294967295] +// +// RFC Section 4.2 - Unsigned Integer +// 32-bit big-endian unsigned integer in range [0, 4294967295] func (enc *Encoder) EncodeUint(v uint32) (int, error) { var b [4]byte b[0] = byte(v >> 24) @@ -145,8 +147,9 @@ func (enc *Encoder) EncodeUint(v uint32) (int, error) { // provided valid values or if writing the data fails. // // Reference: -// RFC Section 4.3 - Enumeration -// Represented as an XDR encoded signed integer +// +// RFC Section 4.3 - Enumeration +// Represented as an XDR encoded signed integer func (enc *Encoder) EncodeEnum(v int32, validEnums map[int32]bool) (int, error) { if !validEnums[v] { err := marshalError("EncodeEnum", ErrBadEnumValue, @@ -163,8 +166,9 @@ func (enc *Encoder) EncodeEnum(v int32, validEnums map[int32]bool) (int, error) // fails. // // Reference: -// RFC Section 4.4 - Boolean -// Represented as an XDR encoded enumeration where 0 is false and 1 is true +// +// RFC Section 4.4 - Boolean +// Represented as an XDR encoded enumeration where 0 is false and 1 is true func (enc *Encoder) EncodeBool(v bool) (int, error) { i := int32(0) if v == true { @@ -181,8 +185,9 @@ func (enc *Encoder) EncodeBool(v bool) (int, error) { // fails. // // Reference: -// RFC Section 4.5 - Hyper Integer -// 64-bit big-endian signed integer in range [-9223372036854775808, 9223372036854775807] +// +// RFC Section 4.5 - Hyper Integer +// 64-bit big-endian signed integer in range [-9223372036854775808, 9223372036854775807] func (enc *Encoder) EncodeHyper(v int64) (int, error) { var b [8]byte b[0] = byte(v >> 56) @@ -212,8 +217,9 @@ func (enc *Encoder) EncodeHyper(v int64) (int, error) { // fails. // // Reference: -// RFC Section 4.5 - Unsigned Hyper Integer -// 64-bit big-endian unsigned integer in range [0, 18446744073709551615] +// +// RFC Section 4.5 - Unsigned Hyper Integer +// 64-bit big-endian unsigned integer in range [0, 18446744073709551615] func (enc *Encoder) EncodeUhyper(v uint64) (int, error) { var b [8]byte b[0] = byte(v >> 56) @@ -243,8 +249,9 @@ func (enc *Encoder) EncodeUhyper(v uint64) (int, error) { // fails. // // Reference: -// RFC Section 4.6 - Floating Point -// 32-bit single-precision IEEE 754 floating point +// +// RFC Section 4.6 - Floating Point +// 32-bit single-precision IEEE 754 floating point func (enc *Encoder) EncodeFloat(v float32) (int, error) { ui := math.Float32bits(v) return enc.EncodeUint(ui) @@ -258,8 +265,9 @@ func (enc *Encoder) EncodeFloat(v float32) (int, error) { // fails. // // Reference: -// RFC Section 4.7 - Double-Precision Floating Point -// 64-bit double-precision IEEE 754 floating point +// +// RFC Section 4.7 - Double-Precision Floating Point +// 64-bit double-precision IEEE 754 floating point func (enc *Encoder) EncodeDouble(v float64) (int, error) { ui := math.Float64bits(v) return enc.EncodeUhyper(ui) @@ -277,8 +285,9 @@ func (enc *Encoder) EncodeDouble(v float64) (int, error) { // fails. // // Reference: -// RFC Section 4.9 - Fixed-Length Opaque Data -// Fixed-length uninterpreted data zero-padded to a multiple of four +// +// RFC Section 4.9 - Fixed-Length Opaque Data +// Fixed-length uninterpreted data zero-padded to a multiple of four func (enc *Encoder) EncodeFixedOpaque(v []byte) (int, error) { l := len(v) pad := (4 - (l % 4)) % 4 @@ -318,8 +327,9 @@ func (enc *Encoder) EncodeFixedOpaque(v []byte) (int, error) { // fails. // // Reference: -// RFC Section 4.10 - Variable-Length Opaque Data -// Unsigned integer length followed by fixed opaque data of that length +// +// RFC Section 4.10 - Variable-Length Opaque Data +// Unsigned integer length followed by fixed opaque data of that length func (enc *Encoder) EncodeOpaque(v []byte) (int, error) { // Length of opaque data. n, err := enc.EncodeUint(uint32(len(v))) @@ -343,8 +353,9 @@ func (enc *Encoder) EncodeOpaque(v []byte) (int, error) { // fails. // // Reference: -// RFC Section 4.11 - String -// Unsigned integer length followed by bytes zero-padded to a multiple of four +// +// RFC Section 4.11 - String +// Unsigned integer length followed by bytes zero-padded to a multiple of four func (enc *Encoder) EncodeString(v string) (int, error) { // Length of string. n, err := enc.EncodeUint(uint32(len(v))) @@ -367,8 +378,9 @@ func (enc *Encoder) EncodeString(v string) (int, error) { // the array elements. // // Reference: -// RFC Section 4.12 - Fixed-Length Array -// Individually XDR encoded array elements +// +// RFC Section 4.12 - Fixed-Length Array +// Individually XDR encoded array elements func (enc *Encoder) encodeFixedArray(v reflect.Value, ignoreOpaque bool) (int, error) { // Treat [#]byte (byte is alias for uint8) as opaque data unless ignored. if !ignoreOpaque && v.Type().Elem().Kind() == reflect.Uint8 { @@ -412,8 +424,9 @@ func (enc *Encoder) encodeFixedArray(v reflect.Value, ignoreOpaque bool) (int, e // the array elements. // // Reference: -// RFC Section 4.13 - Variable-Length Array -// Unsigned integer length followed by individually XDR encoded array elements +// +// RFC Section 4.13 - Variable-Length Array +// Unsigned integer length followed by individually XDR encoded array elements func (enc *Encoder) encodeArray(v reflect.Value, ignoreOpaque bool) (int, error) { numItems := uint32(v.Len()) n, err := enc.EncodeUint(numItems) @@ -436,8 +449,9 @@ func (enc *Encoder) encodeArray(v reflect.Value, ignoreOpaque bool) (int, error) // the elements. // // Reference: -// RFC Section 4.14 - Structure -// XDR encoded elements in the order of their declaration in the struct +// +// RFC Section 4.14 - Structure +// XDR encoded elements in the order of their declaration in the struct func (enc *Encoder) encodeStruct(v reflect.Value) (int, error) { var n int vt := v.Type() diff --git a/vendor/github.com/digitalocean/go-libvirt/libvirt.go b/vendor/github.com/digitalocean/go-libvirt/libvirt.go index 6224d3de6e2..0813e66b7d8 100644 --- a/vendor/github.com/digitalocean/go-libvirt/libvirt.go +++ b/vendor/github.com/digitalocean/go-libvirt/libvirt.go @@ -406,6 +406,7 @@ func (l *Libvirt) LifecycleEvents(ctx context.Context) (<-chan DomainEventLifecy // Run executes the given QAPI command against a domain's QEMU instance. // For a list of available QAPI commands, see: +// // http://git.qemu.org/?p=qemu.git;a=blob;f=qapi-schema.json;hb=HEAD func (l *Libvirt) Run(dom string, cmd []byte) ([]byte, error) { d, err := l.lookup(dom) @@ -607,7 +608,8 @@ type BlockLimit struct { // 'blkdeviotune' command on a VM in virsh. // // Example usage: -// SetBlockIOTune("vm-name", "vda", BlockLimit{libvirt.QEMUBlockIOWriteBytesSec, 1000000}) +// +// SetBlockIOTune("vm-name", "vda", BlockLimit{libvirt.QEMUBlockIOWriteBytesSec, 1000000}) // // Deprecated: use DomainSetBlockIOTune instead. func (l *Libvirt) SetBlockIOTune(dom string, disk string, limits ...BlockLimit) error { diff --git a/vendor/github.com/digitalocean/go-libvirt/qemu_protocol.gen.go b/vendor/github.com/digitalocean/go-libvirt/qemu_protocol.gen.go index 7666a63cd65..04cf51d0d56 100644 --- a/vendor/github.com/digitalocean/go-libvirt/qemu_protocol.gen.go +++ b/vendor/github.com/digitalocean/go-libvirt/qemu_protocol.gen.go @@ -40,19 +40,17 @@ var ( // Typedefs: // -// // Enums: // // QEMUProcedure is libvirt's qemu_procedure type QEMUProcedure int32 -// // Structs: // // QEMUDomainMonitorCommandArgs is libvirt's qemu_domain_monitor_command_args type QEMUDomainMonitorCommandArgs struct { - Dom Domain - Cmd string + Dom Domain + Cmd string Flags uint32 } @@ -64,7 +62,7 @@ type QEMUDomainMonitorCommandRet struct { // QEMUDomainAttachArgs is libvirt's qemu_domain_attach_args type QEMUDomainAttachArgs struct { PidValue uint32 - Flags uint32 + Flags uint32 } // QEMUDomainAttachRet is libvirt's qemu_domain_attach_ret @@ -74,10 +72,10 @@ type QEMUDomainAttachRet struct { // QEMUDomainAgentCommandArgs is libvirt's qemu_domain_agent_command_args type QEMUDomainAgentCommandArgs struct { - Dom Domain - Cmd string + Dom Domain + Cmd string Timeout int32 - Flags uint32 + Flags uint32 } // QEMUDomainAgentCommandRet is libvirt's qemu_domain_agent_command_ret @@ -87,7 +85,7 @@ type QEMUDomainAgentCommandRet struct { // QEMUConnectDomainMonitorEventRegisterArgs is libvirt's qemu_connect_domain_monitor_event_register_args type QEMUConnectDomainMonitorEventRegisterArgs struct { - Dom OptDomain + Dom OptDomain Event OptString Flags uint32 } @@ -105,23 +103,20 @@ type QEMUConnectDomainMonitorEventDeregisterArgs struct { // QEMUDomainMonitorEventMsg is libvirt's qemu_domain_monitor_event_msg type QEMUDomainMonitorEventMsg struct { CallbackID int32 - Dom Domain - Event string - Seconds int64 - Micros uint32 - Details OptString + Dom Domain + Event string + Seconds int64 + Micros uint32 + Details OptString } - - - // QEMUDomainMonitorCommand is the go wrapper for QEMU_PROC_DOMAIN_MONITOR_COMMAND. func (l *Libvirt) QEMUDomainMonitorCommand(Dom Domain, Cmd string, Flags uint32) (rResult string, err error) { var buf []byte - args := QEMUDomainMonitorCommandArgs { - Dom: Dom, - Cmd: Cmd, + args := QEMUDomainMonitorCommandArgs{ + Dom: Dom, + Cmd: Cmd, Flags: Flags, } @@ -154,9 +149,9 @@ func (l *Libvirt) QEMUDomainMonitorCommand(Dom Domain, Cmd string, Flags uint32) func (l *Libvirt) QEMUDomainAttach(PidValue uint32, Flags uint32) (rDom Domain, err error) { var buf []byte - args := QEMUDomainAttachArgs { + args := QEMUDomainAttachArgs{ PidValue: PidValue, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -188,11 +183,11 @@ func (l *Libvirt) QEMUDomainAttach(PidValue uint32, Flags uint32) (rDom Domain, func (l *Libvirt) QEMUDomainAgentCommand(Dom Domain, Cmd string, Timeout int32, Flags uint32) (rResult OptString, err error) { var buf []byte - args := QEMUDomainAgentCommandArgs { - Dom: Dom, - Cmd: Cmd, + args := QEMUDomainAgentCommandArgs{ + Dom: Dom, + Cmd: Cmd, Timeout: Timeout, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -224,8 +219,8 @@ func (l *Libvirt) QEMUDomainAgentCommand(Dom Domain, Cmd string, Timeout int32, func (l *Libvirt) QEMUConnectDomainMonitorEventRegister(Dom OptDomain, Event OptString, Flags uint32) (rCallbackID int32, err error) { var buf []byte - args := QEMUConnectDomainMonitorEventRegisterArgs { - Dom: Dom, + args := QEMUConnectDomainMonitorEventRegisterArgs{ + Dom: Dom, Event: Event, Flags: Flags, } @@ -259,7 +254,7 @@ func (l *Libvirt) QEMUConnectDomainMonitorEventRegister(Dom OptDomain, Event Opt func (l *Libvirt) QEMUConnectDomainMonitorEventDeregister(CallbackID int32) (err error) { var buf []byte - args := QEMUConnectDomainMonitorEventDeregisterArgs { + args := QEMUConnectDomainMonitorEventDeregisterArgs{ CallbackID: CallbackID, } @@ -268,7 +263,6 @@ func (l *Libvirt) QEMUConnectDomainMonitorEventDeregister(CallbackID int32) (err return } - _, err = l.requestStream(5, constants.QEMUProgram, buf, nil, nil) if err != nil { return @@ -281,7 +275,6 @@ func (l *Libvirt) QEMUConnectDomainMonitorEventDeregister(CallbackID int32) (err func (l *Libvirt) QEMUDomainMonitorEvent() (err error) { var buf []byte - _, err = l.requestStream(6, constants.QEMUProgram, buf, nil, nil) if err != nil { return @@ -289,4 +282,3 @@ func (l *Libvirt) QEMUDomainMonitorEvent() (err error) { return } - diff --git a/vendor/github.com/digitalocean/go-libvirt/remote_protocol.gen.go b/vendor/github.com/digitalocean/go-libvirt/remote_protocol.gen.go index db8f847608f..f87ec7bb6d2 100644 --- a/vendor/github.com/digitalocean/go-libvirt/remote_protocol.gen.go +++ b/vendor/github.com/digitalocean/go-libvirt/remote_protocol.gen.go @@ -36,48 +36,56 @@ var ( _ = xdr.Unmarshal ) -// // Typedefs: // // OptString is libvirt's remote_string type OptString []string + // UUID is libvirt's remote_uuid type UUID [UUIDBuflen]byte + // OptDomain is libvirt's remote_domain type OptDomain []Domain + // OptNetwork is libvirt's remote_network type OptNetwork []Network + // OptNetworkPort is libvirt's remote_network_port type OptNetworkPort []NetworkPort + // OptNwfilter is libvirt's remote_nwfilter type OptNwfilter []Nwfilter + // OptNwfilterBinding is libvirt's remote_nwfilter_binding type OptNwfilterBinding []NwfilterBinding + // OptStoragePool is libvirt's remote_storage_pool type OptStoragePool []StoragePool + // OptStorageVol is libvirt's remote_storage_vol type OptStorageVol []StorageVol + // OptNodeDevice is libvirt's remote_node_device type OptNodeDevice []NodeDevice + // OptSecret is libvirt's remote_secret type OptSecret []Secret -// // Enums: // // AuthType is libvirt's remote_auth_type type AuthType int32 + // Procedure is libvirt's remote_procedure type Procedure int32 -// // Structs: // // Domain is libvirt's remote_nonnull_domain type Domain struct { Name string UUID UUID - ID int32 + ID int32 } // Network is libvirt's remote_nonnull_network @@ -88,7 +96,7 @@ type Network struct { // NetworkPort is libvirt's remote_nonnull_network_port type NetworkPort struct { - Net Network + Net Network UUID UUID } @@ -100,14 +108,14 @@ type Nwfilter struct { // NwfilterBinding is libvirt's remote_nonnull_nwfilter_binding type NwfilterBinding struct { - Portdev string + Portdev string Filtername string } // Interface is libvirt's remote_nonnull_interface type Interface struct { Name string - Mac string + Mac string } // StoragePool is libvirt's remote_nonnull_storage_pool @@ -120,7 +128,7 @@ type StoragePool struct { type StorageVol struct { Pool string Name string - Key string + Key string } // NodeDevice is libvirt's remote_nonnull_node_device @@ -130,44 +138,44 @@ type NodeDevice struct { // Secret is libvirt's remote_nonnull_secret type Secret struct { - UUID UUID + UUID UUID UsageType int32 - UsageID string + UsageID string } // DomainCheckpoint is libvirt's remote_nonnull_domain_checkpoint type DomainCheckpoint struct { Name string - Dom Domain + Dom Domain } // DomainSnapshot is libvirt's remote_nonnull_domain_snapshot type DomainSnapshot struct { Name string - Dom Domain + Dom Domain } // remote_error is libvirt's remote_error type remote_error struct { - Code int32 + Code int32 OptDomain int32 - Message OptString - Level int32 - Dom OptDomain - Str1 OptString - Str2 OptString - Str3 OptString - Int1 int32 - Int2 int32 - Net OptNetwork + Message OptString + Level int32 + Dom OptDomain + Str1 OptString + Str2 OptString + Str3 OptString + Int1 int32 + Int2 int32 + Net OptNetwork } // VcpuInfo is libvirt's remote_vcpu_info type VcpuInfo struct { - Number uint32 - State int32 + Number uint32 + State int32 CPUTime uint64 - CPU int32 + CPU int32 } // TypedParam is libvirt's remote_typed_param @@ -190,13 +198,13 @@ type NodeGetMemoryStats struct { // DomainDiskError is libvirt's remote_domain_disk_error type DomainDiskError struct { - Disk string + Disk string remote_error int32 } // ConnectOpenArgs is libvirt's remote_connect_open_args type ConnectOpenArgs struct { - Name OptString + Name OptString Flags ConnectFlags } @@ -257,13 +265,13 @@ type ConnectGetMaxVcpusRet struct { // NodeGetInfoRet is libvirt's remote_node_get_info_ret type NodeGetInfoRet struct { - Model [32]int8 - Memory uint64 - Cpus int32 - Mhz int32 - Nodes int32 + Model [32]int8 + Memory uint64 + Cpus int32 + Mhz int32 + Nodes int32 Sockets int32 - Cores int32 + Cores int32 Threads int32 } @@ -275,10 +283,10 @@ type ConnectGetCapabilitiesRet struct { // ConnectGetDomainCapabilitiesArgs is libvirt's remote_connect_get_domain_capabilities_args type ConnectGetDomainCapabilitiesArgs struct { Emulatorbin OptString - Arch OptString - Machine OptString - Virttype OptString - Flags uint32 + Arch OptString + Machine OptString + Virttype OptString + Flags uint32 } // ConnectGetDomainCapabilitiesRet is libvirt's remote_connect_get_domain_capabilities_ret @@ -288,14 +296,14 @@ type ConnectGetDomainCapabilitiesRet struct { // NodeGetCPUStatsArgs is libvirt's remote_node_get_cpu_stats_args type NodeGetCPUStatsArgs struct { - CPUNum int32 + CPUNum int32 Nparams int32 - Flags uint32 + Flags uint32 } // NodeGetCPUStatsRet is libvirt's remote_node_get_cpu_stats_ret type NodeGetCPUStatsRet struct { - Params []NodeGetCPUStats + Params []NodeGetCPUStats Nparams int32 } @@ -303,19 +311,19 @@ type NodeGetCPUStatsRet struct { type NodeGetMemoryStatsArgs struct { Nparams int32 CellNum int32 - Flags uint32 + Flags uint32 } // NodeGetMemoryStatsRet is libvirt's remote_node_get_memory_stats_ret type NodeGetMemoryStatsRet struct { - Params []NodeGetMemoryStats + Params []NodeGetMemoryStats Nparams int32 } // NodeGetCellsFreeMemoryArgs is libvirt's remote_node_get_cells_free_memory_args type NodeGetCellsFreeMemoryArgs struct { StartCell int32 - Maxcells int32 + Maxcells int32 } // NodeGetCellsFreeMemoryRet is libvirt's remote_node_get_cells_free_memory_ret @@ -335,13 +343,13 @@ type DomainGetSchedulerTypeArgs struct { // DomainGetSchedulerTypeRet is libvirt's remote_domain_get_scheduler_type_ret type DomainGetSchedulerTypeRet struct { - Type string + Type string Nparams int32 } // DomainGetSchedulerParametersArgs is libvirt's remote_domain_get_scheduler_parameters_args type DomainGetSchedulerParametersArgs struct { - Dom Domain + Dom Domain Nparams int32 } @@ -352,9 +360,9 @@ type DomainGetSchedulerParametersRet struct { // DomainGetSchedulerParametersFlagsArgs is libvirt's remote_domain_get_scheduler_parameters_flags_args type DomainGetSchedulerParametersFlagsArgs struct { - Dom Domain + Dom Domain Nparams int32 - Flags uint32 + Flags uint32 } // DomainGetSchedulerParametersFlagsRet is libvirt's remote_domain_get_scheduler_parameters_flags_ret @@ -364,95 +372,95 @@ type DomainGetSchedulerParametersFlagsRet struct { // DomainSetSchedulerParametersArgs is libvirt's remote_domain_set_scheduler_parameters_args type DomainSetSchedulerParametersArgs struct { - Dom Domain + Dom Domain Params []TypedParam } // DomainSetSchedulerParametersFlagsArgs is libvirt's remote_domain_set_scheduler_parameters_flags_args type DomainSetSchedulerParametersFlagsArgs struct { - Dom Domain + Dom Domain Params []TypedParam - Flags uint32 + Flags uint32 } // DomainSetBlkioParametersArgs is libvirt's remote_domain_set_blkio_parameters_args type DomainSetBlkioParametersArgs struct { - Dom Domain + Dom Domain Params []TypedParam - Flags uint32 + Flags uint32 } // DomainGetBlkioParametersArgs is libvirt's remote_domain_get_blkio_parameters_args type DomainGetBlkioParametersArgs struct { - Dom Domain + Dom Domain Nparams int32 - Flags uint32 + Flags uint32 } // DomainGetBlkioParametersRet is libvirt's remote_domain_get_blkio_parameters_ret type DomainGetBlkioParametersRet struct { - Params []TypedParam + Params []TypedParam Nparams int32 } // DomainSetMemoryParametersArgs is libvirt's remote_domain_set_memory_parameters_args type DomainSetMemoryParametersArgs struct { - Dom Domain + Dom Domain Params []TypedParam - Flags uint32 + Flags uint32 } // DomainGetMemoryParametersArgs is libvirt's remote_domain_get_memory_parameters_args type DomainGetMemoryParametersArgs struct { - Dom Domain + Dom Domain Nparams int32 - Flags uint32 + Flags uint32 } // DomainGetMemoryParametersRet is libvirt's remote_domain_get_memory_parameters_ret type DomainGetMemoryParametersRet struct { - Params []TypedParam + Params []TypedParam Nparams int32 } // DomainBlockResizeArgs is libvirt's remote_domain_block_resize_args type DomainBlockResizeArgs struct { - Dom Domain - Disk string - Size uint64 + Dom Domain + Disk string + Size uint64 Flags DomainBlockResizeFlags } // DomainSetNumaParametersArgs is libvirt's remote_domain_set_numa_parameters_args type DomainSetNumaParametersArgs struct { - Dom Domain + Dom Domain Params []TypedParam - Flags uint32 + Flags uint32 } // DomainGetNumaParametersArgs is libvirt's remote_domain_get_numa_parameters_args type DomainGetNumaParametersArgs struct { - Dom Domain + Dom Domain Nparams int32 - Flags uint32 + Flags uint32 } // DomainGetNumaParametersRet is libvirt's remote_domain_get_numa_parameters_ret type DomainGetNumaParametersRet struct { - Params []TypedParam + Params []TypedParam Nparams int32 } // DomainSetPerfEventsArgs is libvirt's remote_domain_set_perf_events_args type DomainSetPerfEventsArgs struct { - Dom Domain + Dom Domain Params []TypedParam - Flags DomainModificationImpact + Flags DomainModificationImpact } // DomainGetPerfEventsArgs is libvirt's remote_domain_get_perf_events_args type DomainGetPerfEventsArgs struct { - Dom Domain + Dom Domain Flags DomainModificationImpact } @@ -463,78 +471,78 @@ type DomainGetPerfEventsRet struct { // DomainBlockStatsArgs is libvirt's remote_domain_block_stats_args type DomainBlockStatsArgs struct { - Dom Domain + Dom Domain Path string } // DomainBlockStatsRet is libvirt's remote_domain_block_stats_ret type DomainBlockStatsRet struct { - RdReq int64 + RdReq int64 RdBytes int64 - WrReq int64 + WrReq int64 WrBytes int64 - Errs int64 + Errs int64 } // DomainBlockStatsFlagsArgs is libvirt's remote_domain_block_stats_flags_args type DomainBlockStatsFlagsArgs struct { - Dom Domain - Path string + Dom Domain + Path string Nparams int32 - Flags uint32 + Flags uint32 } // DomainBlockStatsFlagsRet is libvirt's remote_domain_block_stats_flags_ret type DomainBlockStatsFlagsRet struct { - Params []TypedParam + Params []TypedParam Nparams int32 } // DomainInterfaceStatsArgs is libvirt's remote_domain_interface_stats_args type DomainInterfaceStatsArgs struct { - Dom Domain + Dom Domain Device string } // DomainInterfaceStatsRet is libvirt's remote_domain_interface_stats_ret type DomainInterfaceStatsRet struct { - RxBytes int64 + RxBytes int64 RxPackets int64 - RxErrs int64 - RxDrop int64 - TxBytes int64 + RxErrs int64 + RxDrop int64 + TxBytes int64 TxPackets int64 - TxErrs int64 - TxDrop int64 + TxErrs int64 + TxDrop int64 } // DomainSetInterfaceParametersArgs is libvirt's remote_domain_set_interface_parameters_args type DomainSetInterfaceParametersArgs struct { - Dom Domain + Dom Domain Device string Params []TypedParam - Flags uint32 + Flags uint32 } // DomainGetInterfaceParametersArgs is libvirt's remote_domain_get_interface_parameters_args type DomainGetInterfaceParametersArgs struct { - Dom Domain - Device string + Dom Domain + Device string Nparams int32 - Flags DomainModificationImpact + Flags DomainModificationImpact } // DomainGetInterfaceParametersRet is libvirt's remote_domain_get_interface_parameters_ret type DomainGetInterfaceParametersRet struct { - Params []TypedParam + Params []TypedParam Nparams int32 } // DomainMemoryStatsArgs is libvirt's remote_domain_memory_stats_args type DomainMemoryStatsArgs struct { - Dom Domain + Dom Domain MaxStats uint32 - Flags uint32 + Flags uint32 } // DomainMemoryStat is libvirt's remote_domain_memory_stat @@ -550,11 +558,11 @@ type DomainMemoryStatsRet struct { // DomainBlockPeekArgs is libvirt's remote_domain_block_peek_args type DomainBlockPeekArgs struct { - Dom Domain - Path string + Dom Domain + Path string Offset uint64 - Size uint32 - Flags uint32 + Size uint32 + Flags uint32 } // DomainBlockPeekRet is libvirt's remote_domain_block_peek_ret @@ -564,10 +572,10 @@ type DomainBlockPeekRet struct { // DomainMemoryPeekArgs is libvirt's remote_domain_memory_peek_args type DomainMemoryPeekArgs struct { - Dom Domain + Dom Domain Offset uint64 - Size uint32 - Flags DomainMemoryFlags + Size uint32 + Flags DomainMemoryFlags } // DomainMemoryPeekRet is libvirt's remote_domain_memory_peek_ret @@ -577,16 +585,16 @@ type DomainMemoryPeekRet struct { // DomainGetBlockInfoArgs is libvirt's remote_domain_get_block_info_args type DomainGetBlockInfoArgs struct { - Dom Domain - Path string + Dom Domain + Path string Flags uint32 } // DomainGetBlockInfoRet is libvirt's remote_domain_get_block_info_ret type DomainGetBlockInfoRet struct { Allocation uint64 - Capacity uint64 - Physical uint64 + Capacity uint64 + Physical uint64 } // ConnectListDomainsArgs is libvirt's remote_connect_list_domains_args @@ -607,7 +615,7 @@ type ConnectNumOfDomainsRet struct { // DomainCreateXMLArgs is libvirt's remote_domain_create_xml_args type DomainCreateXMLArgs struct { XMLDesc string - Flags DomainCreateFlags + Flags DomainCreateFlags } // DomainCreateXMLRet is libvirt's remote_domain_create_xml_ret @@ -618,7 +626,7 @@ type DomainCreateXMLRet struct { // DomainCreateXMLWithFilesArgs is libvirt's remote_domain_create_xml_with_files_args type DomainCreateXMLWithFilesArgs struct { XMLDesc string - Flags DomainCreateFlags + Flags DomainCreateFlags } // DomainCreateXMLWithFilesRet is libvirt's remote_domain_create_xml_with_files_ret @@ -668,15 +676,15 @@ type DomainResumeArgs struct { // DomainPmSuspendForDurationArgs is libvirt's remote_domain_pm_suspend_for_duration_args type DomainPmSuspendForDurationArgs struct { - Dom Domain - Target uint32 + Dom Domain + Target uint32 Duration uint64 - Flags uint32 + Flags uint32 } // DomainPmWakeupArgs is libvirt's remote_domain_pm_wakeup_args type DomainPmWakeupArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -687,13 +695,13 @@ type DomainShutdownArgs struct { // DomainRebootArgs is libvirt's remote_domain_reboot_args type DomainRebootArgs struct { - Dom Domain + Dom Domain Flags DomainRebootFlagValues } // DomainResetArgs is libvirt's remote_domain_reset_args type DomainResetArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -704,7 +712,7 @@ type DomainDestroyArgs struct { // DomainDestroyFlagsArgs is libvirt's remote_domain_destroy_flags_args type DomainDestroyFlagsArgs struct { - Dom Domain + Dom Domain Flags DomainDestroyFlagsValues } @@ -730,28 +738,28 @@ type DomainGetMaxMemoryRet struct { // DomainSetMaxMemoryArgs is libvirt's remote_domain_set_max_memory_args type DomainSetMaxMemoryArgs struct { - Dom Domain + Dom Domain Memory uint64 } // DomainSetMemoryArgs is libvirt's remote_domain_set_memory_args type DomainSetMemoryArgs struct { - Dom Domain + Dom Domain Memory uint64 } // DomainSetMemoryFlagsArgs is libvirt's remote_domain_set_memory_flags_args type DomainSetMemoryFlagsArgs struct { - Dom Domain + Dom Domain Memory uint64 - Flags uint32 + Flags uint32 } // DomainSetMemoryStatsPeriodArgs is libvirt's remote_domain_set_memory_stats_period_args type DomainSetMemoryStatsPeriodArgs struct { - Dom Domain + Dom Domain Period int32 - Flags DomainMemoryModFlags + Flags DomainMemoryModFlags } // DomainGetInfoArgs is libvirt's remote_domain_get_info_args @@ -761,24 +769,24 @@ type DomainGetInfoArgs struct { // DomainGetInfoRet is libvirt's remote_domain_get_info_ret type DomainGetInfoRet struct { - State uint8 - MaxMem uint64 - Memory uint64 + State uint8 + MaxMem uint64 + Memory uint64 NrVirtCPU uint16 - CPUTime uint64 + CPUTime uint64 } // DomainSaveArgs is libvirt's remote_domain_save_args type DomainSaveArgs struct { Dom Domain - To string + To string } // DomainSaveFlagsArgs is libvirt's remote_domain_save_flags_args type DomainSaveFlagsArgs struct { - Dom Domain - To string - Dxml OptString + Dom Domain + To string + Dxml OptString Flags uint32 } @@ -789,14 +797,14 @@ type DomainRestoreArgs struct { // DomainRestoreFlagsArgs is libvirt's remote_domain_restore_flags_args type DomainRestoreFlagsArgs struct { - From string - Dxml OptString + From string + Dxml OptString Flags uint32 } // DomainSaveImageGetXMLDescArgs is libvirt's remote_domain_save_image_get_xml_desc_args type DomainSaveImageGetXMLDescArgs struct { - File string + File string Flags uint32 } @@ -807,31 +815,31 @@ type DomainSaveImageGetXMLDescRet struct { // DomainSaveImageDefineXMLArgs is libvirt's remote_domain_save_image_define_xml_args type DomainSaveImageDefineXMLArgs struct { - File string - Dxml string + File string + Dxml string Flags uint32 } // DomainCoreDumpArgs is libvirt's remote_domain_core_dump_args type DomainCoreDumpArgs struct { - Dom Domain - To string + Dom Domain + To string Flags DomainCoreDumpFlags } // DomainCoreDumpWithFormatArgs is libvirt's remote_domain_core_dump_with_format_args type DomainCoreDumpWithFormatArgs struct { - Dom Domain - To string + Dom Domain + To string Dumpformat uint32 - Flags DomainCoreDumpFlags + Flags DomainCoreDumpFlags } // DomainScreenshotArgs is libvirt's remote_domain_screenshot_args type DomainScreenshotArgs struct { - Dom Domain + Dom Domain Screen uint32 - Flags uint32 + Flags uint32 } // DomainScreenshotRet is libvirt's remote_domain_screenshot_ret @@ -841,7 +849,7 @@ type DomainScreenshotRet struct { // DomainGetXMLDescArgs is libvirt's remote_domain_get_xml_desc_args type DomainGetXMLDescArgs struct { - Dom Domain + Dom Domain Flags DomainXMLFlags } @@ -852,9 +860,9 @@ type DomainGetXMLDescRet struct { // DomainMigratePrepareArgs is libvirt's remote_domain_migrate_prepare_args type DomainMigratePrepareArgs struct { - UriIn OptString - Flags uint64 - Dname OptString + UriIn OptString + Flags uint64 + Dname OptString Resource uint64 } @@ -866,20 +874,20 @@ type DomainMigratePrepareRet struct { // DomainMigratePerformArgs is libvirt's remote_domain_migrate_perform_args type DomainMigratePerformArgs struct { - Dom Domain - Cookie []byte - Uri string - Flags uint64 - Dname OptString + Dom Domain + Cookie []byte + Uri string + Flags uint64 + Dname OptString Resource uint64 } // DomainMigrateFinishArgs is libvirt's remote_domain_migrate_finish_args type DomainMigrateFinishArgs struct { - Dname string + Dname string Cookie []byte - Uri string - Flags uint64 + Uri string + Flags uint64 } // DomainMigrateFinishRet is libvirt's remote_domain_migrate_finish_ret @@ -889,11 +897,11 @@ type DomainMigrateFinishRet struct { // DomainMigratePrepare2Args is libvirt's remote_domain_migrate_prepare2_args type DomainMigratePrepare2Args struct { - UriIn OptString - Flags uint64 - Dname OptString + UriIn OptString + Flags uint64 + Dname OptString Resource uint64 - DomXML string + DomXML string } // DomainMigratePrepare2Ret is libvirt's remote_domain_migrate_prepare2_ret @@ -904,10 +912,10 @@ type DomainMigratePrepare2Ret struct { // DomainMigrateFinish2Args is libvirt's remote_domain_migrate_finish2_args type DomainMigrateFinish2Args struct { - Dname string - Cookie []byte - Uri string - Flags uint64 + Dname string + Cookie []byte + Uri string + Flags uint64 Retcode int32 } @@ -938,7 +946,7 @@ type DomainCreateArgs struct { // DomainCreateWithFlagsArgs is libvirt's remote_domain_create_with_flags_args type DomainCreateWithFlagsArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -949,7 +957,7 @@ type DomainCreateWithFlagsRet struct { // DomainCreateWithFilesArgs is libvirt's remote_domain_create_with_files_args type DomainCreateWithFilesArgs struct { - Dom Domain + Dom Domain Flags DomainCreateFlags } @@ -970,7 +978,7 @@ type DomainDefineXMLRet struct { // DomainDefineXMLFlagsArgs is libvirt's remote_domain_define_xml_flags_args type DomainDefineXMLFlagsArgs struct { - XML string + XML string Flags DomainDefineFlags } @@ -986,49 +994,49 @@ type DomainUndefineArgs struct { // DomainUndefineFlagsArgs is libvirt's remote_domain_undefine_flags_args type DomainUndefineFlagsArgs struct { - Dom Domain + Dom Domain Flags DomainUndefineFlagsValues } // DomainInjectNmiArgs is libvirt's remote_domain_inject_nmi_args type DomainInjectNmiArgs struct { - Dom Domain + Dom Domain Flags uint32 } // DomainSendKeyArgs is libvirt's remote_domain_send_key_args type DomainSendKeyArgs struct { - Dom Domain - Codeset uint32 + Dom Domain + Codeset uint32 Holdtime uint32 Keycodes []uint32 - Flags uint32 + Flags uint32 } // DomainSendProcessSignalArgs is libvirt's remote_domain_send_process_signal_args type DomainSendProcessSignalArgs struct { - Dom Domain + Dom Domain PidValue int64 - Signum uint32 - Flags uint32 + Signum uint32 + Flags uint32 } // DomainSetVcpusArgs is libvirt's remote_domain_set_vcpus_args type DomainSetVcpusArgs struct { - Dom Domain + Dom Domain Nvcpus uint32 } // DomainSetVcpusFlagsArgs is libvirt's remote_domain_set_vcpus_flags_args type DomainSetVcpusFlagsArgs struct { - Dom Domain + Dom Domain Nvcpus uint32 - Flags uint32 + Flags uint32 } // DomainGetVcpusFlagsArgs is libvirt's remote_domain_get_vcpus_flags_args type DomainGetVcpusFlagsArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -1039,63 +1047,63 @@ type DomainGetVcpusFlagsRet struct { // DomainPinVcpuArgs is libvirt's remote_domain_pin_vcpu_args type DomainPinVcpuArgs struct { - Dom Domain - Vcpu uint32 + Dom Domain + Vcpu uint32 Cpumap []byte } // DomainPinVcpuFlagsArgs is libvirt's remote_domain_pin_vcpu_flags_args type DomainPinVcpuFlagsArgs struct { - Dom Domain - Vcpu uint32 + Dom Domain + Vcpu uint32 Cpumap []byte - Flags uint32 + Flags uint32 } // DomainGetVcpuPinInfoArgs is libvirt's remote_domain_get_vcpu_pin_info_args type DomainGetVcpuPinInfoArgs struct { - Dom Domain + Dom Domain Ncpumaps int32 - Maplen int32 - Flags uint32 + Maplen int32 + Flags uint32 } // DomainGetVcpuPinInfoRet is libvirt's remote_domain_get_vcpu_pin_info_ret type DomainGetVcpuPinInfoRet struct { Cpumaps []byte - Num int32 + Num int32 } // DomainPinEmulatorArgs is libvirt's remote_domain_pin_emulator_args type DomainPinEmulatorArgs struct { - Dom Domain + Dom Domain Cpumap []byte - Flags DomainModificationImpact + Flags DomainModificationImpact } // DomainGetEmulatorPinInfoArgs is libvirt's remote_domain_get_emulator_pin_info_args type DomainGetEmulatorPinInfoArgs struct { - Dom Domain + Dom Domain Maplen int32 - Flags DomainModificationImpact + Flags DomainModificationImpact } // DomainGetEmulatorPinInfoRet is libvirt's remote_domain_get_emulator_pin_info_ret type DomainGetEmulatorPinInfoRet struct { Cpumaps []byte - Ret int32 + Ret int32 } // DomainGetVcpusArgs is libvirt's remote_domain_get_vcpus_args type DomainGetVcpusArgs struct { - Dom Domain + Dom Domain Maxinfo int32 - Maplen int32 + Maplen int32 } // DomainGetVcpusRet is libvirt's remote_domain_get_vcpus_ret type DomainGetVcpusRet struct { - Info []VcpuInfo + Info []VcpuInfo Cpumaps []byte } @@ -1112,49 +1120,49 @@ type DomainGetMaxVcpusRet struct { // DomainIothreadInfo is libvirt's remote_domain_iothread_info type DomainIothreadInfo struct { IothreadID uint32 - Cpumap []byte + Cpumap []byte } // DomainGetIothreadInfoArgs is libvirt's remote_domain_get_iothread_info_args type DomainGetIothreadInfoArgs struct { - Dom Domain + Dom Domain Flags DomainModificationImpact } // DomainGetIothreadInfoRet is libvirt's remote_domain_get_iothread_info_ret type DomainGetIothreadInfoRet struct { Info []DomainIothreadInfo - Ret uint32 + Ret uint32 } // DomainPinIothreadArgs is libvirt's remote_domain_pin_iothread_args type DomainPinIothreadArgs struct { - Dom Domain + Dom Domain IothreadsID uint32 - Cpumap []byte - Flags DomainModificationImpact + Cpumap []byte + Flags DomainModificationImpact } // DomainAddIothreadArgs is libvirt's remote_domain_add_iothread_args type DomainAddIothreadArgs struct { - Dom Domain + Dom Domain IothreadID uint32 - Flags DomainModificationImpact + Flags DomainModificationImpact } // DomainDelIothreadArgs is libvirt's remote_domain_del_iothread_args type DomainDelIothreadArgs struct { - Dom Domain + Dom Domain IothreadID uint32 - Flags DomainModificationImpact + Flags DomainModificationImpact } // DomainSetIothreadParamsArgs is libvirt's remote_domain_set_iothread_params_args type DomainSetIothreadParamsArgs struct { - Dom Domain + Dom Domain IothreadID uint32 - Params []TypedParam - Flags uint32 + Params []TypedParam + Flags uint32 } // DomainGetSecurityLabelArgs is libvirt's remote_domain_get_security_label_args @@ -1164,7 +1172,7 @@ type DomainGetSecurityLabelArgs struct { // DomainGetSecurityLabelRet is libvirt's remote_domain_get_security_label_ret type DomainGetSecurityLabelRet struct { - Label []int8 + Label []int8 Enforcing int32 } @@ -1176,13 +1184,13 @@ type DomainGetSecurityLabelListArgs struct { // DomainGetSecurityLabelListRet is libvirt's remote_domain_get_security_label_list_ret type DomainGetSecurityLabelListRet struct { Labels []DomainGetSecurityLabelRet - Ret int32 + Ret int32 } // NodeGetSecurityModelRet is libvirt's remote_node_get_security_model_ret type NodeGetSecurityModelRet struct { Model []int8 - Doi []int8 + Doi []int8 } // DomainAttachDeviceArgs is libvirt's remote_domain_attach_device_args @@ -1193,8 +1201,8 @@ type DomainAttachDeviceArgs struct { // DomainAttachDeviceFlagsArgs is libvirt's remote_domain_attach_device_flags_args type DomainAttachDeviceFlagsArgs struct { - Dom Domain - XML string + Dom Domain + XML string Flags uint32 } @@ -1206,21 +1214,21 @@ type DomainDetachDeviceArgs struct { // DomainDetachDeviceFlagsArgs is libvirt's remote_domain_detach_device_flags_args type DomainDetachDeviceFlagsArgs struct { - Dom Domain - XML string + Dom Domain + XML string Flags uint32 } // DomainUpdateDeviceFlagsArgs is libvirt's remote_domain_update_device_flags_args type DomainUpdateDeviceFlagsArgs struct { - Dom Domain - XML string + Dom Domain + XML string Flags DomainDeviceModifyFlags } // DomainDetachDeviceAliasArgs is libvirt's remote_domain_detach_device_alias_args type DomainDetachDeviceAliasArgs struct { - Dom Domain + Dom Domain Alias string Flags uint32 } @@ -1237,25 +1245,25 @@ type DomainGetAutostartRet struct { // DomainSetAutostartArgs is libvirt's remote_domain_set_autostart_args type DomainSetAutostartArgs struct { - Dom Domain + Dom Domain Autostart int32 } // DomainSetMetadataArgs is libvirt's remote_domain_set_metadata_args type DomainSetMetadataArgs struct { - Dom Domain - Type int32 + Dom Domain + Type int32 Metadata OptString - Key OptString - Uri OptString - Flags DomainModificationImpact + Key OptString + Uri OptString + Flags DomainModificationImpact } // DomainGetMetadataArgs is libvirt's remote_domain_get_metadata_args type DomainGetMetadataArgs struct { - Dom Domain - Type int32 - Uri OptString + Dom Domain + Type int32 + Uri OptString Flags DomainModificationImpact } @@ -1266,111 +1274,111 @@ type DomainGetMetadataRet struct { // DomainBlockJobAbortArgs is libvirt's remote_domain_block_job_abort_args type DomainBlockJobAbortArgs struct { - Dom Domain - Path string + Dom Domain + Path string Flags DomainBlockJobAbortFlags } // DomainGetBlockJobInfoArgs is libvirt's remote_domain_get_block_job_info_args type DomainGetBlockJobInfoArgs struct { - Dom Domain - Path string + Dom Domain + Path string Flags uint32 } // DomainGetBlockJobInfoRet is libvirt's remote_domain_get_block_job_info_ret type DomainGetBlockJobInfoRet struct { - Found int32 - Type int32 + Found int32 + Type int32 Bandwidth uint64 - Cur uint64 - End uint64 + Cur uint64 + End uint64 } // DomainBlockJobSetSpeedArgs is libvirt's remote_domain_block_job_set_speed_args type DomainBlockJobSetSpeedArgs struct { - Dom Domain - Path string + Dom Domain + Path string Bandwidth uint64 - Flags DomainBlockJobSetSpeedFlags + Flags DomainBlockJobSetSpeedFlags } // DomainBlockPullArgs is libvirt's remote_domain_block_pull_args type DomainBlockPullArgs struct { - Dom Domain - Path string + Dom Domain + Path string Bandwidth uint64 - Flags DomainBlockPullFlags + Flags DomainBlockPullFlags } // DomainBlockRebaseArgs is libvirt's remote_domain_block_rebase_args type DomainBlockRebaseArgs struct { - Dom Domain - Path string - Base OptString + Dom Domain + Path string + Base OptString Bandwidth uint64 - Flags DomainBlockRebaseFlags + Flags DomainBlockRebaseFlags } // DomainBlockCopyArgs is libvirt's remote_domain_block_copy_args type DomainBlockCopyArgs struct { - Dom Domain - Path string + Dom Domain + Path string Destxml string - Params []TypedParam - Flags DomainBlockCopyFlags + Params []TypedParam + Flags DomainBlockCopyFlags } // DomainBlockCommitArgs is libvirt's remote_domain_block_commit_args type DomainBlockCommitArgs struct { - Dom Domain - Disk string - Base OptString - Top OptString + Dom Domain + Disk string + Base OptString + Top OptString Bandwidth uint64 - Flags DomainBlockCommitFlags + Flags DomainBlockCommitFlags } // DomainSetBlockIOTuneArgs is libvirt's remote_domain_set_block_io_tune_args type DomainSetBlockIOTuneArgs struct { - Dom Domain - Disk string + Dom Domain + Disk string Params []TypedParam - Flags uint32 + Flags uint32 } // DomainGetBlockIOTuneArgs is libvirt's remote_domain_get_block_io_tune_args type DomainGetBlockIOTuneArgs struct { - Dom Domain - Disk OptString + Dom Domain + Disk OptString Nparams int32 - Flags uint32 + Flags uint32 } // DomainGetBlockIOTuneRet is libvirt's remote_domain_get_block_io_tune_ret type DomainGetBlockIOTuneRet struct { - Params []TypedParam + Params []TypedParam Nparams int32 } // DomainGetCPUStatsArgs is libvirt's remote_domain_get_cpu_stats_args type DomainGetCPUStatsArgs struct { - Dom Domain - Nparams uint32 + Dom Domain + Nparams uint32 StartCPU int32 - Ncpus uint32 - Flags TypedParameterFlags + Ncpus uint32 + Flags TypedParameterFlags } // DomainGetCPUStatsRet is libvirt's remote_domain_get_cpu_stats_ret type DomainGetCPUStatsRet struct { - Params []TypedParam + Params []TypedParam Nparams int32 } // DomainGetHostnameArgs is libvirt's remote_domain_get_hostname_args type DomainGetHostnameArgs struct { - Dom Domain + Dom Domain Flags DomainGetHostnameFlags } @@ -1456,12 +1464,12 @@ type NetworkUndefineArgs struct { // NetworkUpdateArgs is libvirt's remote_network_update_args type NetworkUpdateArgs struct { - Net Network - Command uint32 - Section uint32 + Net Network + Command uint32 + Section uint32 ParentIndex int32 - XML string - Flags NetworkUpdateFlags + XML string + Flags NetworkUpdateFlags } // NetworkCreateArgs is libvirt's remote_network_create_args @@ -1476,7 +1484,7 @@ type NetworkDestroyArgs struct { // NetworkGetXMLDescArgs is libvirt's remote_network_get_xml_desc_args type NetworkGetXMLDescArgs struct { - Net Network + Net Network Flags uint32 } @@ -1507,7 +1515,7 @@ type NetworkGetAutostartRet struct { // NetworkSetAutostartArgs is libvirt's remote_network_set_autostart_args type NetworkSetAutostartArgs struct { - Net Network + Net Network Autostart int32 } @@ -1564,7 +1572,7 @@ type NwfilterUndefineArgs struct { // NwfilterGetXMLDescArgs is libvirt's remote_nwfilter_get_xml_desc_args type NwfilterGetXMLDescArgs struct { OptNwfilter Nwfilter - Flags uint32 + Flags uint32 } // NwfilterGetXMLDescRet is libvirt's remote_nwfilter_get_xml_desc_ret @@ -1635,7 +1643,7 @@ type InterfaceGetXMLDescRet struct { // InterfaceDefineXMLArgs is libvirt's remote_interface_define_xml_args type InterfaceDefineXMLArgs struct { - XML string + XML string Flags uint32 } @@ -1689,28 +1697,28 @@ type AuthSaslInitRet struct { // AuthSaslStartArgs is libvirt's remote_auth_sasl_start_args type AuthSaslStartArgs struct { Mech string - Nil int32 + Nil int32 Data []int8 } // AuthSaslStartRet is libvirt's remote_auth_sasl_start_ret type AuthSaslStartRet struct { Complete int32 - Nil int32 - Data []int8 + Nil int32 + Data []int8 } // AuthSaslStepArgs is libvirt's remote_auth_sasl_step_args type AuthSaslStepArgs struct { - Nil int32 + Nil int32 Data []int8 } // AuthSaslStepRet is libvirt's remote_auth_sasl_step_ret type AuthSaslStepRet struct { Complete int32 - Nil int32 - Data []int8 + Nil int32 + Data []int8 } // AuthPolkitRet is libvirt's remote_auth_polkit_ret @@ -1750,9 +1758,9 @@ type ConnectListDefinedStoragePoolsRet struct { // ConnectFindStoragePoolSourcesArgs is libvirt's remote_connect_find_storage_pool_sources_args type ConnectFindStoragePoolSourcesArgs struct { - Type string + Type string SrcSpec OptString - Flags uint32 + Flags uint32 } // ConnectFindStoragePoolSourcesRet is libvirt's remote_connect_find_storage_pool_sources_ret @@ -1802,7 +1810,7 @@ type StoragePoolLookupByTargetPathRet struct { // StoragePoolCreateXMLArgs is libvirt's remote_storage_pool_create_xml_args type StoragePoolCreateXMLArgs struct { - XML string + XML string Flags StoragePoolCreateFlags } @@ -1813,7 +1821,7 @@ type StoragePoolCreateXMLRet struct { // StoragePoolDefineXMLArgs is libvirt's remote_storage_pool_define_xml_args type StoragePoolDefineXMLArgs struct { - XML string + XML string Flags uint32 } @@ -1824,7 +1832,7 @@ type StoragePoolDefineXMLRet struct { // StoragePoolBuildArgs is libvirt's remote_storage_pool_build_args type StoragePoolBuildArgs struct { - Pool StoragePool + Pool StoragePool Flags StoragePoolBuildFlags } @@ -1835,7 +1843,7 @@ type StoragePoolUndefineArgs struct { // StoragePoolCreateArgs is libvirt's remote_storage_pool_create_args type StoragePoolCreateArgs struct { - Pool StoragePool + Pool StoragePool Flags StoragePoolCreateFlags } @@ -1846,19 +1854,19 @@ type StoragePoolDestroyArgs struct { // StoragePoolDeleteArgs is libvirt's remote_storage_pool_delete_args type StoragePoolDeleteArgs struct { - Pool StoragePool + Pool StoragePool Flags StoragePoolDeleteFlags } // StoragePoolRefreshArgs is libvirt's remote_storage_pool_refresh_args type StoragePoolRefreshArgs struct { - Pool StoragePool + Pool StoragePool Flags uint32 } // StoragePoolGetXMLDescArgs is libvirt's remote_storage_pool_get_xml_desc_args type StoragePoolGetXMLDescArgs struct { - Pool StoragePool + Pool StoragePool Flags StorageXMLFlags } @@ -1874,10 +1882,10 @@ type StoragePoolGetInfoArgs struct { // StoragePoolGetInfoRet is libvirt's remote_storage_pool_get_info_ret type StoragePoolGetInfoRet struct { - State uint8 - Capacity uint64 + State uint8 + Capacity uint64 Allocation uint64 - Available uint64 + Available uint64 } // StoragePoolGetAutostartArgs is libvirt's remote_storage_pool_get_autostart_args @@ -1892,7 +1900,7 @@ type StoragePoolGetAutostartRet struct { // StoragePoolSetAutostartArgs is libvirt's remote_storage_pool_set_autostart_args type StoragePoolSetAutostartArgs struct { - Pool StoragePool + Pool StoragePool Autostart int32 } @@ -1908,7 +1916,7 @@ type StoragePoolNumOfVolumesRet struct { // StoragePoolListVolumesArgs is libvirt's remote_storage_pool_list_volumes_args type StoragePoolListVolumesArgs struct { - Pool StoragePool + Pool StoragePool Maxnames int32 } @@ -1950,8 +1958,8 @@ type StorageVolLookupByPathRet struct { // StorageVolCreateXMLArgs is libvirt's remote_storage_vol_create_xml_args type StorageVolCreateXMLArgs struct { - Pool StoragePool - XML string + Pool StoragePool + XML string Flags StorageVolCreateFlags } @@ -1962,10 +1970,10 @@ type StorageVolCreateXMLRet struct { // StorageVolCreateXMLFromArgs is libvirt's remote_storage_vol_create_xml_from_args type StorageVolCreateXMLFromArgs struct { - Pool StoragePool - XML string + Pool StoragePool + XML string Clonevol StorageVol - Flags StorageVolCreateFlags + Flags StorageVolCreateFlags } // StorageVolCreateXMLFromRet is libvirt's remote_storage_vol_create_xml_from_ret @@ -1975,26 +1983,26 @@ type StorageVolCreateXMLFromRet struct { // StorageVolDeleteArgs is libvirt's remote_storage_vol_delete_args type StorageVolDeleteArgs struct { - Vol StorageVol + Vol StorageVol Flags StorageVolDeleteFlags } // StorageVolWipeArgs is libvirt's remote_storage_vol_wipe_args type StorageVolWipeArgs struct { - Vol StorageVol + Vol StorageVol Flags uint32 } // StorageVolWipePatternArgs is libvirt's remote_storage_vol_wipe_pattern_args type StorageVolWipePatternArgs struct { - Vol StorageVol + Vol StorageVol Algorithm uint32 - Flags uint32 + Flags uint32 } // StorageVolGetXMLDescArgs is libvirt's remote_storage_vol_get_xml_desc_args type StorageVolGetXMLDescArgs struct { - Vol StorageVol + Vol StorageVol Flags uint32 } @@ -2010,21 +2018,21 @@ type StorageVolGetInfoArgs struct { // StorageVolGetInfoRet is libvirt's remote_storage_vol_get_info_ret type StorageVolGetInfoRet struct { - Type int8 - Capacity uint64 + Type int8 + Capacity uint64 Allocation uint64 } // StorageVolGetInfoFlagsArgs is libvirt's remote_storage_vol_get_info_flags_args type StorageVolGetInfoFlagsArgs struct { - Vol StorageVol + Vol StorageVol Flags uint32 } // StorageVolGetInfoFlagsRet is libvirt's remote_storage_vol_get_info_flags_ret type StorageVolGetInfoFlagsRet struct { - Type int8 - Capacity uint64 + Type int8 + Capacity uint64 Allocation uint64 } @@ -2040,14 +2048,14 @@ type StorageVolGetPathRet struct { // StorageVolResizeArgs is libvirt's remote_storage_vol_resize_args type StorageVolResizeArgs struct { - Vol StorageVol + Vol StorageVol Capacity uint64 - Flags StorageVolResizeFlags + Flags StorageVolResizeFlags } // NodeNumOfDevicesArgs is libvirt's remote_node_num_of_devices_args type NodeNumOfDevicesArgs struct { - Cap OptString + Cap OptString Flags uint32 } @@ -2058,9 +2066,9 @@ type NodeNumOfDevicesRet struct { // NodeListDevicesArgs is libvirt's remote_node_list_devices_args type NodeListDevicesArgs struct { - Cap OptString + Cap OptString Maxnames int32 - Flags uint32 + Flags uint32 } // NodeListDevicesRet is libvirt's remote_node_list_devices_ret @@ -2080,8 +2088,8 @@ type NodeDeviceLookupByNameRet struct { // NodeDeviceLookupScsiHostByWwnArgs is libvirt's remote_node_device_lookup_scsi_host_by_wwn_args type NodeDeviceLookupScsiHostByWwnArgs struct { - Wwnn string - Wwpn string + Wwnn string + Wwpn string Flags uint32 } @@ -2092,7 +2100,7 @@ type NodeDeviceLookupScsiHostByWwnRet struct { // NodeDeviceGetXMLDescArgs is libvirt's remote_node_device_get_xml_desc_args type NodeDeviceGetXMLDescArgs struct { - Name string + Name string Flags uint32 } @@ -2123,7 +2131,7 @@ type NodeDeviceNumOfCapsRet struct { // NodeDeviceListCapsArgs is libvirt's remote_node_device_list_caps_args type NodeDeviceListCapsArgs struct { - Name string + Name string Maxnames int32 } @@ -2139,9 +2147,9 @@ type NodeDeviceDettachArgs struct { // NodeDeviceDetachFlagsArgs is libvirt's remote_node_device_detach_flags_args type NodeDeviceDetachFlagsArgs struct { - Name string + Name string DriverName OptString - Flags uint32 + Flags uint32 } // NodeDeviceReAttachArgs is libvirt's remote_node_device_re_attach_args @@ -2157,7 +2165,7 @@ type NodeDeviceResetArgs struct { // NodeDeviceCreateXMLArgs is libvirt's remote_node_device_create_xml_args type NodeDeviceCreateXMLArgs struct { XMLDesc string - Flags uint32 + Flags uint32 } // NodeDeviceCreateXMLRet is libvirt's remote_node_device_create_xml_ret @@ -2182,22 +2190,22 @@ type ConnectDomainEventDeregisterRet struct { // DomainEventLifecycleMsg is libvirt's remote_domain_event_lifecycle_msg type DomainEventLifecycleMsg struct { - Dom Domain - Event int32 + Dom Domain + Event int32 Detail int32 } // DomainEventCallbackLifecycleMsg is libvirt's remote_domain_event_callback_lifecycle_msg type DomainEventCallbackLifecycleMsg struct { CallbackID int32 - Msg DomainEventLifecycleMsg + Msg DomainEventLifecycleMsg } // ConnectDomainXMLFromNativeArgs is libvirt's remote_connect_domain_xml_from_native_args type ConnectDomainXMLFromNativeArgs struct { NativeFormat string NativeConfig string - Flags uint32 + Flags uint32 } // ConnectDomainXMLFromNativeRet is libvirt's remote_connect_domain_xml_from_native_ret @@ -2208,8 +2216,8 @@ type ConnectDomainXMLFromNativeRet struct { // ConnectDomainXMLToNativeArgs is libvirt's remote_connect_domain_xml_to_native_args type ConnectDomainXMLToNativeArgs struct { NativeFormat string - DomainXML string - Flags uint32 + DomainXML string + Flags uint32 } // ConnectDomainXMLToNativeRet is libvirt's remote_connect_domain_xml_to_native_ret @@ -2244,7 +2252,7 @@ type SecretLookupByUUIDRet struct { // SecretDefineXMLArgs is libvirt's remote_secret_define_xml_args type SecretDefineXMLArgs struct { - XML string + XML string Flags uint32 } @@ -2256,7 +2264,7 @@ type SecretDefineXMLRet struct { // SecretGetXMLDescArgs is libvirt's remote_secret_get_xml_desc_args type SecretGetXMLDescArgs struct { OptSecret Secret - Flags uint32 + Flags uint32 } // SecretGetXMLDescRet is libvirt's remote_secret_get_xml_desc_ret @@ -2267,14 +2275,14 @@ type SecretGetXMLDescRet struct { // SecretSetValueArgs is libvirt's remote_secret_set_value_args type SecretSetValueArgs struct { OptSecret Secret - Value []byte - Flags uint32 + Value []byte + Flags uint32 } // SecretGetValueArgs is libvirt's remote_secret_get_value_args type SecretGetValueArgs struct { OptSecret Secret - Flags uint32 + Flags uint32 } // SecretGetValueRet is libvirt's remote_secret_get_value_ret @@ -2290,7 +2298,7 @@ type SecretUndefineArgs struct { // SecretLookupByUsageArgs is libvirt's remote_secret_lookup_by_usage_args type SecretLookupByUsageArgs struct { UsageType int32 - UsageID string + UsageID string } // SecretLookupByUsageRet is libvirt's remote_secret_lookup_by_usage_ret @@ -2300,10 +2308,10 @@ type SecretLookupByUsageRet struct { // DomainMigratePrepareTunnelArgs is libvirt's remote_domain_migrate_prepare_tunnel_args type DomainMigratePrepareTunnelArgs struct { - Flags uint64 - Dname OptString + Flags uint64 + Dname OptString Resource uint64 - DomXML string + DomXML string } // ConnectIsSecureRet is libvirt's remote_connect_is_secure_ret @@ -2393,7 +2401,7 @@ type InterfaceIsActiveRet struct { // ConnectCompareCPUArgs is libvirt's remote_connect_compare_cpu_args type ConnectCompareCPUArgs struct { - XML string + XML string Flags ConnectCompareCPUFlags } @@ -2405,7 +2413,7 @@ type ConnectCompareCPURet struct { // ConnectBaselineCPUArgs is libvirt's remote_connect_baseline_cpu_args type ConnectBaselineCPUArgs struct { XMLCPUs []string - Flags ConnectBaselineCPUFlags + Flags ConnectBaselineCPUFlags } // ConnectBaselineCPURet is libvirt's remote_connect_baseline_cpu_ret @@ -2420,29 +2428,29 @@ type DomainGetJobInfoArgs struct { // DomainGetJobInfoRet is libvirt's remote_domain_get_job_info_ret type DomainGetJobInfoRet struct { - Type int32 - TimeElapsed uint64 + Type int32 + TimeElapsed uint64 TimeRemaining uint64 - DataTotal uint64 + DataTotal uint64 DataProcessed uint64 DataRemaining uint64 - MemTotal uint64 - MemProcessed uint64 - MemRemaining uint64 - FileTotal uint64 + MemTotal uint64 + MemProcessed uint64 + MemRemaining uint64 + FileTotal uint64 FileProcessed uint64 FileRemaining uint64 } // DomainGetJobStatsArgs is libvirt's remote_domain_get_job_stats_args type DomainGetJobStatsArgs struct { - Dom Domain + Dom Domain Flags DomainGetJobStatsFlags } // DomainGetJobStatsRet is libvirt's remote_domain_get_job_stats_ret type DomainGetJobStatsRet struct { - Type int32 + Type int32 Params []TypedParam } @@ -2453,7 +2461,7 @@ type DomainAbortJobArgs struct { // DomainMigrateGetMaxDowntimeArgs is libvirt's remote_domain_migrate_get_max_downtime_args type DomainMigrateGetMaxDowntimeArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -2464,14 +2472,14 @@ type DomainMigrateGetMaxDowntimeRet struct { // DomainMigrateSetMaxDowntimeArgs is libvirt's remote_domain_migrate_set_max_downtime_args type DomainMigrateSetMaxDowntimeArgs struct { - Dom Domain + Dom Domain Downtime uint64 - Flags uint32 + Flags uint32 } // DomainMigrateGetCompressionCacheArgs is libvirt's remote_domain_migrate_get_compression_cache_args type DomainMigrateGetCompressionCacheArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -2482,21 +2490,21 @@ type DomainMigrateGetCompressionCacheRet struct { // DomainMigrateSetCompressionCacheArgs is libvirt's remote_domain_migrate_set_compression_cache_args type DomainMigrateSetCompressionCacheArgs struct { - Dom Domain + Dom Domain CacheSize uint64 - Flags uint32 + Flags uint32 } // DomainMigrateSetMaxSpeedArgs is libvirt's remote_domain_migrate_set_max_speed_args type DomainMigrateSetMaxSpeedArgs struct { - Dom Domain + Dom Domain Bandwidth uint64 - Flags uint32 + Flags uint32 } // DomainMigrateGetMaxSpeedArgs is libvirt's remote_domain_migrate_get_max_speed_args type DomainMigrateGetMaxSpeedArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -2518,7 +2526,7 @@ type ConnectDomainEventDeregisterAnyArgs struct { // ConnectDomainEventCallbackRegisterAnyArgs is libvirt's remote_connect_domain_event_callback_register_any_args type ConnectDomainEventCallbackRegisterAnyArgs struct { EventID int32 - Dom OptDomain + Dom OptDomain } // ConnectDomainEventCallbackRegisterAnyRet is libvirt's remote_connect_domain_event_callback_register_any_ret @@ -2539,66 +2547,66 @@ type DomainEventRebootMsg struct { // DomainEventCallbackRebootMsg is libvirt's remote_domain_event_callback_reboot_msg type DomainEventCallbackRebootMsg struct { CallbackID int32 - Msg DomainEventRebootMsg + Msg DomainEventRebootMsg } // DomainEventRtcChangeMsg is libvirt's remote_domain_event_rtc_change_msg type DomainEventRtcChangeMsg struct { - Dom Domain + Dom Domain Offset int64 } // DomainEventCallbackRtcChangeMsg is libvirt's remote_domain_event_callback_rtc_change_msg type DomainEventCallbackRtcChangeMsg struct { CallbackID int32 - Msg DomainEventRtcChangeMsg + Msg DomainEventRtcChangeMsg } // DomainEventWatchdogMsg is libvirt's remote_domain_event_watchdog_msg type DomainEventWatchdogMsg struct { - Dom Domain + Dom Domain Action int32 } // DomainEventCallbackWatchdogMsg is libvirt's remote_domain_event_callback_watchdog_msg type DomainEventCallbackWatchdogMsg struct { CallbackID int32 - Msg DomainEventWatchdogMsg + Msg DomainEventWatchdogMsg } // DomainEventIOErrorMsg is libvirt's remote_domain_event_io_error_msg type DomainEventIOErrorMsg struct { - Dom Domain - SrcPath string + Dom Domain + SrcPath string DevAlias string - Action int32 + Action int32 } // DomainEventCallbackIOErrorMsg is libvirt's remote_domain_event_callback_io_error_msg type DomainEventCallbackIOErrorMsg struct { CallbackID int32 - Msg DomainEventIOErrorMsg + Msg DomainEventIOErrorMsg } // DomainEventIOErrorReasonMsg is libvirt's remote_domain_event_io_error_reason_msg type DomainEventIOErrorReasonMsg struct { - Dom Domain - SrcPath string + Dom Domain + SrcPath string DevAlias string - Action int32 - Reason string + Action int32 + Reason string } // DomainEventCallbackIOErrorReasonMsg is libvirt's remote_domain_event_callback_io_error_reason_msg type DomainEventCallbackIOErrorReasonMsg struct { CallbackID int32 - Msg DomainEventIOErrorReasonMsg + Msg DomainEventIOErrorReasonMsg } // DomainEventGraphicsAddress is libvirt's remote_domain_event_graphics_address type DomainEventGraphicsAddress struct { - Family int32 - Node string + Family int32 + Node string Service string } @@ -2610,60 +2618,60 @@ type DomainEventGraphicsIdentity struct { // DomainEventGraphicsMsg is libvirt's remote_domain_event_graphics_msg type DomainEventGraphicsMsg struct { - Dom Domain - Phase int32 - Local DomainEventGraphicsAddress - Remote DomainEventGraphicsAddress + Dom Domain + Phase int32 + Local DomainEventGraphicsAddress + Remote DomainEventGraphicsAddress AuthScheme string - Subject []DomainEventGraphicsIdentity + Subject []DomainEventGraphicsIdentity } // DomainEventCallbackGraphicsMsg is libvirt's remote_domain_event_callback_graphics_msg type DomainEventCallbackGraphicsMsg struct { CallbackID int32 - Msg DomainEventGraphicsMsg + Msg DomainEventGraphicsMsg } // DomainEventBlockJobMsg is libvirt's remote_domain_event_block_job_msg type DomainEventBlockJobMsg struct { - Dom Domain - Path string - Type int32 + Dom Domain + Path string + Type int32 Status int32 } // DomainEventCallbackBlockJobMsg is libvirt's remote_domain_event_callback_block_job_msg type DomainEventCallbackBlockJobMsg struct { CallbackID int32 - Msg DomainEventBlockJobMsg + Msg DomainEventBlockJobMsg } // DomainEventDiskChangeMsg is libvirt's remote_domain_event_disk_change_msg type DomainEventDiskChangeMsg struct { - Dom Domain + Dom Domain OldSrcPath OptString NewSrcPath OptString - DevAlias string - Reason int32 + DevAlias string + Reason int32 } // DomainEventCallbackDiskChangeMsg is libvirt's remote_domain_event_callback_disk_change_msg type DomainEventCallbackDiskChangeMsg struct { CallbackID int32 - Msg DomainEventDiskChangeMsg + Msg DomainEventDiskChangeMsg } // DomainEventTrayChangeMsg is libvirt's remote_domain_event_tray_change_msg type DomainEventTrayChangeMsg struct { - Dom Domain + Dom Domain DevAlias string - Reason int32 + Reason int32 } // DomainEventCallbackTrayChangeMsg is libvirt's remote_domain_event_callback_tray_change_msg type DomainEventCallbackTrayChangeMsg struct { CallbackID int32 - Msg DomainEventTrayChangeMsg + Msg DomainEventTrayChangeMsg } // DomainEventPmwakeupMsg is libvirt's remote_domain_event_pmwakeup_msg @@ -2674,8 +2682,8 @@ type DomainEventPmwakeupMsg struct { // DomainEventCallbackPmwakeupMsg is libvirt's remote_domain_event_callback_pmwakeup_msg type DomainEventCallbackPmwakeupMsg struct { CallbackID int32 - Reason int32 - Msg DomainEventPmwakeupMsg + Reason int32 + Msg DomainEventPmwakeupMsg } // DomainEventPmsuspendMsg is libvirt's remote_domain_event_pmsuspend_msg @@ -2686,20 +2694,20 @@ type DomainEventPmsuspendMsg struct { // DomainEventCallbackPmsuspendMsg is libvirt's remote_domain_event_callback_pmsuspend_msg type DomainEventCallbackPmsuspendMsg struct { CallbackID int32 - Reason int32 - Msg DomainEventPmsuspendMsg + Reason int32 + Msg DomainEventPmsuspendMsg } // DomainEventBalloonChangeMsg is libvirt's remote_domain_event_balloon_change_msg type DomainEventBalloonChangeMsg struct { - Dom Domain + Dom Domain Actual uint64 } // DomainEventCallbackBalloonChangeMsg is libvirt's remote_domain_event_callback_balloon_change_msg type DomainEventCallbackBalloonChangeMsg struct { CallbackID int32 - Msg DomainEventBalloonChangeMsg + Msg DomainEventBalloonChangeMsg } // DomainEventPmsuspendDiskMsg is libvirt's remote_domain_event_pmsuspend_disk_msg @@ -2710,19 +2718,19 @@ type DomainEventPmsuspendDiskMsg struct { // DomainEventCallbackPmsuspendDiskMsg is libvirt's remote_domain_event_callback_pmsuspend_disk_msg type DomainEventCallbackPmsuspendDiskMsg struct { CallbackID int32 - Reason int32 - Msg DomainEventPmsuspendDiskMsg + Reason int32 + Msg DomainEventPmsuspendDiskMsg } // DomainManagedSaveArgs is libvirt's remote_domain_managed_save_args type DomainManagedSaveArgs struct { - Dom Domain + Dom Domain Flags uint32 } // DomainHasManagedSaveImageArgs is libvirt's remote_domain_has_managed_save_image_args type DomainHasManagedSaveImageArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -2733,13 +2741,13 @@ type DomainHasManagedSaveImageRet struct { // DomainManagedSaveRemoveArgs is libvirt's remote_domain_managed_save_remove_args type DomainManagedSaveRemoveArgs struct { - Dom Domain + Dom Domain Flags uint32 } // DomainManagedSaveGetXMLDescArgs is libvirt's remote_domain_managed_save_get_xml_desc_args type DomainManagedSaveGetXMLDescArgs struct { - Dom Domain + Dom Domain Flags DomainXMLFlags } @@ -2750,16 +2758,16 @@ type DomainManagedSaveGetXMLDescRet struct { // DomainManagedSaveDefineXMLArgs is libvirt's remote_domain_managed_save_define_xml_args type DomainManagedSaveDefineXMLArgs struct { - Dom Domain - Dxml OptString + Dom Domain + Dxml OptString Flags DomainSaveRestoreFlags } // DomainSnapshotCreateXMLArgs is libvirt's remote_domain_snapshot_create_xml_args type DomainSnapshotCreateXMLArgs struct { - Dom Domain + Dom Domain XMLDesc string - Flags uint32 + Flags uint32 } // DomainSnapshotCreateXMLRet is libvirt's remote_domain_snapshot_create_xml_ret @@ -2769,7 +2777,7 @@ type DomainSnapshotCreateXMLRet struct { // DomainSnapshotGetXMLDescArgs is libvirt's remote_domain_snapshot_get_xml_desc_args type DomainSnapshotGetXMLDescArgs struct { - Snap DomainSnapshot + Snap DomainSnapshot Flags uint32 } @@ -2780,7 +2788,7 @@ type DomainSnapshotGetXMLDescRet struct { // DomainSnapshotNumArgs is libvirt's remote_domain_snapshot_num_args type DomainSnapshotNumArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -2791,9 +2799,9 @@ type DomainSnapshotNumRet struct { // DomainSnapshotListNamesArgs is libvirt's remote_domain_snapshot_list_names_args type DomainSnapshotListNamesArgs struct { - Dom Domain + Dom Domain Maxnames int32 - Flags uint32 + Flags uint32 } // DomainSnapshotListNamesRet is libvirt's remote_domain_snapshot_list_names_ret @@ -2803,20 +2811,20 @@ type DomainSnapshotListNamesRet struct { // DomainListAllSnapshotsArgs is libvirt's remote_domain_list_all_snapshots_args type DomainListAllSnapshotsArgs struct { - Dom Domain + Dom Domain NeedResults int32 - Flags uint32 + Flags uint32 } // DomainListAllSnapshotsRet is libvirt's remote_domain_list_all_snapshots_ret type DomainListAllSnapshotsRet struct { Snapshots []DomainSnapshot - Ret int32 + Ret int32 } // DomainSnapshotNumChildrenArgs is libvirt's remote_domain_snapshot_num_children_args type DomainSnapshotNumChildrenArgs struct { - Snap DomainSnapshot + Snap DomainSnapshot Flags uint32 } @@ -2827,9 +2835,9 @@ type DomainSnapshotNumChildrenRet struct { // DomainSnapshotListChildrenNamesArgs is libvirt's remote_domain_snapshot_list_children_names_args type DomainSnapshotListChildrenNamesArgs struct { - Snap DomainSnapshot + Snap DomainSnapshot Maxnames int32 - Flags uint32 + Flags uint32 } // DomainSnapshotListChildrenNamesRet is libvirt's remote_domain_snapshot_list_children_names_ret @@ -2839,21 +2847,21 @@ type DomainSnapshotListChildrenNamesRet struct { // DomainSnapshotListAllChildrenArgs is libvirt's remote_domain_snapshot_list_all_children_args type DomainSnapshotListAllChildrenArgs struct { - Snapshot DomainSnapshot + Snapshot DomainSnapshot NeedResults int32 - Flags uint32 + Flags uint32 } // DomainSnapshotListAllChildrenRet is libvirt's remote_domain_snapshot_list_all_children_ret type DomainSnapshotListAllChildrenRet struct { Snapshots []DomainSnapshot - Ret int32 + Ret int32 } // DomainSnapshotLookupByNameArgs is libvirt's remote_domain_snapshot_lookup_by_name_args type DomainSnapshotLookupByNameArgs struct { - Dom Domain - Name string + Dom Domain + Name string Flags uint32 } @@ -2864,7 +2872,7 @@ type DomainSnapshotLookupByNameRet struct { // DomainHasCurrentSnapshotArgs is libvirt's remote_domain_has_current_snapshot_args type DomainHasCurrentSnapshotArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -2875,7 +2883,7 @@ type DomainHasCurrentSnapshotRet struct { // DomainSnapshotGetParentArgs is libvirt's remote_domain_snapshot_get_parent_args type DomainSnapshotGetParentArgs struct { - Snap DomainSnapshot + Snap DomainSnapshot Flags uint32 } @@ -2886,7 +2894,7 @@ type DomainSnapshotGetParentRet struct { // DomainSnapshotCurrentArgs is libvirt's remote_domain_snapshot_current_args type DomainSnapshotCurrentArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -2897,7 +2905,7 @@ type DomainSnapshotCurrentRet struct { // DomainSnapshotIsCurrentArgs is libvirt's remote_domain_snapshot_is_current_args type DomainSnapshotIsCurrentArgs struct { - Snap DomainSnapshot + Snap DomainSnapshot Flags uint32 } @@ -2908,7 +2916,7 @@ type DomainSnapshotIsCurrentRet struct { // DomainSnapshotHasMetadataArgs is libvirt's remote_domain_snapshot_has_metadata_args type DomainSnapshotHasMetadataArgs struct { - Snap DomainSnapshot + Snap DomainSnapshot Flags uint32 } @@ -2919,96 +2927,96 @@ type DomainSnapshotHasMetadataRet struct { // DomainRevertToSnapshotArgs is libvirt's remote_domain_revert_to_snapshot_args type DomainRevertToSnapshotArgs struct { - Snap DomainSnapshot + Snap DomainSnapshot Flags uint32 } // DomainSnapshotDeleteArgs is libvirt's remote_domain_snapshot_delete_args type DomainSnapshotDeleteArgs struct { - Snap DomainSnapshot + Snap DomainSnapshot Flags DomainSnapshotDeleteFlags } // DomainOpenConsoleArgs is libvirt's remote_domain_open_console_args type DomainOpenConsoleArgs struct { - Dom Domain + Dom Domain DevName OptString - Flags uint32 + Flags uint32 } // DomainOpenChannelArgs is libvirt's remote_domain_open_channel_args type DomainOpenChannelArgs struct { - Dom Domain - Name OptString + Dom Domain + Name OptString Flags DomainChannelFlags } // StorageVolUploadArgs is libvirt's remote_storage_vol_upload_args type StorageVolUploadArgs struct { - Vol StorageVol + Vol StorageVol Offset uint64 Length uint64 - Flags StorageVolUploadFlags + Flags StorageVolUploadFlags } // StorageVolDownloadArgs is libvirt's remote_storage_vol_download_args type StorageVolDownloadArgs struct { - Vol StorageVol + Vol StorageVol Offset uint64 Length uint64 - Flags StorageVolDownloadFlags + Flags StorageVolDownloadFlags } // DomainGetStateArgs is libvirt's remote_domain_get_state_args type DomainGetStateArgs struct { - Dom Domain + Dom Domain Flags uint32 } // DomainGetStateRet is libvirt's remote_domain_get_state_ret type DomainGetStateRet struct { - State int32 + State int32 Reason int32 } // DomainMigrateBegin3Args is libvirt's remote_domain_migrate_begin3_args type DomainMigrateBegin3Args struct { - Dom Domain - Xmlin OptString - Flags uint64 - Dname OptString + Dom Domain + Xmlin OptString + Flags uint64 + Dname OptString Resource uint64 } // DomainMigrateBegin3Ret is libvirt's remote_domain_migrate_begin3_ret type DomainMigrateBegin3Ret struct { CookieOut []byte - XML string + XML string } // DomainMigratePrepare3Args is libvirt's remote_domain_migrate_prepare3_args type DomainMigratePrepare3Args struct { CookieIn []byte - UriIn OptString - Flags uint64 - Dname OptString + UriIn OptString + Flags uint64 + Dname OptString Resource uint64 - DomXML string + DomXML string } // DomainMigratePrepare3Ret is libvirt's remote_domain_migrate_prepare3_ret type DomainMigratePrepare3Ret struct { CookieOut []byte - UriOut OptString + UriOut OptString } // DomainMigratePrepareTunnel3Args is libvirt's remote_domain_migrate_prepare_tunnel3_args type DomainMigratePrepareTunnel3Args struct { CookieIn []byte - Flags uint64 - Dname OptString + Flags uint64 + Dname OptString Resource uint64 - DomXML string + DomXML string } // DomainMigratePrepareTunnel3Ret is libvirt's remote_domain_migrate_prepare_tunnel3_ret @@ -3018,13 +3026,13 @@ type DomainMigratePrepareTunnel3Ret struct { // DomainMigratePerform3Args is libvirt's remote_domain_migrate_perform3_args type DomainMigratePerform3Args struct { - Dom Domain - Xmlin OptString + Dom Domain + Xmlin OptString CookieIn []byte Dconnuri OptString - Uri OptString - Flags uint64 - Dname OptString + Uri OptString + Flags uint64 + Dname OptString Resource uint64 } @@ -3035,25 +3043,25 @@ type DomainMigratePerform3Ret struct { // DomainMigrateFinish3Args is libvirt's remote_domain_migrate_finish3_args type DomainMigrateFinish3Args struct { - Dname string - CookieIn []byte - Dconnuri OptString - Uri OptString - Flags uint64 + Dname string + CookieIn []byte + Dconnuri OptString + Uri OptString + Flags uint64 Cancelled int32 } // DomainMigrateFinish3Ret is libvirt's remote_domain_migrate_finish3_ret type DomainMigrateFinish3Ret struct { - Dom Domain + Dom Domain CookieOut []byte } // DomainMigrateConfirm3Args is libvirt's remote_domain_migrate_confirm3_args type DomainMigrateConfirm3Args struct { - Dom Domain - CookieIn []byte - Flags uint64 + Dom Domain + CookieIn []byte + Flags uint64 Cancelled int32 } @@ -3065,250 +3073,250 @@ type DomainEventControlErrorMsg struct { // DomainEventCallbackControlErrorMsg is libvirt's remote_domain_event_callback_control_error_msg type DomainEventCallbackControlErrorMsg struct { CallbackID int32 - Msg DomainEventControlErrorMsg + Msg DomainEventControlErrorMsg } // DomainGetControlInfoArgs is libvirt's remote_domain_get_control_info_args type DomainGetControlInfoArgs struct { - Dom Domain + Dom Domain Flags uint32 } // DomainGetControlInfoRet is libvirt's remote_domain_get_control_info_ret type DomainGetControlInfoRet struct { - State uint32 - Details uint32 + State uint32 + Details uint32 StateTime uint64 } // DomainOpenGraphicsArgs is libvirt's remote_domain_open_graphics_args type DomainOpenGraphicsArgs struct { - Dom Domain - Idx uint32 + Dom Domain + Idx uint32 Flags DomainOpenGraphicsFlags } // DomainOpenGraphicsFdArgs is libvirt's remote_domain_open_graphics_fd_args type DomainOpenGraphicsFdArgs struct { - Dom Domain - Idx uint32 + Dom Domain + Idx uint32 Flags DomainOpenGraphicsFlags } // NodeSuspendForDurationArgs is libvirt's remote_node_suspend_for_duration_args type NodeSuspendForDurationArgs struct { - Target uint32 + Target uint32 Duration uint64 - Flags uint32 + Flags uint32 } // DomainShutdownFlagsArgs is libvirt's remote_domain_shutdown_flags_args type DomainShutdownFlagsArgs struct { - Dom Domain + Dom Domain Flags DomainShutdownFlagValues } // DomainGetDiskErrorsArgs is libvirt's remote_domain_get_disk_errors_args type DomainGetDiskErrorsArgs struct { - Dom Domain + Dom Domain Maxerrors uint32 - Flags uint32 + Flags uint32 } // DomainGetDiskErrorsRet is libvirt's remote_domain_get_disk_errors_ret type DomainGetDiskErrorsRet struct { - Errors []DomainDiskError + Errors []DomainDiskError Nerrors int32 } // ConnectListAllDomainsArgs is libvirt's remote_connect_list_all_domains_args type ConnectListAllDomainsArgs struct { NeedResults int32 - Flags ConnectListAllDomainsFlags + Flags ConnectListAllDomainsFlags } // ConnectListAllDomainsRet is libvirt's remote_connect_list_all_domains_ret type ConnectListAllDomainsRet struct { Domains []Domain - Ret uint32 + Ret uint32 } // ConnectListAllStoragePoolsArgs is libvirt's remote_connect_list_all_storage_pools_args type ConnectListAllStoragePoolsArgs struct { NeedResults int32 - Flags ConnectListAllStoragePoolsFlags + Flags ConnectListAllStoragePoolsFlags } // ConnectListAllStoragePoolsRet is libvirt's remote_connect_list_all_storage_pools_ret type ConnectListAllStoragePoolsRet struct { Pools []StoragePool - Ret uint32 + Ret uint32 } // StoragePoolListAllVolumesArgs is libvirt's remote_storage_pool_list_all_volumes_args type StoragePoolListAllVolumesArgs struct { - Pool StoragePool + Pool StoragePool NeedResults int32 - Flags uint32 + Flags uint32 } // StoragePoolListAllVolumesRet is libvirt's remote_storage_pool_list_all_volumes_ret type StoragePoolListAllVolumesRet struct { Vols []StorageVol - Ret uint32 + Ret uint32 } // ConnectListAllNetworksArgs is libvirt's remote_connect_list_all_networks_args type ConnectListAllNetworksArgs struct { NeedResults int32 - Flags ConnectListAllNetworksFlags + Flags ConnectListAllNetworksFlags } // ConnectListAllNetworksRet is libvirt's remote_connect_list_all_networks_ret type ConnectListAllNetworksRet struct { Nets []Network - Ret uint32 + Ret uint32 } // ConnectListAllInterfacesArgs is libvirt's remote_connect_list_all_interfaces_args type ConnectListAllInterfacesArgs struct { NeedResults int32 - Flags ConnectListAllInterfacesFlags + Flags ConnectListAllInterfacesFlags } // ConnectListAllInterfacesRet is libvirt's remote_connect_list_all_interfaces_ret type ConnectListAllInterfacesRet struct { Ifaces []Interface - Ret uint32 + Ret uint32 } // ConnectListAllNodeDevicesArgs is libvirt's remote_connect_list_all_node_devices_args type ConnectListAllNodeDevicesArgs struct { NeedResults int32 - Flags uint32 + Flags uint32 } // ConnectListAllNodeDevicesRet is libvirt's remote_connect_list_all_node_devices_ret type ConnectListAllNodeDevicesRet struct { Devices []NodeDevice - Ret uint32 + Ret uint32 } // ConnectListAllNwfiltersArgs is libvirt's remote_connect_list_all_nwfilters_args type ConnectListAllNwfiltersArgs struct { NeedResults int32 - Flags uint32 + Flags uint32 } // ConnectListAllNwfiltersRet is libvirt's remote_connect_list_all_nwfilters_ret type ConnectListAllNwfiltersRet struct { Filters []Nwfilter - Ret uint32 + Ret uint32 } // ConnectListAllSecretsArgs is libvirt's remote_connect_list_all_secrets_args type ConnectListAllSecretsArgs struct { NeedResults int32 - Flags ConnectListAllSecretsFlags + Flags ConnectListAllSecretsFlags } // ConnectListAllSecretsRet is libvirt's remote_connect_list_all_secrets_ret type ConnectListAllSecretsRet struct { Secrets []Secret - Ret uint32 + Ret uint32 } // NodeSetMemoryParametersArgs is libvirt's remote_node_set_memory_parameters_args type NodeSetMemoryParametersArgs struct { Params []TypedParam - Flags uint32 + Flags uint32 } // NodeGetMemoryParametersArgs is libvirt's remote_node_get_memory_parameters_args type NodeGetMemoryParametersArgs struct { Nparams int32 - Flags uint32 + Flags uint32 } // NodeGetMemoryParametersRet is libvirt's remote_node_get_memory_parameters_ret type NodeGetMemoryParametersRet struct { - Params []TypedParam + Params []TypedParam Nparams int32 } // NodeGetCPUMapArgs is libvirt's remote_node_get_cpu_map_args type NodeGetCPUMapArgs struct { - NeedMap int32 + NeedMap int32 NeedOnline int32 - Flags uint32 + Flags uint32 } // NodeGetCPUMapRet is libvirt's remote_node_get_cpu_map_ret type NodeGetCPUMapRet struct { Cpumap []byte Online uint32 - Ret int32 + Ret int32 } // DomainFstrimArgs is libvirt's remote_domain_fstrim_args type DomainFstrimArgs struct { - Dom Domain + Dom Domain MountPoint OptString - Minimum uint64 - Flags uint32 + Minimum uint64 + Flags uint32 } // DomainGetTimeArgs is libvirt's remote_domain_get_time_args type DomainGetTimeArgs struct { - Dom Domain + Dom Domain Flags uint32 } // DomainGetTimeRet is libvirt's remote_domain_get_time_ret type DomainGetTimeRet struct { - Seconds int64 + Seconds int64 Nseconds uint32 } // DomainSetTimeArgs is libvirt's remote_domain_set_time_args type DomainSetTimeArgs struct { - Dom Domain - Seconds int64 + Dom Domain + Seconds int64 Nseconds uint32 - Flags DomainSetTimeFlags + Flags DomainSetTimeFlags } // DomainMigrateBegin3ParamsArgs is libvirt's remote_domain_migrate_begin3_params_args type DomainMigrateBegin3ParamsArgs struct { - Dom Domain + Dom Domain Params []TypedParam - Flags uint32 + Flags uint32 } // DomainMigrateBegin3ParamsRet is libvirt's remote_domain_migrate_begin3_params_ret type DomainMigrateBegin3ParamsRet struct { CookieOut []byte - XML string + XML string } // DomainMigratePrepare3ParamsArgs is libvirt's remote_domain_migrate_prepare3_params_args type DomainMigratePrepare3ParamsArgs struct { - Params []TypedParam + Params []TypedParam CookieIn []byte - Flags uint32 + Flags uint32 } // DomainMigratePrepare3ParamsRet is libvirt's remote_domain_migrate_prepare3_params_ret type DomainMigratePrepare3ParamsRet struct { CookieOut []byte - UriOut OptString + UriOut OptString } // DomainMigratePrepareTunnel3ParamsArgs is libvirt's remote_domain_migrate_prepare_tunnel3_params_args type DomainMigratePrepareTunnel3ParamsArgs struct { - Params []TypedParam + Params []TypedParam CookieIn []byte - Flags uint32 + Flags uint32 } // DomainMigratePrepareTunnel3ParamsRet is libvirt's remote_domain_migrate_prepare_tunnel3_params_ret @@ -3318,11 +3326,11 @@ type DomainMigratePrepareTunnel3ParamsRet struct { // DomainMigratePerform3ParamsArgs is libvirt's remote_domain_migrate_perform3_params_args type DomainMigratePerform3ParamsArgs struct { - Dom Domain + Dom Domain Dconnuri OptString - Params []TypedParam + Params []TypedParam CookieIn []byte - Flags DomainMigrateFlags + Flags DomainMigrateFlags } // DomainMigratePerform3ParamsRet is libvirt's remote_domain_migrate_perform3_params_ret @@ -3332,70 +3340,70 @@ type DomainMigratePerform3ParamsRet struct { // DomainMigrateFinish3ParamsArgs is libvirt's remote_domain_migrate_finish3_params_args type DomainMigrateFinish3ParamsArgs struct { - Params []TypedParam - CookieIn []byte - Flags uint32 + Params []TypedParam + CookieIn []byte + Flags uint32 Cancelled int32 } // DomainMigrateFinish3ParamsRet is libvirt's remote_domain_migrate_finish3_params_ret type DomainMigrateFinish3ParamsRet struct { - Dom Domain + Dom Domain CookieOut []byte } // DomainMigrateConfirm3ParamsArgs is libvirt's remote_domain_migrate_confirm3_params_args type DomainMigrateConfirm3ParamsArgs struct { - Dom Domain - Params []TypedParam - CookieIn []byte - Flags uint32 + Dom Domain + Params []TypedParam + CookieIn []byte + Flags uint32 Cancelled int32 } // DomainEventDeviceRemovedMsg is libvirt's remote_domain_event_device_removed_msg type DomainEventDeviceRemovedMsg struct { - Dom Domain + Dom Domain DevAlias string } // DomainEventCallbackDeviceRemovedMsg is libvirt's remote_domain_event_callback_device_removed_msg type DomainEventCallbackDeviceRemovedMsg struct { CallbackID int32 - Msg DomainEventDeviceRemovedMsg + Msg DomainEventDeviceRemovedMsg } // DomainEventBlockJob2Msg is libvirt's remote_domain_event_block_job_2_msg type DomainEventBlockJob2Msg struct { CallbackID int32 - Dom Domain - Dst string - Type int32 - Status int32 + Dom Domain + Dst string + Type int32 + Status int32 } // DomainEventBlockThresholdMsg is libvirt's remote_domain_event_block_threshold_msg type DomainEventBlockThresholdMsg struct { CallbackID int32 - Dom Domain - Dev string - Path OptString - Threshold uint64 - Excess uint64 + Dom Domain + Dev string + Path OptString + Threshold uint64 + Excess uint64 } // DomainEventCallbackTunableMsg is libvirt's remote_domain_event_callback_tunable_msg type DomainEventCallbackTunableMsg struct { CallbackID int32 - Dom Domain - Params []TypedParam + Dom Domain + Params []TypedParam } // DomainEventCallbackDeviceAddedMsg is libvirt's remote_domain_event_callback_device_added_msg type DomainEventCallbackDeviceAddedMsg struct { CallbackID int32 - Dom Domain - DevAlias string + Dom Domain + DevAlias string } // ConnectEventConnectionClosedMsg is libvirt's remote_connect_event_connection_closed_msg @@ -3405,21 +3413,21 @@ type ConnectEventConnectionClosedMsg struct { // ConnectGetCPUModelNamesArgs is libvirt's remote_connect_get_cpu_model_names_args type ConnectGetCPUModelNamesArgs struct { - Arch string + Arch string NeedResults int32 - Flags uint32 + Flags uint32 } // ConnectGetCPUModelNamesRet is libvirt's remote_connect_get_cpu_model_names_ret type ConnectGetCPUModelNamesRet struct { Models []string - Ret int32 + Ret int32 } // ConnectNetworkEventRegisterAnyArgs is libvirt's remote_connect_network_event_register_any_args type ConnectNetworkEventRegisterAnyArgs struct { EventID int32 - Net OptNetwork + Net OptNetwork } // ConnectNetworkEventRegisterAnyRet is libvirt's remote_connect_network_event_register_any_ret @@ -3435,15 +3443,15 @@ type ConnectNetworkEventDeregisterAnyArgs struct { // NetworkEventLifecycleMsg is libvirt's remote_network_event_lifecycle_msg type NetworkEventLifecycleMsg struct { CallbackID int32 - Net Network - Event int32 - Detail int32 + Net Network + Event int32 + Detail int32 } // ConnectStoragePoolEventRegisterAnyArgs is libvirt's remote_connect_storage_pool_event_register_any_args type ConnectStoragePoolEventRegisterAnyArgs struct { EventID int32 - Pool OptStoragePool + Pool OptStoragePool } // ConnectStoragePoolEventRegisterAnyRet is libvirt's remote_connect_storage_pool_event_register_any_ret @@ -3459,21 +3467,21 @@ type ConnectStoragePoolEventDeregisterAnyArgs struct { // StoragePoolEventLifecycleMsg is libvirt's remote_storage_pool_event_lifecycle_msg type StoragePoolEventLifecycleMsg struct { CallbackID int32 - Pool StoragePool - Event int32 - Detail int32 + Pool StoragePool + Event int32 + Detail int32 } // StoragePoolEventRefreshMsg is libvirt's remote_storage_pool_event_refresh_msg type StoragePoolEventRefreshMsg struct { CallbackID int32 - Pool StoragePool + Pool StoragePool } // ConnectNodeDeviceEventRegisterAnyArgs is libvirt's remote_connect_node_device_event_register_any_args type ConnectNodeDeviceEventRegisterAnyArgs struct { EventID int32 - Dev OptNodeDevice + Dev OptNodeDevice } // ConnectNodeDeviceEventRegisterAnyRet is libvirt's remote_connect_node_device_event_register_any_ret @@ -3489,22 +3497,22 @@ type ConnectNodeDeviceEventDeregisterAnyArgs struct { // NodeDeviceEventLifecycleMsg is libvirt's remote_node_device_event_lifecycle_msg type NodeDeviceEventLifecycleMsg struct { CallbackID int32 - Dev NodeDevice - Event int32 - Detail int32 + Dev NodeDevice + Event int32 + Detail int32 } // NodeDeviceEventUpdateMsg is libvirt's remote_node_device_event_update_msg type NodeDeviceEventUpdateMsg struct { CallbackID int32 - Dev NodeDevice + Dev NodeDevice } // DomainFsfreezeArgs is libvirt's remote_domain_fsfreeze_args type DomainFsfreezeArgs struct { - Dom Domain + Dom Domain Mountpoints []string - Flags uint32 + Flags uint32 } // DomainFsfreezeRet is libvirt's remote_domain_fsfreeze_ret @@ -3514,9 +3522,9 @@ type DomainFsfreezeRet struct { // DomainFsthawArgs is libvirt's remote_domain_fsthaw_args type DomainFsthawArgs struct { - Dom Domain + Dom Domain Mountpoints []string - Flags uint32 + Flags uint32 } // DomainFsthawRet is libvirt's remote_domain_fsthaw_ret @@ -3526,10 +3534,10 @@ type DomainFsthawRet struct { // NodeGetFreePagesArgs is libvirt's remote_node_get_free_pages_args type NodeGetFreePagesArgs struct { - Pages []uint32 + Pages []uint32 StartCell int32 CellCount uint32 - Flags uint32 + Flags uint32 } // NodeGetFreePagesRet is libvirt's remote_node_get_free_pages_ret @@ -3539,11 +3547,11 @@ type NodeGetFreePagesRet struct { // NodeAllocPagesArgs is libvirt's remote_node_alloc_pages_args type NodeAllocPagesArgs struct { - PageSizes []uint32 + PageSizes []uint32 PageCounts []uint64 - StartCell int32 - CellCount uint32 - Flags NodeAllocPagesFlags + StartCell int32 + CellCount uint32 + Flags NodeAllocPagesFlags } // NodeAllocPagesRet is libvirt's remote_node_alloc_pages_ret @@ -3553,40 +3561,40 @@ type NodeAllocPagesRet struct { // NetworkDhcpLease is libvirt's remote_network_dhcp_lease type NetworkDhcpLease struct { - Iface string + Iface string Expirytime int64 - Type int32 - Mac OptString - Iaid OptString - Ipaddr string - Prefix uint32 - Hostname OptString - Clientid OptString + Type int32 + Mac OptString + Iaid OptString + Ipaddr string + Prefix uint32 + Hostname OptString + Clientid OptString } // NetworkGetDhcpLeasesArgs is libvirt's remote_network_get_dhcp_leases_args type NetworkGetDhcpLeasesArgs struct { - Net Network - Mac OptString + Net Network + Mac OptString NeedResults int32 - Flags uint32 + Flags uint32 } // NetworkGetDhcpLeasesRet is libvirt's remote_network_get_dhcp_leases_ret type NetworkGetDhcpLeasesRet struct { Leases []NetworkDhcpLease - Ret uint32 + Ret uint32 } // DomainStatsRecord is libvirt's remote_domain_stats_record type DomainStatsRecord struct { - Dom Domain + Dom Domain Params []TypedParam } // ConnectGetAllDomainStatsArgs is libvirt's remote_connect_get_all_domain_stats_args type ConnectGetAllDomainStatsArgs struct { - Doms []Domain + Doms []Domain Stats uint32 Flags ConnectGetAllDomainStatsFlags } @@ -3594,9 +3602,9 @@ type ConnectGetAllDomainStatsArgs struct { // DomainEventCallbackAgentLifecycleMsg is libvirt's remote_domain_event_callback_agent_lifecycle_msg type DomainEventCallbackAgentLifecycleMsg struct { CallbackID int32 - Dom Domain - State int32 - Reason int32 + Dom Domain + State int32 + Reason int32 } // ConnectGetAllDomainStatsRet is libvirt's remote_connect_get_all_domain_stats_ret @@ -3607,42 +3615,42 @@ type ConnectGetAllDomainStatsRet struct { // DomainFsinfo is libvirt's remote_domain_fsinfo type DomainFsinfo struct { Mountpoint string - Name string - Fstype string + Name string + Fstype string DevAliases []string } // DomainGetFsinfoArgs is libvirt's remote_domain_get_fsinfo_args type DomainGetFsinfoArgs struct { - Dom Domain + Dom Domain Flags uint32 } // DomainGetFsinfoRet is libvirt's remote_domain_get_fsinfo_ret type DomainGetFsinfoRet struct { Info []DomainFsinfo - Ret uint32 + Ret uint32 } // DomainIPAddr is libvirt's remote_domain_ip_addr type DomainIPAddr struct { - Type int32 - Addr string + Type int32 + Addr string Prefix uint32 } // DomainInterface is libvirt's remote_domain_interface type DomainInterface struct { - Name string + Name string Hwaddr OptString - Addrs []DomainIPAddr + Addrs []DomainIPAddr } // DomainInterfaceAddressesArgs is libvirt's remote_domain_interface_addresses_args type DomainInterfaceAddressesArgs struct { - Dom Domain + Dom Domain Source uint32 - Flags uint32 + Flags uint32 } // DomainInterfaceAddressesRet is libvirt's remote_domain_interface_addresses_ret @@ -3652,17 +3660,17 @@ type DomainInterfaceAddressesRet struct { // DomainSetUserPasswordArgs is libvirt's remote_domain_set_user_password_args type DomainSetUserPasswordArgs struct { - Dom Domain - User OptString + Dom Domain + User OptString Password OptString - Flags DomainSetUserPasswordFlags + Flags DomainSetUserPasswordFlags } // DomainRenameArgs is libvirt's remote_domain_rename_args type DomainRenameArgs struct { - Dom Domain + Dom Domain NewName OptString - Flags uint32 + Flags uint32 } // DomainRenameRet is libvirt's remote_domain_rename_ret @@ -3673,33 +3681,33 @@ type DomainRenameRet struct { // DomainEventCallbackMigrationIterationMsg is libvirt's remote_domain_event_callback_migration_iteration_msg type DomainEventCallbackMigrationIterationMsg struct { CallbackID int32 - Dom Domain - Iteration int32 + Dom Domain + Iteration int32 } // DomainEventCallbackJobCompletedMsg is libvirt's remote_domain_event_callback_job_completed_msg type DomainEventCallbackJobCompletedMsg struct { CallbackID int32 - Dom Domain - Params []TypedParam + Dom Domain + Params []TypedParam } // DomainMigrateStartPostCopyArgs is libvirt's remote_domain_migrate_start_post_copy_args type DomainMigrateStartPostCopyArgs struct { - Dom Domain + Dom Domain Flags uint32 } // DomainEventCallbackDeviceRemovalFailedMsg is libvirt's remote_domain_event_callback_device_removal_failed_msg type DomainEventCallbackDeviceRemovalFailedMsg struct { CallbackID int32 - Dom Domain - DevAlias string + Dom Domain + DevAlias string } // DomainGetGuestVcpusArgs is libvirt's remote_domain_get_guest_vcpus_args type DomainGetGuestVcpusArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -3710,40 +3718,40 @@ type DomainGetGuestVcpusRet struct { // DomainSetGuestVcpusArgs is libvirt's remote_domain_set_guest_vcpus_args type DomainSetGuestVcpusArgs struct { - Dom Domain + Dom Domain Cpumap string - State int32 - Flags uint32 + State int32 + Flags uint32 } // DomainSetVcpuArgs is libvirt's remote_domain_set_vcpu_args type DomainSetVcpuArgs struct { - Dom Domain + Dom Domain Cpumap string - State int32 - Flags DomainModificationImpact + State int32 + Flags DomainModificationImpact } // DomainEventCallbackMetadataChangeMsg is libvirt's remote_domain_event_callback_metadata_change_msg type DomainEventCallbackMetadataChangeMsg struct { CallbackID int32 - Dom Domain - Type int32 - Nsuri OptString + Dom Domain + Type int32 + Nsuri OptString } // DomainEventMemoryFailureMsg is libvirt's remote_domain_event_memory_failure_msg type DomainEventMemoryFailureMsg struct { CallbackID int32 - Dom Domain - Recipient int32 - Action int32 - Flags uint32 + Dom Domain + Recipient int32 + Action int32 + Flags uint32 } // ConnectSecretEventRegisterAnyArgs is libvirt's remote_connect_secret_event_register_any_args type ConnectSecretEventRegisterAnyArgs struct { - EventID int32 + EventID int32 OptSecret OptSecret } @@ -3760,41 +3768,41 @@ type ConnectSecretEventDeregisterAnyArgs struct { // SecretEventLifecycleMsg is libvirt's remote_secret_event_lifecycle_msg type SecretEventLifecycleMsg struct { CallbackID int32 - OptSecret Secret - Event int32 - Detail int32 + OptSecret Secret + Event int32 + Detail int32 } // SecretEventValueChangedMsg is libvirt's remote_secret_event_value_changed_msg type SecretEventValueChangedMsg struct { CallbackID int32 - OptSecret Secret + OptSecret Secret } // DomainSetBlockThresholdArgs is libvirt's remote_domain_set_block_threshold_args type DomainSetBlockThresholdArgs struct { - Dom Domain - Dev string + Dom Domain + Dev string Threshold uint64 - Flags uint32 + Flags uint32 } // DomainSetLifecycleActionArgs is libvirt's remote_domain_set_lifecycle_action_args type DomainSetLifecycleActionArgs struct { - Dom Domain - Type uint32 + Dom Domain + Type uint32 Action uint32 - Flags DomainModificationImpact + Flags DomainModificationImpact } // ConnectCompareHypervisorCPUArgs is libvirt's remote_connect_compare_hypervisor_cpu_args type ConnectCompareHypervisorCPUArgs struct { Emulator OptString - Arch OptString - Machine OptString + Arch OptString + Machine OptString Virttype OptString - XMLCPU string - Flags uint32 + XMLCPU string + Flags uint32 } // ConnectCompareHypervisorCPURet is libvirt's remote_connect_compare_hypervisor_cpu_ret @@ -3805,11 +3813,11 @@ type ConnectCompareHypervisorCPURet struct { // ConnectBaselineHypervisorCPUArgs is libvirt's remote_connect_baseline_hypervisor_cpu_args type ConnectBaselineHypervisorCPUArgs struct { Emulator OptString - Arch OptString - Machine OptString + Arch OptString + Machine OptString Virttype OptString - XMLCPUs []string - Flags uint32 + XMLCPUs []string + Flags uint32 } // ConnectBaselineHypervisorCPURet is libvirt's remote_connect_baseline_hypervisor_cpu_ret @@ -3820,18 +3828,18 @@ type ConnectBaselineHypervisorCPURet struct { // NodeGetSevInfoArgs is libvirt's remote_node_get_sev_info_args type NodeGetSevInfoArgs struct { Nparams int32 - Flags uint32 + Flags uint32 } // NodeGetSevInfoRet is libvirt's remote_node_get_sev_info_ret type NodeGetSevInfoRet struct { - Params []TypedParam + Params []TypedParam Nparams int32 } // DomainGetLaunchSecurityInfoArgs is libvirt's remote_domain_get_launch_security_info_args type DomainGetLaunchSecurityInfoArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -3852,7 +3860,7 @@ type NwfilterBindingLookupByPortDevRet struct { // NwfilterBindingCreateXMLArgs is libvirt's remote_nwfilter_binding_create_xml_args type NwfilterBindingCreateXMLArgs struct { - XML string + XML string Flags uint32 } @@ -3869,7 +3877,7 @@ type NwfilterBindingDeleteArgs struct { // NwfilterBindingGetXMLDescArgs is libvirt's remote_nwfilter_binding_get_xml_desc_args type NwfilterBindingGetXMLDescArgs struct { OptNwfilter NwfilterBinding - Flags uint32 + Flags uint32 } // NwfilterBindingGetXMLDescRet is libvirt's remote_nwfilter_binding_get_xml_desc_ret @@ -3880,13 +3888,13 @@ type NwfilterBindingGetXMLDescRet struct { // ConnectListAllNwfilterBindingsArgs is libvirt's remote_connect_list_all_nwfilter_bindings_args type ConnectListAllNwfilterBindingsArgs struct { NeedResults int32 - Flags uint32 + Flags uint32 } // ConnectListAllNwfilterBindingsRet is libvirt's remote_connect_list_all_nwfilter_bindings_ret type ConnectListAllNwfilterBindingsRet struct { Bindings []NwfilterBinding - Ret uint32 + Ret uint32 } // ConnectGetStoragePoolCapabilitiesArgs is libvirt's remote_connect_get_storage_pool_capabilities_args @@ -3901,21 +3909,21 @@ type ConnectGetStoragePoolCapabilitiesRet struct { // NetworkListAllPortsArgs is libvirt's remote_network_list_all_ports_args type NetworkListAllPortsArgs struct { - OptNetwork Network + OptNetwork Network NeedResults int32 - Flags uint32 + Flags uint32 } // NetworkListAllPortsRet is libvirt's remote_network_list_all_ports_ret type NetworkListAllPortsRet struct { Ports []NetworkPort - Ret uint32 + Ret uint32 } // NetworkPortLookupByUUIDArgs is libvirt's remote_network_port_lookup_by_uuid_args type NetworkPortLookupByUUIDArgs struct { OptNetwork Network - UUID UUID + UUID UUID } // NetworkPortLookupByUUIDRet is libvirt's remote_network_port_lookup_by_uuid_ret @@ -3926,8 +3934,8 @@ type NetworkPortLookupByUUIDRet struct { // NetworkPortCreateXMLArgs is libvirt's remote_network_port_create_xml_args type NetworkPortCreateXMLArgs struct { OptNetwork Network - XML string - Flags uint32 + XML string + Flags uint32 } // NetworkPortCreateXMLRet is libvirt's remote_network_port_create_xml_ret @@ -3937,27 +3945,27 @@ type NetworkPortCreateXMLRet struct { // NetworkPortSetParametersArgs is libvirt's remote_network_port_set_parameters_args type NetworkPortSetParametersArgs struct { - Port NetworkPort + Port NetworkPort Params []TypedParam - Flags uint32 + Flags uint32 } // NetworkPortGetParametersArgs is libvirt's remote_network_port_get_parameters_args type NetworkPortGetParametersArgs struct { - Port NetworkPort + Port NetworkPort Nparams int32 - Flags uint32 + Flags uint32 } // NetworkPortGetParametersRet is libvirt's remote_network_port_get_parameters_ret type NetworkPortGetParametersRet struct { - Params []TypedParam + Params []TypedParam Nparams int32 } // NetworkPortGetXMLDescArgs is libvirt's remote_network_port_get_xml_desc_args type NetworkPortGetXMLDescArgs struct { - Port NetworkPort + Port NetworkPort Flags uint32 } @@ -3968,15 +3976,15 @@ type NetworkPortGetXMLDescRet struct { // NetworkPortDeleteArgs is libvirt's remote_network_port_delete_args type NetworkPortDeleteArgs struct { - Port NetworkPort + Port NetworkPort Flags uint32 } // DomainCheckpointCreateXMLArgs is libvirt's remote_domain_checkpoint_create_xml_args type DomainCheckpointCreateXMLArgs struct { - Dom Domain + Dom Domain XMLDesc string - Flags uint32 + Flags uint32 } // DomainCheckpointCreateXMLRet is libvirt's remote_domain_checkpoint_create_xml_ret @@ -3987,7 +3995,7 @@ type DomainCheckpointCreateXMLRet struct { // DomainCheckpointGetXMLDescArgs is libvirt's remote_domain_checkpoint_get_xml_desc_args type DomainCheckpointGetXMLDescArgs struct { Checkpoint DomainCheckpoint - Flags uint32 + Flags uint32 } // DomainCheckpointGetXMLDescRet is libvirt's remote_domain_checkpoint_get_xml_desc_ret @@ -3997,34 +4005,34 @@ type DomainCheckpointGetXMLDescRet struct { // DomainListAllCheckpointsArgs is libvirt's remote_domain_list_all_checkpoints_args type DomainListAllCheckpointsArgs struct { - Dom Domain + Dom Domain NeedResults int32 - Flags uint32 + Flags uint32 } // DomainListAllCheckpointsRet is libvirt's remote_domain_list_all_checkpoints_ret type DomainListAllCheckpointsRet struct { Checkpoints []DomainCheckpoint - Ret int32 + Ret int32 } // DomainCheckpointListAllChildrenArgs is libvirt's remote_domain_checkpoint_list_all_children_args type DomainCheckpointListAllChildrenArgs struct { - Checkpoint DomainCheckpoint + Checkpoint DomainCheckpoint NeedResults int32 - Flags uint32 + Flags uint32 } // DomainCheckpointListAllChildrenRet is libvirt's remote_domain_checkpoint_list_all_children_ret type DomainCheckpointListAllChildrenRet struct { Checkpoints []DomainCheckpoint - Ret int32 + Ret int32 } // DomainCheckpointLookupByNameArgs is libvirt's remote_domain_checkpoint_lookup_by_name_args type DomainCheckpointLookupByNameArgs struct { - Dom Domain - Name string + Dom Domain + Name string Flags uint32 } @@ -4036,7 +4044,7 @@ type DomainCheckpointLookupByNameRet struct { // DomainCheckpointGetParentArgs is libvirt's remote_domain_checkpoint_get_parent_args type DomainCheckpointGetParentArgs struct { Checkpoint DomainCheckpoint - Flags uint32 + Flags uint32 } // DomainCheckpointGetParentRet is libvirt's remote_domain_checkpoint_get_parent_ret @@ -4047,12 +4055,12 @@ type DomainCheckpointGetParentRet struct { // DomainCheckpointDeleteArgs is libvirt's remote_domain_checkpoint_delete_args type DomainCheckpointDeleteArgs struct { Checkpoint DomainCheckpoint - Flags DomainCheckpointDeleteFlags + Flags DomainCheckpointDeleteFlags } // DomainGetGuestInfoArgs is libvirt's remote_domain_get_guest_info_args type DomainGetGuestInfoArgs struct { - Dom Domain + Dom Domain Types uint32 Flags uint32 } @@ -4065,14 +4073,14 @@ type DomainGetGuestInfoRet struct { // ConnectSetIdentityArgs is libvirt's remote_connect_set_identity_args type ConnectSetIdentityArgs struct { Params []TypedParam - Flags uint32 + Flags uint32 } // DomainAgentSetResponseTimeoutArgs is libvirt's remote_domain_agent_set_response_timeout_args type DomainAgentSetResponseTimeoutArgs struct { - Dom Domain + Dom Domain Timeout int32 - Flags uint32 + Flags uint32 } // DomainAgentSetResponseTimeoutRet is libvirt's remote_domain_agent_set_response_timeout_ret @@ -4082,15 +4090,15 @@ type DomainAgentSetResponseTimeoutRet struct { // DomainBackupBeginArgs is libvirt's remote_domain_backup_begin_args type DomainBackupBeginArgs struct { - Dom Domain - BackupXML string + Dom Domain + BackupXML string CheckpointXML OptString - Flags DomainBackupBeginFlags + Flags DomainBackupBeginFlags } // DomainBackupGetXMLDescArgs is libvirt's remote_domain_backup_get_xml_desc_args type DomainBackupGetXMLDescArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -4101,8 +4109,8 @@ type DomainBackupGetXMLDescRet struct { // DomainAuthorizedSshKeysGetArgs is libvirt's remote_domain_authorized_ssh_keys_get_args type DomainAuthorizedSshKeysGetArgs struct { - Dom Domain - User string + Dom Domain + User string Flags uint32 } @@ -4113,15 +4121,15 @@ type DomainAuthorizedSshKeysGetRet struct { // DomainAuthorizedSshKeysSetArgs is libvirt's remote_domain_authorized_ssh_keys_set_args type DomainAuthorizedSshKeysSetArgs struct { - Dom Domain - User string - Keys []string + Dom Domain + User string + Keys []string Flags uint32 } // DomainGetMessagesArgs is libvirt's remote_domain_get_messages_args type DomainGetMessagesArgs struct { - Dom Domain + Dom Domain Flags uint32 } @@ -4130,7 +4138,6 @@ type DomainGetMessagesRet struct { Msgs []string } - // TypedParamValue is a discriminated union. type TypedParamValue struct { D uint32 @@ -4179,13 +4186,12 @@ func NewTypedParamValueString(v string) *TypedParamValue { return &TypedParamValue{D: 7, I: v} } - // ConnectOpen is the go wrapper for REMOTE_PROC_CONNECT_OPEN. func (l *Libvirt) ConnectOpen(Name OptString, Flags ConnectFlags) (err error) { var buf []byte - args := ConnectOpenArgs { - Name: Name, + args := ConnectOpenArgs{ + Name: Name, Flags: Flags, } @@ -4194,7 +4200,6 @@ func (l *Libvirt) ConnectOpen(Name OptString, Flags ConnectFlags) (err error) { return } - _, err = l.requestStream(1, constants.Program, buf, nil, nil) if err != nil { return @@ -4207,7 +4212,6 @@ func (l *Libvirt) ConnectOpen(Name OptString, Flags ConnectFlags) (err error) { func (l *Libvirt) ConnectClose() (err error) { var buf []byte - _, err = l.requestStream(2, constants.Program, buf, nil, nil) if err != nil { return @@ -4268,7 +4272,7 @@ func (l *Libvirt) ConnectGetVersion() (rHvVer uint64, err error) { func (l *Libvirt) ConnectGetMaxVcpus(Type OptString) (rMaxVcpus int32, err error) { var buf []byte - args := ConnectGetMaxVcpusArgs { + args := ConnectGetMaxVcpusArgs{ Type: Type, } @@ -4384,7 +4388,7 @@ func (l *Libvirt) ConnectGetCapabilities() (rCapabilities string, err error) { func (l *Libvirt) DomainAttachDevice(Dom Domain, XML string) (err error) { var buf []byte - args := DomainAttachDeviceArgs { + args := DomainAttachDeviceArgs{ Dom: Dom, XML: XML, } @@ -4394,7 +4398,6 @@ func (l *Libvirt) DomainAttachDevice(Dom Domain, XML string) (err error) { return } - _, err = l.requestStream(8, constants.Program, buf, nil, nil) if err != nil { return @@ -4407,7 +4410,7 @@ func (l *Libvirt) DomainAttachDevice(Dom Domain, XML string) (err error) { func (l *Libvirt) DomainCreate(Dom Domain) (err error) { var buf []byte - args := DomainCreateArgs { + args := DomainCreateArgs{ Dom: Dom, } @@ -4416,7 +4419,6 @@ func (l *Libvirt) DomainCreate(Dom Domain) (err error) { return } - _, err = l.requestStream(9, constants.Program, buf, nil, nil) if err != nil { return @@ -4429,9 +4431,9 @@ func (l *Libvirt) DomainCreate(Dom Domain) (err error) { func (l *Libvirt) DomainCreateXML(XMLDesc string, Flags DomainCreateFlags) (rDom Domain, err error) { var buf []byte - args := DomainCreateXMLArgs { + args := DomainCreateXMLArgs{ XMLDesc: XMLDesc, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -4463,7 +4465,7 @@ func (l *Libvirt) DomainCreateXML(XMLDesc string, Flags DomainCreateFlags) (rDom func (l *Libvirt) DomainDefineXML(XML string) (rDom Domain, err error) { var buf []byte - args := DomainDefineXMLArgs { + args := DomainDefineXMLArgs{ XML: XML, } @@ -4496,7 +4498,7 @@ func (l *Libvirt) DomainDefineXML(XML string) (rDom Domain, err error) { func (l *Libvirt) DomainDestroy(Dom Domain) (err error) { var buf []byte - args := DomainDestroyArgs { + args := DomainDestroyArgs{ Dom: Dom, } @@ -4505,7 +4507,6 @@ func (l *Libvirt) DomainDestroy(Dom Domain) (err error) { return } - _, err = l.requestStream(12, constants.Program, buf, nil, nil) if err != nil { return @@ -4518,7 +4519,7 @@ func (l *Libvirt) DomainDestroy(Dom Domain) (err error) { func (l *Libvirt) DomainDetachDevice(Dom Domain, XML string) (err error) { var buf []byte - args := DomainDetachDeviceArgs { + args := DomainDetachDeviceArgs{ Dom: Dom, XML: XML, } @@ -4528,7 +4529,6 @@ func (l *Libvirt) DomainDetachDevice(Dom Domain, XML string) (err error) { return } - _, err = l.requestStream(13, constants.Program, buf, nil, nil) if err != nil { return @@ -4541,8 +4541,8 @@ func (l *Libvirt) DomainDetachDevice(Dom Domain, XML string) (err error) { func (l *Libvirt) DomainGetXMLDesc(Dom Domain, Flags DomainXMLFlags) (rXML string, err error) { var buf []byte - args := DomainGetXMLDescArgs { - Dom: Dom, + args := DomainGetXMLDescArgs{ + Dom: Dom, Flags: Flags, } @@ -4575,7 +4575,7 @@ func (l *Libvirt) DomainGetXMLDesc(Dom Domain, Flags DomainXMLFlags) (rXML strin func (l *Libvirt) DomainGetAutostart(Dom Domain) (rAutostart int32, err error) { var buf []byte - args := DomainGetAutostartArgs { + args := DomainGetAutostartArgs{ Dom: Dom, } @@ -4608,7 +4608,7 @@ func (l *Libvirt) DomainGetAutostart(Dom Domain) (rAutostart int32, err error) { func (l *Libvirt) DomainGetInfo(Dom Domain) (rState uint8, rMaxMem uint64, rMemory uint64, rNrVirtCPU uint16, rCPUTime uint64, err error) { var buf []byte - args := DomainGetInfoArgs { + args := DomainGetInfoArgs{ Dom: Dom, } @@ -4661,7 +4661,7 @@ func (l *Libvirt) DomainGetInfo(Dom Domain) (rState uint8, rMaxMem uint64, rMemo func (l *Libvirt) DomainGetMaxMemory(Dom Domain) (rMemory uint64, err error) { var buf []byte - args := DomainGetMaxMemoryArgs { + args := DomainGetMaxMemoryArgs{ Dom: Dom, } @@ -4694,7 +4694,7 @@ func (l *Libvirt) DomainGetMaxMemory(Dom Domain) (rMemory uint64, err error) { func (l *Libvirt) DomainGetMaxVcpus(Dom Domain) (rNum int32, err error) { var buf []byte - args := DomainGetMaxVcpusArgs { + args := DomainGetMaxVcpusArgs{ Dom: Dom, } @@ -4727,7 +4727,7 @@ func (l *Libvirt) DomainGetMaxVcpus(Dom Domain) (rNum int32, err error) { func (l *Libvirt) DomainGetOsType(Dom Domain) (rType string, err error) { var buf []byte - args := DomainGetOsTypeArgs { + args := DomainGetOsTypeArgs{ Dom: Dom, } @@ -4760,10 +4760,10 @@ func (l *Libvirt) DomainGetOsType(Dom Domain) (rType string, err error) { func (l *Libvirt) DomainGetVcpus(Dom Domain, Maxinfo int32, Maplen int32) (rInfo []VcpuInfo, rCpumaps []byte, err error) { var buf []byte - args := DomainGetVcpusArgs { - Dom: Dom, + args := DomainGetVcpusArgs{ + Dom: Dom, Maxinfo: Maxinfo, - Maplen: Maplen, + Maplen: Maplen, } buf, err = encode(&args) @@ -4800,7 +4800,7 @@ func (l *Libvirt) DomainGetVcpus(Dom Domain, Maxinfo int32, Maplen int32) (rInfo func (l *Libvirt) ConnectListDefinedDomains(Maxnames int32) (rNames []string, err error) { var buf []byte - args := ConnectListDefinedDomainsArgs { + args := ConnectListDefinedDomainsArgs{ Maxnames: Maxnames, } @@ -4833,7 +4833,7 @@ func (l *Libvirt) ConnectListDefinedDomains(Maxnames int32) (rNames []string, er func (l *Libvirt) DomainLookupByID(ID int32) (rDom Domain, err error) { var buf []byte - args := DomainLookupByIDArgs { + args := DomainLookupByIDArgs{ ID: ID, } @@ -4866,7 +4866,7 @@ func (l *Libvirt) DomainLookupByID(ID int32) (rDom Domain, err error) { func (l *Libvirt) DomainLookupByName(Name string) (rDom Domain, err error) { var buf []byte - args := DomainLookupByNameArgs { + args := DomainLookupByNameArgs{ Name: Name, } @@ -4899,7 +4899,7 @@ func (l *Libvirt) DomainLookupByName(Name string) (rDom Domain, err error) { func (l *Libvirt) DomainLookupByUUID(UUID UUID) (rDom Domain, err error) { var buf []byte - args := DomainLookupByUUIDArgs { + args := DomainLookupByUUIDArgs{ UUID: UUID, } @@ -4956,9 +4956,9 @@ func (l *Libvirt) ConnectNumOfDefinedDomains() (rNum int32, err error) { func (l *Libvirt) DomainPinVcpu(Dom Domain, Vcpu uint32, Cpumap []byte) (err error) { var buf []byte - args := DomainPinVcpuArgs { - Dom: Dom, - Vcpu: Vcpu, + args := DomainPinVcpuArgs{ + Dom: Dom, + Vcpu: Vcpu, Cpumap: Cpumap, } @@ -4967,7 +4967,6 @@ func (l *Libvirt) DomainPinVcpu(Dom Domain, Vcpu uint32, Cpumap []byte) (err err return } - _, err = l.requestStream(26, constants.Program, buf, nil, nil) if err != nil { return @@ -4980,8 +4979,8 @@ func (l *Libvirt) DomainPinVcpu(Dom Domain, Vcpu uint32, Cpumap []byte) (err err func (l *Libvirt) DomainReboot(Dom Domain, Flags DomainRebootFlagValues) (err error) { var buf []byte - args := DomainRebootArgs { - Dom: Dom, + args := DomainRebootArgs{ + Dom: Dom, Flags: Flags, } @@ -4990,7 +4989,6 @@ func (l *Libvirt) DomainReboot(Dom Domain, Flags DomainRebootFlagValues) (err er return } - _, err = l.requestStream(27, constants.Program, buf, nil, nil) if err != nil { return @@ -5003,7 +5001,7 @@ func (l *Libvirt) DomainReboot(Dom Domain, Flags DomainRebootFlagValues) (err er func (l *Libvirt) DomainResume(Dom Domain) (err error) { var buf []byte - args := DomainResumeArgs { + args := DomainResumeArgs{ Dom: Dom, } @@ -5012,7 +5010,6 @@ func (l *Libvirt) DomainResume(Dom Domain) (err error) { return } - _, err = l.requestStream(28, constants.Program, buf, nil, nil) if err != nil { return @@ -5025,8 +5022,8 @@ func (l *Libvirt) DomainResume(Dom Domain) (err error) { func (l *Libvirt) DomainSetAutostart(Dom Domain, Autostart int32) (err error) { var buf []byte - args := DomainSetAutostartArgs { - Dom: Dom, + args := DomainSetAutostartArgs{ + Dom: Dom, Autostart: Autostart, } @@ -5035,7 +5032,6 @@ func (l *Libvirt) DomainSetAutostart(Dom Domain, Autostart int32) (err error) { return } - _, err = l.requestStream(29, constants.Program, buf, nil, nil) if err != nil { return @@ -5048,8 +5044,8 @@ func (l *Libvirt) DomainSetAutostart(Dom Domain, Autostart int32) (err error) { func (l *Libvirt) DomainSetMaxMemory(Dom Domain, Memory uint64) (err error) { var buf []byte - args := DomainSetMaxMemoryArgs { - Dom: Dom, + args := DomainSetMaxMemoryArgs{ + Dom: Dom, Memory: Memory, } @@ -5058,7 +5054,6 @@ func (l *Libvirt) DomainSetMaxMemory(Dom Domain, Memory uint64) (err error) { return } - _, err = l.requestStream(30, constants.Program, buf, nil, nil) if err != nil { return @@ -5071,8 +5066,8 @@ func (l *Libvirt) DomainSetMaxMemory(Dom Domain, Memory uint64) (err error) { func (l *Libvirt) DomainSetMemory(Dom Domain, Memory uint64) (err error) { var buf []byte - args := DomainSetMemoryArgs { - Dom: Dom, + args := DomainSetMemoryArgs{ + Dom: Dom, Memory: Memory, } @@ -5081,7 +5076,6 @@ func (l *Libvirt) DomainSetMemory(Dom Domain, Memory uint64) (err error) { return } - _, err = l.requestStream(31, constants.Program, buf, nil, nil) if err != nil { return @@ -5094,8 +5088,8 @@ func (l *Libvirt) DomainSetMemory(Dom Domain, Memory uint64) (err error) { func (l *Libvirt) DomainSetVcpus(Dom Domain, Nvcpus uint32) (err error) { var buf []byte - args := DomainSetVcpusArgs { - Dom: Dom, + args := DomainSetVcpusArgs{ + Dom: Dom, Nvcpus: Nvcpus, } @@ -5104,7 +5098,6 @@ func (l *Libvirt) DomainSetVcpus(Dom Domain, Nvcpus uint32) (err error) { return } - _, err = l.requestStream(32, constants.Program, buf, nil, nil) if err != nil { return @@ -5117,7 +5110,7 @@ func (l *Libvirt) DomainSetVcpus(Dom Domain, Nvcpus uint32) (err error) { func (l *Libvirt) DomainShutdown(Dom Domain) (err error) { var buf []byte - args := DomainShutdownArgs { + args := DomainShutdownArgs{ Dom: Dom, } @@ -5126,7 +5119,6 @@ func (l *Libvirt) DomainShutdown(Dom Domain) (err error) { return } - _, err = l.requestStream(33, constants.Program, buf, nil, nil) if err != nil { return @@ -5139,7 +5131,7 @@ func (l *Libvirt) DomainShutdown(Dom Domain) (err error) { func (l *Libvirt) DomainSuspend(Dom Domain) (err error) { var buf []byte - args := DomainSuspendArgs { + args := DomainSuspendArgs{ Dom: Dom, } @@ -5148,7 +5140,6 @@ func (l *Libvirt) DomainSuspend(Dom Domain) (err error) { return } - _, err = l.requestStream(34, constants.Program, buf, nil, nil) if err != nil { return @@ -5161,7 +5152,7 @@ func (l *Libvirt) DomainSuspend(Dom Domain) (err error) { func (l *Libvirt) DomainUndefine(Dom Domain) (err error) { var buf []byte - args := DomainUndefineArgs { + args := DomainUndefineArgs{ Dom: Dom, } @@ -5170,7 +5161,6 @@ func (l *Libvirt) DomainUndefine(Dom Domain) (err error) { return } - _, err = l.requestStream(35, constants.Program, buf, nil, nil) if err != nil { return @@ -5183,7 +5173,7 @@ func (l *Libvirt) DomainUndefine(Dom Domain) (err error) { func (l *Libvirt) ConnectListDefinedNetworks(Maxnames int32) (rNames []string, err error) { var buf []byte - args := ConnectListDefinedNetworksArgs { + args := ConnectListDefinedNetworksArgs{ Maxnames: Maxnames, } @@ -5216,7 +5206,7 @@ func (l *Libvirt) ConnectListDefinedNetworks(Maxnames int32) (rNames []string, e func (l *Libvirt) ConnectListDomains(Maxids int32) (rIds []int32, err error) { var buf []byte - args := ConnectListDomainsArgs { + args := ConnectListDomainsArgs{ Maxids: Maxids, } @@ -5249,7 +5239,7 @@ func (l *Libvirt) ConnectListDomains(Maxids int32) (rIds []int32, err error) { func (l *Libvirt) ConnectListNetworks(Maxnames int32) (rNames []string, err error) { var buf []byte - args := ConnectListNetworksArgs { + args := ConnectListNetworksArgs{ Maxnames: Maxnames, } @@ -5282,7 +5272,7 @@ func (l *Libvirt) ConnectListNetworks(Maxnames int32) (rNames []string, err erro func (l *Libvirt) NetworkCreate(Net Network) (err error) { var buf []byte - args := NetworkCreateArgs { + args := NetworkCreateArgs{ Net: Net, } @@ -5291,7 +5281,6 @@ func (l *Libvirt) NetworkCreate(Net Network) (err error) { return } - _, err = l.requestStream(39, constants.Program, buf, nil, nil) if err != nil { return @@ -5304,7 +5293,7 @@ func (l *Libvirt) NetworkCreate(Net Network) (err error) { func (l *Libvirt) NetworkCreateXML(XML string) (rNet Network, err error) { var buf []byte - args := NetworkCreateXMLArgs { + args := NetworkCreateXMLArgs{ XML: XML, } @@ -5337,7 +5326,7 @@ func (l *Libvirt) NetworkCreateXML(XML string) (rNet Network, err error) { func (l *Libvirt) NetworkDefineXML(XML string) (rNet Network, err error) { var buf []byte - args := NetworkDefineXMLArgs { + args := NetworkDefineXMLArgs{ XML: XML, } @@ -5370,7 +5359,7 @@ func (l *Libvirt) NetworkDefineXML(XML string) (rNet Network, err error) { func (l *Libvirt) NetworkDestroy(Net Network) (err error) { var buf []byte - args := NetworkDestroyArgs { + args := NetworkDestroyArgs{ Net: Net, } @@ -5379,7 +5368,6 @@ func (l *Libvirt) NetworkDestroy(Net Network) (err error) { return } - _, err = l.requestStream(42, constants.Program, buf, nil, nil) if err != nil { return @@ -5392,8 +5380,8 @@ func (l *Libvirt) NetworkDestroy(Net Network) (err error) { func (l *Libvirt) NetworkGetXMLDesc(Net Network, Flags uint32) (rXML string, err error) { var buf []byte - args := NetworkGetXMLDescArgs { - Net: Net, + args := NetworkGetXMLDescArgs{ + Net: Net, Flags: Flags, } @@ -5426,7 +5414,7 @@ func (l *Libvirt) NetworkGetXMLDesc(Net Network, Flags uint32) (rXML string, err func (l *Libvirt) NetworkGetAutostart(Net Network) (rAutostart int32, err error) { var buf []byte - args := NetworkGetAutostartArgs { + args := NetworkGetAutostartArgs{ Net: Net, } @@ -5459,7 +5447,7 @@ func (l *Libvirt) NetworkGetAutostart(Net Network) (rAutostart int32, err error) func (l *Libvirt) NetworkGetBridgeName(Net Network) (rName string, err error) { var buf []byte - args := NetworkGetBridgeNameArgs { + args := NetworkGetBridgeNameArgs{ Net: Net, } @@ -5492,7 +5480,7 @@ func (l *Libvirt) NetworkGetBridgeName(Net Network) (rName string, err error) { func (l *Libvirt) NetworkLookupByName(Name string) (rNet Network, err error) { var buf []byte - args := NetworkLookupByNameArgs { + args := NetworkLookupByNameArgs{ Name: Name, } @@ -5525,7 +5513,7 @@ func (l *Libvirt) NetworkLookupByName(Name string) (rNet Network, err error) { func (l *Libvirt) NetworkLookupByUUID(UUID UUID) (rNet Network, err error) { var buf []byte - args := NetworkLookupByUUIDArgs { + args := NetworkLookupByUUIDArgs{ UUID: UUID, } @@ -5558,8 +5546,8 @@ func (l *Libvirt) NetworkLookupByUUID(UUID UUID) (rNet Network, err error) { func (l *Libvirt) NetworkSetAutostart(Net Network, Autostart int32) (err error) { var buf []byte - args := NetworkSetAutostartArgs { - Net: Net, + args := NetworkSetAutostartArgs{ + Net: Net, Autostart: Autostart, } @@ -5568,7 +5556,6 @@ func (l *Libvirt) NetworkSetAutostart(Net Network, Autostart int32) (err error) return } - _, err = l.requestStream(48, constants.Program, buf, nil, nil) if err != nil { return @@ -5581,7 +5568,7 @@ func (l *Libvirt) NetworkSetAutostart(Net Network, Autostart int32) (err error) func (l *Libvirt) NetworkUndefine(Net Network) (err error) { var buf []byte - args := NetworkUndefineArgs { + args := NetworkUndefineArgs{ Net: Net, } @@ -5590,7 +5577,6 @@ func (l *Libvirt) NetworkUndefine(Net Network) (err error) { return } - _, err = l.requestStream(49, constants.Program, buf, nil, nil) if err != nil { return @@ -5675,9 +5661,9 @@ func (l *Libvirt) ConnectNumOfNetworks() (rNum int32, err error) { func (l *Libvirt) DomainCoreDump(Dom Domain, To string, Flags DomainCoreDumpFlags) (err error) { var buf []byte - args := DomainCoreDumpArgs { - Dom: Dom, - To: To, + args := DomainCoreDumpArgs{ + Dom: Dom, + To: To, Flags: Flags, } @@ -5686,7 +5672,6 @@ func (l *Libvirt) DomainCoreDump(Dom Domain, To string, Flags DomainCoreDumpFlag return } - _, err = l.requestStream(53, constants.Program, buf, nil, nil) if err != nil { return @@ -5699,7 +5684,7 @@ func (l *Libvirt) DomainCoreDump(Dom Domain, To string, Flags DomainCoreDumpFlag func (l *Libvirt) DomainRestore(From string) (err error) { var buf []byte - args := DomainRestoreArgs { + args := DomainRestoreArgs{ From: From, } @@ -5708,7 +5693,6 @@ func (l *Libvirt) DomainRestore(From string) (err error) { return } - _, err = l.requestStream(54, constants.Program, buf, nil, nil) if err != nil { return @@ -5721,9 +5705,9 @@ func (l *Libvirt) DomainRestore(From string) (err error) { func (l *Libvirt) DomainSave(Dom Domain, To string) (err error) { var buf []byte - args := DomainSaveArgs { + args := DomainSaveArgs{ Dom: Dom, - To: To, + To: To, } buf, err = encode(&args) @@ -5731,7 +5715,6 @@ func (l *Libvirt) DomainSave(Dom Domain, To string) (err error) { return } - _, err = l.requestStream(55, constants.Program, buf, nil, nil) if err != nil { return @@ -5744,7 +5727,7 @@ func (l *Libvirt) DomainSave(Dom Domain, To string) (err error) { func (l *Libvirt) DomainGetSchedulerType(Dom Domain) (rType string, rNparams int32, err error) { var buf []byte - args := DomainGetSchedulerTypeArgs { + args := DomainGetSchedulerTypeArgs{ Dom: Dom, } @@ -5782,8 +5765,8 @@ func (l *Libvirt) DomainGetSchedulerType(Dom Domain) (rType string, rNparams int func (l *Libvirt) DomainGetSchedulerParameters(Dom Domain, Nparams int32) (rParams []TypedParam, err error) { var buf []byte - args := DomainGetSchedulerParametersArgs { - Dom: Dom, + args := DomainGetSchedulerParametersArgs{ + Dom: Dom, Nparams: Nparams, } @@ -5816,8 +5799,8 @@ func (l *Libvirt) DomainGetSchedulerParameters(Dom Domain, Nparams int32) (rPara func (l *Libvirt) DomainSetSchedulerParameters(Dom Domain, Params []TypedParam) (err error) { var buf []byte - args := DomainSetSchedulerParametersArgs { - Dom: Dom, + args := DomainSetSchedulerParametersArgs{ + Dom: Dom, Params: Params, } @@ -5826,7 +5809,6 @@ func (l *Libvirt) DomainSetSchedulerParameters(Dom Domain, Params []TypedParam) return } - _, err = l.requestStream(58, constants.Program, buf, nil, nil) if err != nil { return @@ -5863,7 +5845,7 @@ func (l *Libvirt) ConnectGetHostname() (rHostname string, err error) { func (l *Libvirt) ConnectSupportsFeature(Feature int32) (rSupported int32, err error) { var buf []byte - args := ConnectSupportsFeatureArgs { + args := ConnectSupportsFeatureArgs{ Feature: Feature, } @@ -5896,10 +5878,10 @@ func (l *Libvirt) ConnectSupportsFeature(Feature int32) (rSupported int32, err e func (l *Libvirt) DomainMigratePrepare(UriIn OptString, Flags uint64, Dname OptString, Resource uint64) (rCookie []byte, rUriOut OptString, err error) { var buf []byte - args := DomainMigratePrepareArgs { - UriIn: UriIn, - Flags: Flags, - Dname: Dname, + args := DomainMigratePrepareArgs{ + UriIn: UriIn, + Flags: Flags, + Dname: Dname, Resource: Resource, } @@ -5937,12 +5919,12 @@ func (l *Libvirt) DomainMigratePrepare(UriIn OptString, Flags uint64, Dname OptS func (l *Libvirt) DomainMigratePerform(Dom Domain, Cookie []byte, Uri string, Flags uint64, Dname OptString, Resource uint64) (err error) { var buf []byte - args := DomainMigratePerformArgs { - Dom: Dom, - Cookie: Cookie, - Uri: Uri, - Flags: Flags, - Dname: Dname, + args := DomainMigratePerformArgs{ + Dom: Dom, + Cookie: Cookie, + Uri: Uri, + Flags: Flags, + Dname: Dname, Resource: Resource, } @@ -5951,7 +5933,6 @@ func (l *Libvirt) DomainMigratePerform(Dom Domain, Cookie []byte, Uri string, Fl return } - _, err = l.requestStream(62, constants.Program, buf, nil, nil) if err != nil { return @@ -5964,11 +5945,11 @@ func (l *Libvirt) DomainMigratePerform(Dom Domain, Cookie []byte, Uri string, Fl func (l *Libvirt) DomainMigrateFinish(Dname string, Cookie []byte, Uri string, Flags uint64) (rDdom Domain, err error) { var buf []byte - args := DomainMigrateFinishArgs { - Dname: Dname, + args := DomainMigrateFinishArgs{ + Dname: Dname, Cookie: Cookie, - Uri: Uri, - Flags: Flags, + Uri: Uri, + Flags: Flags, } buf, err = encode(&args) @@ -6000,8 +5981,8 @@ func (l *Libvirt) DomainMigrateFinish(Dname string, Cookie []byte, Uri string, F func (l *Libvirt) DomainBlockStats(Dom Domain, Path string) (rRdReq int64, rRdBytes int64, rWrReq int64, rWrBytes int64, rErrs int64, err error) { var buf []byte - args := DomainBlockStatsArgs { - Dom: Dom, + args := DomainBlockStatsArgs{ + Dom: Dom, Path: Path, } @@ -6054,8 +6035,8 @@ func (l *Libvirt) DomainBlockStats(Dom Domain, Path string) (rRdReq int64, rRdBy func (l *Libvirt) DomainInterfaceStats(Dom Domain, Device string) (rRxBytes int64, rRxPackets int64, rRxErrs int64, rRxDrop int64, rTxBytes int64, rTxPackets int64, rTxErrs int64, rTxDrop int64, err error) { var buf []byte - args := DomainInterfaceStatsArgs { - Dom: Dom, + args := DomainInterfaceStatsArgs{ + Dom: Dom, Device: Device, } @@ -6171,9 +6152,9 @@ func (l *Libvirt) AuthSaslInit() (rMechlist string, err error) { func (l *Libvirt) AuthSaslStart(Mech string, Nil int32, Data []int8) (rComplete int32, rNil int32, rData []int8, err error) { var buf []byte - args := AuthSaslStartArgs { + args := AuthSaslStartArgs{ Mech: Mech, - Nil: Nil, + Nil: Nil, Data: Data, } @@ -6216,8 +6197,8 @@ func (l *Libvirt) AuthSaslStart(Mech string, Nil int32, Data []int8) (rComplete func (l *Libvirt) AuthSaslStep(Nil int32, Data []int8) (rComplete int32, rNil int32, rData []int8, err error) { var buf []byte - args := AuthSaslStepArgs { - Nil: Nil, + args := AuthSaslStepArgs{ + Nil: Nil, Data: Data, } @@ -6308,7 +6289,7 @@ func (l *Libvirt) ConnectNumOfStoragePools() (rNum int32, err error) { func (l *Libvirt) ConnectListStoragePools(Maxnames int32) (rNames []string, err error) { var buf []byte - args := ConnectListStoragePoolsArgs { + args := ConnectListStoragePoolsArgs{ Maxnames: Maxnames, } @@ -6365,7 +6346,7 @@ func (l *Libvirt) ConnectNumOfDefinedStoragePools() (rNum int32, err error) { func (l *Libvirt) ConnectListDefinedStoragePools(Maxnames int32) (rNames []string, err error) { var buf []byte - args := ConnectListDefinedStoragePoolsArgs { + args := ConnectListDefinedStoragePoolsArgs{ Maxnames: Maxnames, } @@ -6398,10 +6379,10 @@ func (l *Libvirt) ConnectListDefinedStoragePools(Maxnames int32) (rNames []strin func (l *Libvirt) ConnectFindStoragePoolSources(Type string, SrcSpec OptString, Flags uint32) (rXML string, err error) { var buf []byte - args := ConnectFindStoragePoolSourcesArgs { - Type: Type, + args := ConnectFindStoragePoolSourcesArgs{ + Type: Type, SrcSpec: SrcSpec, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -6433,8 +6414,8 @@ func (l *Libvirt) ConnectFindStoragePoolSources(Type string, SrcSpec OptString, func (l *Libvirt) StoragePoolCreateXML(XML string, Flags StoragePoolCreateFlags) (rPool StoragePool, err error) { var buf []byte - args := StoragePoolCreateXMLArgs { - XML: XML, + args := StoragePoolCreateXMLArgs{ + XML: XML, Flags: Flags, } @@ -6467,8 +6448,8 @@ func (l *Libvirt) StoragePoolCreateXML(XML string, Flags StoragePoolCreateFlags) func (l *Libvirt) StoragePoolDefineXML(XML string, Flags uint32) (rPool StoragePool, err error) { var buf []byte - args := StoragePoolDefineXMLArgs { - XML: XML, + args := StoragePoolDefineXMLArgs{ + XML: XML, Flags: Flags, } @@ -6501,8 +6482,8 @@ func (l *Libvirt) StoragePoolDefineXML(XML string, Flags uint32) (rPool StorageP func (l *Libvirt) StoragePoolCreate(Pool StoragePool, Flags StoragePoolCreateFlags) (err error) { var buf []byte - args := StoragePoolCreateArgs { - Pool: Pool, + args := StoragePoolCreateArgs{ + Pool: Pool, Flags: Flags, } @@ -6511,7 +6492,6 @@ func (l *Libvirt) StoragePoolCreate(Pool StoragePool, Flags StoragePoolCreateFla return } - _, err = l.requestStream(78, constants.Program, buf, nil, nil) if err != nil { return @@ -6524,8 +6504,8 @@ func (l *Libvirt) StoragePoolCreate(Pool StoragePool, Flags StoragePoolCreateFla func (l *Libvirt) StoragePoolBuild(Pool StoragePool, Flags StoragePoolBuildFlags) (err error) { var buf []byte - args := StoragePoolBuildArgs { - Pool: Pool, + args := StoragePoolBuildArgs{ + Pool: Pool, Flags: Flags, } @@ -6534,7 +6514,6 @@ func (l *Libvirt) StoragePoolBuild(Pool StoragePool, Flags StoragePoolBuildFlags return } - _, err = l.requestStream(79, constants.Program, buf, nil, nil) if err != nil { return @@ -6547,7 +6526,7 @@ func (l *Libvirt) StoragePoolBuild(Pool StoragePool, Flags StoragePoolBuildFlags func (l *Libvirt) StoragePoolDestroy(Pool StoragePool) (err error) { var buf []byte - args := StoragePoolDestroyArgs { + args := StoragePoolDestroyArgs{ Pool: Pool, } @@ -6556,7 +6535,6 @@ func (l *Libvirt) StoragePoolDestroy(Pool StoragePool) (err error) { return } - _, err = l.requestStream(80, constants.Program, buf, nil, nil) if err != nil { return @@ -6569,8 +6547,8 @@ func (l *Libvirt) StoragePoolDestroy(Pool StoragePool) (err error) { func (l *Libvirt) StoragePoolDelete(Pool StoragePool, Flags StoragePoolDeleteFlags) (err error) { var buf []byte - args := StoragePoolDeleteArgs { - Pool: Pool, + args := StoragePoolDeleteArgs{ + Pool: Pool, Flags: Flags, } @@ -6579,7 +6557,6 @@ func (l *Libvirt) StoragePoolDelete(Pool StoragePool, Flags StoragePoolDeleteFla return } - _, err = l.requestStream(81, constants.Program, buf, nil, nil) if err != nil { return @@ -6592,7 +6569,7 @@ func (l *Libvirt) StoragePoolDelete(Pool StoragePool, Flags StoragePoolDeleteFla func (l *Libvirt) StoragePoolUndefine(Pool StoragePool) (err error) { var buf []byte - args := StoragePoolUndefineArgs { + args := StoragePoolUndefineArgs{ Pool: Pool, } @@ -6601,7 +6578,6 @@ func (l *Libvirt) StoragePoolUndefine(Pool StoragePool) (err error) { return } - _, err = l.requestStream(82, constants.Program, buf, nil, nil) if err != nil { return @@ -6614,8 +6590,8 @@ func (l *Libvirt) StoragePoolUndefine(Pool StoragePool) (err error) { func (l *Libvirt) StoragePoolRefresh(Pool StoragePool, Flags uint32) (err error) { var buf []byte - args := StoragePoolRefreshArgs { - Pool: Pool, + args := StoragePoolRefreshArgs{ + Pool: Pool, Flags: Flags, } @@ -6624,7 +6600,6 @@ func (l *Libvirt) StoragePoolRefresh(Pool StoragePool, Flags uint32) (err error) return } - _, err = l.requestStream(83, constants.Program, buf, nil, nil) if err != nil { return @@ -6637,7 +6612,7 @@ func (l *Libvirt) StoragePoolRefresh(Pool StoragePool, Flags uint32) (err error) func (l *Libvirt) StoragePoolLookupByName(Name string) (rPool StoragePool, err error) { var buf []byte - args := StoragePoolLookupByNameArgs { + args := StoragePoolLookupByNameArgs{ Name: Name, } @@ -6670,7 +6645,7 @@ func (l *Libvirt) StoragePoolLookupByName(Name string) (rPool StoragePool, err e func (l *Libvirt) StoragePoolLookupByUUID(UUID UUID) (rPool StoragePool, err error) { var buf []byte - args := StoragePoolLookupByUUIDArgs { + args := StoragePoolLookupByUUIDArgs{ UUID: UUID, } @@ -6703,7 +6678,7 @@ func (l *Libvirt) StoragePoolLookupByUUID(UUID UUID) (rPool StoragePool, err err func (l *Libvirt) StoragePoolLookupByVolume(Vol StorageVol) (rPool StoragePool, err error) { var buf []byte - args := StoragePoolLookupByVolumeArgs { + args := StoragePoolLookupByVolumeArgs{ Vol: Vol, } @@ -6736,7 +6711,7 @@ func (l *Libvirt) StoragePoolLookupByVolume(Vol StorageVol) (rPool StoragePool, func (l *Libvirt) StoragePoolGetInfo(Pool StoragePool) (rState uint8, rCapacity uint64, rAllocation uint64, rAvailable uint64, err error) { var buf []byte - args := StoragePoolGetInfoArgs { + args := StoragePoolGetInfoArgs{ Pool: Pool, } @@ -6784,8 +6759,8 @@ func (l *Libvirt) StoragePoolGetInfo(Pool StoragePool) (rState uint8, rCapacity func (l *Libvirt) StoragePoolGetXMLDesc(Pool StoragePool, Flags StorageXMLFlags) (rXML string, err error) { var buf []byte - args := StoragePoolGetXMLDescArgs { - Pool: Pool, + args := StoragePoolGetXMLDescArgs{ + Pool: Pool, Flags: Flags, } @@ -6818,7 +6793,7 @@ func (l *Libvirt) StoragePoolGetXMLDesc(Pool StoragePool, Flags StorageXMLFlags) func (l *Libvirt) StoragePoolGetAutostart(Pool StoragePool) (rAutostart int32, err error) { var buf []byte - args := StoragePoolGetAutostartArgs { + args := StoragePoolGetAutostartArgs{ Pool: Pool, } @@ -6851,8 +6826,8 @@ func (l *Libvirt) StoragePoolGetAutostart(Pool StoragePool) (rAutostart int32, e func (l *Libvirt) StoragePoolSetAutostart(Pool StoragePool, Autostart int32) (err error) { var buf []byte - args := StoragePoolSetAutostartArgs { - Pool: Pool, + args := StoragePoolSetAutostartArgs{ + Pool: Pool, Autostart: Autostart, } @@ -6861,7 +6836,6 @@ func (l *Libvirt) StoragePoolSetAutostart(Pool StoragePool, Autostart int32) (er return } - _, err = l.requestStream(90, constants.Program, buf, nil, nil) if err != nil { return @@ -6874,7 +6848,7 @@ func (l *Libvirt) StoragePoolSetAutostart(Pool StoragePool, Autostart int32) (er func (l *Libvirt) StoragePoolNumOfVolumes(Pool StoragePool) (rNum int32, err error) { var buf []byte - args := StoragePoolNumOfVolumesArgs { + args := StoragePoolNumOfVolumesArgs{ Pool: Pool, } @@ -6907,8 +6881,8 @@ func (l *Libvirt) StoragePoolNumOfVolumes(Pool StoragePool) (rNum int32, err err func (l *Libvirt) StoragePoolListVolumes(Pool StoragePool, Maxnames int32) (rNames []string, err error) { var buf []byte - args := StoragePoolListVolumesArgs { - Pool: Pool, + args := StoragePoolListVolumesArgs{ + Pool: Pool, Maxnames: Maxnames, } @@ -6941,9 +6915,9 @@ func (l *Libvirt) StoragePoolListVolumes(Pool StoragePool, Maxnames int32) (rNam func (l *Libvirt) StorageVolCreateXML(Pool StoragePool, XML string, Flags StorageVolCreateFlags) (rVol StorageVol, err error) { var buf []byte - args := StorageVolCreateXMLArgs { - Pool: Pool, - XML: XML, + args := StorageVolCreateXMLArgs{ + Pool: Pool, + XML: XML, Flags: Flags, } @@ -6976,8 +6950,8 @@ func (l *Libvirt) StorageVolCreateXML(Pool StoragePool, XML string, Flags Storag func (l *Libvirt) StorageVolDelete(Vol StorageVol, Flags StorageVolDeleteFlags) (err error) { var buf []byte - args := StorageVolDeleteArgs { - Vol: Vol, + args := StorageVolDeleteArgs{ + Vol: Vol, Flags: Flags, } @@ -6986,7 +6960,6 @@ func (l *Libvirt) StorageVolDelete(Vol StorageVol, Flags StorageVolDeleteFlags) return } - _, err = l.requestStream(94, constants.Program, buf, nil, nil) if err != nil { return @@ -6999,7 +6972,7 @@ func (l *Libvirt) StorageVolDelete(Vol StorageVol, Flags StorageVolDeleteFlags) func (l *Libvirt) StorageVolLookupByName(Pool StoragePool, Name string) (rVol StorageVol, err error) { var buf []byte - args := StorageVolLookupByNameArgs { + args := StorageVolLookupByNameArgs{ Pool: Pool, Name: Name, } @@ -7033,7 +7006,7 @@ func (l *Libvirt) StorageVolLookupByName(Pool StoragePool, Name string) (rVol St func (l *Libvirt) StorageVolLookupByKey(Key string) (rVol StorageVol, err error) { var buf []byte - args := StorageVolLookupByKeyArgs { + args := StorageVolLookupByKeyArgs{ Key: Key, } @@ -7066,7 +7039,7 @@ func (l *Libvirt) StorageVolLookupByKey(Key string) (rVol StorageVol, err error) func (l *Libvirt) StorageVolLookupByPath(Path string) (rVol StorageVol, err error) { var buf []byte - args := StorageVolLookupByPathArgs { + args := StorageVolLookupByPathArgs{ Path: Path, } @@ -7099,7 +7072,7 @@ func (l *Libvirt) StorageVolLookupByPath(Path string) (rVol StorageVol, err erro func (l *Libvirt) StorageVolGetInfo(Vol StorageVol) (rType int8, rCapacity uint64, rAllocation uint64, err error) { var buf []byte - args := StorageVolGetInfoArgs { + args := StorageVolGetInfoArgs{ Vol: Vol, } @@ -7142,8 +7115,8 @@ func (l *Libvirt) StorageVolGetInfo(Vol StorageVol) (rType int8, rCapacity uint6 func (l *Libvirt) StorageVolGetXMLDesc(Vol StorageVol, Flags uint32) (rXML string, err error) { var buf []byte - args := StorageVolGetXMLDescArgs { - Vol: Vol, + args := StorageVolGetXMLDescArgs{ + Vol: Vol, Flags: Flags, } @@ -7176,7 +7149,7 @@ func (l *Libvirt) StorageVolGetXMLDesc(Vol StorageVol, Flags uint32) (rXML strin func (l *Libvirt) StorageVolGetPath(Vol StorageVol) (rName string, err error) { var buf []byte - args := StorageVolGetPathArgs { + args := StorageVolGetPathArgs{ Vol: Vol, } @@ -7209,9 +7182,9 @@ func (l *Libvirt) StorageVolGetPath(Vol StorageVol) (rName string, err error) { func (l *Libvirt) NodeGetCellsFreeMemory(StartCell int32, Maxcells int32) (rCells []uint64, err error) { var buf []byte - args := NodeGetCellsFreeMemoryArgs { + args := NodeGetCellsFreeMemoryArgs{ StartCell: StartCell, - Maxcells: Maxcells, + Maxcells: Maxcells, } buf, err = encode(&args) @@ -7267,12 +7240,12 @@ func (l *Libvirt) NodeGetFreeMemory() (rFreeMem uint64, err error) { func (l *Libvirt) DomainBlockPeek(Dom Domain, Path string, Offset uint64, Size uint32, Flags uint32) (rBuffer []byte, err error) { var buf []byte - args := DomainBlockPeekArgs { - Dom: Dom, - Path: Path, + args := DomainBlockPeekArgs{ + Dom: Dom, + Path: Path, Offset: Offset, - Size: Size, - Flags: Flags, + Size: Size, + Flags: Flags, } buf, err = encode(&args) @@ -7304,11 +7277,11 @@ func (l *Libvirt) DomainBlockPeek(Dom Domain, Path string, Offset uint64, Size u func (l *Libvirt) DomainMemoryPeek(Dom Domain, Offset uint64, Size uint32, Flags DomainMemoryFlags) (rBuffer []byte, err error) { var buf []byte - args := DomainMemoryPeekArgs { - Dom: Dom, + args := DomainMemoryPeekArgs{ + Dom: Dom, Offset: Offset, - Size: Size, - Flags: Flags, + Size: Size, + Flags: Flags, } buf, err = encode(&args) @@ -7388,7 +7361,6 @@ func (l *Libvirt) ConnectDomainEventDeregister() (rCbRegistered int32, err error func (l *Libvirt) DomainEventLifecycle() (err error) { var buf []byte - _, err = l.requestStream(107, constants.Program, buf, nil, nil) if err != nil { return @@ -7401,12 +7373,12 @@ func (l *Libvirt) DomainEventLifecycle() (err error) { func (l *Libvirt) DomainMigratePrepare2(UriIn OptString, Flags uint64, Dname OptString, Resource uint64, DomXML string) (rCookie []byte, rUriOut OptString, err error) { var buf []byte - args := DomainMigratePrepare2Args { - UriIn: UriIn, - Flags: Flags, - Dname: Dname, + args := DomainMigratePrepare2Args{ + UriIn: UriIn, + Flags: Flags, + Dname: Dname, Resource: Resource, - DomXML: DomXML, + DomXML: DomXML, } buf, err = encode(&args) @@ -7443,11 +7415,11 @@ func (l *Libvirt) DomainMigratePrepare2(UriIn OptString, Flags uint64, Dname Opt func (l *Libvirt) DomainMigrateFinish2(Dname string, Cookie []byte, Uri string, Flags uint64, Retcode int32) (rDdom Domain, err error) { var buf []byte - args := DomainMigrateFinish2Args { - Dname: Dname, - Cookie: Cookie, - Uri: Uri, - Flags: Flags, + args := DomainMigrateFinish2Args{ + Dname: Dname, + Cookie: Cookie, + Uri: Uri, + Flags: Flags, Retcode: Retcode, } @@ -7504,8 +7476,8 @@ func (l *Libvirt) ConnectGetUri() (rUri string, err error) { func (l *Libvirt) NodeNumOfDevices(Cap OptString, Flags uint32) (rNum int32, err error) { var buf []byte - args := NodeNumOfDevicesArgs { - Cap: Cap, + args := NodeNumOfDevicesArgs{ + Cap: Cap, Flags: Flags, } @@ -7538,10 +7510,10 @@ func (l *Libvirt) NodeNumOfDevices(Cap OptString, Flags uint32) (rNum int32, err func (l *Libvirt) NodeListDevices(Cap OptString, Maxnames int32, Flags uint32) (rNames []string, err error) { var buf []byte - args := NodeListDevicesArgs { - Cap: Cap, + args := NodeListDevicesArgs{ + Cap: Cap, Maxnames: Maxnames, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -7573,7 +7545,7 @@ func (l *Libvirt) NodeListDevices(Cap OptString, Maxnames int32, Flags uint32) ( func (l *Libvirt) NodeDeviceLookupByName(Name string) (rDev NodeDevice, err error) { var buf []byte - args := NodeDeviceLookupByNameArgs { + args := NodeDeviceLookupByNameArgs{ Name: Name, } @@ -7606,8 +7578,8 @@ func (l *Libvirt) NodeDeviceLookupByName(Name string) (rDev NodeDevice, err erro func (l *Libvirt) NodeDeviceGetXMLDesc(Name string, Flags uint32) (rXML string, err error) { var buf []byte - args := NodeDeviceGetXMLDescArgs { - Name: Name, + args := NodeDeviceGetXMLDescArgs{ + Name: Name, Flags: Flags, } @@ -7640,7 +7612,7 @@ func (l *Libvirt) NodeDeviceGetXMLDesc(Name string, Flags uint32) (rXML string, func (l *Libvirt) NodeDeviceGetParent(Name string) (rParentName OptString, err error) { var buf []byte - args := NodeDeviceGetParentArgs { + args := NodeDeviceGetParentArgs{ Name: Name, } @@ -7673,7 +7645,7 @@ func (l *Libvirt) NodeDeviceGetParent(Name string) (rParentName OptString, err e func (l *Libvirt) NodeDeviceNumOfCaps(Name string) (rNum int32, err error) { var buf []byte - args := NodeDeviceNumOfCapsArgs { + args := NodeDeviceNumOfCapsArgs{ Name: Name, } @@ -7706,8 +7678,8 @@ func (l *Libvirt) NodeDeviceNumOfCaps(Name string) (rNum int32, err error) { func (l *Libvirt) NodeDeviceListCaps(Name string, Maxnames int32) (rNames []string, err error) { var buf []byte - args := NodeDeviceListCapsArgs { - Name: Name, + args := NodeDeviceListCapsArgs{ + Name: Name, Maxnames: Maxnames, } @@ -7740,7 +7712,7 @@ func (l *Libvirt) NodeDeviceListCaps(Name string, Maxnames int32) (rNames []stri func (l *Libvirt) NodeDeviceDettach(Name string) (err error) { var buf []byte - args := NodeDeviceDettachArgs { + args := NodeDeviceDettachArgs{ Name: Name, } @@ -7749,7 +7721,6 @@ func (l *Libvirt) NodeDeviceDettach(Name string) (err error) { return } - _, err = l.requestStream(118, constants.Program, buf, nil, nil) if err != nil { return @@ -7762,7 +7733,7 @@ func (l *Libvirt) NodeDeviceDettach(Name string) (err error) { func (l *Libvirt) NodeDeviceReAttach(Name string) (err error) { var buf []byte - args := NodeDeviceReAttachArgs { + args := NodeDeviceReAttachArgs{ Name: Name, } @@ -7771,7 +7742,6 @@ func (l *Libvirt) NodeDeviceReAttach(Name string) (err error) { return } - _, err = l.requestStream(119, constants.Program, buf, nil, nil) if err != nil { return @@ -7784,7 +7754,7 @@ func (l *Libvirt) NodeDeviceReAttach(Name string) (err error) { func (l *Libvirt) NodeDeviceReset(Name string) (err error) { var buf []byte - args := NodeDeviceResetArgs { + args := NodeDeviceResetArgs{ Name: Name, } @@ -7793,7 +7763,6 @@ func (l *Libvirt) NodeDeviceReset(Name string) (err error) { return } - _, err = l.requestStream(120, constants.Program, buf, nil, nil) if err != nil { return @@ -7806,7 +7775,7 @@ func (l *Libvirt) NodeDeviceReset(Name string) (err error) { func (l *Libvirt) DomainGetSecurityLabel(Dom Domain) (rLabel []int8, rEnforcing int32, err error) { var buf []byte - args := DomainGetSecurityLabelArgs { + args := DomainGetSecurityLabelArgs{ Dom: Dom, } @@ -7873,9 +7842,9 @@ func (l *Libvirt) NodeGetSecurityModel() (rModel []int8, rDoi []int8, err error) func (l *Libvirt) NodeDeviceCreateXML(XMLDesc string, Flags uint32) (rDev NodeDevice, err error) { var buf []byte - args := NodeDeviceCreateXMLArgs { + args := NodeDeviceCreateXMLArgs{ XMLDesc: XMLDesc, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -7907,7 +7876,7 @@ func (l *Libvirt) NodeDeviceCreateXML(XMLDesc string, Flags uint32) (rDev NodeDe func (l *Libvirt) NodeDeviceDestroy(Name string) (err error) { var buf []byte - args := NodeDeviceDestroyArgs { + args := NodeDeviceDestroyArgs{ Name: Name, } @@ -7916,7 +7885,6 @@ func (l *Libvirt) NodeDeviceDestroy(Name string) (err error) { return } - _, err = l.requestStream(124, constants.Program, buf, nil, nil) if err != nil { return @@ -7929,11 +7897,11 @@ func (l *Libvirt) NodeDeviceDestroy(Name string) (err error) { func (l *Libvirt) StorageVolCreateXMLFrom(Pool StoragePool, XML string, Clonevol StorageVol, Flags StorageVolCreateFlags) (rVol StorageVol, err error) { var buf []byte - args := StorageVolCreateXMLFromArgs { - Pool: Pool, - XML: XML, + args := StorageVolCreateXMLFromArgs{ + Pool: Pool, + XML: XML, Clonevol: Clonevol, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -7989,7 +7957,7 @@ func (l *Libvirt) ConnectNumOfInterfaces() (rNum int32, err error) { func (l *Libvirt) ConnectListInterfaces(Maxnames int32) (rNames []string, err error) { var buf []byte - args := ConnectListInterfacesArgs { + args := ConnectListInterfacesArgs{ Maxnames: Maxnames, } @@ -8022,7 +7990,7 @@ func (l *Libvirt) ConnectListInterfaces(Maxnames int32) (rNames []string, err er func (l *Libvirt) InterfaceLookupByName(Name string) (rIface Interface, err error) { var buf []byte - args := InterfaceLookupByNameArgs { + args := InterfaceLookupByNameArgs{ Name: Name, } @@ -8055,7 +8023,7 @@ func (l *Libvirt) InterfaceLookupByName(Name string) (rIface Interface, err erro func (l *Libvirt) InterfaceLookupByMacString(Mac string) (rIface Interface, err error) { var buf []byte - args := InterfaceLookupByMacStringArgs { + args := InterfaceLookupByMacStringArgs{ Mac: Mac, } @@ -8088,7 +8056,7 @@ func (l *Libvirt) InterfaceLookupByMacString(Mac string) (rIface Interface, err func (l *Libvirt) InterfaceGetXMLDesc(Iface Interface, Flags uint32) (rXML string, err error) { var buf []byte - args := InterfaceGetXMLDescArgs { + args := InterfaceGetXMLDescArgs{ Iface: Iface, Flags: Flags, } @@ -8122,8 +8090,8 @@ func (l *Libvirt) InterfaceGetXMLDesc(Iface Interface, Flags uint32) (rXML strin func (l *Libvirt) InterfaceDefineXML(XML string, Flags uint32) (rIface Interface, err error) { var buf []byte - args := InterfaceDefineXMLArgs { - XML: XML, + args := InterfaceDefineXMLArgs{ + XML: XML, Flags: Flags, } @@ -8156,7 +8124,7 @@ func (l *Libvirt) InterfaceDefineXML(XML string, Flags uint32) (rIface Interface func (l *Libvirt) InterfaceUndefine(Iface Interface) (err error) { var buf []byte - args := InterfaceUndefineArgs { + args := InterfaceUndefineArgs{ Iface: Iface, } @@ -8165,7 +8133,6 @@ func (l *Libvirt) InterfaceUndefine(Iface Interface) (err error) { return } - _, err = l.requestStream(132, constants.Program, buf, nil, nil) if err != nil { return @@ -8178,7 +8145,7 @@ func (l *Libvirt) InterfaceUndefine(Iface Interface) (err error) { func (l *Libvirt) InterfaceCreate(Iface Interface, Flags uint32) (err error) { var buf []byte - args := InterfaceCreateArgs { + args := InterfaceCreateArgs{ Iface: Iface, Flags: Flags, } @@ -8188,7 +8155,6 @@ func (l *Libvirt) InterfaceCreate(Iface Interface, Flags uint32) (err error) { return } - _, err = l.requestStream(133, constants.Program, buf, nil, nil) if err != nil { return @@ -8201,7 +8167,7 @@ func (l *Libvirt) InterfaceCreate(Iface Interface, Flags uint32) (err error) { func (l *Libvirt) InterfaceDestroy(Iface Interface, Flags uint32) (err error) { var buf []byte - args := InterfaceDestroyArgs { + args := InterfaceDestroyArgs{ Iface: Iface, Flags: Flags, } @@ -8211,7 +8177,6 @@ func (l *Libvirt) InterfaceDestroy(Iface Interface, Flags uint32) (err error) { return } - _, err = l.requestStream(134, constants.Program, buf, nil, nil) if err != nil { return @@ -8224,10 +8189,10 @@ func (l *Libvirt) InterfaceDestroy(Iface Interface, Flags uint32) (err error) { func (l *Libvirt) ConnectDomainXMLFromNative(NativeFormat string, NativeConfig string, Flags uint32) (rDomainXML string, err error) { var buf []byte - args := ConnectDomainXMLFromNativeArgs { + args := ConnectDomainXMLFromNativeArgs{ NativeFormat: NativeFormat, NativeConfig: NativeConfig, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -8259,10 +8224,10 @@ func (l *Libvirt) ConnectDomainXMLFromNative(NativeFormat string, NativeConfig s func (l *Libvirt) ConnectDomainXMLToNative(NativeFormat string, DomainXML string, Flags uint32) (rNativeConfig string, err error) { var buf []byte - args := ConnectDomainXMLToNativeArgs { + args := ConnectDomainXMLToNativeArgs{ NativeFormat: NativeFormat, - DomainXML: DomainXML, - Flags: Flags, + DomainXML: DomainXML, + Flags: Flags, } buf, err = encode(&args) @@ -8318,7 +8283,7 @@ func (l *Libvirt) ConnectNumOfDefinedInterfaces() (rNum int32, err error) { func (l *Libvirt) ConnectListDefinedInterfaces(Maxnames int32) (rNames []string, err error) { var buf []byte - args := ConnectListDefinedInterfacesArgs { + args := ConnectListDefinedInterfacesArgs{ Maxnames: Maxnames, } @@ -8375,7 +8340,7 @@ func (l *Libvirt) ConnectNumOfSecrets() (rNum int32, err error) { func (l *Libvirt) ConnectListSecrets(Maxuuids int32) (rUuids []string, err error) { var buf []byte - args := ConnectListSecretsArgs { + args := ConnectListSecretsArgs{ Maxuuids: Maxuuids, } @@ -8408,7 +8373,7 @@ func (l *Libvirt) ConnectListSecrets(Maxuuids int32) (rUuids []string, err error func (l *Libvirt) SecretLookupByUUID(UUID UUID) (rOptSecret Secret, err error) { var buf []byte - args := SecretLookupByUUIDArgs { + args := SecretLookupByUUIDArgs{ UUID: UUID, } @@ -8441,8 +8406,8 @@ func (l *Libvirt) SecretLookupByUUID(UUID UUID) (rOptSecret Secret, err error) { func (l *Libvirt) SecretDefineXML(XML string, Flags uint32) (rOptSecret Secret, err error) { var buf []byte - args := SecretDefineXMLArgs { - XML: XML, + args := SecretDefineXMLArgs{ + XML: XML, Flags: Flags, } @@ -8475,9 +8440,9 @@ func (l *Libvirt) SecretDefineXML(XML string, Flags uint32) (rOptSecret Secret, func (l *Libvirt) SecretGetXMLDesc(OptSecret Secret, Flags uint32) (rXML string, err error) { var buf []byte - args := SecretGetXMLDescArgs { + args := SecretGetXMLDescArgs{ OptSecret: OptSecret, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -8509,10 +8474,10 @@ func (l *Libvirt) SecretGetXMLDesc(OptSecret Secret, Flags uint32) (rXML string, func (l *Libvirt) SecretSetValue(OptSecret Secret, Value []byte, Flags uint32) (err error) { var buf []byte - args := SecretSetValueArgs { + args := SecretSetValueArgs{ OptSecret: OptSecret, - Value: Value, - Flags: Flags, + Value: Value, + Flags: Flags, } buf, err = encode(&args) @@ -8520,7 +8485,6 @@ func (l *Libvirt) SecretSetValue(OptSecret Secret, Value []byte, Flags uint32) ( return } - _, err = l.requestStream(144, constants.Program, buf, nil, nil) if err != nil { return @@ -8533,9 +8497,9 @@ func (l *Libvirt) SecretSetValue(OptSecret Secret, Value []byte, Flags uint32) ( func (l *Libvirt) SecretGetValue(OptSecret Secret, Flags uint32) (rValue []byte, err error) { var buf []byte - args := SecretGetValueArgs { + args := SecretGetValueArgs{ OptSecret: OptSecret, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -8567,7 +8531,7 @@ func (l *Libvirt) SecretGetValue(OptSecret Secret, Flags uint32) (rValue []byte, func (l *Libvirt) SecretUndefine(OptSecret Secret) (err error) { var buf []byte - args := SecretUndefineArgs { + args := SecretUndefineArgs{ OptSecret: OptSecret, } @@ -8576,7 +8540,6 @@ func (l *Libvirt) SecretUndefine(OptSecret Secret) (err error) { return } - _, err = l.requestStream(146, constants.Program, buf, nil, nil) if err != nil { return @@ -8589,9 +8552,9 @@ func (l *Libvirt) SecretUndefine(OptSecret Secret) (err error) { func (l *Libvirt) SecretLookupByUsage(UsageType int32, UsageID string) (rOptSecret Secret, err error) { var buf []byte - args := SecretLookupByUsageArgs { + args := SecretLookupByUsageArgs{ UsageType: UsageType, - UsageID: UsageID, + UsageID: UsageID, } buf, err = encode(&args) @@ -8623,11 +8586,11 @@ func (l *Libvirt) SecretLookupByUsage(UsageType int32, UsageID string) (rOptSecr func (l *Libvirt) DomainMigratePrepareTunnel(Flags uint64, outStream io.Reader, Dname OptString, Resource uint64, DomXML string) (err error) { var buf []byte - args := DomainMigratePrepareTunnelArgs { - Flags: Flags, - Dname: Dname, + args := DomainMigratePrepareTunnelArgs{ + Flags: Flags, + Dname: Dname, Resource: Resource, - DomXML: DomXML, + DomXML: DomXML, } buf, err = encode(&args) @@ -8635,7 +8598,6 @@ func (l *Libvirt) DomainMigratePrepareTunnel(Flags uint64, outStream io.Reader, return } - _, err = l.requestStream(148, constants.Program, buf, outStream, nil) if err != nil { return @@ -8672,7 +8634,7 @@ func (l *Libvirt) ConnectIsSecure() (rSecure int32, err error) { func (l *Libvirt) DomainIsActive(Dom Domain) (rActive int32, err error) { var buf []byte - args := DomainIsActiveArgs { + args := DomainIsActiveArgs{ Dom: Dom, } @@ -8705,7 +8667,7 @@ func (l *Libvirt) DomainIsActive(Dom Domain) (rActive int32, err error) { func (l *Libvirt) DomainIsPersistent(Dom Domain) (rPersistent int32, err error) { var buf []byte - args := DomainIsPersistentArgs { + args := DomainIsPersistentArgs{ Dom: Dom, } @@ -8738,7 +8700,7 @@ func (l *Libvirt) DomainIsPersistent(Dom Domain) (rPersistent int32, err error) func (l *Libvirt) NetworkIsActive(Net Network) (rActive int32, err error) { var buf []byte - args := NetworkIsActiveArgs { + args := NetworkIsActiveArgs{ Net: Net, } @@ -8771,7 +8733,7 @@ func (l *Libvirt) NetworkIsActive(Net Network) (rActive int32, err error) { func (l *Libvirt) NetworkIsPersistent(Net Network) (rPersistent int32, err error) { var buf []byte - args := NetworkIsPersistentArgs { + args := NetworkIsPersistentArgs{ Net: Net, } @@ -8804,7 +8766,7 @@ func (l *Libvirt) NetworkIsPersistent(Net Network) (rPersistent int32, err error func (l *Libvirt) StoragePoolIsActive(Pool StoragePool) (rActive int32, err error) { var buf []byte - args := StoragePoolIsActiveArgs { + args := StoragePoolIsActiveArgs{ Pool: Pool, } @@ -8837,7 +8799,7 @@ func (l *Libvirt) StoragePoolIsActive(Pool StoragePool) (rActive int32, err erro func (l *Libvirt) StoragePoolIsPersistent(Pool StoragePool) (rPersistent int32, err error) { var buf []byte - args := StoragePoolIsPersistentArgs { + args := StoragePoolIsPersistentArgs{ Pool: Pool, } @@ -8870,7 +8832,7 @@ func (l *Libvirt) StoragePoolIsPersistent(Pool StoragePool) (rPersistent int32, func (l *Libvirt) InterfaceIsActive(Iface Interface) (rActive int32, err error) { var buf []byte - args := InterfaceIsActiveArgs { + args := InterfaceIsActiveArgs{ Iface: Iface, } @@ -8927,8 +8889,8 @@ func (l *Libvirt) ConnectGetLibVersion() (rLibVer uint64, err error) { func (l *Libvirt) ConnectCompareCPU(XML string, Flags ConnectCompareCPUFlags) (rResult int32, err error) { var buf []byte - args := ConnectCompareCPUArgs { - XML: XML, + args := ConnectCompareCPUArgs{ + XML: XML, Flags: Flags, } @@ -8961,10 +8923,10 @@ func (l *Libvirt) ConnectCompareCPU(XML string, Flags ConnectCompareCPUFlags) (r func (l *Libvirt) DomainMemoryStats(Dom Domain, MaxStats uint32, Flags uint32) (rStats []DomainMemoryStat, err error) { var buf []byte - args := DomainMemoryStatsArgs { - Dom: Dom, + args := DomainMemoryStatsArgs{ + Dom: Dom, MaxStats: MaxStats, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -8996,9 +8958,9 @@ func (l *Libvirt) DomainMemoryStats(Dom Domain, MaxStats uint32, Flags uint32) ( func (l *Libvirt) DomainAttachDeviceFlags(Dom Domain, XML string, Flags uint32) (err error) { var buf []byte - args := DomainAttachDeviceFlagsArgs { - Dom: Dom, - XML: XML, + args := DomainAttachDeviceFlagsArgs{ + Dom: Dom, + XML: XML, Flags: Flags, } @@ -9007,7 +8969,6 @@ func (l *Libvirt) DomainAttachDeviceFlags(Dom Domain, XML string, Flags uint32) return } - _, err = l.requestStream(160, constants.Program, buf, nil, nil) if err != nil { return @@ -9020,9 +8981,9 @@ func (l *Libvirt) DomainAttachDeviceFlags(Dom Domain, XML string, Flags uint32) func (l *Libvirt) DomainDetachDeviceFlags(Dom Domain, XML string, Flags uint32) (err error) { var buf []byte - args := DomainDetachDeviceFlagsArgs { - Dom: Dom, - XML: XML, + args := DomainDetachDeviceFlagsArgs{ + Dom: Dom, + XML: XML, Flags: Flags, } @@ -9031,7 +8992,6 @@ func (l *Libvirt) DomainDetachDeviceFlags(Dom Domain, XML string, Flags uint32) return } - _, err = l.requestStream(161, constants.Program, buf, nil, nil) if err != nil { return @@ -9044,9 +9004,9 @@ func (l *Libvirt) DomainDetachDeviceFlags(Dom Domain, XML string, Flags uint32) func (l *Libvirt) ConnectBaselineCPU(XMLCPUs []string, Flags ConnectBaselineCPUFlags) (rCPU string, err error) { var buf []byte - args := ConnectBaselineCPUArgs { + args := ConnectBaselineCPUArgs{ XMLCPUs: XMLCPUs, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -9078,7 +9038,7 @@ func (l *Libvirt) ConnectBaselineCPU(XMLCPUs []string, Flags ConnectBaselineCPUF func (l *Libvirt) DomainGetJobInfo(Dom Domain) (rType int32, rTimeElapsed uint64, rTimeRemaining uint64, rDataTotal uint64, rDataProcessed uint64, rDataRemaining uint64, rMemTotal uint64, rMemProcessed uint64, rMemRemaining uint64, rFileTotal uint64, rFileProcessed uint64, rFileRemaining uint64, err error) { var buf []byte - args := DomainGetJobInfoArgs { + args := DomainGetJobInfoArgs{ Dom: Dom, } @@ -9166,7 +9126,7 @@ func (l *Libvirt) DomainGetJobInfo(Dom Domain) (rType int32, rTimeElapsed uint64 func (l *Libvirt) DomainAbortJob(Dom Domain) (err error) { var buf []byte - args := DomainAbortJobArgs { + args := DomainAbortJobArgs{ Dom: Dom, } @@ -9175,7 +9135,6 @@ func (l *Libvirt) DomainAbortJob(Dom Domain) (err error) { return } - _, err = l.requestStream(164, constants.Program, buf, nil, nil) if err != nil { return @@ -9188,8 +9147,8 @@ func (l *Libvirt) DomainAbortJob(Dom Domain) (err error) { func (l *Libvirt) StorageVolWipe(Vol StorageVol, Flags uint32) (err error) { var buf []byte - args := StorageVolWipeArgs { - Vol: Vol, + args := StorageVolWipeArgs{ + Vol: Vol, Flags: Flags, } @@ -9198,7 +9157,6 @@ func (l *Libvirt) StorageVolWipe(Vol StorageVol, Flags uint32) (err error) { return } - _, err = l.requestStream(165, constants.Program, buf, nil, nil) if err != nil { return @@ -9211,10 +9169,10 @@ func (l *Libvirt) StorageVolWipe(Vol StorageVol, Flags uint32) (err error) { func (l *Libvirt) DomainMigrateSetMaxDowntime(Dom Domain, Downtime uint64, Flags uint32) (err error) { var buf []byte - args := DomainMigrateSetMaxDowntimeArgs { - Dom: Dom, + args := DomainMigrateSetMaxDowntimeArgs{ + Dom: Dom, Downtime: Downtime, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -9222,7 +9180,6 @@ func (l *Libvirt) DomainMigrateSetMaxDowntime(Dom Domain, Downtime uint64, Flags return } - _, err = l.requestStream(166, constants.Program, buf, nil, nil) if err != nil { return @@ -9235,7 +9192,7 @@ func (l *Libvirt) DomainMigrateSetMaxDowntime(Dom Domain, Downtime uint64, Flags func (l *Libvirt) ConnectDomainEventRegisterAny(EventID int32) (err error) { var buf []byte - args := ConnectDomainEventRegisterAnyArgs { + args := ConnectDomainEventRegisterAnyArgs{ EventID: EventID, } @@ -9244,7 +9201,6 @@ func (l *Libvirt) ConnectDomainEventRegisterAny(EventID int32) (err error) { return } - _, err = l.requestStream(167, constants.Program, buf, nil, nil) if err != nil { return @@ -9257,7 +9213,7 @@ func (l *Libvirt) ConnectDomainEventRegisterAny(EventID int32) (err error) { func (l *Libvirt) ConnectDomainEventDeregisterAny(EventID int32) (err error) { var buf []byte - args := ConnectDomainEventDeregisterAnyArgs { + args := ConnectDomainEventDeregisterAnyArgs{ EventID: EventID, } @@ -9266,7 +9222,6 @@ func (l *Libvirt) ConnectDomainEventDeregisterAny(EventID int32) (err error) { return } - _, err = l.requestStream(168, constants.Program, buf, nil, nil) if err != nil { return @@ -9279,7 +9234,6 @@ func (l *Libvirt) ConnectDomainEventDeregisterAny(EventID int32) (err error) { func (l *Libvirt) DomainEventReboot() (err error) { var buf []byte - _, err = l.requestStream(169, constants.Program, buf, nil, nil) if err != nil { return @@ -9292,7 +9246,6 @@ func (l *Libvirt) DomainEventReboot() (err error) { func (l *Libvirt) DomainEventRtcChange() (err error) { var buf []byte - _, err = l.requestStream(170, constants.Program, buf, nil, nil) if err != nil { return @@ -9305,7 +9258,6 @@ func (l *Libvirt) DomainEventRtcChange() (err error) { func (l *Libvirt) DomainEventWatchdog() (err error) { var buf []byte - _, err = l.requestStream(171, constants.Program, buf, nil, nil) if err != nil { return @@ -9318,7 +9270,6 @@ func (l *Libvirt) DomainEventWatchdog() (err error) { func (l *Libvirt) DomainEventIOError() (err error) { var buf []byte - _, err = l.requestStream(172, constants.Program, buf, nil, nil) if err != nil { return @@ -9331,7 +9282,6 @@ func (l *Libvirt) DomainEventIOError() (err error) { func (l *Libvirt) DomainEventGraphics() (err error) { var buf []byte - _, err = l.requestStream(173, constants.Program, buf, nil, nil) if err != nil { return @@ -9344,9 +9294,9 @@ func (l *Libvirt) DomainEventGraphics() (err error) { func (l *Libvirt) DomainUpdateDeviceFlags(Dom Domain, XML string, Flags DomainDeviceModifyFlags) (err error) { var buf []byte - args := DomainUpdateDeviceFlagsArgs { - Dom: Dom, - XML: XML, + args := DomainUpdateDeviceFlagsArgs{ + Dom: Dom, + XML: XML, Flags: Flags, } @@ -9355,7 +9305,6 @@ func (l *Libvirt) DomainUpdateDeviceFlags(Dom Domain, XML string, Flags DomainDe return } - _, err = l.requestStream(174, constants.Program, buf, nil, nil) if err != nil { return @@ -9368,7 +9317,7 @@ func (l *Libvirt) DomainUpdateDeviceFlags(Dom Domain, XML string, Flags DomainDe func (l *Libvirt) NwfilterLookupByName(Name string) (rOptNwfilter Nwfilter, err error) { var buf []byte - args := NwfilterLookupByNameArgs { + args := NwfilterLookupByNameArgs{ Name: Name, } @@ -9401,7 +9350,7 @@ func (l *Libvirt) NwfilterLookupByName(Name string) (rOptNwfilter Nwfilter, err func (l *Libvirt) NwfilterLookupByUUID(UUID UUID) (rOptNwfilter Nwfilter, err error) { var buf []byte - args := NwfilterLookupByUUIDArgs { + args := NwfilterLookupByUUIDArgs{ UUID: UUID, } @@ -9434,9 +9383,9 @@ func (l *Libvirt) NwfilterLookupByUUID(UUID UUID) (rOptNwfilter Nwfilter, err er func (l *Libvirt) NwfilterGetXMLDesc(OptNwfilter Nwfilter, Flags uint32) (rXML string, err error) { var buf []byte - args := NwfilterGetXMLDescArgs { + args := NwfilterGetXMLDescArgs{ OptNwfilter: OptNwfilter, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -9492,7 +9441,7 @@ func (l *Libvirt) ConnectNumOfNwfilters() (rNum int32, err error) { func (l *Libvirt) ConnectListNwfilters(Maxnames int32) (rNames []string, err error) { var buf []byte - args := ConnectListNwfiltersArgs { + args := ConnectListNwfiltersArgs{ Maxnames: Maxnames, } @@ -9525,7 +9474,7 @@ func (l *Libvirt) ConnectListNwfilters(Maxnames int32) (rNames []string, err err func (l *Libvirt) NwfilterDefineXML(XML string) (rOptNwfilter Nwfilter, err error) { var buf []byte - args := NwfilterDefineXMLArgs { + args := NwfilterDefineXMLArgs{ XML: XML, } @@ -9558,7 +9507,7 @@ func (l *Libvirt) NwfilterDefineXML(XML string) (rOptNwfilter Nwfilter, err erro func (l *Libvirt) NwfilterUndefine(OptNwfilter Nwfilter) (err error) { var buf []byte - args := NwfilterUndefineArgs { + args := NwfilterUndefineArgs{ OptNwfilter: OptNwfilter, } @@ -9567,7 +9516,6 @@ func (l *Libvirt) NwfilterUndefine(OptNwfilter Nwfilter) (err error) { return } - _, err = l.requestStream(181, constants.Program, buf, nil, nil) if err != nil { return @@ -9580,8 +9528,8 @@ func (l *Libvirt) NwfilterUndefine(OptNwfilter Nwfilter) (err error) { func (l *Libvirt) DomainManagedSave(Dom Domain, Flags uint32) (err error) { var buf []byte - args := DomainManagedSaveArgs { - Dom: Dom, + args := DomainManagedSaveArgs{ + Dom: Dom, Flags: Flags, } @@ -9590,7 +9538,6 @@ func (l *Libvirt) DomainManagedSave(Dom Domain, Flags uint32) (err error) { return } - _, err = l.requestStream(182, constants.Program, buf, nil, nil) if err != nil { return @@ -9603,8 +9550,8 @@ func (l *Libvirt) DomainManagedSave(Dom Domain, Flags uint32) (err error) { func (l *Libvirt) DomainHasManagedSaveImage(Dom Domain, Flags uint32) (rResult int32, err error) { var buf []byte - args := DomainHasManagedSaveImageArgs { - Dom: Dom, + args := DomainHasManagedSaveImageArgs{ + Dom: Dom, Flags: Flags, } @@ -9637,8 +9584,8 @@ func (l *Libvirt) DomainHasManagedSaveImage(Dom Domain, Flags uint32) (rResult i func (l *Libvirt) DomainManagedSaveRemove(Dom Domain, Flags uint32) (err error) { var buf []byte - args := DomainManagedSaveRemoveArgs { - Dom: Dom, + args := DomainManagedSaveRemoveArgs{ + Dom: Dom, Flags: Flags, } @@ -9647,7 +9594,6 @@ func (l *Libvirt) DomainManagedSaveRemove(Dom Domain, Flags uint32) (err error) return } - _, err = l.requestStream(184, constants.Program, buf, nil, nil) if err != nil { return @@ -9660,10 +9606,10 @@ func (l *Libvirt) DomainManagedSaveRemove(Dom Domain, Flags uint32) (err error) func (l *Libvirt) DomainSnapshotCreateXML(Dom Domain, XMLDesc string, Flags uint32) (rSnap DomainSnapshot, err error) { var buf []byte - args := DomainSnapshotCreateXMLArgs { - Dom: Dom, + args := DomainSnapshotCreateXMLArgs{ + Dom: Dom, XMLDesc: XMLDesc, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -9695,8 +9641,8 @@ func (l *Libvirt) DomainSnapshotCreateXML(Dom Domain, XMLDesc string, Flags uint func (l *Libvirt) DomainSnapshotGetXMLDesc(Snap DomainSnapshot, Flags uint32) (rXML string, err error) { var buf []byte - args := DomainSnapshotGetXMLDescArgs { - Snap: Snap, + args := DomainSnapshotGetXMLDescArgs{ + Snap: Snap, Flags: Flags, } @@ -9729,8 +9675,8 @@ func (l *Libvirt) DomainSnapshotGetXMLDesc(Snap DomainSnapshot, Flags uint32) (r func (l *Libvirt) DomainSnapshotNum(Dom Domain, Flags uint32) (rNum int32, err error) { var buf []byte - args := DomainSnapshotNumArgs { - Dom: Dom, + args := DomainSnapshotNumArgs{ + Dom: Dom, Flags: Flags, } @@ -9763,10 +9709,10 @@ func (l *Libvirt) DomainSnapshotNum(Dom Domain, Flags uint32) (rNum int32, err e func (l *Libvirt) DomainSnapshotListNames(Dom Domain, Maxnames int32, Flags uint32) (rNames []string, err error) { var buf []byte - args := DomainSnapshotListNamesArgs { - Dom: Dom, + args := DomainSnapshotListNamesArgs{ + Dom: Dom, Maxnames: Maxnames, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -9798,9 +9744,9 @@ func (l *Libvirt) DomainSnapshotListNames(Dom Domain, Maxnames int32, Flags uint func (l *Libvirt) DomainSnapshotLookupByName(Dom Domain, Name string, Flags uint32) (rSnap DomainSnapshot, err error) { var buf []byte - args := DomainSnapshotLookupByNameArgs { - Dom: Dom, - Name: Name, + args := DomainSnapshotLookupByNameArgs{ + Dom: Dom, + Name: Name, Flags: Flags, } @@ -9833,8 +9779,8 @@ func (l *Libvirt) DomainSnapshotLookupByName(Dom Domain, Name string, Flags uint func (l *Libvirt) DomainHasCurrentSnapshot(Dom Domain, Flags uint32) (rResult int32, err error) { var buf []byte - args := DomainHasCurrentSnapshotArgs { - Dom: Dom, + args := DomainHasCurrentSnapshotArgs{ + Dom: Dom, Flags: Flags, } @@ -9867,8 +9813,8 @@ func (l *Libvirt) DomainHasCurrentSnapshot(Dom Domain, Flags uint32) (rResult in func (l *Libvirt) DomainSnapshotCurrent(Dom Domain, Flags uint32) (rSnap DomainSnapshot, err error) { var buf []byte - args := DomainSnapshotCurrentArgs { - Dom: Dom, + args := DomainSnapshotCurrentArgs{ + Dom: Dom, Flags: Flags, } @@ -9901,8 +9847,8 @@ func (l *Libvirt) DomainSnapshotCurrent(Dom Domain, Flags uint32) (rSnap DomainS func (l *Libvirt) DomainRevertToSnapshot(Snap DomainSnapshot, Flags uint32) (err error) { var buf []byte - args := DomainRevertToSnapshotArgs { - Snap: Snap, + args := DomainRevertToSnapshotArgs{ + Snap: Snap, Flags: Flags, } @@ -9911,7 +9857,6 @@ func (l *Libvirt) DomainRevertToSnapshot(Snap DomainSnapshot, Flags uint32) (err return } - _, err = l.requestStream(192, constants.Program, buf, nil, nil) if err != nil { return @@ -9924,8 +9869,8 @@ func (l *Libvirt) DomainRevertToSnapshot(Snap DomainSnapshot, Flags uint32) (err func (l *Libvirt) DomainSnapshotDelete(Snap DomainSnapshot, Flags DomainSnapshotDeleteFlags) (err error) { var buf []byte - args := DomainSnapshotDeleteArgs { - Snap: Snap, + args := DomainSnapshotDeleteArgs{ + Snap: Snap, Flags: Flags, } @@ -9934,7 +9879,6 @@ func (l *Libvirt) DomainSnapshotDelete(Snap DomainSnapshot, Flags DomainSnapshot return } - _, err = l.requestStream(193, constants.Program, buf, nil, nil) if err != nil { return @@ -9947,9 +9891,9 @@ func (l *Libvirt) DomainSnapshotDelete(Snap DomainSnapshot, Flags DomainSnapshot func (l *Libvirt) DomainGetBlockInfo(Dom Domain, Path string, Flags uint32) (rAllocation uint64, rCapacity uint64, rPhysical uint64, err error) { var buf []byte - args := DomainGetBlockInfoArgs { - Dom: Dom, - Path: Path, + args := DomainGetBlockInfoArgs{ + Dom: Dom, + Path: Path, Flags: Flags, } @@ -9992,7 +9936,6 @@ func (l *Libvirt) DomainGetBlockInfo(Dom Domain, Path string, Flags uint32) (rAl func (l *Libvirt) DomainEventIOErrorReason() (err error) { var buf []byte - _, err = l.requestStream(195, constants.Program, buf, nil, nil) if err != nil { return @@ -10005,8 +9948,8 @@ func (l *Libvirt) DomainEventIOErrorReason() (err error) { func (l *Libvirt) DomainCreateWithFlags(Dom Domain, Flags uint32) (rDom Domain, err error) { var buf []byte - args := DomainCreateWithFlagsArgs { - Dom: Dom, + args := DomainCreateWithFlagsArgs{ + Dom: Dom, Flags: Flags, } @@ -10039,10 +9982,10 @@ func (l *Libvirt) DomainCreateWithFlags(Dom Domain, Flags uint32) (rDom Domain, func (l *Libvirt) DomainSetMemoryParameters(Dom Domain, Params []TypedParam, Flags uint32) (err error) { var buf []byte - args := DomainSetMemoryParametersArgs { - Dom: Dom, + args := DomainSetMemoryParametersArgs{ + Dom: Dom, Params: Params, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10050,7 +9993,6 @@ func (l *Libvirt) DomainSetMemoryParameters(Dom Domain, Params []TypedParam, Fla return } - _, err = l.requestStream(197, constants.Program, buf, nil, nil) if err != nil { return @@ -10063,10 +10005,10 @@ func (l *Libvirt) DomainSetMemoryParameters(Dom Domain, Params []TypedParam, Fla func (l *Libvirt) DomainGetMemoryParameters(Dom Domain, Nparams int32, Flags uint32) (rParams []TypedParam, rNparams int32, err error) { var buf []byte - args := DomainGetMemoryParametersArgs { - Dom: Dom, + args := DomainGetMemoryParametersArgs{ + Dom: Dom, Nparams: Nparams, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10103,10 +10045,10 @@ func (l *Libvirt) DomainGetMemoryParameters(Dom Domain, Nparams int32, Flags uin func (l *Libvirt) DomainSetVcpusFlags(Dom Domain, Nvcpus uint32, Flags uint32) (err error) { var buf []byte - args := DomainSetVcpusFlagsArgs { - Dom: Dom, + args := DomainSetVcpusFlagsArgs{ + Dom: Dom, Nvcpus: Nvcpus, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10114,7 +10056,6 @@ func (l *Libvirt) DomainSetVcpusFlags(Dom Domain, Nvcpus uint32, Flags uint32) ( return } - _, err = l.requestStream(199, constants.Program, buf, nil, nil) if err != nil { return @@ -10127,8 +10068,8 @@ func (l *Libvirt) DomainSetVcpusFlags(Dom Domain, Nvcpus uint32, Flags uint32) ( func (l *Libvirt) DomainGetVcpusFlags(Dom Domain, Flags uint32) (rNum int32, err error) { var buf []byte - args := DomainGetVcpusFlagsArgs { - Dom: Dom, + args := DomainGetVcpusFlagsArgs{ + Dom: Dom, Flags: Flags, } @@ -10161,10 +10102,10 @@ func (l *Libvirt) DomainGetVcpusFlags(Dom Domain, Flags uint32) (rNum int32, err func (l *Libvirt) DomainOpenConsole(Dom Domain, DevName OptString, inStream io.Writer, Flags uint32) (err error) { var buf []byte - args := DomainOpenConsoleArgs { - Dom: Dom, + args := DomainOpenConsoleArgs{ + Dom: Dom, DevName: DevName, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10172,7 +10113,6 @@ func (l *Libvirt) DomainOpenConsole(Dom Domain, DevName OptString, inStream io.W return } - _, err = l.requestStream(201, constants.Program, buf, nil, inStream) if err != nil { return @@ -10185,7 +10125,7 @@ func (l *Libvirt) DomainOpenConsole(Dom Domain, DevName OptString, inStream io.W func (l *Libvirt) DomainIsUpdated(Dom Domain) (rUpdated int32, err error) { var buf []byte - args := DomainIsUpdatedArgs { + args := DomainIsUpdatedArgs{ Dom: Dom, } @@ -10218,7 +10158,7 @@ func (l *Libvirt) DomainIsUpdated(Dom Domain) (rUpdated int32, err error) { func (l *Libvirt) ConnectGetSysinfo(Flags uint32) (rSysinfo string, err error) { var buf []byte - args := ConnectGetSysinfoArgs { + args := ConnectGetSysinfoArgs{ Flags: Flags, } @@ -10251,10 +10191,10 @@ func (l *Libvirt) ConnectGetSysinfo(Flags uint32) (rSysinfo string, err error) { func (l *Libvirt) DomainSetMemoryFlags(Dom Domain, Memory uint64, Flags uint32) (err error) { var buf []byte - args := DomainSetMemoryFlagsArgs { - Dom: Dom, + args := DomainSetMemoryFlagsArgs{ + Dom: Dom, Memory: Memory, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10262,7 +10202,6 @@ func (l *Libvirt) DomainSetMemoryFlags(Dom Domain, Memory uint64, Flags uint32) return } - _, err = l.requestStream(204, constants.Program, buf, nil, nil) if err != nil { return @@ -10275,10 +10214,10 @@ func (l *Libvirt) DomainSetMemoryFlags(Dom Domain, Memory uint64, Flags uint32) func (l *Libvirt) DomainSetBlkioParameters(Dom Domain, Params []TypedParam, Flags uint32) (err error) { var buf []byte - args := DomainSetBlkioParametersArgs { - Dom: Dom, + args := DomainSetBlkioParametersArgs{ + Dom: Dom, Params: Params, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10286,7 +10225,6 @@ func (l *Libvirt) DomainSetBlkioParameters(Dom Domain, Params []TypedParam, Flag return } - _, err = l.requestStream(205, constants.Program, buf, nil, nil) if err != nil { return @@ -10299,10 +10237,10 @@ func (l *Libvirt) DomainSetBlkioParameters(Dom Domain, Params []TypedParam, Flag func (l *Libvirt) DomainGetBlkioParameters(Dom Domain, Nparams int32, Flags uint32) (rParams []TypedParam, rNparams int32, err error) { var buf []byte - args := DomainGetBlkioParametersArgs { - Dom: Dom, + args := DomainGetBlkioParametersArgs{ + Dom: Dom, Nparams: Nparams, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10339,10 +10277,10 @@ func (l *Libvirt) DomainGetBlkioParameters(Dom Domain, Nparams int32, Flags uint func (l *Libvirt) DomainMigrateSetMaxSpeed(Dom Domain, Bandwidth uint64, Flags uint32) (err error) { var buf []byte - args := DomainMigrateSetMaxSpeedArgs { - Dom: Dom, + args := DomainMigrateSetMaxSpeedArgs{ + Dom: Dom, Bandwidth: Bandwidth, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10350,7 +10288,6 @@ func (l *Libvirt) DomainMigrateSetMaxSpeed(Dom Domain, Bandwidth uint64, Flags u return } - _, err = l.requestStream(207, constants.Program, buf, nil, nil) if err != nil { return @@ -10363,11 +10300,11 @@ func (l *Libvirt) DomainMigrateSetMaxSpeed(Dom Domain, Bandwidth uint64, Flags u func (l *Libvirt) StorageVolUpload(Vol StorageVol, outStream io.Reader, Offset uint64, Length uint64, Flags StorageVolUploadFlags) (err error) { var buf []byte - args := StorageVolUploadArgs { - Vol: Vol, + args := StorageVolUploadArgs{ + Vol: Vol, Offset: Offset, Length: Length, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10375,7 +10312,6 @@ func (l *Libvirt) StorageVolUpload(Vol StorageVol, outStream io.Reader, Offset u return } - _, err = l.requestStream(208, constants.Program, buf, outStream, nil) if err != nil { return @@ -10388,11 +10324,11 @@ func (l *Libvirt) StorageVolUpload(Vol StorageVol, outStream io.Reader, Offset u func (l *Libvirt) StorageVolDownload(Vol StorageVol, inStream io.Writer, Offset uint64, Length uint64, Flags StorageVolDownloadFlags) (err error) { var buf []byte - args := StorageVolDownloadArgs { - Vol: Vol, + args := StorageVolDownloadArgs{ + Vol: Vol, Offset: Offset, Length: Length, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10400,7 +10336,6 @@ func (l *Libvirt) StorageVolDownload(Vol StorageVol, inStream io.Writer, Offset return } - _, err = l.requestStream(209, constants.Program, buf, nil, inStream) if err != nil { return @@ -10413,8 +10348,8 @@ func (l *Libvirt) StorageVolDownload(Vol StorageVol, inStream io.Writer, Offset func (l *Libvirt) DomainInjectNmi(Dom Domain, Flags uint32) (err error) { var buf []byte - args := DomainInjectNmiArgs { - Dom: Dom, + args := DomainInjectNmiArgs{ + Dom: Dom, Flags: Flags, } @@ -10423,7 +10358,6 @@ func (l *Libvirt) DomainInjectNmi(Dom Domain, Flags uint32) (err error) { return } - _, err = l.requestStream(210, constants.Program, buf, nil, nil) if err != nil { return @@ -10436,10 +10370,10 @@ func (l *Libvirt) DomainInjectNmi(Dom Domain, Flags uint32) (err error) { func (l *Libvirt) DomainScreenshot(Dom Domain, inStream io.Writer, Screen uint32, Flags uint32) (rMime OptString, err error) { var buf []byte - args := DomainScreenshotArgs { - Dom: Dom, + args := DomainScreenshotArgs{ + Dom: Dom, Screen: Screen, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10471,8 +10405,8 @@ func (l *Libvirt) DomainScreenshot(Dom Domain, inStream io.Writer, Screen uint32 func (l *Libvirt) DomainGetState(Dom Domain, Flags uint32) (rState int32, rReason int32, err error) { var buf []byte - args := DomainGetStateArgs { - Dom: Dom, + args := DomainGetStateArgs{ + Dom: Dom, Flags: Flags, } @@ -10510,11 +10444,11 @@ func (l *Libvirt) DomainGetState(Dom Domain, Flags uint32) (rState int32, rReaso func (l *Libvirt) DomainMigrateBegin3(Dom Domain, Xmlin OptString, Flags uint64, Dname OptString, Resource uint64) (rCookieOut []byte, rXML string, err error) { var buf []byte - args := DomainMigrateBegin3Args { - Dom: Dom, - Xmlin: Xmlin, - Flags: Flags, - Dname: Dname, + args := DomainMigrateBegin3Args{ + Dom: Dom, + Xmlin: Xmlin, + Flags: Flags, + Dname: Dname, Resource: Resource, } @@ -10552,13 +10486,13 @@ func (l *Libvirt) DomainMigrateBegin3(Dom Domain, Xmlin OptString, Flags uint64, func (l *Libvirt) DomainMigratePrepare3(CookieIn []byte, UriIn OptString, Flags uint64, Dname OptString, Resource uint64, DomXML string) (rCookieOut []byte, rUriOut OptString, err error) { var buf []byte - args := DomainMigratePrepare3Args { + args := DomainMigratePrepare3Args{ CookieIn: CookieIn, - UriIn: UriIn, - Flags: Flags, - Dname: Dname, + UriIn: UriIn, + Flags: Flags, + Dname: Dname, Resource: Resource, - DomXML: DomXML, + DomXML: DomXML, } buf, err = encode(&args) @@ -10595,12 +10529,12 @@ func (l *Libvirt) DomainMigratePrepare3(CookieIn []byte, UriIn OptString, Flags func (l *Libvirt) DomainMigratePrepareTunnel3(CookieIn []byte, outStream io.Reader, Flags uint64, Dname OptString, Resource uint64, DomXML string) (rCookieOut []byte, err error) { var buf []byte - args := DomainMigratePrepareTunnel3Args { + args := DomainMigratePrepareTunnel3Args{ CookieIn: CookieIn, - Flags: Flags, - Dname: Dname, + Flags: Flags, + Dname: Dname, Resource: Resource, - DomXML: DomXML, + DomXML: DomXML, } buf, err = encode(&args) @@ -10632,14 +10566,14 @@ func (l *Libvirt) DomainMigratePrepareTunnel3(CookieIn []byte, outStream io.Read func (l *Libvirt) DomainMigratePerform3(Dom Domain, Xmlin OptString, CookieIn []byte, Dconnuri OptString, Uri OptString, Flags uint64, Dname OptString, Resource uint64) (rCookieOut []byte, err error) { var buf []byte - args := DomainMigratePerform3Args { - Dom: Dom, - Xmlin: Xmlin, + args := DomainMigratePerform3Args{ + Dom: Dom, + Xmlin: Xmlin, CookieIn: CookieIn, Dconnuri: Dconnuri, - Uri: Uri, - Flags: Flags, - Dname: Dname, + Uri: Uri, + Flags: Flags, + Dname: Dname, Resource: Resource, } @@ -10672,12 +10606,12 @@ func (l *Libvirt) DomainMigratePerform3(Dom Domain, Xmlin OptString, CookieIn [] func (l *Libvirt) DomainMigrateFinish3(Dname string, CookieIn []byte, Dconnuri OptString, Uri OptString, Flags uint64, Cancelled int32) (rDom Domain, rCookieOut []byte, err error) { var buf []byte - args := DomainMigrateFinish3Args { - Dname: Dname, - CookieIn: CookieIn, - Dconnuri: Dconnuri, - Uri: Uri, - Flags: Flags, + args := DomainMigrateFinish3Args{ + Dname: Dname, + CookieIn: CookieIn, + Dconnuri: Dconnuri, + Uri: Uri, + Flags: Flags, Cancelled: Cancelled, } @@ -10715,10 +10649,10 @@ func (l *Libvirt) DomainMigrateFinish3(Dname string, CookieIn []byte, Dconnuri O func (l *Libvirt) DomainMigrateConfirm3(Dom Domain, CookieIn []byte, Flags uint64, Cancelled int32) (err error) { var buf []byte - args := DomainMigrateConfirm3Args { - Dom: Dom, - CookieIn: CookieIn, - Flags: Flags, + args := DomainMigrateConfirm3Args{ + Dom: Dom, + CookieIn: CookieIn, + Flags: Flags, Cancelled: Cancelled, } @@ -10727,7 +10661,6 @@ func (l *Libvirt) DomainMigrateConfirm3(Dom Domain, CookieIn []byte, Flags uint6 return } - _, err = l.requestStream(218, constants.Program, buf, nil, nil) if err != nil { return @@ -10740,10 +10673,10 @@ func (l *Libvirt) DomainMigrateConfirm3(Dom Domain, CookieIn []byte, Flags uint6 func (l *Libvirt) DomainSetSchedulerParametersFlags(Dom Domain, Params []TypedParam, Flags uint32) (err error) { var buf []byte - args := DomainSetSchedulerParametersFlagsArgs { - Dom: Dom, + args := DomainSetSchedulerParametersFlagsArgs{ + Dom: Dom, Params: Params, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10751,7 +10684,6 @@ func (l *Libvirt) DomainSetSchedulerParametersFlags(Dom Domain, Params []TypedPa return } - _, err = l.requestStream(219, constants.Program, buf, nil, nil) if err != nil { return @@ -10764,7 +10696,7 @@ func (l *Libvirt) DomainSetSchedulerParametersFlags(Dom Domain, Params []TypedPa func (l *Libvirt) InterfaceChangeBegin(Flags uint32) (err error) { var buf []byte - args := InterfaceChangeBeginArgs { + args := InterfaceChangeBeginArgs{ Flags: Flags, } @@ -10773,7 +10705,6 @@ func (l *Libvirt) InterfaceChangeBegin(Flags uint32) (err error) { return } - _, err = l.requestStream(220, constants.Program, buf, nil, nil) if err != nil { return @@ -10786,7 +10717,7 @@ func (l *Libvirt) InterfaceChangeBegin(Flags uint32) (err error) { func (l *Libvirt) InterfaceChangeCommit(Flags uint32) (err error) { var buf []byte - args := InterfaceChangeCommitArgs { + args := InterfaceChangeCommitArgs{ Flags: Flags, } @@ -10795,7 +10726,6 @@ func (l *Libvirt) InterfaceChangeCommit(Flags uint32) (err error) { return } - _, err = l.requestStream(221, constants.Program, buf, nil, nil) if err != nil { return @@ -10808,7 +10738,7 @@ func (l *Libvirt) InterfaceChangeCommit(Flags uint32) (err error) { func (l *Libvirt) InterfaceChangeRollback(Flags uint32) (err error) { var buf []byte - args := InterfaceChangeRollbackArgs { + args := InterfaceChangeRollbackArgs{ Flags: Flags, } @@ -10817,7 +10747,6 @@ func (l *Libvirt) InterfaceChangeRollback(Flags uint32) (err error) { return } - _, err = l.requestStream(222, constants.Program, buf, nil, nil) if err != nil { return @@ -10830,10 +10759,10 @@ func (l *Libvirt) InterfaceChangeRollback(Flags uint32) (err error) { func (l *Libvirt) DomainGetSchedulerParametersFlags(Dom Domain, Nparams int32, Flags uint32) (rParams []TypedParam, err error) { var buf []byte - args := DomainGetSchedulerParametersFlagsArgs { - Dom: Dom, + args := DomainGetSchedulerParametersFlagsArgs{ + Dom: Dom, Nparams: Nparams, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10865,7 +10794,6 @@ func (l *Libvirt) DomainGetSchedulerParametersFlags(Dom Domain, Nparams int32, F func (l *Libvirt) DomainEventControlError() (err error) { var buf []byte - _, err = l.requestStream(224, constants.Program, buf, nil, nil) if err != nil { return @@ -10878,11 +10806,11 @@ func (l *Libvirt) DomainEventControlError() (err error) { func (l *Libvirt) DomainPinVcpuFlags(Dom Domain, Vcpu uint32, Cpumap []byte, Flags uint32) (err error) { var buf []byte - args := DomainPinVcpuFlagsArgs { - Dom: Dom, - Vcpu: Vcpu, + args := DomainPinVcpuFlagsArgs{ + Dom: Dom, + Vcpu: Vcpu, Cpumap: Cpumap, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10890,7 +10818,6 @@ func (l *Libvirt) DomainPinVcpuFlags(Dom Domain, Vcpu uint32, Cpumap []byte, Fla return } - _, err = l.requestStream(225, constants.Program, buf, nil, nil) if err != nil { return @@ -10903,12 +10830,12 @@ func (l *Libvirt) DomainPinVcpuFlags(Dom Domain, Vcpu uint32, Cpumap []byte, Fla func (l *Libvirt) DomainSendKey(Dom Domain, Codeset uint32, Holdtime uint32, Keycodes []uint32, Flags uint32) (err error) { var buf []byte - args := DomainSendKeyArgs { - Dom: Dom, - Codeset: Codeset, + args := DomainSendKeyArgs{ + Dom: Dom, + Codeset: Codeset, Holdtime: Holdtime, Keycodes: Keycodes, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10916,7 +10843,6 @@ func (l *Libvirt) DomainSendKey(Dom Domain, Codeset uint32, Holdtime uint32, Key return } - _, err = l.requestStream(226, constants.Program, buf, nil, nil) if err != nil { return @@ -10929,10 +10855,10 @@ func (l *Libvirt) DomainSendKey(Dom Domain, Codeset uint32, Holdtime uint32, Key func (l *Libvirt) NodeGetCPUStats(CPUNum int32, Nparams int32, Flags uint32) (rParams []NodeGetCPUStats, rNparams int32, err error) { var buf []byte - args := NodeGetCPUStatsArgs { - CPUNum: CPUNum, + args := NodeGetCPUStatsArgs{ + CPUNum: CPUNum, Nparams: Nparams, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -10969,10 +10895,10 @@ func (l *Libvirt) NodeGetCPUStats(CPUNum int32, Nparams int32, Flags uint32) (rP func (l *Libvirt) NodeGetMemoryStats(Nparams int32, CellNum int32, Flags uint32) (rParams []NodeGetMemoryStats, rNparams int32, err error) { var buf []byte - args := NodeGetMemoryStatsArgs { + args := NodeGetMemoryStatsArgs{ Nparams: Nparams, CellNum: CellNum, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11009,8 +10935,8 @@ func (l *Libvirt) NodeGetMemoryStats(Nparams int32, CellNum int32, Flags uint32) func (l *Libvirt) DomainGetControlInfo(Dom Domain, Flags uint32) (rState uint32, rDetails uint32, rStateTime uint64, err error) { var buf []byte - args := DomainGetControlInfoArgs { - Dom: Dom, + args := DomainGetControlInfoArgs{ + Dom: Dom, Flags: Flags, } @@ -11053,11 +10979,11 @@ func (l *Libvirt) DomainGetControlInfo(Dom Domain, Flags uint32) (rState uint32, func (l *Libvirt) DomainGetVcpuPinInfo(Dom Domain, Ncpumaps int32, Maplen int32, Flags uint32) (rCpumaps []byte, rNum int32, err error) { var buf []byte - args := DomainGetVcpuPinInfoArgs { - Dom: Dom, + args := DomainGetVcpuPinInfoArgs{ + Dom: Dom, Ncpumaps: Ncpumaps, - Maplen: Maplen, - Flags: Flags, + Maplen: Maplen, + Flags: Flags, } buf, err = encode(&args) @@ -11094,8 +11020,8 @@ func (l *Libvirt) DomainGetVcpuPinInfo(Dom Domain, Ncpumaps int32, Maplen int32, func (l *Libvirt) DomainUndefineFlags(Dom Domain, Flags DomainUndefineFlagsValues) (err error) { var buf []byte - args := DomainUndefineFlagsArgs { - Dom: Dom, + args := DomainUndefineFlagsArgs{ + Dom: Dom, Flags: Flags, } @@ -11104,7 +11030,6 @@ func (l *Libvirt) DomainUndefineFlags(Dom Domain, Flags DomainUndefineFlagsValue return } - _, err = l.requestStream(231, constants.Program, buf, nil, nil) if err != nil { return @@ -11117,10 +11042,10 @@ func (l *Libvirt) DomainUndefineFlags(Dom Domain, Flags DomainUndefineFlagsValue func (l *Libvirt) DomainSaveFlags(Dom Domain, To string, Dxml OptString, Flags uint32) (err error) { var buf []byte - args := DomainSaveFlagsArgs { - Dom: Dom, - To: To, - Dxml: Dxml, + args := DomainSaveFlagsArgs{ + Dom: Dom, + To: To, + Dxml: Dxml, Flags: Flags, } @@ -11129,7 +11054,6 @@ func (l *Libvirt) DomainSaveFlags(Dom Domain, To string, Dxml OptString, Flags u return } - _, err = l.requestStream(232, constants.Program, buf, nil, nil) if err != nil { return @@ -11142,9 +11066,9 @@ func (l *Libvirt) DomainSaveFlags(Dom Domain, To string, Dxml OptString, Flags u func (l *Libvirt) DomainRestoreFlags(From string, Dxml OptString, Flags uint32) (err error) { var buf []byte - args := DomainRestoreFlagsArgs { - From: From, - Dxml: Dxml, + args := DomainRestoreFlagsArgs{ + From: From, + Dxml: Dxml, Flags: Flags, } @@ -11153,7 +11077,6 @@ func (l *Libvirt) DomainRestoreFlags(From string, Dxml OptString, Flags uint32) return } - _, err = l.requestStream(233, constants.Program, buf, nil, nil) if err != nil { return @@ -11166,8 +11089,8 @@ func (l *Libvirt) DomainRestoreFlags(From string, Dxml OptString, Flags uint32) func (l *Libvirt) DomainDestroyFlags(Dom Domain, Flags DomainDestroyFlagsValues) (err error) { var buf []byte - args := DomainDestroyFlagsArgs { - Dom: Dom, + args := DomainDestroyFlagsArgs{ + Dom: Dom, Flags: Flags, } @@ -11176,7 +11099,6 @@ func (l *Libvirt) DomainDestroyFlags(Dom Domain, Flags DomainDestroyFlagsValues) return } - _, err = l.requestStream(234, constants.Program, buf, nil, nil) if err != nil { return @@ -11189,8 +11111,8 @@ func (l *Libvirt) DomainDestroyFlags(Dom Domain, Flags DomainDestroyFlagsValues) func (l *Libvirt) DomainSaveImageGetXMLDesc(File string, Flags uint32) (rXML string, err error) { var buf []byte - args := DomainSaveImageGetXMLDescArgs { - File: File, + args := DomainSaveImageGetXMLDescArgs{ + File: File, Flags: Flags, } @@ -11223,9 +11145,9 @@ func (l *Libvirt) DomainSaveImageGetXMLDesc(File string, Flags uint32) (rXML str func (l *Libvirt) DomainSaveImageDefineXML(File string, Dxml string, Flags uint32) (err error) { var buf []byte - args := DomainSaveImageDefineXMLArgs { - File: File, - Dxml: Dxml, + args := DomainSaveImageDefineXMLArgs{ + File: File, + Dxml: Dxml, Flags: Flags, } @@ -11234,7 +11156,6 @@ func (l *Libvirt) DomainSaveImageDefineXML(File string, Dxml string, Flags uint3 return } - _, err = l.requestStream(236, constants.Program, buf, nil, nil) if err != nil { return @@ -11247,9 +11168,9 @@ func (l *Libvirt) DomainSaveImageDefineXML(File string, Dxml string, Flags uint3 func (l *Libvirt) DomainBlockJobAbort(Dom Domain, Path string, Flags DomainBlockJobAbortFlags) (err error) { var buf []byte - args := DomainBlockJobAbortArgs { - Dom: Dom, - Path: Path, + args := DomainBlockJobAbortArgs{ + Dom: Dom, + Path: Path, Flags: Flags, } @@ -11258,7 +11179,6 @@ func (l *Libvirt) DomainBlockJobAbort(Dom Domain, Path string, Flags DomainBlock return } - _, err = l.requestStream(237, constants.Program, buf, nil, nil) if err != nil { return @@ -11271,9 +11191,9 @@ func (l *Libvirt) DomainBlockJobAbort(Dom Domain, Path string, Flags DomainBlock func (l *Libvirt) DomainGetBlockJobInfo(Dom Domain, Path string, Flags uint32) (rFound int32, rType int32, rBandwidth uint64, rCur uint64, rEnd uint64, err error) { var buf []byte - args := DomainGetBlockJobInfoArgs { - Dom: Dom, - Path: Path, + args := DomainGetBlockJobInfoArgs{ + Dom: Dom, + Path: Path, Flags: Flags, } @@ -11326,11 +11246,11 @@ func (l *Libvirt) DomainGetBlockJobInfo(Dom Domain, Path string, Flags uint32) ( func (l *Libvirt) DomainBlockJobSetSpeed(Dom Domain, Path string, Bandwidth uint64, Flags DomainBlockJobSetSpeedFlags) (err error) { var buf []byte - args := DomainBlockJobSetSpeedArgs { - Dom: Dom, - Path: Path, + args := DomainBlockJobSetSpeedArgs{ + Dom: Dom, + Path: Path, Bandwidth: Bandwidth, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11338,7 +11258,6 @@ func (l *Libvirt) DomainBlockJobSetSpeed(Dom Domain, Path string, Bandwidth uint return } - _, err = l.requestStream(239, constants.Program, buf, nil, nil) if err != nil { return @@ -11351,11 +11270,11 @@ func (l *Libvirt) DomainBlockJobSetSpeed(Dom Domain, Path string, Bandwidth uint func (l *Libvirt) DomainBlockPull(Dom Domain, Path string, Bandwidth uint64, Flags DomainBlockPullFlags) (err error) { var buf []byte - args := DomainBlockPullArgs { - Dom: Dom, - Path: Path, + args := DomainBlockPullArgs{ + Dom: Dom, + Path: Path, Bandwidth: Bandwidth, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11363,7 +11282,6 @@ func (l *Libvirt) DomainBlockPull(Dom Domain, Path string, Bandwidth uint64, Fla return } - _, err = l.requestStream(240, constants.Program, buf, nil, nil) if err != nil { return @@ -11376,7 +11294,6 @@ func (l *Libvirt) DomainBlockPull(Dom Domain, Path string, Bandwidth uint64, Fla func (l *Libvirt) DomainEventBlockJob() (err error) { var buf []byte - _, err = l.requestStream(241, constants.Program, buf, nil, nil) if err != nil { return @@ -11389,8 +11306,8 @@ func (l *Libvirt) DomainEventBlockJob() (err error) { func (l *Libvirt) DomainMigrateGetMaxSpeed(Dom Domain, Flags uint32) (rBandwidth uint64, err error) { var buf []byte - args := DomainMigrateGetMaxSpeedArgs { - Dom: Dom, + args := DomainMigrateGetMaxSpeedArgs{ + Dom: Dom, Flags: Flags, } @@ -11423,11 +11340,11 @@ func (l *Libvirt) DomainMigrateGetMaxSpeed(Dom Domain, Flags uint32) (rBandwidth func (l *Libvirt) DomainBlockStatsFlags(Dom Domain, Path string, Nparams int32, Flags uint32) (rParams []TypedParam, rNparams int32, err error) { var buf []byte - args := DomainBlockStatsFlagsArgs { - Dom: Dom, - Path: Path, + args := DomainBlockStatsFlagsArgs{ + Dom: Dom, + Path: Path, Nparams: Nparams, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11464,8 +11381,8 @@ func (l *Libvirt) DomainBlockStatsFlags(Dom Domain, Path string, Nparams int32, func (l *Libvirt) DomainSnapshotGetParent(Snap DomainSnapshot, Flags uint32) (rSnap DomainSnapshot, err error) { var buf []byte - args := DomainSnapshotGetParentArgs { - Snap: Snap, + args := DomainSnapshotGetParentArgs{ + Snap: Snap, Flags: Flags, } @@ -11498,8 +11415,8 @@ func (l *Libvirt) DomainSnapshotGetParent(Snap DomainSnapshot, Flags uint32) (rS func (l *Libvirt) DomainReset(Dom Domain, Flags uint32) (err error) { var buf []byte - args := DomainResetArgs { - Dom: Dom, + args := DomainResetArgs{ + Dom: Dom, Flags: Flags, } @@ -11508,7 +11425,6 @@ func (l *Libvirt) DomainReset(Dom Domain, Flags uint32) (err error) { return } - _, err = l.requestStream(245, constants.Program, buf, nil, nil) if err != nil { return @@ -11521,8 +11437,8 @@ func (l *Libvirt) DomainReset(Dom Domain, Flags uint32) (err error) { func (l *Libvirt) DomainSnapshotNumChildren(Snap DomainSnapshot, Flags uint32) (rNum int32, err error) { var buf []byte - args := DomainSnapshotNumChildrenArgs { - Snap: Snap, + args := DomainSnapshotNumChildrenArgs{ + Snap: Snap, Flags: Flags, } @@ -11555,10 +11471,10 @@ func (l *Libvirt) DomainSnapshotNumChildren(Snap DomainSnapshot, Flags uint32) ( func (l *Libvirt) DomainSnapshotListChildrenNames(Snap DomainSnapshot, Maxnames int32, Flags uint32) (rNames []string, err error) { var buf []byte - args := DomainSnapshotListChildrenNamesArgs { - Snap: Snap, + args := DomainSnapshotListChildrenNamesArgs{ + Snap: Snap, Maxnames: Maxnames, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11590,7 +11506,6 @@ func (l *Libvirt) DomainSnapshotListChildrenNames(Snap DomainSnapshot, Maxnames func (l *Libvirt) DomainEventDiskChange() (err error) { var buf []byte - _, err = l.requestStream(248, constants.Program, buf, nil, nil) if err != nil { return @@ -11603,9 +11518,9 @@ func (l *Libvirt) DomainEventDiskChange() (err error) { func (l *Libvirt) DomainOpenGraphics(Dom Domain, Idx uint32, Flags DomainOpenGraphicsFlags) (err error) { var buf []byte - args := DomainOpenGraphicsArgs { - Dom: Dom, - Idx: Idx, + args := DomainOpenGraphicsArgs{ + Dom: Dom, + Idx: Idx, Flags: Flags, } @@ -11614,7 +11529,6 @@ func (l *Libvirt) DomainOpenGraphics(Dom Domain, Idx uint32, Flags DomainOpenGra return } - _, err = l.requestStream(249, constants.Program, buf, nil, nil) if err != nil { return @@ -11627,10 +11541,10 @@ func (l *Libvirt) DomainOpenGraphics(Dom Domain, Idx uint32, Flags DomainOpenGra func (l *Libvirt) NodeSuspendForDuration(Target uint32, Duration uint64, Flags uint32) (err error) { var buf []byte - args := NodeSuspendForDurationArgs { - Target: Target, + args := NodeSuspendForDurationArgs{ + Target: Target, Duration: Duration, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11638,7 +11552,6 @@ func (l *Libvirt) NodeSuspendForDuration(Target uint32, Duration uint64, Flags u return } - _, err = l.requestStream(250, constants.Program, buf, nil, nil) if err != nil { return @@ -11651,10 +11564,10 @@ func (l *Libvirt) NodeSuspendForDuration(Target uint32, Duration uint64, Flags u func (l *Libvirt) DomainBlockResize(Dom Domain, Disk string, Size uint64, Flags DomainBlockResizeFlags) (err error) { var buf []byte - args := DomainBlockResizeArgs { - Dom: Dom, - Disk: Disk, - Size: Size, + args := DomainBlockResizeArgs{ + Dom: Dom, + Disk: Disk, + Size: Size, Flags: Flags, } @@ -11663,7 +11576,6 @@ func (l *Libvirt) DomainBlockResize(Dom Domain, Disk string, Size uint64, Flags return } - _, err = l.requestStream(251, constants.Program, buf, nil, nil) if err != nil { return @@ -11676,11 +11588,11 @@ func (l *Libvirt) DomainBlockResize(Dom Domain, Disk string, Size uint64, Flags func (l *Libvirt) DomainSetBlockIOTune(Dom Domain, Disk string, Params []TypedParam, Flags uint32) (err error) { var buf []byte - args := DomainSetBlockIOTuneArgs { - Dom: Dom, - Disk: Disk, + args := DomainSetBlockIOTuneArgs{ + Dom: Dom, + Disk: Disk, Params: Params, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11688,7 +11600,6 @@ func (l *Libvirt) DomainSetBlockIOTune(Dom Domain, Disk string, Params []TypedPa return } - _, err = l.requestStream(252, constants.Program, buf, nil, nil) if err != nil { return @@ -11701,11 +11612,11 @@ func (l *Libvirt) DomainSetBlockIOTune(Dom Domain, Disk string, Params []TypedPa func (l *Libvirt) DomainGetBlockIOTune(Dom Domain, Disk OptString, Nparams int32, Flags uint32) (rParams []TypedParam, rNparams int32, err error) { var buf []byte - args := DomainGetBlockIOTuneArgs { - Dom: Dom, - Disk: Disk, + args := DomainGetBlockIOTuneArgs{ + Dom: Dom, + Disk: Disk, Nparams: Nparams, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11742,10 +11653,10 @@ func (l *Libvirt) DomainGetBlockIOTune(Dom Domain, Disk OptString, Nparams int32 func (l *Libvirt) DomainSetNumaParameters(Dom Domain, Params []TypedParam, Flags uint32) (err error) { var buf []byte - args := DomainSetNumaParametersArgs { - Dom: Dom, + args := DomainSetNumaParametersArgs{ + Dom: Dom, Params: Params, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11753,7 +11664,6 @@ func (l *Libvirt) DomainSetNumaParameters(Dom Domain, Params []TypedParam, Flags return } - _, err = l.requestStream(254, constants.Program, buf, nil, nil) if err != nil { return @@ -11766,10 +11676,10 @@ func (l *Libvirt) DomainSetNumaParameters(Dom Domain, Params []TypedParam, Flags func (l *Libvirt) DomainGetNumaParameters(Dom Domain, Nparams int32, Flags uint32) (rParams []TypedParam, rNparams int32, err error) { var buf []byte - args := DomainGetNumaParametersArgs { - Dom: Dom, + args := DomainGetNumaParametersArgs{ + Dom: Dom, Nparams: Nparams, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11806,11 +11716,11 @@ func (l *Libvirt) DomainGetNumaParameters(Dom Domain, Nparams int32, Flags uint3 func (l *Libvirt) DomainSetInterfaceParameters(Dom Domain, Device string, Params []TypedParam, Flags uint32) (err error) { var buf []byte - args := DomainSetInterfaceParametersArgs { - Dom: Dom, + args := DomainSetInterfaceParametersArgs{ + Dom: Dom, Device: Device, Params: Params, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11818,7 +11728,6 @@ func (l *Libvirt) DomainSetInterfaceParameters(Dom Domain, Device string, Params return } - _, err = l.requestStream(256, constants.Program, buf, nil, nil) if err != nil { return @@ -11831,11 +11740,11 @@ func (l *Libvirt) DomainSetInterfaceParameters(Dom Domain, Device string, Params func (l *Libvirt) DomainGetInterfaceParameters(Dom Domain, Device string, Nparams int32, Flags DomainModificationImpact) (rParams []TypedParam, rNparams int32, err error) { var buf []byte - args := DomainGetInterfaceParametersArgs { - Dom: Dom, - Device: Device, + args := DomainGetInterfaceParametersArgs{ + Dom: Dom, + Device: Device, Nparams: Nparams, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11872,8 +11781,8 @@ func (l *Libvirt) DomainGetInterfaceParameters(Dom Domain, Device string, Nparam func (l *Libvirt) DomainShutdownFlags(Dom Domain, Flags DomainShutdownFlagValues) (err error) { var buf []byte - args := DomainShutdownFlagsArgs { - Dom: Dom, + args := DomainShutdownFlagsArgs{ + Dom: Dom, Flags: Flags, } @@ -11882,7 +11791,6 @@ func (l *Libvirt) DomainShutdownFlags(Dom Domain, Flags DomainShutdownFlagValues return } - _, err = l.requestStream(258, constants.Program, buf, nil, nil) if err != nil { return @@ -11895,10 +11803,10 @@ func (l *Libvirt) DomainShutdownFlags(Dom Domain, Flags DomainShutdownFlagValues func (l *Libvirt) StorageVolWipePattern(Vol StorageVol, Algorithm uint32, Flags uint32) (err error) { var buf []byte - args := StorageVolWipePatternArgs { - Vol: Vol, + args := StorageVolWipePatternArgs{ + Vol: Vol, Algorithm: Algorithm, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11906,7 +11814,6 @@ func (l *Libvirt) StorageVolWipePattern(Vol StorageVol, Algorithm uint32, Flags return } - _, err = l.requestStream(259, constants.Program, buf, nil, nil) if err != nil { return @@ -11919,10 +11826,10 @@ func (l *Libvirt) StorageVolWipePattern(Vol StorageVol, Algorithm uint32, Flags func (l *Libvirt) StorageVolResize(Vol StorageVol, Capacity uint64, Flags StorageVolResizeFlags) (err error) { var buf []byte - args := StorageVolResizeArgs { - Vol: Vol, + args := StorageVolResizeArgs{ + Vol: Vol, Capacity: Capacity, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11930,7 +11837,6 @@ func (l *Libvirt) StorageVolResize(Vol StorageVol, Capacity uint64, Flags Storag return } - _, err = l.requestStream(260, constants.Program, buf, nil, nil) if err != nil { return @@ -11943,11 +11849,11 @@ func (l *Libvirt) StorageVolResize(Vol StorageVol, Capacity uint64, Flags Storag func (l *Libvirt) DomainPmSuspendForDuration(Dom Domain, Target uint32, Duration uint64, Flags uint32) (err error) { var buf []byte - args := DomainPmSuspendForDurationArgs { - Dom: Dom, - Target: Target, + args := DomainPmSuspendForDurationArgs{ + Dom: Dom, + Target: Target, Duration: Duration, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -11955,7 +11861,6 @@ func (l *Libvirt) DomainPmSuspendForDuration(Dom Domain, Target uint32, Duration return } - _, err = l.requestStream(261, constants.Program, buf, nil, nil) if err != nil { return @@ -11968,12 +11873,12 @@ func (l *Libvirt) DomainPmSuspendForDuration(Dom Domain, Target uint32, Duration func (l *Libvirt) DomainGetCPUStats(Dom Domain, Nparams uint32, StartCPU int32, Ncpus uint32, Flags TypedParameterFlags) (rParams []TypedParam, rNparams int32, err error) { var buf []byte - args := DomainGetCPUStatsArgs { - Dom: Dom, - Nparams: Nparams, + args := DomainGetCPUStatsArgs{ + Dom: Dom, + Nparams: Nparams, StartCPU: StartCPU, - Ncpus: Ncpus, - Flags: Flags, + Ncpus: Ncpus, + Flags: Flags, } buf, err = encode(&args) @@ -12010,10 +11915,10 @@ func (l *Libvirt) DomainGetCPUStats(Dom Domain, Nparams uint32, StartCPU int32, func (l *Libvirt) DomainGetDiskErrors(Dom Domain, Maxerrors uint32, Flags uint32) (rErrors []DomainDiskError, rNerrors int32, err error) { var buf []byte - args := DomainGetDiskErrorsArgs { - Dom: Dom, + args := DomainGetDiskErrorsArgs{ + Dom: Dom, Maxerrors: Maxerrors, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12050,13 +11955,13 @@ func (l *Libvirt) DomainGetDiskErrors(Dom Domain, Maxerrors uint32, Flags uint32 func (l *Libvirt) DomainSetMetadata(Dom Domain, Type int32, Metadata OptString, Key OptString, Uri OptString, Flags DomainModificationImpact) (err error) { var buf []byte - args := DomainSetMetadataArgs { - Dom: Dom, - Type: Type, + args := DomainSetMetadataArgs{ + Dom: Dom, + Type: Type, Metadata: Metadata, - Key: Key, - Uri: Uri, - Flags: Flags, + Key: Key, + Uri: Uri, + Flags: Flags, } buf, err = encode(&args) @@ -12064,7 +11969,6 @@ func (l *Libvirt) DomainSetMetadata(Dom Domain, Type int32, Metadata OptString, return } - _, err = l.requestStream(264, constants.Program, buf, nil, nil) if err != nil { return @@ -12077,10 +11981,10 @@ func (l *Libvirt) DomainSetMetadata(Dom Domain, Type int32, Metadata OptString, func (l *Libvirt) DomainGetMetadata(Dom Domain, Type int32, Uri OptString, Flags DomainModificationImpact) (rMetadata string, err error) { var buf []byte - args := DomainGetMetadataArgs { - Dom: Dom, - Type: Type, - Uri: Uri, + args := DomainGetMetadataArgs{ + Dom: Dom, + Type: Type, + Uri: Uri, Flags: Flags, } @@ -12113,12 +12017,12 @@ func (l *Libvirt) DomainGetMetadata(Dom Domain, Type int32, Uri OptString, Flags func (l *Libvirt) DomainBlockRebase(Dom Domain, Path string, Base OptString, Bandwidth uint64, Flags DomainBlockRebaseFlags) (err error) { var buf []byte - args := DomainBlockRebaseArgs { - Dom: Dom, - Path: Path, - Base: Base, + args := DomainBlockRebaseArgs{ + Dom: Dom, + Path: Path, + Base: Base, Bandwidth: Bandwidth, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12126,7 +12030,6 @@ func (l *Libvirt) DomainBlockRebase(Dom Domain, Path string, Base OptString, Ban return } - _, err = l.requestStream(266, constants.Program, buf, nil, nil) if err != nil { return @@ -12139,8 +12042,8 @@ func (l *Libvirt) DomainBlockRebase(Dom Domain, Path string, Base OptString, Ban func (l *Libvirt) DomainPmWakeup(Dom Domain, Flags uint32) (err error) { var buf []byte - args := DomainPmWakeupArgs { - Dom: Dom, + args := DomainPmWakeupArgs{ + Dom: Dom, Flags: Flags, } @@ -12149,7 +12052,6 @@ func (l *Libvirt) DomainPmWakeup(Dom Domain, Flags uint32) (err error) { return } - _, err = l.requestStream(267, constants.Program, buf, nil, nil) if err != nil { return @@ -12162,7 +12064,6 @@ func (l *Libvirt) DomainPmWakeup(Dom Domain, Flags uint32) (err error) { func (l *Libvirt) DomainEventTrayChange() (err error) { var buf []byte - _, err = l.requestStream(268, constants.Program, buf, nil, nil) if err != nil { return @@ -12175,7 +12076,6 @@ func (l *Libvirt) DomainEventTrayChange() (err error) { func (l *Libvirt) DomainEventPmwakeup() (err error) { var buf []byte - _, err = l.requestStream(269, constants.Program, buf, nil, nil) if err != nil { return @@ -12188,7 +12088,6 @@ func (l *Libvirt) DomainEventPmwakeup() (err error) { func (l *Libvirt) DomainEventPmsuspend() (err error) { var buf []byte - _, err = l.requestStream(270, constants.Program, buf, nil, nil) if err != nil { return @@ -12201,8 +12100,8 @@ func (l *Libvirt) DomainEventPmsuspend() (err error) { func (l *Libvirt) DomainSnapshotIsCurrent(Snap DomainSnapshot, Flags uint32) (rCurrent int32, err error) { var buf []byte - args := DomainSnapshotIsCurrentArgs { - Snap: Snap, + args := DomainSnapshotIsCurrentArgs{ + Snap: Snap, Flags: Flags, } @@ -12235,8 +12134,8 @@ func (l *Libvirt) DomainSnapshotIsCurrent(Snap DomainSnapshot, Flags uint32) (rC func (l *Libvirt) DomainSnapshotHasMetadata(Snap DomainSnapshot, Flags uint32) (rMetadata int32, err error) { var buf []byte - args := DomainSnapshotHasMetadataArgs { - Snap: Snap, + args := DomainSnapshotHasMetadataArgs{ + Snap: Snap, Flags: Flags, } @@ -12269,9 +12168,9 @@ func (l *Libvirt) DomainSnapshotHasMetadata(Snap DomainSnapshot, Flags uint32) ( func (l *Libvirt) ConnectListAllDomains(NeedResults int32, Flags ConnectListAllDomainsFlags) (rDomains []Domain, rRet uint32, err error) { var buf []byte - args := ConnectListAllDomainsArgs { + args := ConnectListAllDomainsArgs{ NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12308,10 +12207,10 @@ func (l *Libvirt) ConnectListAllDomains(NeedResults int32, Flags ConnectListAllD func (l *Libvirt) DomainListAllSnapshots(Dom Domain, NeedResults int32, Flags uint32) (rSnapshots []DomainSnapshot, rRet int32, err error) { var buf []byte - args := DomainListAllSnapshotsArgs { - Dom: Dom, + args := DomainListAllSnapshotsArgs{ + Dom: Dom, NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12348,10 +12247,10 @@ func (l *Libvirt) DomainListAllSnapshots(Dom Domain, NeedResults int32, Flags ui func (l *Libvirt) DomainSnapshotListAllChildren(Snapshot DomainSnapshot, NeedResults int32, Flags uint32) (rSnapshots []DomainSnapshot, rRet int32, err error) { var buf []byte - args := DomainSnapshotListAllChildrenArgs { - Snapshot: Snapshot, + args := DomainSnapshotListAllChildrenArgs{ + Snapshot: Snapshot, NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12388,7 +12287,6 @@ func (l *Libvirt) DomainSnapshotListAllChildren(Snapshot DomainSnapshot, NeedRes func (l *Libvirt) DomainEventBalloonChange() (err error) { var buf []byte - _, err = l.requestStream(276, constants.Program, buf, nil, nil) if err != nil { return @@ -12401,8 +12299,8 @@ func (l *Libvirt) DomainEventBalloonChange() (err error) { func (l *Libvirt) DomainGetHostname(Dom Domain, Flags DomainGetHostnameFlags) (rHostname string, err error) { var buf []byte - args := DomainGetHostnameArgs { - Dom: Dom, + args := DomainGetHostnameArgs{ + Dom: Dom, Flags: Flags, } @@ -12435,7 +12333,7 @@ func (l *Libvirt) DomainGetHostname(Dom Domain, Flags DomainGetHostnameFlags) (r func (l *Libvirt) DomainGetSecurityLabelList(Dom Domain) (rLabels []DomainGetSecurityLabelRet, rRet int32, err error) { var buf []byte - args := DomainGetSecurityLabelListArgs { + args := DomainGetSecurityLabelListArgs{ Dom: Dom, } @@ -12473,10 +12371,10 @@ func (l *Libvirt) DomainGetSecurityLabelList(Dom Domain) (rLabels []DomainGetSec func (l *Libvirt) DomainPinEmulator(Dom Domain, Cpumap []byte, Flags DomainModificationImpact) (err error) { var buf []byte - args := DomainPinEmulatorArgs { - Dom: Dom, + args := DomainPinEmulatorArgs{ + Dom: Dom, Cpumap: Cpumap, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12484,7 +12382,6 @@ func (l *Libvirt) DomainPinEmulator(Dom Domain, Cpumap []byte, Flags DomainModif return } - _, err = l.requestStream(279, constants.Program, buf, nil, nil) if err != nil { return @@ -12497,10 +12394,10 @@ func (l *Libvirt) DomainPinEmulator(Dom Domain, Cpumap []byte, Flags DomainModif func (l *Libvirt) DomainGetEmulatorPinInfo(Dom Domain, Maplen int32, Flags DomainModificationImpact) (rCpumaps []byte, rRet int32, err error) { var buf []byte - args := DomainGetEmulatorPinInfoArgs { - Dom: Dom, + args := DomainGetEmulatorPinInfoArgs{ + Dom: Dom, Maplen: Maplen, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12537,9 +12434,9 @@ func (l *Libvirt) DomainGetEmulatorPinInfo(Dom Domain, Maplen int32, Flags Domai func (l *Libvirt) ConnectListAllStoragePools(NeedResults int32, Flags ConnectListAllStoragePoolsFlags) (rPools []StoragePool, rRet uint32, err error) { var buf []byte - args := ConnectListAllStoragePoolsArgs { + args := ConnectListAllStoragePoolsArgs{ NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12576,10 +12473,10 @@ func (l *Libvirt) ConnectListAllStoragePools(NeedResults int32, Flags ConnectLis func (l *Libvirt) StoragePoolListAllVolumes(Pool StoragePool, NeedResults int32, Flags uint32) (rVols []StorageVol, rRet uint32, err error) { var buf []byte - args := StoragePoolListAllVolumesArgs { - Pool: Pool, + args := StoragePoolListAllVolumesArgs{ + Pool: Pool, NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12616,9 +12513,9 @@ func (l *Libvirt) StoragePoolListAllVolumes(Pool StoragePool, NeedResults int32, func (l *Libvirt) ConnectListAllNetworks(NeedResults int32, Flags ConnectListAllNetworksFlags) (rNets []Network, rRet uint32, err error) { var buf []byte - args := ConnectListAllNetworksArgs { + args := ConnectListAllNetworksArgs{ NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12655,9 +12552,9 @@ func (l *Libvirt) ConnectListAllNetworks(NeedResults int32, Flags ConnectListAll func (l *Libvirt) ConnectListAllInterfaces(NeedResults int32, Flags ConnectListAllInterfacesFlags) (rIfaces []Interface, rRet uint32, err error) { var buf []byte - args := ConnectListAllInterfacesArgs { + args := ConnectListAllInterfacesArgs{ NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12694,9 +12591,9 @@ func (l *Libvirt) ConnectListAllInterfaces(NeedResults int32, Flags ConnectListA func (l *Libvirt) ConnectListAllNodeDevices(NeedResults int32, Flags uint32) (rDevices []NodeDevice, rRet uint32, err error) { var buf []byte - args := ConnectListAllNodeDevicesArgs { + args := ConnectListAllNodeDevicesArgs{ NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12733,9 +12630,9 @@ func (l *Libvirt) ConnectListAllNodeDevices(NeedResults int32, Flags uint32) (rD func (l *Libvirt) ConnectListAllNwfilters(NeedResults int32, Flags uint32) (rFilters []Nwfilter, rRet uint32, err error) { var buf []byte - args := ConnectListAllNwfiltersArgs { + args := ConnectListAllNwfiltersArgs{ NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12772,9 +12669,9 @@ func (l *Libvirt) ConnectListAllNwfilters(NeedResults int32, Flags uint32) (rFil func (l *Libvirt) ConnectListAllSecrets(NeedResults int32, Flags ConnectListAllSecretsFlags) (rSecrets []Secret, rRet uint32, err error) { var buf []byte - args := ConnectListAllSecretsArgs { + args := ConnectListAllSecretsArgs{ NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12811,9 +12708,9 @@ func (l *Libvirt) ConnectListAllSecrets(NeedResults int32, Flags ConnectListAllS func (l *Libvirt) NodeSetMemoryParameters(Params []TypedParam, Flags uint32) (err error) { var buf []byte - args := NodeSetMemoryParametersArgs { + args := NodeSetMemoryParametersArgs{ Params: Params, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12821,7 +12718,6 @@ func (l *Libvirt) NodeSetMemoryParameters(Params []TypedParam, Flags uint32) (er return } - _, err = l.requestStream(288, constants.Program, buf, nil, nil) if err != nil { return @@ -12834,9 +12730,9 @@ func (l *Libvirt) NodeSetMemoryParameters(Params []TypedParam, Flags uint32) (er func (l *Libvirt) NodeGetMemoryParameters(Nparams int32, Flags uint32) (rParams []TypedParam, rNparams int32, err error) { var buf []byte - args := NodeGetMemoryParametersArgs { + args := NodeGetMemoryParametersArgs{ Nparams: Nparams, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12873,13 +12769,13 @@ func (l *Libvirt) NodeGetMemoryParameters(Nparams int32, Flags uint32) (rParams func (l *Libvirt) DomainBlockCommit(Dom Domain, Disk string, Base OptString, Top OptString, Bandwidth uint64, Flags DomainBlockCommitFlags) (err error) { var buf []byte - args := DomainBlockCommitArgs { - Dom: Dom, - Disk: Disk, - Base: Base, - Top: Top, + args := DomainBlockCommitArgs{ + Dom: Dom, + Disk: Disk, + Base: Base, + Top: Top, Bandwidth: Bandwidth, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12887,7 +12783,6 @@ func (l *Libvirt) DomainBlockCommit(Dom Domain, Disk string, Base OptString, Top return } - _, err = l.requestStream(290, constants.Program, buf, nil, nil) if err != nil { return @@ -12900,13 +12795,13 @@ func (l *Libvirt) DomainBlockCommit(Dom Domain, Disk string, Base OptString, Top func (l *Libvirt) NetworkUpdate(Net Network, Command uint32, Section uint32, ParentIndex int32, XML string, Flags NetworkUpdateFlags) (err error) { var buf []byte - args := NetworkUpdateArgs { - Net: Net, - Command: Command, - Section: Section, + args := NetworkUpdateArgs{ + Net: Net, + Command: Command, + Section: Section, ParentIndex: ParentIndex, - XML: XML, - Flags: Flags, + XML: XML, + Flags: Flags, } buf, err = encode(&args) @@ -12914,7 +12809,6 @@ func (l *Libvirt) NetworkUpdate(Net Network, Command uint32, Section uint32, Par return } - _, err = l.requestStream(291, constants.Program, buf, nil, nil) if err != nil { return @@ -12927,7 +12821,6 @@ func (l *Libvirt) NetworkUpdate(Net Network, Command uint32, Section uint32, Par func (l *Libvirt) DomainEventPmsuspendDisk() (err error) { var buf []byte - _, err = l.requestStream(292, constants.Program, buf, nil, nil) if err != nil { return @@ -12940,10 +12833,10 @@ func (l *Libvirt) DomainEventPmsuspendDisk() (err error) { func (l *Libvirt) NodeGetCPUMap(NeedMap int32, NeedOnline int32, Flags uint32) (rCpumap []byte, rOnline uint32, rRet int32, err error) { var buf []byte - args := NodeGetCPUMapArgs { - NeedMap: NeedMap, + args := NodeGetCPUMapArgs{ + NeedMap: NeedMap, NeedOnline: NeedOnline, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -12985,11 +12878,11 @@ func (l *Libvirt) NodeGetCPUMap(NeedMap int32, NeedOnline int32, Flags uint32) ( func (l *Libvirt) DomainFstrim(Dom Domain, MountPoint OptString, Minimum uint64, Flags uint32) (err error) { var buf []byte - args := DomainFstrimArgs { - Dom: Dom, + args := DomainFstrimArgs{ + Dom: Dom, MountPoint: MountPoint, - Minimum: Minimum, - Flags: Flags, + Minimum: Minimum, + Flags: Flags, } buf, err = encode(&args) @@ -12997,7 +12890,6 @@ func (l *Libvirt) DomainFstrim(Dom Domain, MountPoint OptString, Minimum uint64, return } - _, err = l.requestStream(294, constants.Program, buf, nil, nil) if err != nil { return @@ -13010,11 +12902,11 @@ func (l *Libvirt) DomainFstrim(Dom Domain, MountPoint OptString, Minimum uint64, func (l *Libvirt) DomainSendProcessSignal(Dom Domain, PidValue int64, Signum uint32, Flags uint32) (err error) { var buf []byte - args := DomainSendProcessSignalArgs { - Dom: Dom, + args := DomainSendProcessSignalArgs{ + Dom: Dom, PidValue: PidValue, - Signum: Signum, - Flags: Flags, + Signum: Signum, + Flags: Flags, } buf, err = encode(&args) @@ -13022,7 +12914,6 @@ func (l *Libvirt) DomainSendProcessSignal(Dom Domain, PidValue int64, Signum uin return } - _, err = l.requestStream(295, constants.Program, buf, nil, nil) if err != nil { return @@ -13035,9 +12926,9 @@ func (l *Libvirt) DomainSendProcessSignal(Dom Domain, PidValue int64, Signum uin func (l *Libvirt) DomainOpenChannel(Dom Domain, Name OptString, inStream io.Writer, Flags DomainChannelFlags) (err error) { var buf []byte - args := DomainOpenChannelArgs { - Dom: Dom, - Name: Name, + args := DomainOpenChannelArgs{ + Dom: Dom, + Name: Name, Flags: Flags, } @@ -13046,7 +12937,6 @@ func (l *Libvirt) DomainOpenChannel(Dom Domain, Name OptString, inStream io.Writ return } - _, err = l.requestStream(296, constants.Program, buf, nil, inStream) if err != nil { return @@ -13059,9 +12949,9 @@ func (l *Libvirt) DomainOpenChannel(Dom Domain, Name OptString, inStream io.Writ func (l *Libvirt) NodeDeviceLookupScsiHostByWwn(Wwnn string, Wwpn string, Flags uint32) (rDev NodeDevice, err error) { var buf []byte - args := NodeDeviceLookupScsiHostByWwnArgs { - Wwnn: Wwnn, - Wwpn: Wwpn, + args := NodeDeviceLookupScsiHostByWwnArgs{ + Wwnn: Wwnn, + Wwpn: Wwpn, Flags: Flags, } @@ -13094,8 +12984,8 @@ func (l *Libvirt) NodeDeviceLookupScsiHostByWwn(Wwnn string, Wwpn string, Flags func (l *Libvirt) DomainGetJobStats(Dom Domain, Flags DomainGetJobStatsFlags) (rType int32, rParams []TypedParam, err error) { var buf []byte - args := DomainGetJobStatsArgs { - Dom: Dom, + args := DomainGetJobStatsArgs{ + Dom: Dom, Flags: Flags, } @@ -13133,8 +13023,8 @@ func (l *Libvirt) DomainGetJobStats(Dom Domain, Flags DomainGetJobStatsFlags) (r func (l *Libvirt) DomainMigrateGetCompressionCache(Dom Domain, Flags uint32) (rCacheSize uint64, err error) { var buf []byte - args := DomainMigrateGetCompressionCacheArgs { - Dom: Dom, + args := DomainMigrateGetCompressionCacheArgs{ + Dom: Dom, Flags: Flags, } @@ -13167,10 +13057,10 @@ func (l *Libvirt) DomainMigrateGetCompressionCache(Dom Domain, Flags uint32) (rC func (l *Libvirt) DomainMigrateSetCompressionCache(Dom Domain, CacheSize uint64, Flags uint32) (err error) { var buf []byte - args := DomainMigrateSetCompressionCacheArgs { - Dom: Dom, + args := DomainMigrateSetCompressionCacheArgs{ + Dom: Dom, CacheSize: CacheSize, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -13178,7 +13068,6 @@ func (l *Libvirt) DomainMigrateSetCompressionCache(Dom Domain, CacheSize uint64, return } - _, err = l.requestStream(300, constants.Program, buf, nil, nil) if err != nil { return @@ -13191,10 +13080,10 @@ func (l *Libvirt) DomainMigrateSetCompressionCache(Dom Domain, CacheSize uint64, func (l *Libvirt) NodeDeviceDetachFlags(Name string, DriverName OptString, Flags uint32) (err error) { var buf []byte - args := NodeDeviceDetachFlagsArgs { - Name: Name, + args := NodeDeviceDetachFlagsArgs{ + Name: Name, DriverName: DriverName, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -13202,7 +13091,6 @@ func (l *Libvirt) NodeDeviceDetachFlags(Name string, DriverName OptString, Flags return } - _, err = l.requestStream(301, constants.Program, buf, nil, nil) if err != nil { return @@ -13215,10 +13103,10 @@ func (l *Libvirt) NodeDeviceDetachFlags(Name string, DriverName OptString, Flags func (l *Libvirt) DomainMigrateBegin3Params(Dom Domain, Params []TypedParam, Flags uint32) (rCookieOut []byte, rXML string, err error) { var buf []byte - args := DomainMigrateBegin3ParamsArgs { - Dom: Dom, + args := DomainMigrateBegin3ParamsArgs{ + Dom: Dom, Params: Params, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -13255,10 +13143,10 @@ func (l *Libvirt) DomainMigrateBegin3Params(Dom Domain, Params []TypedParam, Fla func (l *Libvirt) DomainMigratePrepare3Params(Params []TypedParam, CookieIn []byte, Flags uint32) (rCookieOut []byte, rUriOut OptString, err error) { var buf []byte - args := DomainMigratePrepare3ParamsArgs { - Params: Params, + args := DomainMigratePrepare3ParamsArgs{ + Params: Params, CookieIn: CookieIn, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -13295,10 +13183,10 @@ func (l *Libvirt) DomainMigratePrepare3Params(Params []TypedParam, CookieIn []by func (l *Libvirt) DomainMigratePrepareTunnel3Params(Params []TypedParam, CookieIn []byte, Flags uint32) (rCookieOut []byte, err error) { var buf []byte - args := DomainMigratePrepareTunnel3ParamsArgs { - Params: Params, + args := DomainMigratePrepareTunnel3ParamsArgs{ + Params: Params, CookieIn: CookieIn, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -13330,12 +13218,12 @@ func (l *Libvirt) DomainMigratePrepareTunnel3Params(Params []TypedParam, CookieI func (l *Libvirt) DomainMigratePerform3Params(Dom Domain, Dconnuri OptString, Params []TypedParam, CookieIn []byte, Flags DomainMigrateFlags) (rCookieOut []byte, err error) { var buf []byte - args := DomainMigratePerform3ParamsArgs { - Dom: Dom, + args := DomainMigratePerform3ParamsArgs{ + Dom: Dom, Dconnuri: Dconnuri, - Params: Params, + Params: Params, CookieIn: CookieIn, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -13367,10 +13255,10 @@ func (l *Libvirt) DomainMigratePerform3Params(Dom Domain, Dconnuri OptString, Pa func (l *Libvirt) DomainMigrateFinish3Params(Params []TypedParam, CookieIn []byte, Flags uint32, Cancelled int32) (rDom Domain, rCookieOut []byte, err error) { var buf []byte - args := DomainMigrateFinish3ParamsArgs { - Params: Params, - CookieIn: CookieIn, - Flags: Flags, + args := DomainMigrateFinish3ParamsArgs{ + Params: Params, + CookieIn: CookieIn, + Flags: Flags, Cancelled: Cancelled, } @@ -13408,11 +13296,11 @@ func (l *Libvirt) DomainMigrateFinish3Params(Params []TypedParam, CookieIn []byt func (l *Libvirt) DomainMigrateConfirm3Params(Dom Domain, Params []TypedParam, CookieIn []byte, Flags uint32, Cancelled int32) (err error) { var buf []byte - args := DomainMigrateConfirm3ParamsArgs { - Dom: Dom, - Params: Params, - CookieIn: CookieIn, - Flags: Flags, + args := DomainMigrateConfirm3ParamsArgs{ + Dom: Dom, + Params: Params, + CookieIn: CookieIn, + Flags: Flags, Cancelled: Cancelled, } @@ -13421,7 +13309,6 @@ func (l *Libvirt) DomainMigrateConfirm3Params(Dom Domain, Params []TypedParam, C return } - _, err = l.requestStream(307, constants.Program, buf, nil, nil) if err != nil { return @@ -13434,10 +13321,10 @@ func (l *Libvirt) DomainMigrateConfirm3Params(Dom Domain, Params []TypedParam, C func (l *Libvirt) DomainSetMemoryStatsPeriod(Dom Domain, Period int32, Flags DomainMemoryModFlags) (err error) { var buf []byte - args := DomainSetMemoryStatsPeriodArgs { - Dom: Dom, + args := DomainSetMemoryStatsPeriodArgs{ + Dom: Dom, Period: Period, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -13445,7 +13332,6 @@ func (l *Libvirt) DomainSetMemoryStatsPeriod(Dom Domain, Period int32, Flags Dom return } - _, err = l.requestStream(308, constants.Program, buf, nil, nil) if err != nil { return @@ -13458,9 +13344,9 @@ func (l *Libvirt) DomainSetMemoryStatsPeriod(Dom Domain, Period int32, Flags Dom func (l *Libvirt) DomainCreateXMLWithFiles(XMLDesc string, Flags DomainCreateFlags) (rDom Domain, err error) { var buf []byte - args := DomainCreateXMLWithFilesArgs { + args := DomainCreateXMLWithFilesArgs{ XMLDesc: XMLDesc, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -13492,8 +13378,8 @@ func (l *Libvirt) DomainCreateXMLWithFiles(XMLDesc string, Flags DomainCreateFla func (l *Libvirt) DomainCreateWithFiles(Dom Domain, Flags DomainCreateFlags) (rDom Domain, err error) { var buf []byte - args := DomainCreateWithFilesArgs { - Dom: Dom, + args := DomainCreateWithFilesArgs{ + Dom: Dom, Flags: Flags, } @@ -13526,7 +13412,6 @@ func (l *Libvirt) DomainCreateWithFiles(Dom Domain, Flags DomainCreateFlags) (rD func (l *Libvirt) DomainEventDeviceRemoved() (err error) { var buf []byte - _, err = l.requestStream(311, constants.Program, buf, nil, nil) if err != nil { return @@ -13539,10 +13424,10 @@ func (l *Libvirt) DomainEventDeviceRemoved() (err error) { func (l *Libvirt) ConnectGetCPUModelNames(Arch string, NeedResults int32, Flags uint32) (rModels []string, rRet int32, err error) { var buf []byte - args := ConnectGetCPUModelNamesArgs { - Arch: Arch, + args := ConnectGetCPUModelNamesArgs{ + Arch: Arch, NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -13579,9 +13464,9 @@ func (l *Libvirt) ConnectGetCPUModelNames(Arch string, NeedResults int32, Flags func (l *Libvirt) ConnectNetworkEventRegisterAny(EventID int32, Net OptNetwork) (rCallbackID int32, err error) { var buf []byte - args := ConnectNetworkEventRegisterAnyArgs { + args := ConnectNetworkEventRegisterAnyArgs{ EventID: EventID, - Net: Net, + Net: Net, } buf, err = encode(&args) @@ -13613,7 +13498,7 @@ func (l *Libvirt) ConnectNetworkEventRegisterAny(EventID int32, Net OptNetwork) func (l *Libvirt) ConnectNetworkEventDeregisterAny(CallbackID int32) (err error) { var buf []byte - args := ConnectNetworkEventDeregisterAnyArgs { + args := ConnectNetworkEventDeregisterAnyArgs{ CallbackID: CallbackID, } @@ -13622,7 +13507,6 @@ func (l *Libvirt) ConnectNetworkEventDeregisterAny(CallbackID int32) (err error) return } - _, err = l.requestStream(314, constants.Program, buf, nil, nil) if err != nil { return @@ -13635,7 +13519,6 @@ func (l *Libvirt) ConnectNetworkEventDeregisterAny(CallbackID int32) (err error) func (l *Libvirt) NetworkEventLifecycle() (err error) { var buf []byte - _, err = l.requestStream(315, constants.Program, buf, nil, nil) if err != nil { return @@ -13648,9 +13531,9 @@ func (l *Libvirt) NetworkEventLifecycle() (err error) { func (l *Libvirt) ConnectDomainEventCallbackRegisterAny(EventID int32, Dom OptDomain) (rCallbackID int32, err error) { var buf []byte - args := ConnectDomainEventCallbackRegisterAnyArgs { + args := ConnectDomainEventCallbackRegisterAnyArgs{ EventID: EventID, - Dom: Dom, + Dom: Dom, } buf, err = encode(&args) @@ -13682,7 +13565,7 @@ func (l *Libvirt) ConnectDomainEventCallbackRegisterAny(EventID int32, Dom OptDo func (l *Libvirt) ConnectDomainEventCallbackDeregisterAny(CallbackID int32) (err error) { var buf []byte - args := ConnectDomainEventCallbackDeregisterAnyArgs { + args := ConnectDomainEventCallbackDeregisterAnyArgs{ CallbackID: CallbackID, } @@ -13691,7 +13574,6 @@ func (l *Libvirt) ConnectDomainEventCallbackDeregisterAny(CallbackID int32) (err return } - _, err = l.requestStream(317, constants.Program, buf, nil, nil) if err != nil { return @@ -13704,7 +13586,6 @@ func (l *Libvirt) ConnectDomainEventCallbackDeregisterAny(CallbackID int32) (err func (l *Libvirt) DomainEventCallbackLifecycle() (err error) { var buf []byte - _, err = l.requestStream(318, constants.Program, buf, nil, nil) if err != nil { return @@ -13717,7 +13598,6 @@ func (l *Libvirt) DomainEventCallbackLifecycle() (err error) { func (l *Libvirt) DomainEventCallbackReboot() (err error) { var buf []byte - _, err = l.requestStream(319, constants.Program, buf, nil, nil) if err != nil { return @@ -13730,7 +13610,6 @@ func (l *Libvirt) DomainEventCallbackReboot() (err error) { func (l *Libvirt) DomainEventCallbackRtcChange() (err error) { var buf []byte - _, err = l.requestStream(320, constants.Program, buf, nil, nil) if err != nil { return @@ -13743,7 +13622,6 @@ func (l *Libvirt) DomainEventCallbackRtcChange() (err error) { func (l *Libvirt) DomainEventCallbackWatchdog() (err error) { var buf []byte - _, err = l.requestStream(321, constants.Program, buf, nil, nil) if err != nil { return @@ -13756,7 +13634,6 @@ func (l *Libvirt) DomainEventCallbackWatchdog() (err error) { func (l *Libvirt) DomainEventCallbackIOError() (err error) { var buf []byte - _, err = l.requestStream(322, constants.Program, buf, nil, nil) if err != nil { return @@ -13769,7 +13646,6 @@ func (l *Libvirt) DomainEventCallbackIOError() (err error) { func (l *Libvirt) DomainEventCallbackGraphics() (err error) { var buf []byte - _, err = l.requestStream(323, constants.Program, buf, nil, nil) if err != nil { return @@ -13782,7 +13658,6 @@ func (l *Libvirt) DomainEventCallbackGraphics() (err error) { func (l *Libvirt) DomainEventCallbackIOErrorReason() (err error) { var buf []byte - _, err = l.requestStream(324, constants.Program, buf, nil, nil) if err != nil { return @@ -13795,7 +13670,6 @@ func (l *Libvirt) DomainEventCallbackIOErrorReason() (err error) { func (l *Libvirt) DomainEventCallbackControlError() (err error) { var buf []byte - _, err = l.requestStream(325, constants.Program, buf, nil, nil) if err != nil { return @@ -13808,7 +13682,6 @@ func (l *Libvirt) DomainEventCallbackControlError() (err error) { func (l *Libvirt) DomainEventCallbackBlockJob() (err error) { var buf []byte - _, err = l.requestStream(326, constants.Program, buf, nil, nil) if err != nil { return @@ -13821,7 +13694,6 @@ func (l *Libvirt) DomainEventCallbackBlockJob() (err error) { func (l *Libvirt) DomainEventCallbackDiskChange() (err error) { var buf []byte - _, err = l.requestStream(327, constants.Program, buf, nil, nil) if err != nil { return @@ -13834,7 +13706,6 @@ func (l *Libvirt) DomainEventCallbackDiskChange() (err error) { func (l *Libvirt) DomainEventCallbackTrayChange() (err error) { var buf []byte - _, err = l.requestStream(328, constants.Program, buf, nil, nil) if err != nil { return @@ -13847,7 +13718,6 @@ func (l *Libvirt) DomainEventCallbackTrayChange() (err error) { func (l *Libvirt) DomainEventCallbackPmwakeup() (err error) { var buf []byte - _, err = l.requestStream(329, constants.Program, buf, nil, nil) if err != nil { return @@ -13860,7 +13730,6 @@ func (l *Libvirt) DomainEventCallbackPmwakeup() (err error) { func (l *Libvirt) DomainEventCallbackPmsuspend() (err error) { var buf []byte - _, err = l.requestStream(330, constants.Program, buf, nil, nil) if err != nil { return @@ -13873,7 +13742,6 @@ func (l *Libvirt) DomainEventCallbackPmsuspend() (err error) { func (l *Libvirt) DomainEventCallbackBalloonChange() (err error) { var buf []byte - _, err = l.requestStream(331, constants.Program, buf, nil, nil) if err != nil { return @@ -13886,7 +13754,6 @@ func (l *Libvirt) DomainEventCallbackBalloonChange() (err error) { func (l *Libvirt) DomainEventCallbackPmsuspendDisk() (err error) { var buf []byte - _, err = l.requestStream(332, constants.Program, buf, nil, nil) if err != nil { return @@ -13899,7 +13766,6 @@ func (l *Libvirt) DomainEventCallbackPmsuspendDisk() (err error) { func (l *Libvirt) DomainEventCallbackDeviceRemoved() (err error) { var buf []byte - _, err = l.requestStream(333, constants.Program, buf, nil, nil) if err != nil { return @@ -13912,11 +13778,11 @@ func (l *Libvirt) DomainEventCallbackDeviceRemoved() (err error) { func (l *Libvirt) DomainCoreDumpWithFormat(Dom Domain, To string, Dumpformat uint32, Flags DomainCoreDumpFlags) (err error) { var buf []byte - args := DomainCoreDumpWithFormatArgs { - Dom: Dom, - To: To, + args := DomainCoreDumpWithFormatArgs{ + Dom: Dom, + To: To, Dumpformat: Dumpformat, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -13924,7 +13790,6 @@ func (l *Libvirt) DomainCoreDumpWithFormat(Dom Domain, To string, Dumpformat uin return } - _, err = l.requestStream(334, constants.Program, buf, nil, nil) if err != nil { return @@ -13937,10 +13802,10 @@ func (l *Libvirt) DomainCoreDumpWithFormat(Dom Domain, To string, Dumpformat uin func (l *Libvirt) DomainFsfreeze(Dom Domain, Mountpoints []string, Flags uint32) (rFilesystems int32, err error) { var buf []byte - args := DomainFsfreezeArgs { - Dom: Dom, + args := DomainFsfreezeArgs{ + Dom: Dom, Mountpoints: Mountpoints, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -13972,10 +13837,10 @@ func (l *Libvirt) DomainFsfreeze(Dom Domain, Mountpoints []string, Flags uint32) func (l *Libvirt) DomainFsthaw(Dom Domain, Mountpoints []string, Flags uint32) (rFilesystems int32, err error) { var buf []byte - args := DomainFsthawArgs { - Dom: Dom, + args := DomainFsthawArgs{ + Dom: Dom, Mountpoints: Mountpoints, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -14007,8 +13872,8 @@ func (l *Libvirt) DomainFsthaw(Dom Domain, Mountpoints []string, Flags uint32) ( func (l *Libvirt) DomainGetTime(Dom Domain, Flags uint32) (rSeconds int64, rNseconds uint32, err error) { var buf []byte - args := DomainGetTimeArgs { - Dom: Dom, + args := DomainGetTimeArgs{ + Dom: Dom, Flags: Flags, } @@ -14046,11 +13911,11 @@ func (l *Libvirt) DomainGetTime(Dom Domain, Flags uint32) (rSeconds int64, rNsec func (l *Libvirt) DomainSetTime(Dom Domain, Seconds int64, Nseconds uint32, Flags DomainSetTimeFlags) (err error) { var buf []byte - args := DomainSetTimeArgs { - Dom: Dom, - Seconds: Seconds, + args := DomainSetTimeArgs{ + Dom: Dom, + Seconds: Seconds, Nseconds: Nseconds, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -14058,7 +13923,6 @@ func (l *Libvirt) DomainSetTime(Dom Domain, Seconds int64, Nseconds uint32, Flag return } - _, err = l.requestStream(338, constants.Program, buf, nil, nil) if err != nil { return @@ -14071,7 +13935,6 @@ func (l *Libvirt) DomainSetTime(Dom Domain, Seconds int64, Nseconds uint32, Flag func (l *Libvirt) DomainEventBlockJob2() (err error) { var buf []byte - _, err = l.requestStream(339, constants.Program, buf, nil, nil) if err != nil { return @@ -14084,11 +13947,11 @@ func (l *Libvirt) DomainEventBlockJob2() (err error) { func (l *Libvirt) NodeGetFreePages(Pages []uint32, StartCell int32, CellCount uint32, Flags uint32) (rCounts []uint64, err error) { var buf []byte - args := NodeGetFreePagesArgs { - Pages: Pages, + args := NodeGetFreePagesArgs{ + Pages: Pages, StartCell: StartCell, CellCount: CellCount, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -14120,11 +13983,11 @@ func (l *Libvirt) NodeGetFreePages(Pages []uint32, StartCell int32, CellCount ui func (l *Libvirt) NetworkGetDhcpLeases(Net Network, Mac OptString, NeedResults int32, Flags uint32) (rLeases []NetworkDhcpLease, rRet uint32, err error) { var buf []byte - args := NetworkGetDhcpLeasesArgs { - Net: Net, - Mac: Mac, + args := NetworkGetDhcpLeasesArgs{ + Net: Net, + Mac: Mac, NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -14161,12 +14024,12 @@ func (l *Libvirt) NetworkGetDhcpLeases(Net Network, Mac OptString, NeedResults i func (l *Libvirt) ConnectGetDomainCapabilities(Emulatorbin OptString, Arch OptString, Machine OptString, Virttype OptString, Flags uint32) (rCapabilities string, err error) { var buf []byte - args := ConnectGetDomainCapabilitiesArgs { + args := ConnectGetDomainCapabilitiesArgs{ Emulatorbin: Emulatorbin, - Arch: Arch, - Machine: Machine, - Virttype: Virttype, - Flags: Flags, + Arch: Arch, + Machine: Machine, + Virttype: Virttype, + Flags: Flags, } buf, err = encode(&args) @@ -14198,9 +14061,9 @@ func (l *Libvirt) ConnectGetDomainCapabilities(Emulatorbin OptString, Arch OptSt func (l *Libvirt) DomainOpenGraphicsFd(Dom Domain, Idx uint32, Flags DomainOpenGraphicsFlags) (err error) { var buf []byte - args := DomainOpenGraphicsFdArgs { - Dom: Dom, - Idx: Idx, + args := DomainOpenGraphicsFdArgs{ + Dom: Dom, + Idx: Idx, Flags: Flags, } @@ -14209,7 +14072,6 @@ func (l *Libvirt) DomainOpenGraphicsFd(Dom Domain, Idx uint32, Flags DomainOpenG return } - _, err = l.requestStream(343, constants.Program, buf, nil, nil) if err != nil { return @@ -14222,8 +14084,8 @@ func (l *Libvirt) DomainOpenGraphicsFd(Dom Domain, Idx uint32, Flags DomainOpenG func (l *Libvirt) ConnectGetAllDomainStats(Doms []Domain, Stats uint32, Flags ConnectGetAllDomainStatsFlags) (rRetStats []DomainStatsRecord, err error) { var buf []byte - args := ConnectGetAllDomainStatsArgs { - Doms: Doms, + args := ConnectGetAllDomainStatsArgs{ + Doms: Doms, Stats: Stats, Flags: Flags, } @@ -14257,12 +14119,12 @@ func (l *Libvirt) ConnectGetAllDomainStats(Doms []Domain, Stats uint32, Flags Co func (l *Libvirt) DomainBlockCopy(Dom Domain, Path string, Destxml string, Params []TypedParam, Flags DomainBlockCopyFlags) (err error) { var buf []byte - args := DomainBlockCopyArgs { - Dom: Dom, - Path: Path, + args := DomainBlockCopyArgs{ + Dom: Dom, + Path: Path, Destxml: Destxml, - Params: Params, - Flags: Flags, + Params: Params, + Flags: Flags, } buf, err = encode(&args) @@ -14270,7 +14132,6 @@ func (l *Libvirt) DomainBlockCopy(Dom Domain, Path string, Destxml string, Param return } - _, err = l.requestStream(345, constants.Program, buf, nil, nil) if err != nil { return @@ -14283,7 +14144,6 @@ func (l *Libvirt) DomainBlockCopy(Dom Domain, Path string, Destxml string, Param func (l *Libvirt) DomainEventCallbackTunable() (err error) { var buf []byte - _, err = l.requestStream(346, constants.Program, buf, nil, nil) if err != nil { return @@ -14296,12 +14156,12 @@ func (l *Libvirt) DomainEventCallbackTunable() (err error) { func (l *Libvirt) NodeAllocPages(PageSizes []uint32, PageCounts []uint64, StartCell int32, CellCount uint32, Flags NodeAllocPagesFlags) (rRet int32, err error) { var buf []byte - args := NodeAllocPagesArgs { - PageSizes: PageSizes, + args := NodeAllocPagesArgs{ + PageSizes: PageSizes, PageCounts: PageCounts, - StartCell: StartCell, - CellCount: CellCount, - Flags: Flags, + StartCell: StartCell, + CellCount: CellCount, + Flags: Flags, } buf, err = encode(&args) @@ -14333,7 +14193,6 @@ func (l *Libvirt) NodeAllocPages(PageSizes []uint32, PageCounts []uint64, StartC func (l *Libvirt) DomainEventCallbackAgentLifecycle() (err error) { var buf []byte - _, err = l.requestStream(348, constants.Program, buf, nil, nil) if err != nil { return @@ -14346,8 +14205,8 @@ func (l *Libvirt) DomainEventCallbackAgentLifecycle() (err error) { func (l *Libvirt) DomainGetFsinfo(Dom Domain, Flags uint32) (rInfo []DomainFsinfo, rRet uint32, err error) { var buf []byte - args := DomainGetFsinfoArgs { - Dom: Dom, + args := DomainGetFsinfoArgs{ + Dom: Dom, Flags: Flags, } @@ -14385,8 +14244,8 @@ func (l *Libvirt) DomainGetFsinfo(Dom Domain, Flags uint32) (rInfo []DomainFsinf func (l *Libvirt) DomainDefineXMLFlags(XML string, Flags DomainDefineFlags) (rDom Domain, err error) { var buf []byte - args := DomainDefineXMLFlagsArgs { - XML: XML, + args := DomainDefineXMLFlagsArgs{ + XML: XML, Flags: Flags, } @@ -14419,8 +14278,8 @@ func (l *Libvirt) DomainDefineXMLFlags(XML string, Flags DomainDefineFlags) (rDo func (l *Libvirt) DomainGetIothreadInfo(Dom Domain, Flags DomainModificationImpact) (rInfo []DomainIothreadInfo, rRet uint32, err error) { var buf []byte - args := DomainGetIothreadInfoArgs { - Dom: Dom, + args := DomainGetIothreadInfoArgs{ + Dom: Dom, Flags: Flags, } @@ -14458,11 +14317,11 @@ func (l *Libvirt) DomainGetIothreadInfo(Dom Domain, Flags DomainModificationImpa func (l *Libvirt) DomainPinIothread(Dom Domain, IothreadsID uint32, Cpumap []byte, Flags DomainModificationImpact) (err error) { var buf []byte - args := DomainPinIothreadArgs { - Dom: Dom, + args := DomainPinIothreadArgs{ + Dom: Dom, IothreadsID: IothreadsID, - Cpumap: Cpumap, - Flags: Flags, + Cpumap: Cpumap, + Flags: Flags, } buf, err = encode(&args) @@ -14470,7 +14329,6 @@ func (l *Libvirt) DomainPinIothread(Dom Domain, IothreadsID uint32, Cpumap []byt return } - _, err = l.requestStream(352, constants.Program, buf, nil, nil) if err != nil { return @@ -14483,10 +14341,10 @@ func (l *Libvirt) DomainPinIothread(Dom Domain, IothreadsID uint32, Cpumap []byt func (l *Libvirt) DomainInterfaceAddresses(Dom Domain, Source uint32, Flags uint32) (rIfaces []DomainInterface, err error) { var buf []byte - args := DomainInterfaceAddressesArgs { - Dom: Dom, + args := DomainInterfaceAddressesArgs{ + Dom: Dom, Source: Source, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -14518,7 +14376,6 @@ func (l *Libvirt) DomainInterfaceAddresses(Dom Domain, Source uint32, Flags uint func (l *Libvirt) DomainEventCallbackDeviceAdded() (err error) { var buf []byte - _, err = l.requestStream(354, constants.Program, buf, nil, nil) if err != nil { return @@ -14531,10 +14388,10 @@ func (l *Libvirt) DomainEventCallbackDeviceAdded() (err error) { func (l *Libvirt) DomainAddIothread(Dom Domain, IothreadID uint32, Flags DomainModificationImpact) (err error) { var buf []byte - args := DomainAddIothreadArgs { - Dom: Dom, + args := DomainAddIothreadArgs{ + Dom: Dom, IothreadID: IothreadID, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -14542,7 +14399,6 @@ func (l *Libvirt) DomainAddIothread(Dom Domain, IothreadID uint32, Flags DomainM return } - _, err = l.requestStream(355, constants.Program, buf, nil, nil) if err != nil { return @@ -14555,10 +14411,10 @@ func (l *Libvirt) DomainAddIothread(Dom Domain, IothreadID uint32, Flags DomainM func (l *Libvirt) DomainDelIothread(Dom Domain, IothreadID uint32, Flags DomainModificationImpact) (err error) { var buf []byte - args := DomainDelIothreadArgs { - Dom: Dom, + args := DomainDelIothreadArgs{ + Dom: Dom, IothreadID: IothreadID, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -14566,7 +14422,6 @@ func (l *Libvirt) DomainDelIothread(Dom Domain, IothreadID uint32, Flags DomainM return } - _, err = l.requestStream(356, constants.Program, buf, nil, nil) if err != nil { return @@ -14579,11 +14434,11 @@ func (l *Libvirt) DomainDelIothread(Dom Domain, IothreadID uint32, Flags DomainM func (l *Libvirt) DomainSetUserPassword(Dom Domain, User OptString, Password OptString, Flags DomainSetUserPasswordFlags) (err error) { var buf []byte - args := DomainSetUserPasswordArgs { - Dom: Dom, - User: User, + args := DomainSetUserPasswordArgs{ + Dom: Dom, + User: User, Password: Password, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -14591,7 +14446,6 @@ func (l *Libvirt) DomainSetUserPassword(Dom Domain, User OptString, Password Opt return } - _, err = l.requestStream(357, constants.Program, buf, nil, nil) if err != nil { return @@ -14604,10 +14458,10 @@ func (l *Libvirt) DomainSetUserPassword(Dom Domain, User OptString, Password Opt func (l *Libvirt) DomainRename(Dom Domain, NewName OptString, Flags uint32) (rRetcode int32, err error) { var buf []byte - args := DomainRenameArgs { - Dom: Dom, + args := DomainRenameArgs{ + Dom: Dom, NewName: NewName, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -14639,7 +14493,6 @@ func (l *Libvirt) DomainRename(Dom Domain, NewName OptString, Flags uint32) (rRe func (l *Libvirt) DomainEventCallbackMigrationIteration() (err error) { var buf []byte - _, err = l.requestStream(359, constants.Program, buf, nil, nil) if err != nil { return @@ -14652,7 +14505,6 @@ func (l *Libvirt) DomainEventCallbackMigrationIteration() (err error) { func (l *Libvirt) ConnectRegisterCloseCallback() (err error) { var buf []byte - _, err = l.requestStream(360, constants.Program, buf, nil, nil) if err != nil { return @@ -14665,7 +14517,6 @@ func (l *Libvirt) ConnectRegisterCloseCallback() (err error) { func (l *Libvirt) ConnectUnregisterCloseCallback() (err error) { var buf []byte - _, err = l.requestStream(361, constants.Program, buf, nil, nil) if err != nil { return @@ -14678,7 +14529,6 @@ func (l *Libvirt) ConnectUnregisterCloseCallback() (err error) { func (l *Libvirt) ConnectEventConnectionClosed() (err error) { var buf []byte - _, err = l.requestStream(362, constants.Program, buf, nil, nil) if err != nil { return @@ -14691,7 +14541,6 @@ func (l *Libvirt) ConnectEventConnectionClosed() (err error) { func (l *Libvirt) DomainEventCallbackJobCompleted() (err error) { var buf []byte - _, err = l.requestStream(363, constants.Program, buf, nil, nil) if err != nil { return @@ -14704,8 +14553,8 @@ func (l *Libvirt) DomainEventCallbackJobCompleted() (err error) { func (l *Libvirt) DomainMigrateStartPostCopy(Dom Domain, Flags uint32) (err error) { var buf []byte - args := DomainMigrateStartPostCopyArgs { - Dom: Dom, + args := DomainMigrateStartPostCopyArgs{ + Dom: Dom, Flags: Flags, } @@ -14714,7 +14563,6 @@ func (l *Libvirt) DomainMigrateStartPostCopy(Dom Domain, Flags uint32) (err erro return } - _, err = l.requestStream(364, constants.Program, buf, nil, nil) if err != nil { return @@ -14727,8 +14575,8 @@ func (l *Libvirt) DomainMigrateStartPostCopy(Dom Domain, Flags uint32) (err erro func (l *Libvirt) DomainGetPerfEvents(Dom Domain, Flags DomainModificationImpact) (rParams []TypedParam, err error) { var buf []byte - args := DomainGetPerfEventsArgs { - Dom: Dom, + args := DomainGetPerfEventsArgs{ + Dom: Dom, Flags: Flags, } @@ -14761,10 +14609,10 @@ func (l *Libvirt) DomainGetPerfEvents(Dom Domain, Flags DomainModificationImpact func (l *Libvirt) DomainSetPerfEvents(Dom Domain, Params []TypedParam, Flags DomainModificationImpact) (err error) { var buf []byte - args := DomainSetPerfEventsArgs { - Dom: Dom, + args := DomainSetPerfEventsArgs{ + Dom: Dom, Params: Params, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -14772,7 +14620,6 @@ func (l *Libvirt) DomainSetPerfEvents(Dom Domain, Params []TypedParam, Flags Dom return } - _, err = l.requestStream(366, constants.Program, buf, nil, nil) if err != nil { return @@ -14785,7 +14632,6 @@ func (l *Libvirt) DomainSetPerfEvents(Dom Domain, Params []TypedParam, Flags Dom func (l *Libvirt) DomainEventCallbackDeviceRemovalFailed() (err error) { var buf []byte - _, err = l.requestStream(367, constants.Program, buf, nil, nil) if err != nil { return @@ -14798,9 +14644,9 @@ func (l *Libvirt) DomainEventCallbackDeviceRemovalFailed() (err error) { func (l *Libvirt) ConnectStoragePoolEventRegisterAny(EventID int32, Pool OptStoragePool) (rCallbackID int32, err error) { var buf []byte - args := ConnectStoragePoolEventRegisterAnyArgs { + args := ConnectStoragePoolEventRegisterAnyArgs{ EventID: EventID, - Pool: Pool, + Pool: Pool, } buf, err = encode(&args) @@ -14832,7 +14678,7 @@ func (l *Libvirt) ConnectStoragePoolEventRegisterAny(EventID int32, Pool OptStor func (l *Libvirt) ConnectStoragePoolEventDeregisterAny(CallbackID int32) (err error) { var buf []byte - args := ConnectStoragePoolEventDeregisterAnyArgs { + args := ConnectStoragePoolEventDeregisterAnyArgs{ CallbackID: CallbackID, } @@ -14841,7 +14687,6 @@ func (l *Libvirt) ConnectStoragePoolEventDeregisterAny(CallbackID int32) (err er return } - _, err = l.requestStream(369, constants.Program, buf, nil, nil) if err != nil { return @@ -14854,7 +14699,6 @@ func (l *Libvirt) ConnectStoragePoolEventDeregisterAny(CallbackID int32) (err er func (l *Libvirt) StoragePoolEventLifecycle() (err error) { var buf []byte - _, err = l.requestStream(370, constants.Program, buf, nil, nil) if err != nil { return @@ -14867,8 +14711,8 @@ func (l *Libvirt) StoragePoolEventLifecycle() (err error) { func (l *Libvirt) DomainGetGuestVcpus(Dom Domain, Flags uint32) (rParams []TypedParam, err error) { var buf []byte - args := DomainGetGuestVcpusArgs { - Dom: Dom, + args := DomainGetGuestVcpusArgs{ + Dom: Dom, Flags: Flags, } @@ -14901,11 +14745,11 @@ func (l *Libvirt) DomainGetGuestVcpus(Dom Domain, Flags uint32) (rParams []Typed func (l *Libvirt) DomainSetGuestVcpus(Dom Domain, Cpumap string, State int32, Flags uint32) (err error) { var buf []byte - args := DomainSetGuestVcpusArgs { - Dom: Dom, + args := DomainSetGuestVcpusArgs{ + Dom: Dom, Cpumap: Cpumap, - State: State, - Flags: Flags, + State: State, + Flags: Flags, } buf, err = encode(&args) @@ -14913,7 +14757,6 @@ func (l *Libvirt) DomainSetGuestVcpus(Dom Domain, Cpumap string, State int32, Fl return } - _, err = l.requestStream(372, constants.Program, buf, nil, nil) if err != nil { return @@ -14926,7 +14769,6 @@ func (l *Libvirt) DomainSetGuestVcpus(Dom Domain, Cpumap string, State int32, Fl func (l *Libvirt) StoragePoolEventRefresh() (err error) { var buf []byte - _, err = l.requestStream(373, constants.Program, buf, nil, nil) if err != nil { return @@ -14939,9 +14781,9 @@ func (l *Libvirt) StoragePoolEventRefresh() (err error) { func (l *Libvirt) ConnectNodeDeviceEventRegisterAny(EventID int32, Dev OptNodeDevice) (rCallbackID int32, err error) { var buf []byte - args := ConnectNodeDeviceEventRegisterAnyArgs { + args := ConnectNodeDeviceEventRegisterAnyArgs{ EventID: EventID, - Dev: Dev, + Dev: Dev, } buf, err = encode(&args) @@ -14973,7 +14815,7 @@ func (l *Libvirt) ConnectNodeDeviceEventRegisterAny(EventID int32, Dev OptNodeDe func (l *Libvirt) ConnectNodeDeviceEventDeregisterAny(CallbackID int32) (err error) { var buf []byte - args := ConnectNodeDeviceEventDeregisterAnyArgs { + args := ConnectNodeDeviceEventDeregisterAnyArgs{ CallbackID: CallbackID, } @@ -14982,7 +14824,6 @@ func (l *Libvirt) ConnectNodeDeviceEventDeregisterAny(CallbackID int32) (err err return } - _, err = l.requestStream(375, constants.Program, buf, nil, nil) if err != nil { return @@ -14995,7 +14836,6 @@ func (l *Libvirt) ConnectNodeDeviceEventDeregisterAny(CallbackID int32) (err err func (l *Libvirt) NodeDeviceEventLifecycle() (err error) { var buf []byte - _, err = l.requestStream(376, constants.Program, buf, nil, nil) if err != nil { return @@ -15008,7 +14848,6 @@ func (l *Libvirt) NodeDeviceEventLifecycle() (err error) { func (l *Libvirt) NodeDeviceEventUpdate() (err error) { var buf []byte - _, err = l.requestStream(377, constants.Program, buf, nil, nil) if err != nil { return @@ -15021,8 +14860,8 @@ func (l *Libvirt) NodeDeviceEventUpdate() (err error) { func (l *Libvirt) StorageVolGetInfoFlags(Vol StorageVol, Flags uint32) (rType int8, rCapacity uint64, rAllocation uint64, err error) { var buf []byte - args := StorageVolGetInfoFlagsArgs { - Vol: Vol, + args := StorageVolGetInfoFlagsArgs{ + Vol: Vol, Flags: Flags, } @@ -15065,7 +14904,6 @@ func (l *Libvirt) StorageVolGetInfoFlags(Vol StorageVol, Flags uint32) (rType in func (l *Libvirt) DomainEventCallbackMetadataChange() (err error) { var buf []byte - _, err = l.requestStream(379, constants.Program, buf, nil, nil) if err != nil { return @@ -15078,8 +14916,8 @@ func (l *Libvirt) DomainEventCallbackMetadataChange() (err error) { func (l *Libvirt) ConnectSecretEventRegisterAny(EventID int32, OptSecret OptSecret) (rCallbackID int32, err error) { var buf []byte - args := ConnectSecretEventRegisterAnyArgs { - EventID: EventID, + args := ConnectSecretEventRegisterAnyArgs{ + EventID: EventID, OptSecret: OptSecret, } @@ -15112,7 +14950,7 @@ func (l *Libvirt) ConnectSecretEventRegisterAny(EventID int32, OptSecret OptSecr func (l *Libvirt) ConnectSecretEventDeregisterAny(CallbackID int32) (err error) { var buf []byte - args := ConnectSecretEventDeregisterAnyArgs { + args := ConnectSecretEventDeregisterAnyArgs{ CallbackID: CallbackID, } @@ -15121,7 +14959,6 @@ func (l *Libvirt) ConnectSecretEventDeregisterAny(CallbackID int32) (err error) return } - _, err = l.requestStream(381, constants.Program, buf, nil, nil) if err != nil { return @@ -15134,7 +14971,6 @@ func (l *Libvirt) ConnectSecretEventDeregisterAny(CallbackID int32) (err error) func (l *Libvirt) SecretEventLifecycle() (err error) { var buf []byte - _, err = l.requestStream(382, constants.Program, buf, nil, nil) if err != nil { return @@ -15147,7 +14983,6 @@ func (l *Libvirt) SecretEventLifecycle() (err error) { func (l *Libvirt) SecretEventValueChanged() (err error) { var buf []byte - _, err = l.requestStream(383, constants.Program, buf, nil, nil) if err != nil { return @@ -15160,11 +14995,11 @@ func (l *Libvirt) SecretEventValueChanged() (err error) { func (l *Libvirt) DomainSetVcpu(Dom Domain, Cpumap string, State int32, Flags DomainModificationImpact) (err error) { var buf []byte - args := DomainSetVcpuArgs { - Dom: Dom, + args := DomainSetVcpuArgs{ + Dom: Dom, Cpumap: Cpumap, - State: State, - Flags: Flags, + State: State, + Flags: Flags, } buf, err = encode(&args) @@ -15172,7 +15007,6 @@ func (l *Libvirt) DomainSetVcpu(Dom Domain, Cpumap string, State int32, Flags Do return } - _, err = l.requestStream(384, constants.Program, buf, nil, nil) if err != nil { return @@ -15185,7 +15019,6 @@ func (l *Libvirt) DomainSetVcpu(Dom Domain, Cpumap string, State int32, Flags Do func (l *Libvirt) DomainEventBlockThreshold() (err error) { var buf []byte - _, err = l.requestStream(385, constants.Program, buf, nil, nil) if err != nil { return @@ -15198,11 +15031,11 @@ func (l *Libvirt) DomainEventBlockThreshold() (err error) { func (l *Libvirt) DomainSetBlockThreshold(Dom Domain, Dev string, Threshold uint64, Flags uint32) (err error) { var buf []byte - args := DomainSetBlockThresholdArgs { - Dom: Dom, - Dev: Dev, + args := DomainSetBlockThresholdArgs{ + Dom: Dom, + Dev: Dev, Threshold: Threshold, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -15210,7 +15043,6 @@ func (l *Libvirt) DomainSetBlockThreshold(Dom Domain, Dev string, Threshold uint return } - _, err = l.requestStream(386, constants.Program, buf, nil, nil) if err != nil { return @@ -15223,8 +15055,8 @@ func (l *Libvirt) DomainSetBlockThreshold(Dom Domain, Dev string, Threshold uint func (l *Libvirt) DomainMigrateGetMaxDowntime(Dom Domain, Flags uint32) (rDowntime uint64, err error) { var buf []byte - args := DomainMigrateGetMaxDowntimeArgs { - Dom: Dom, + args := DomainMigrateGetMaxDowntimeArgs{ + Dom: Dom, Flags: Flags, } @@ -15257,8 +15089,8 @@ func (l *Libvirt) DomainMigrateGetMaxDowntime(Dom Domain, Flags uint32) (rDownti func (l *Libvirt) DomainManagedSaveGetXMLDesc(Dom Domain, Flags DomainXMLFlags) (rXML string, err error) { var buf []byte - args := DomainManagedSaveGetXMLDescArgs { - Dom: Dom, + args := DomainManagedSaveGetXMLDescArgs{ + Dom: Dom, Flags: Flags, } @@ -15291,9 +15123,9 @@ func (l *Libvirt) DomainManagedSaveGetXMLDesc(Dom Domain, Flags DomainXMLFlags) func (l *Libvirt) DomainManagedSaveDefineXML(Dom Domain, Dxml OptString, Flags DomainSaveRestoreFlags) (err error) { var buf []byte - args := DomainManagedSaveDefineXMLArgs { - Dom: Dom, - Dxml: Dxml, + args := DomainManagedSaveDefineXMLArgs{ + Dom: Dom, + Dxml: Dxml, Flags: Flags, } @@ -15302,7 +15134,6 @@ func (l *Libvirt) DomainManagedSaveDefineXML(Dom Domain, Dxml OptString, Flags D return } - _, err = l.requestStream(389, constants.Program, buf, nil, nil) if err != nil { return @@ -15315,11 +15146,11 @@ func (l *Libvirt) DomainManagedSaveDefineXML(Dom Domain, Dxml OptString, Flags D func (l *Libvirt) DomainSetLifecycleAction(Dom Domain, Type uint32, Action uint32, Flags DomainModificationImpact) (err error) { var buf []byte - args := DomainSetLifecycleActionArgs { - Dom: Dom, - Type: Type, + args := DomainSetLifecycleActionArgs{ + Dom: Dom, + Type: Type, Action: Action, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -15327,7 +15158,6 @@ func (l *Libvirt) DomainSetLifecycleAction(Dom Domain, Type uint32, Action uint3 return } - _, err = l.requestStream(390, constants.Program, buf, nil, nil) if err != nil { return @@ -15340,7 +15170,7 @@ func (l *Libvirt) DomainSetLifecycleAction(Dom Domain, Type uint32, Action uint3 func (l *Libvirt) StoragePoolLookupByTargetPath(Path string) (rPool StoragePool, err error) { var buf []byte - args := StoragePoolLookupByTargetPathArgs { + args := StoragePoolLookupByTargetPathArgs{ Path: Path, } @@ -15373,8 +15203,8 @@ func (l *Libvirt) StoragePoolLookupByTargetPath(Path string) (rPool StoragePool, func (l *Libvirt) DomainDetachDeviceAlias(Dom Domain, Alias string, Flags uint32) (err error) { var buf []byte - args := DomainDetachDeviceAliasArgs { - Dom: Dom, + args := DomainDetachDeviceAliasArgs{ + Dom: Dom, Alias: Alias, Flags: Flags, } @@ -15384,7 +15214,6 @@ func (l *Libvirt) DomainDetachDeviceAlias(Dom Domain, Alias string, Flags uint32 return } - _, err = l.requestStream(392, constants.Program, buf, nil, nil) if err != nil { return @@ -15397,13 +15226,13 @@ func (l *Libvirt) DomainDetachDeviceAlias(Dom Domain, Alias string, Flags uint32 func (l *Libvirt) ConnectCompareHypervisorCPU(Emulator OptString, Arch OptString, Machine OptString, Virttype OptString, XMLCPU string, Flags uint32) (rResult int32, err error) { var buf []byte - args := ConnectCompareHypervisorCPUArgs { + args := ConnectCompareHypervisorCPUArgs{ Emulator: Emulator, - Arch: Arch, - Machine: Machine, + Arch: Arch, + Machine: Machine, Virttype: Virttype, - XMLCPU: XMLCPU, - Flags: Flags, + XMLCPU: XMLCPU, + Flags: Flags, } buf, err = encode(&args) @@ -15435,13 +15264,13 @@ func (l *Libvirt) ConnectCompareHypervisorCPU(Emulator OptString, Arch OptString func (l *Libvirt) ConnectBaselineHypervisorCPU(Emulator OptString, Arch OptString, Machine OptString, Virttype OptString, XMLCPUs []string, Flags uint32) (rCPU string, err error) { var buf []byte - args := ConnectBaselineHypervisorCPUArgs { + args := ConnectBaselineHypervisorCPUArgs{ Emulator: Emulator, - Arch: Arch, - Machine: Machine, + Arch: Arch, + Machine: Machine, Virttype: Virttype, - XMLCPUs: XMLCPUs, - Flags: Flags, + XMLCPUs: XMLCPUs, + Flags: Flags, } buf, err = encode(&args) @@ -15473,9 +15302,9 @@ func (l *Libvirt) ConnectBaselineHypervisorCPU(Emulator OptString, Arch OptStrin func (l *Libvirt) NodeGetSevInfo(Nparams int32, Flags uint32) (rParams []TypedParam, rNparams int32, err error) { var buf []byte - args := NodeGetSevInfoArgs { + args := NodeGetSevInfoArgs{ Nparams: Nparams, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -15512,8 +15341,8 @@ func (l *Libvirt) NodeGetSevInfo(Nparams int32, Flags uint32) (rParams []TypedPa func (l *Libvirt) DomainGetLaunchSecurityInfo(Dom Domain, Flags uint32) (rParams []TypedParam, err error) { var buf []byte - args := DomainGetLaunchSecurityInfoArgs { - Dom: Dom, + args := DomainGetLaunchSecurityInfoArgs{ + Dom: Dom, Flags: Flags, } @@ -15546,7 +15375,7 @@ func (l *Libvirt) DomainGetLaunchSecurityInfo(Dom Domain, Flags uint32) (rParams func (l *Libvirt) NwfilterBindingLookupByPortDev(Name string) (rOptNwfilter NwfilterBinding, err error) { var buf []byte - args := NwfilterBindingLookupByPortDevArgs { + args := NwfilterBindingLookupByPortDevArgs{ Name: Name, } @@ -15579,9 +15408,9 @@ func (l *Libvirt) NwfilterBindingLookupByPortDev(Name string) (rOptNwfilter Nwfi func (l *Libvirt) NwfilterBindingGetXMLDesc(OptNwfilter NwfilterBinding, Flags uint32) (rXML string, err error) { var buf []byte - args := NwfilterBindingGetXMLDescArgs { + args := NwfilterBindingGetXMLDescArgs{ OptNwfilter: OptNwfilter, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -15613,8 +15442,8 @@ func (l *Libvirt) NwfilterBindingGetXMLDesc(OptNwfilter NwfilterBinding, Flags u func (l *Libvirt) NwfilterBindingCreateXML(XML string, Flags uint32) (rOptNwfilter NwfilterBinding, err error) { var buf []byte - args := NwfilterBindingCreateXMLArgs { - XML: XML, + args := NwfilterBindingCreateXMLArgs{ + XML: XML, Flags: Flags, } @@ -15647,7 +15476,7 @@ func (l *Libvirt) NwfilterBindingCreateXML(XML string, Flags uint32) (rOptNwfilt func (l *Libvirt) NwfilterBindingDelete(OptNwfilter NwfilterBinding) (err error) { var buf []byte - args := NwfilterBindingDeleteArgs { + args := NwfilterBindingDeleteArgs{ OptNwfilter: OptNwfilter, } @@ -15656,7 +15485,6 @@ func (l *Libvirt) NwfilterBindingDelete(OptNwfilter NwfilterBinding) (err error) return } - _, err = l.requestStream(400, constants.Program, buf, nil, nil) if err != nil { return @@ -15669,9 +15497,9 @@ func (l *Libvirt) NwfilterBindingDelete(OptNwfilter NwfilterBinding) (err error) func (l *Libvirt) ConnectListAllNwfilterBindings(NeedResults int32, Flags uint32) (rBindings []NwfilterBinding, rRet uint32, err error) { var buf []byte - args := ConnectListAllNwfilterBindingsArgs { + args := ConnectListAllNwfilterBindingsArgs{ NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -15708,11 +15536,11 @@ func (l *Libvirt) ConnectListAllNwfilterBindings(NeedResults int32, Flags uint32 func (l *Libvirt) DomainSetIothreadParams(Dom Domain, IothreadID uint32, Params []TypedParam, Flags uint32) (err error) { var buf []byte - args := DomainSetIothreadParamsArgs { - Dom: Dom, + args := DomainSetIothreadParamsArgs{ + Dom: Dom, IothreadID: IothreadID, - Params: Params, - Flags: Flags, + Params: Params, + Flags: Flags, } buf, err = encode(&args) @@ -15720,7 +15548,6 @@ func (l *Libvirt) DomainSetIothreadParams(Dom Domain, IothreadID uint32, Params return } - _, err = l.requestStream(402, constants.Program, buf, nil, nil) if err != nil { return @@ -15733,7 +15560,7 @@ func (l *Libvirt) DomainSetIothreadParams(Dom Domain, IothreadID uint32, Params func (l *Libvirt) ConnectGetStoragePoolCapabilities(Flags uint32) (rCapabilities string, err error) { var buf []byte - args := ConnectGetStoragePoolCapabilitiesArgs { + args := ConnectGetStoragePoolCapabilitiesArgs{ Flags: Flags, } @@ -15766,10 +15593,10 @@ func (l *Libvirt) ConnectGetStoragePoolCapabilities(Flags uint32) (rCapabilities func (l *Libvirt) NetworkListAllPorts(OptNetwork Network, NeedResults int32, Flags uint32) (rPorts []NetworkPort, rRet uint32, err error) { var buf []byte - args := NetworkListAllPortsArgs { - OptNetwork: OptNetwork, + args := NetworkListAllPortsArgs{ + OptNetwork: OptNetwork, NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -15806,9 +15633,9 @@ func (l *Libvirt) NetworkListAllPorts(OptNetwork Network, NeedResults int32, Fla func (l *Libvirt) NetworkPortLookupByUUID(OptNetwork Network, UUID UUID) (rPort NetworkPort, err error) { var buf []byte - args := NetworkPortLookupByUUIDArgs { + args := NetworkPortLookupByUUIDArgs{ OptNetwork: OptNetwork, - UUID: UUID, + UUID: UUID, } buf, err = encode(&args) @@ -15840,10 +15667,10 @@ func (l *Libvirt) NetworkPortLookupByUUID(OptNetwork Network, UUID UUID) (rPort func (l *Libvirt) NetworkPortCreateXML(OptNetwork Network, XML string, Flags uint32) (rPort NetworkPort, err error) { var buf []byte - args := NetworkPortCreateXMLArgs { + args := NetworkPortCreateXMLArgs{ OptNetwork: OptNetwork, - XML: XML, - Flags: Flags, + XML: XML, + Flags: Flags, } buf, err = encode(&args) @@ -15875,10 +15702,10 @@ func (l *Libvirt) NetworkPortCreateXML(OptNetwork Network, XML string, Flags uin func (l *Libvirt) NetworkPortGetParameters(Port NetworkPort, Nparams int32, Flags uint32) (rParams []TypedParam, rNparams int32, err error) { var buf []byte - args := NetworkPortGetParametersArgs { - Port: Port, + args := NetworkPortGetParametersArgs{ + Port: Port, Nparams: Nparams, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -15915,10 +15742,10 @@ func (l *Libvirt) NetworkPortGetParameters(Port NetworkPort, Nparams int32, Flag func (l *Libvirt) NetworkPortSetParameters(Port NetworkPort, Params []TypedParam, Flags uint32) (err error) { var buf []byte - args := NetworkPortSetParametersArgs { - Port: Port, + args := NetworkPortSetParametersArgs{ + Port: Port, Params: Params, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -15926,7 +15753,6 @@ func (l *Libvirt) NetworkPortSetParameters(Port NetworkPort, Params []TypedParam return } - _, err = l.requestStream(408, constants.Program, buf, nil, nil) if err != nil { return @@ -15939,8 +15765,8 @@ func (l *Libvirt) NetworkPortSetParameters(Port NetworkPort, Params []TypedParam func (l *Libvirt) NetworkPortGetXMLDesc(Port NetworkPort, Flags uint32) (rXML string, err error) { var buf []byte - args := NetworkPortGetXMLDescArgs { - Port: Port, + args := NetworkPortGetXMLDescArgs{ + Port: Port, Flags: Flags, } @@ -15973,8 +15799,8 @@ func (l *Libvirt) NetworkPortGetXMLDesc(Port NetworkPort, Flags uint32) (rXML st func (l *Libvirt) NetworkPortDelete(Port NetworkPort, Flags uint32) (err error) { var buf []byte - args := NetworkPortDeleteArgs { - Port: Port, + args := NetworkPortDeleteArgs{ + Port: Port, Flags: Flags, } @@ -15983,7 +15809,6 @@ func (l *Libvirt) NetworkPortDelete(Port NetworkPort, Flags uint32) (err error) return } - _, err = l.requestStream(410, constants.Program, buf, nil, nil) if err != nil { return @@ -15996,10 +15821,10 @@ func (l *Libvirt) NetworkPortDelete(Port NetworkPort, Flags uint32) (err error) func (l *Libvirt) DomainCheckpointCreateXML(Dom Domain, XMLDesc string, Flags uint32) (rCheckpoint DomainCheckpoint, err error) { var buf []byte - args := DomainCheckpointCreateXMLArgs { - Dom: Dom, + args := DomainCheckpointCreateXMLArgs{ + Dom: Dom, XMLDesc: XMLDesc, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -16031,9 +15856,9 @@ func (l *Libvirt) DomainCheckpointCreateXML(Dom Domain, XMLDesc string, Flags ui func (l *Libvirt) DomainCheckpointGetXMLDesc(Checkpoint DomainCheckpoint, Flags uint32) (rXML string, err error) { var buf []byte - args := DomainCheckpointGetXMLDescArgs { + args := DomainCheckpointGetXMLDescArgs{ Checkpoint: Checkpoint, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -16065,10 +15890,10 @@ func (l *Libvirt) DomainCheckpointGetXMLDesc(Checkpoint DomainCheckpoint, Flags func (l *Libvirt) DomainListAllCheckpoints(Dom Domain, NeedResults int32, Flags uint32) (rCheckpoints []DomainCheckpoint, rRet int32, err error) { var buf []byte - args := DomainListAllCheckpointsArgs { - Dom: Dom, + args := DomainListAllCheckpointsArgs{ + Dom: Dom, NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -16105,10 +15930,10 @@ func (l *Libvirt) DomainListAllCheckpoints(Dom Domain, NeedResults int32, Flags func (l *Libvirt) DomainCheckpointListAllChildren(Checkpoint DomainCheckpoint, NeedResults int32, Flags uint32) (rCheckpoints []DomainCheckpoint, rRet int32, err error) { var buf []byte - args := DomainCheckpointListAllChildrenArgs { - Checkpoint: Checkpoint, + args := DomainCheckpointListAllChildrenArgs{ + Checkpoint: Checkpoint, NeedResults: NeedResults, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -16145,9 +15970,9 @@ func (l *Libvirt) DomainCheckpointListAllChildren(Checkpoint DomainCheckpoint, N func (l *Libvirt) DomainCheckpointLookupByName(Dom Domain, Name string, Flags uint32) (rCheckpoint DomainCheckpoint, err error) { var buf []byte - args := DomainCheckpointLookupByNameArgs { - Dom: Dom, - Name: Name, + args := DomainCheckpointLookupByNameArgs{ + Dom: Dom, + Name: Name, Flags: Flags, } @@ -16180,9 +16005,9 @@ func (l *Libvirt) DomainCheckpointLookupByName(Dom Domain, Name string, Flags ui func (l *Libvirt) DomainCheckpointGetParent(Checkpoint DomainCheckpoint, Flags uint32) (rParent DomainCheckpoint, err error) { var buf []byte - args := DomainCheckpointGetParentArgs { + args := DomainCheckpointGetParentArgs{ Checkpoint: Checkpoint, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -16214,9 +16039,9 @@ func (l *Libvirt) DomainCheckpointGetParent(Checkpoint DomainCheckpoint, Flags u func (l *Libvirt) DomainCheckpointDelete(Checkpoint DomainCheckpoint, Flags DomainCheckpointDeleteFlags) (err error) { var buf []byte - args := DomainCheckpointDeleteArgs { + args := DomainCheckpointDeleteArgs{ Checkpoint: Checkpoint, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -16224,7 +16049,6 @@ func (l *Libvirt) DomainCheckpointDelete(Checkpoint DomainCheckpoint, Flags Doma return } - _, err = l.requestStream(417, constants.Program, buf, nil, nil) if err != nil { return @@ -16237,8 +16061,8 @@ func (l *Libvirt) DomainCheckpointDelete(Checkpoint DomainCheckpoint, Flags Doma func (l *Libvirt) DomainGetGuestInfo(Dom Domain, Types uint32, Flags uint32) (rParams []TypedParam, err error) { var buf []byte - args := DomainGetGuestInfoArgs { - Dom: Dom, + args := DomainGetGuestInfoArgs{ + Dom: Dom, Types: Types, Flags: Flags, } @@ -16272,9 +16096,9 @@ func (l *Libvirt) DomainGetGuestInfo(Dom Domain, Types uint32, Flags uint32) (rP func (l *Libvirt) ConnectSetIdentity(Params []TypedParam, Flags uint32) (err error) { var buf []byte - args := ConnectSetIdentityArgs { + args := ConnectSetIdentityArgs{ Params: Params, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -16282,7 +16106,6 @@ func (l *Libvirt) ConnectSetIdentity(Params []TypedParam, Flags uint32) (err err return } - _, err = l.requestStream(419, constants.Program, buf, nil, nil) if err != nil { return @@ -16295,10 +16118,10 @@ func (l *Libvirt) ConnectSetIdentity(Params []TypedParam, Flags uint32) (err err func (l *Libvirt) DomainAgentSetResponseTimeout(Dom Domain, Timeout int32, Flags uint32) (rResult int32, err error) { var buf []byte - args := DomainAgentSetResponseTimeoutArgs { - Dom: Dom, + args := DomainAgentSetResponseTimeoutArgs{ + Dom: Dom, Timeout: Timeout, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -16330,11 +16153,11 @@ func (l *Libvirt) DomainAgentSetResponseTimeout(Dom Domain, Timeout int32, Flags func (l *Libvirt) DomainBackupBegin(Dom Domain, BackupXML string, CheckpointXML OptString, Flags DomainBackupBeginFlags) (err error) { var buf []byte - args := DomainBackupBeginArgs { - Dom: Dom, - BackupXML: BackupXML, + args := DomainBackupBeginArgs{ + Dom: Dom, + BackupXML: BackupXML, CheckpointXML: CheckpointXML, - Flags: Flags, + Flags: Flags, } buf, err = encode(&args) @@ -16342,7 +16165,6 @@ func (l *Libvirt) DomainBackupBegin(Dom Domain, BackupXML string, CheckpointXML return } - _, err = l.requestStream(421, constants.Program, buf, nil, nil) if err != nil { return @@ -16355,8 +16177,8 @@ func (l *Libvirt) DomainBackupBegin(Dom Domain, BackupXML string, CheckpointXML func (l *Libvirt) DomainBackupGetXMLDesc(Dom Domain, Flags uint32) (rXML string, err error) { var buf []byte - args := DomainBackupGetXMLDescArgs { - Dom: Dom, + args := DomainBackupGetXMLDescArgs{ + Dom: Dom, Flags: Flags, } @@ -16389,7 +16211,6 @@ func (l *Libvirt) DomainBackupGetXMLDesc(Dom Domain, Flags uint32) (rXML string, func (l *Libvirt) DomainEventMemoryFailure() (err error) { var buf []byte - _, err = l.requestStream(423, constants.Program, buf, nil, nil) if err != nil { return @@ -16402,9 +16223,9 @@ func (l *Libvirt) DomainEventMemoryFailure() (err error) { func (l *Libvirt) DomainAuthorizedSshKeysGet(Dom Domain, User string, Flags uint32) (rKeys []string, err error) { var buf []byte - args := DomainAuthorizedSshKeysGetArgs { - Dom: Dom, - User: User, + args := DomainAuthorizedSshKeysGetArgs{ + Dom: Dom, + User: User, Flags: Flags, } @@ -16437,10 +16258,10 @@ func (l *Libvirt) DomainAuthorizedSshKeysGet(Dom Domain, User string, Flags uint func (l *Libvirt) DomainAuthorizedSshKeysSet(Dom Domain, User string, Keys []string, Flags uint32) (err error) { var buf []byte - args := DomainAuthorizedSshKeysSetArgs { - Dom: Dom, - User: User, - Keys: Keys, + args := DomainAuthorizedSshKeysSetArgs{ + Dom: Dom, + User: User, + Keys: Keys, Flags: Flags, } @@ -16449,7 +16270,6 @@ func (l *Libvirt) DomainAuthorizedSshKeysSet(Dom Domain, User string, Keys []str return } - _, err = l.requestStream(425, constants.Program, buf, nil, nil) if err != nil { return @@ -16462,8 +16282,8 @@ func (l *Libvirt) DomainAuthorizedSshKeysSet(Dom Domain, User string, Keys []str func (l *Libvirt) DomainGetMessages(Dom Domain, Flags uint32) (rMsgs []string, err error) { var buf []byte - args := DomainGetMessagesArgs { - Dom: Dom, + args := DomainGetMessagesArgs{ + Dom: Dom, Flags: Flags, } @@ -16491,4 +16311,3 @@ func (l *Libvirt) DomainGetMessages(Dom Domain, Flags uint32) (rMsgs []string, e return } - diff --git a/vendor/github.com/digitalocean/go-qemu/qmp/rpc.go b/vendor/github.com/digitalocean/go-qemu/qmp/rpc.go index dfedd2c59fd..4eceabdb3e1 100644 --- a/vendor/github.com/digitalocean/go-qemu/qmp/rpc.go +++ b/vendor/github.com/digitalocean/go-qemu/qmp/rpc.go @@ -84,6 +84,7 @@ func (rpc *LibvirtRPCMonitor) Events(ctx context.Context) (<-chan Event, error) // Run executes the given QAPI command against a domain's QEMU instance. // For a list of available QAPI commands, see: +// // http://git.qemu.org/?p=qemu.git;a=blob;f=qapi-schema.json;hb=HEAD func (rpc *LibvirtRPCMonitor) Run(cmd []byte) ([]byte, error) { return rpc.l.Run(rpc.Domain, cmd) diff --git a/vendor/github.com/digitalocean/go-qemu/qmp/socket.go b/vendor/github.com/digitalocean/go-qemu/qmp/socket.go index c929a77e3b9..4240e7ff8f6 100644 --- a/vendor/github.com/digitalocean/go-qemu/qmp/socket.go +++ b/vendor/github.com/digitalocean/go-qemu/qmp/socket.go @@ -58,6 +58,7 @@ type SocketMonitor struct { // dial attempt times out. // // NewSocketMonitor may dial the QEMU socket using a variety of connection types: +// // NewSocketMonitor("unix", "/var/lib/qemu/example.monitor", 2 * time.Second) // NewSocketMonitor("tcp", "8.8.8.8:4444", 2 * time.Second) func NewSocketMonitor(network, addr string, timeout time.Duration) (*SocketMonitor, error) { @@ -78,6 +79,7 @@ func NewSocketMonitor(network, addr string, timeout time.Duration) (*SocketMonit // An error is returned if unable to listen at the specified file path or port. // // Listen will wait for a QEMU socket connection using a variety connection types: +// // Listen("unix", "/var/lib/qemu/example.monitor") // Listen("tcp", "0.0.0.0:4444") func Listen(network, addr string) (*SocketMonitor, error) { @@ -203,6 +205,7 @@ func (mon *SocketMonitor) listen(r io.Reader, events chan<- Event, stream chan<- // Run executes the given QAPI command against a domain's QEMU instance. // For a list of available QAPI commands, see: +// // http://git.qemu.org/?p=qemu.git;a=blob;f=qapi-schema.json;hb=HEAD func (mon *SocketMonitor) Run(command []byte) ([]byte, error) { // Just call RunWithFile with no file diff --git a/vendor/github.com/digitalocean/go-qemu/qmp/socket_unix.go b/vendor/github.com/digitalocean/go-qemu/qmp/socket_unix.go index 859ff64ea23..3f997dcfc3f 100644 --- a/vendor/github.com/digitalocean/go-qemu/qmp/socket_unix.go +++ b/vendor/github.com/digitalocean/go-qemu/qmp/socket_unix.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +//go:build !windows // +build !windows package qmp diff --git a/vendor/github.com/digitalocean/go-qemu/qmp/socket_windows.go b/vendor/github.com/digitalocean/go-qemu/qmp/socket_windows.go index b8a611dbf06..c17d77a7cb7 100644 --- a/vendor/github.com/digitalocean/go-qemu/qmp/socket_windows.go +++ b/vendor/github.com/digitalocean/go-qemu/qmp/socket_windows.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +//go:build windows // +build windows package qmp diff --git a/vendor/github.com/disiqueira/gotree/v3/gotree.go b/vendor/github.com/disiqueira/gotree/v3/gotree.go index c529f62be0b..2cbf8b48595 100644 --- a/vendor/github.com/disiqueira/gotree/v3/gotree.go +++ b/vendor/github.com/disiqueira/gotree/v3/gotree.go @@ -37,7 +37,7 @@ type ( } ) -//New returns a new GoTree.Tree +// New returns a new GoTree.Tree func New(text string) Tree { return &tree{ text: text, @@ -45,29 +45,29 @@ func New(text string) Tree { } } -//Add adds a node to the tree +// Add adds a node to the tree func (t *tree) Add(text string) Tree { n := New(text) t.items = append(t.items, n) return n } -//AddTree adds a tree as an item +// AddTree adds a tree as an item func (t *tree) AddTree(tree Tree) { t.items = append(t.items, tree) } -//Text returns the node's value +// Text returns the node's value func (t *tree) Text() string { return t.text } -//Items returns all items in the tree +// Items returns all items in the tree func (t *tree) Items() []Tree { return t.items } -//Print returns an visual representation of the tree +// Print returns an visual representation of the tree func (t *tree) Print() string { return newPrinter().Print(t) } @@ -76,7 +76,7 @@ func newPrinter() Printer { return &printer{} } -//Print prints a tree to a string +// Print prints a tree to a string func (p *printer) Print(t Tree) string { return t.Text() + newLine + p.printItems(t.Items(), []bool{}) } diff --git a/vendor/github.com/felixge/httpsnoop/wrap_generated_gteq_1.8.go b/vendor/github.com/felixge/httpsnoop/wrap_generated_gteq_1.8.go index 101cedde674..cffd3d0526c 100644 --- a/vendor/github.com/felixge/httpsnoop/wrap_generated_gteq_1.8.go +++ b/vendor/github.com/felixge/httpsnoop/wrap_generated_gteq_1.8.go @@ -1,4 +1,6 @@ +//go:build go1.8 // +build go1.8 + // Code generated by "httpsnoop/codegen"; DO NOT EDIT. package httpsnoop diff --git a/vendor/github.com/felixge/httpsnoop/wrap_generated_lt_1.8.go b/vendor/github.com/felixge/httpsnoop/wrap_generated_lt_1.8.go index e0951df1527..c5ae196621a 100644 --- a/vendor/github.com/felixge/httpsnoop/wrap_generated_lt_1.8.go +++ b/vendor/github.com/felixge/httpsnoop/wrap_generated_lt_1.8.go @@ -1,4 +1,6 @@ +//go:build !go1.8 // +build !go1.8 + // Code generated by "httpsnoop/codegen"; DO NOT EDIT. package httpsnoop diff --git a/vendor/github.com/go-ole/go-ole/com.go b/vendor/github.com/go-ole/go-ole/com.go index cabbac0122c..dca260e1c56 100644 --- a/vendor/github.com/go-ole/go-ole/com.go +++ b/vendor/github.com/go-ole/go-ole/com.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/com_func.go b/vendor/github.com/go-ole/go-ole/com_func.go index cef539d9ddd..7b9fa67f3b2 100644 --- a/vendor/github.com/go-ole/go-ole/com_func.go +++ b/vendor/github.com/go-ole/go-ole/com_func.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package ole diff --git a/vendor/github.com/go-ole/go-ole/error_func.go b/vendor/github.com/go-ole/go-ole/error_func.go index 8a2ffaa2724..6478b3390b2 100644 --- a/vendor/github.com/go-ole/go-ole/error_func.go +++ b/vendor/github.com/go-ole/go-ole/error_func.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package ole diff --git a/vendor/github.com/go-ole/go-ole/error_windows.go b/vendor/github.com/go-ole/go-ole/error_windows.go index d0e8e68595c..8da277c05db 100644 --- a/vendor/github.com/go-ole/go-ole/error_windows.go +++ b/vendor/github.com/go-ole/go-ole/error_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/guid.go b/vendor/github.com/go-ole/go-ole/guid.go index 8d20f68fbf4..27f9557b3a6 100644 --- a/vendor/github.com/go-ole/go-ole/guid.go +++ b/vendor/github.com/go-ole/go-ole/guid.go @@ -108,9 +108,9 @@ type GUID struct { // // The supplied string may be in any of these formats: // -// XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX -// XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX -// {XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX} +// XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX +// XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX +// {XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX} // // The conversion of the supplied string is not case-sensitive. func NewGUID(guid string) *GUID { @@ -216,11 +216,11 @@ func decodeHexChar(c byte) (byte, bool) { // String converts the GUID to string form. It will adhere to this pattern: // -// {XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX} +// {XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX} // // If the GUID is nil, the string representation of an empty GUID is returned: // -// {00000000-0000-0000-0000-000000000000} +// {00000000-0000-0000-0000-000000000000} func (guid *GUID) String() string { if guid == nil { return emptyGUID diff --git a/vendor/github.com/go-ole/go-ole/iconnectionpoint_func.go b/vendor/github.com/go-ole/go-ole/iconnectionpoint_func.go index 5414dc3cd3b..999720a0d4b 100644 --- a/vendor/github.com/go-ole/go-ole/iconnectionpoint_func.go +++ b/vendor/github.com/go-ole/go-ole/iconnectionpoint_func.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package ole diff --git a/vendor/github.com/go-ole/go-ole/iconnectionpoint_windows.go b/vendor/github.com/go-ole/go-ole/iconnectionpoint_windows.go index 32bc183248d..c7325ad0b1e 100644 --- a/vendor/github.com/go-ole/go-ole/iconnectionpoint_windows.go +++ b/vendor/github.com/go-ole/go-ole/iconnectionpoint_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/iconnectionpointcontainer_func.go b/vendor/github.com/go-ole/go-ole/iconnectionpointcontainer_func.go index 5dfa42aaebb..26e264d1b65 100644 --- a/vendor/github.com/go-ole/go-ole/iconnectionpointcontainer_func.go +++ b/vendor/github.com/go-ole/go-ole/iconnectionpointcontainer_func.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package ole diff --git a/vendor/github.com/go-ole/go-ole/iconnectionpointcontainer_windows.go b/vendor/github.com/go-ole/go-ole/iconnectionpointcontainer_windows.go index ad30d79efc4..8b090f49e31 100644 --- a/vendor/github.com/go-ole/go-ole/iconnectionpointcontainer_windows.go +++ b/vendor/github.com/go-ole/go-ole/iconnectionpointcontainer_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/idispatch_func.go b/vendor/github.com/go-ole/go-ole/idispatch_func.go index b8fbbe319f1..5315505ae4c 100644 --- a/vendor/github.com/go-ole/go-ole/idispatch_func.go +++ b/vendor/github.com/go-ole/go-ole/idispatch_func.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package ole diff --git a/vendor/github.com/go-ole/go-ole/ienumvariant_func.go b/vendor/github.com/go-ole/go-ole/ienumvariant_func.go index c14848199cb..f332e439b72 100644 --- a/vendor/github.com/go-ole/go-ole/ienumvariant_func.go +++ b/vendor/github.com/go-ole/go-ole/ienumvariant_func.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package ole diff --git a/vendor/github.com/go-ole/go-ole/ienumvariant_windows.go b/vendor/github.com/go-ole/go-ole/ienumvariant_windows.go index 4781f3b8b00..72e5f31d6e1 100644 --- a/vendor/github.com/go-ole/go-ole/ienumvariant_windows.go +++ b/vendor/github.com/go-ole/go-ole/ienumvariant_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/iinspectable_func.go b/vendor/github.com/go-ole/go-ole/iinspectable_func.go index 348829bf062..cf0fba0dcbb 100644 --- a/vendor/github.com/go-ole/go-ole/iinspectable_func.go +++ b/vendor/github.com/go-ole/go-ole/iinspectable_func.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package ole diff --git a/vendor/github.com/go-ole/go-ole/iinspectable_windows.go b/vendor/github.com/go-ole/go-ole/iinspectable_windows.go index 4519a4aa449..9a686d256cb 100644 --- a/vendor/github.com/go-ole/go-ole/iinspectable_windows.go +++ b/vendor/github.com/go-ole/go-ole/iinspectable_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/iprovideclassinfo_func.go b/vendor/github.com/go-ole/go-ole/iprovideclassinfo_func.go index 7e3cb63ea73..90109f5576d 100644 --- a/vendor/github.com/go-ole/go-ole/iprovideclassinfo_func.go +++ b/vendor/github.com/go-ole/go-ole/iprovideclassinfo_func.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package ole diff --git a/vendor/github.com/go-ole/go-ole/iprovideclassinfo_windows.go b/vendor/github.com/go-ole/go-ole/iprovideclassinfo_windows.go index 2ad01639497..c758acd9bd7 100644 --- a/vendor/github.com/go-ole/go-ole/iprovideclassinfo_windows.go +++ b/vendor/github.com/go-ole/go-ole/iprovideclassinfo_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/itypeinfo_func.go b/vendor/github.com/go-ole/go-ole/itypeinfo_func.go index 8364a659bae..31c0677c6d8 100644 --- a/vendor/github.com/go-ole/go-ole/itypeinfo_func.go +++ b/vendor/github.com/go-ole/go-ole/itypeinfo_func.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package ole diff --git a/vendor/github.com/go-ole/go-ole/itypeinfo_windows.go b/vendor/github.com/go-ole/go-ole/itypeinfo_windows.go index 54782b3da5d..2abab82140c 100644 --- a/vendor/github.com/go-ole/go-ole/itypeinfo_windows.go +++ b/vendor/github.com/go-ole/go-ole/itypeinfo_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/iunknown_func.go b/vendor/github.com/go-ole/go-ole/iunknown_func.go index d0a62cfd730..247fccb3c94 100644 --- a/vendor/github.com/go-ole/go-ole/iunknown_func.go +++ b/vendor/github.com/go-ole/go-ole/iunknown_func.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package ole diff --git a/vendor/github.com/go-ole/go-ole/iunknown_windows.go b/vendor/github.com/go-ole/go-ole/iunknown_windows.go index ede5bb8c173..faf9c4c7fdf 100644 --- a/vendor/github.com/go-ole/go-ole/iunknown_windows.go +++ b/vendor/github.com/go-ole/go-ole/iunknown_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/oleutil/connection.go b/vendor/github.com/go-ole/go-ole/oleutil/connection.go index 60df73cda00..4c52d55ef0f 100644 --- a/vendor/github.com/go-ole/go-ole/oleutil/connection.go +++ b/vendor/github.com/go-ole/go-ole/oleutil/connection.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package oleutil diff --git a/vendor/github.com/go-ole/go-ole/oleutil/connection_func.go b/vendor/github.com/go-ole/go-ole/oleutil/connection_func.go index 8818fb8275a..b00ac4a92d9 100644 --- a/vendor/github.com/go-ole/go-ole/oleutil/connection_func.go +++ b/vendor/github.com/go-ole/go-ole/oleutil/connection_func.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package oleutil diff --git a/vendor/github.com/go-ole/go-ole/oleutil/connection_windows.go b/vendor/github.com/go-ole/go-ole/oleutil/connection_windows.go index ab9c0d8dcbd..19fa27e51d3 100644 --- a/vendor/github.com/go-ole/go-ole/oleutil/connection_windows.go +++ b/vendor/github.com/go-ole/go-ole/oleutil/connection_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package oleutil diff --git a/vendor/github.com/go-ole/go-ole/oleutil/go-get.go b/vendor/github.com/go-ole/go-ole/oleutil/go-get.go index 58347628f24..40bd9ff61bf 100644 --- a/vendor/github.com/go-ole/go-ole/oleutil/go-get.go +++ b/vendor/github.com/go-ole/go-ole/oleutil/go-get.go @@ -1,6 +1,7 @@ // This file is here so go get succeeds as without it errors with: // no buildable Go source files in ... // +//go:build !windows // +build !windows package oleutil diff --git a/vendor/github.com/go-ole/go-ole/safearray_func.go b/vendor/github.com/go-ole/go-ole/safearray_func.go index 0dee670ceb6..afb1d02d5e0 100644 --- a/vendor/github.com/go-ole/go-ole/safearray_func.go +++ b/vendor/github.com/go-ole/go-ole/safearray_func.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package ole diff --git a/vendor/github.com/go-ole/go-ole/safearray_windows.go b/vendor/github.com/go-ole/go-ole/safearray_windows.go index 0c1b3a10ff9..0a322f5da58 100644 --- a/vendor/github.com/go-ole/go-ole/safearray_windows.go +++ b/vendor/github.com/go-ole/go-ole/safearray_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/safearrayconversion.go b/vendor/github.com/go-ole/go-ole/safearrayconversion.go index da737293d7c..dde3e17e0ac 100644 --- a/vendor/github.com/go-ole/go-ole/safearrayconversion.go +++ b/vendor/github.com/go-ole/go-ole/safearrayconversion.go @@ -84,7 +84,7 @@ func (sac *SafeArrayConversion) ToValueArray() (values []interface{}) { safeArrayGetElement(sac.Array, i, unsafe.Pointer(&v)) values[i] = v case VT_BSTR: - v , _ := safeArrayGetElementString(sac.Array, i) + v, _ := safeArrayGetElementString(sac.Array, i) values[i] = v case VT_VARIANT: var v VARIANT diff --git a/vendor/github.com/go-ole/go-ole/safearrayslices.go b/vendor/github.com/go-ole/go-ole/safearrayslices.go index a9fa885f1d8..063dbbfec64 100644 --- a/vendor/github.com/go-ole/go-ole/safearrayslices.go +++ b/vendor/github.com/go-ole/go-ole/safearrayslices.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/variables.go b/vendor/github.com/go-ole/go-ole/variables.go index a6add1b0066..056f844d9a2 100644 --- a/vendor/github.com/go-ole/go-ole/variables.go +++ b/vendor/github.com/go-ole/go-ole/variables.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/variant_386.go b/vendor/github.com/go-ole/go-ole/variant_386.go index e73736bf391..2e3d3aa4aa2 100644 --- a/vendor/github.com/go-ole/go-ole/variant_386.go +++ b/vendor/github.com/go-ole/go-ole/variant_386.go @@ -1,3 +1,4 @@ +//go:build 386 // +build 386 package ole diff --git a/vendor/github.com/go-ole/go-ole/variant_amd64.go b/vendor/github.com/go-ole/go-ole/variant_amd64.go index dccdde13233..b48c3ce6fc0 100644 --- a/vendor/github.com/go-ole/go-ole/variant_amd64.go +++ b/vendor/github.com/go-ole/go-ole/variant_amd64.go @@ -1,3 +1,4 @@ +//go:build amd64 // +build amd64 package ole diff --git a/vendor/github.com/go-ole/go-ole/variant_arm.go b/vendor/github.com/go-ole/go-ole/variant_arm.go index d4724544437..5c8d492d620 100644 --- a/vendor/github.com/go-ole/go-ole/variant_arm.go +++ b/vendor/github.com/go-ole/go-ole/variant_arm.go @@ -1,3 +1,4 @@ +//go:build arm // +build arm package ole diff --git a/vendor/github.com/go-ole/go-ole/variant_date_386.go b/vendor/github.com/go-ole/go-ole/variant_date_386.go index 1b970f63f5f..8c3d3085fe4 100644 --- a/vendor/github.com/go-ole/go-ole/variant_date_386.go +++ b/vendor/github.com/go-ole/go-ole/variant_date_386.go @@ -1,3 +1,4 @@ +//go:build windows && 386 // +build windows,386 package ole diff --git a/vendor/github.com/go-ole/go-ole/variant_date_amd64.go b/vendor/github.com/go-ole/go-ole/variant_date_amd64.go index 6952f1f0de6..8554d38d919 100644 --- a/vendor/github.com/go-ole/go-ole/variant_date_amd64.go +++ b/vendor/github.com/go-ole/go-ole/variant_date_amd64.go @@ -1,3 +1,4 @@ +//go:build windows && amd64 // +build windows,amd64 package ole diff --git a/vendor/github.com/go-ole/go-ole/variant_date_arm.go b/vendor/github.com/go-ole/go-ole/variant_date_arm.go index 09ec7b5cfdf..7afe38b892f 100644 --- a/vendor/github.com/go-ole/go-ole/variant_date_arm.go +++ b/vendor/github.com/go-ole/go-ole/variant_date_arm.go @@ -1,3 +1,4 @@ +//go:build windows && arm // +build windows,arm package ole diff --git a/vendor/github.com/go-ole/go-ole/variant_ppc64le.go b/vendor/github.com/go-ole/go-ole/variant_ppc64le.go index 326427a7d14..4ce060d8fce 100644 --- a/vendor/github.com/go-ole/go-ole/variant_ppc64le.go +++ b/vendor/github.com/go-ole/go-ole/variant_ppc64le.go @@ -1,3 +1,4 @@ +//go:build ppc64le // +build ppc64le package ole diff --git a/vendor/github.com/go-ole/go-ole/variant_s390x.go b/vendor/github.com/go-ole/go-ole/variant_s390x.go index 9874ca66b4f..f83731098a0 100644 --- a/vendor/github.com/go-ole/go-ole/variant_s390x.go +++ b/vendor/github.com/go-ole/go-ole/variant_s390x.go @@ -1,3 +1,4 @@ +//go:build s390x // +build s390x package ole diff --git a/vendor/github.com/go-ole/go-ole/winrt.go b/vendor/github.com/go-ole/go-ole/winrt.go index 4e9eca73244..f503d685f53 100644 --- a/vendor/github.com/go-ole/go-ole/winrt.go +++ b/vendor/github.com/go-ole/go-ole/winrt.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package ole diff --git a/vendor/github.com/go-ole/go-ole/winrt_doc.go b/vendor/github.com/go-ole/go-ole/winrt_doc.go index 52e6d74c9ab..a392928d219 100644 --- a/vendor/github.com/go-ole/go-ole/winrt_doc.go +++ b/vendor/github.com/go-ole/go-ole/winrt_doc.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package ole diff --git a/vendor/github.com/go-task/slim-sprig/v3/functions.go b/vendor/github.com/go-task/slim-sprig/v3/functions.go index 5ea74f89930..32a3b07462f 100644 --- a/vendor/github.com/go-task/slim-sprig/v3/functions.go +++ b/vendor/github.com/go-task/slim-sprig/v3/functions.go @@ -18,8 +18,7 @@ import ( // // Use this to pass the functions into the template engine: // -// tpl := template.New("foo").Funcs(sprig.FuncMap())) -// +// tpl := template.New("foo").Funcs(sprig.FuncMap())) func FuncMap() template.FuncMap { return HtmlFuncMap() } diff --git a/vendor/github.com/gogo/protobuf/proto/lib.go b/vendor/github.com/gogo/protobuf/proto/lib.go index 80db1c155b5..10eec0d0ee5 100644 --- a/vendor/github.com/gogo/protobuf/proto/lib.go +++ b/vendor/github.com/gogo/protobuf/proto/lib.go @@ -39,35 +39,35 @@ for a protocol buffer variable v: - Names are turned from camel_case to CamelCase for export. - There are no methods on v to set fields; just treat - them as structure fields. + them as structure fields. - There are getters that return a field's value if set, - and return the field's default value if unset. - The getters work even if the receiver is a nil message. + and return the field's default value if unset. + The getters work even if the receiver is a nil message. - The zero value for a struct is its correct initialization state. - All desired fields must be set before marshaling. + All desired fields must be set before marshaling. - A Reset() method will restore a protobuf struct to its zero state. - Non-repeated fields are pointers to the values; nil means unset. - That is, optional or required field int32 f becomes F *int32. + That is, optional or required field int32 f becomes F *int32. - Repeated fields are slices. - Helper functions are available to aid the setting of fields. - msg.Foo = proto.String("hello") // set field + msg.Foo = proto.String("hello") // set field - Constants are defined to hold the default values of all fields that - have them. They have the form Default_StructName_FieldName. - Because the getter methods handle defaulted values, - direct use of these constants should be rare. + have them. They have the form Default_StructName_FieldName. + Because the getter methods handle defaulted values, + direct use of these constants should be rare. - Enums are given type names and maps from names to values. - Enum values are prefixed by the enclosing message's name, or by the - enum's type name if it is a top-level enum. Enum types have a String - method, and a Enum method to assist in message construction. + Enum values are prefixed by the enclosing message's name, or by the + enum's type name if it is a top-level enum. Enum types have a String + method, and a Enum method to assist in message construction. - Nested messages, groups and enums have type names prefixed with the name of - the surrounding message type. + the surrounding message type. - Extensions are given descriptor names that start with E_, - followed by an underscore-delimited list of the nested messages - that contain it (if any) followed by the CamelCased name of the - extension field itself. HasExtension, ClearExtension, GetExtension - and SetExtension are functions for manipulating extensions. + followed by an underscore-delimited list of the nested messages + that contain it (if any) followed by the CamelCased name of the + extension field itself. HasExtension, ClearExtension, GetExtension + and SetExtension are functions for manipulating extensions. - Oneof field sets are given a single field in their message, - with distinguished wrapper types for each possible field value. + with distinguished wrapper types for each possible field value. - Marshal and Unmarshal are functions to encode and decode the wire format. When the .proto file specifies `syntax="proto3"`, there are some differences: diff --git a/vendor/github.com/gogo/protobuf/proto/pointer_reflect.go b/vendor/github.com/gogo/protobuf/proto/pointer_reflect.go index b6cad90834b..461d58218af 100644 --- a/vendor/github.com/gogo/protobuf/proto/pointer_reflect.go +++ b/vendor/github.com/gogo/protobuf/proto/pointer_reflect.go @@ -29,6 +29,7 @@ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +//go:build purego || appengine || js // +build purego appengine js // This file contains an implementation of proto field accesses using package reflect. diff --git a/vendor/github.com/gogo/protobuf/proto/pointer_reflect_gogo.go b/vendor/github.com/gogo/protobuf/proto/pointer_reflect_gogo.go index 7ffd3c29d90..d6e07e2f719 100644 --- a/vendor/github.com/gogo/protobuf/proto/pointer_reflect_gogo.go +++ b/vendor/github.com/gogo/protobuf/proto/pointer_reflect_gogo.go @@ -26,6 +26,7 @@ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +//go:build purego || appengine || js // +build purego appengine js // This file contains an implementation of proto field accesses using package reflect. diff --git a/vendor/github.com/gogo/protobuf/proto/pointer_unsafe.go b/vendor/github.com/gogo/protobuf/proto/pointer_unsafe.go index d55a335d945..c998399ba71 100644 --- a/vendor/github.com/gogo/protobuf/proto/pointer_unsafe.go +++ b/vendor/github.com/gogo/protobuf/proto/pointer_unsafe.go @@ -29,6 +29,7 @@ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +//go:build !purego && !appengine && !js // +build !purego,!appengine,!js // This file contains the implementation of the proto field accesses using package unsafe. diff --git a/vendor/github.com/gogo/protobuf/proto/pointer_unsafe_gogo.go b/vendor/github.com/gogo/protobuf/proto/pointer_unsafe_gogo.go index aca8eed02a1..57a1496565f 100644 --- a/vendor/github.com/gogo/protobuf/proto/pointer_unsafe_gogo.go +++ b/vendor/github.com/gogo/protobuf/proto/pointer_unsafe_gogo.go @@ -26,6 +26,7 @@ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +//go:build !purego && !appengine && !js // +build !purego,!appengine,!js // This file contains the implementation of the proto field accesses using package unsafe. diff --git a/vendor/github.com/gogo/protobuf/proto/table_unmarshal.go b/vendor/github.com/gogo/protobuf/proto/table_unmarshal.go index 937229386a2..7c3e9e000ee 100644 --- a/vendor/github.com/gogo/protobuf/proto/table_unmarshal.go +++ b/vendor/github.com/gogo/protobuf/proto/table_unmarshal.go @@ -2004,12 +2004,14 @@ func makeUnmarshalMap(f *reflect.StructField) unmarshaler { // makeUnmarshalOneof makes an unmarshaler for oneof fields. // for: -// message Msg { -// oneof F { -// int64 X = 1; -// float64 Y = 2; -// } -// } +// +// message Msg { +// oneof F { +// int64 X = 1; +// float64 Y = 2; +// } +// } +// // typ is the type of the concrete entry for a oneof case (e.g. Msg_X). // ityp is the interface type of the oneof field (e.g. isMsg_F). // unmarshal is the unmarshaler for the base type of the oneof case (e.g. int64). diff --git a/vendor/github.com/google/shlex/shlex.go b/vendor/github.com/google/shlex/shlex.go index d98308bce38..04d2dedac81 100644 --- a/vendor/github.com/google/shlex/shlex.go +++ b/vendor/github.com/google/shlex/shlex.go @@ -20,22 +20,21 @@ shell-style rules for quoting and commenting. The basic use case uses the default ASCII lexer to split a string into sub-strings: - shlex.Split("one \"two three\" four") -> []string{"one", "two three", "four"} + shlex.Split("one \"two three\" four") -> []string{"one", "two three", "four"} To process a stream of strings: - l := NewLexer(os.Stdin) - for ; token, err := l.Next(); err != nil { - // process token - } + l := NewLexer(os.Stdin) + for ; token, err := l.Next(); err != nil { + // process token + } To access the raw token stream (which includes tokens for comments): - t := NewTokenizer(os.Stdin) - for ; token, err := t.Next(); err != nil { - // process token - } - + t := NewTokenizer(os.Stdin) + for ; token, err := t.Next(); err != nil { + // process token + } */ package shlex diff --git a/vendor/github.com/google/uuid/dce.go b/vendor/github.com/google/uuid/dce.go index fa820b9d309..9302a1c1bb5 100644 --- a/vendor/github.com/google/uuid/dce.go +++ b/vendor/github.com/google/uuid/dce.go @@ -42,7 +42,7 @@ func NewDCESecurity(domain Domain, id uint32) (UUID, error) { // NewDCEPerson returns a DCE Security (Version 2) UUID in the person // domain with the id returned by os.Getuid. // -// NewDCESecurity(Person, uint32(os.Getuid())) +// NewDCESecurity(Person, uint32(os.Getuid())) func NewDCEPerson() (UUID, error) { return NewDCESecurity(Person, uint32(os.Getuid())) } @@ -50,7 +50,7 @@ func NewDCEPerson() (UUID, error) { // NewDCEGroup returns a DCE Security (Version 2) UUID in the group // domain with the id returned by os.Getgid. // -// NewDCESecurity(Group, uint32(os.Getgid())) +// NewDCESecurity(Group, uint32(os.Getgid())) func NewDCEGroup() (UUID, error) { return NewDCESecurity(Group, uint32(os.Getgid())) } diff --git a/vendor/github.com/google/uuid/hash.go b/vendor/github.com/google/uuid/hash.go index dc60082d3b3..cee37578b3c 100644 --- a/vendor/github.com/google/uuid/hash.go +++ b/vendor/github.com/google/uuid/hash.go @@ -45,7 +45,7 @@ func NewHash(h hash.Hash, space UUID, data []byte, version int) UUID { // NewMD5 returns a new MD5 (Version 3) UUID based on the // supplied name space and data. It is the same as calling: // -// NewHash(md5.New(), space, data, 3) +// NewHash(md5.New(), space, data, 3) func NewMD5(space UUID, data []byte) UUID { return NewHash(md5.New(), space, data, 3) } @@ -53,7 +53,7 @@ func NewMD5(space UUID, data []byte) UUID { // NewSHA1 returns a new SHA1 (Version 5) UUID based on the // supplied name space and data. It is the same as calling: // -// NewHash(sha1.New(), space, data, 5) +// NewHash(sha1.New(), space, data, 5) func NewSHA1(space UUID, data []byte) UUID { return NewHash(sha1.New(), space, data, 5) } diff --git a/vendor/github.com/google/uuid/node_js.go b/vendor/github.com/google/uuid/node_js.go index b2a0bc8711b..f745d7017fc 100644 --- a/vendor/github.com/google/uuid/node_js.go +++ b/vendor/github.com/google/uuid/node_js.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build js // +build js package uuid diff --git a/vendor/github.com/google/uuid/node_net.go b/vendor/github.com/google/uuid/node_net.go index 0cbbcddbd6e..e91358f7d9e 100644 --- a/vendor/github.com/google/uuid/node_net.go +++ b/vendor/github.com/google/uuid/node_net.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build !js // +build !js package uuid diff --git a/vendor/github.com/google/uuid/null.go b/vendor/github.com/google/uuid/null.go index d7fcbf28651..06ecf9de2af 100644 --- a/vendor/github.com/google/uuid/null.go +++ b/vendor/github.com/google/uuid/null.go @@ -17,15 +17,14 @@ var jsonNull = []byte("null") // NullUUID implements the SQL driver.Scanner interface so // it can be used as a scan destination: // -// var u uuid.NullUUID -// err := db.QueryRow("SELECT name FROM foo WHERE id=?", id).Scan(&u) -// ... -// if u.Valid { -// // use u.UUID -// } else { -// // NULL value -// } -// +// var u uuid.NullUUID +// err := db.QueryRow("SELECT name FROM foo WHERE id=?", id).Scan(&u) +// ... +// if u.Valid { +// // use u.UUID +// } else { +// // NULL value +// } type NullUUID struct { UUID UUID Valid bool // Valid is true if UUID is not NULL diff --git a/vendor/github.com/google/uuid/uuid.go b/vendor/github.com/google/uuid/uuid.go index 5232b486780..1051192bc51 100644 --- a/vendor/github.com/google/uuid/uuid.go +++ b/vendor/github.com/google/uuid/uuid.go @@ -187,10 +187,12 @@ func Must(uuid UUID, err error) UUID { } // Validate returns an error if s is not a properly formatted UUID in one of the following formats: -// xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx -// urn:uuid:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx -// xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx -// {xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx} +// +// xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx +// urn:uuid:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx +// xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx +// {xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx} +// // It returns an error if the format is invalid, otherwise nil. func Validate(s string) error { switch len(s) { diff --git a/vendor/github.com/google/uuid/version4.go b/vendor/github.com/google/uuid/version4.go index 7697802e4d1..62ac273815c 100644 --- a/vendor/github.com/google/uuid/version4.go +++ b/vendor/github.com/google/uuid/version4.go @@ -9,7 +9,7 @@ import "io" // New creates a new random UUID or panics. New is equivalent to // the expression // -// uuid.Must(uuid.NewRandom()) +// uuid.Must(uuid.NewRandom()) func New() UUID { return Must(NewRandom()) } @@ -17,7 +17,7 @@ func New() UUID { // NewString creates a new random UUID and returns it as a string or panics. // NewString is equivalent to the expression // -// uuid.New().String() +// uuid.New().String() func NewString() string { return Must(NewRandom()).String() } @@ -31,11 +31,11 @@ func NewString() string { // // A note about uniqueness derived from the UUID Wikipedia entry: // -// Randomly generated UUIDs have 122 random bits. One's annual risk of being -// hit by a meteorite is estimated to be one chance in 17 billion, that -// means the probability is about 0.00000000006 (6 × 10−11), -// equivalent to the odds of creating a few tens of trillions of UUIDs in a -// year and having one duplicate. +// Randomly generated UUIDs have 122 random bits. One's annual risk of being +// hit by a meteorite is estimated to be one chance in 17 billion, that +// means the probability is about 0.00000000006 (6 × 10−11), +// equivalent to the odds of creating a few tens of trillions of UUIDs in a +// year and having one duplicate. func NewRandom() (UUID, error) { if !poolEnabled { return NewRandomFromReader(rander) diff --git a/vendor/github.com/gorilla/schema/doc.go b/vendor/github.com/gorilla/schema/doc.go index aae9f33f9d7..fff0fe76168 100644 --- a/vendor/github.com/gorilla/schema/doc.go +++ b/vendor/github.com/gorilla/schema/doc.go @@ -60,14 +60,14 @@ certain fields, use a dash for the name and it will be ignored: The supported field types in the destination struct are: - * bool - * float variants (float32, float64) - * int variants (int, int8, int16, int32, int64) - * string - * uint variants (uint, uint8, uint16, uint32, uint64) - * struct - * a pointer to one of the above types - * a slice or a pointer to a slice of one of the above types + - bool + - float variants (float32, float64) + - int variants (int, int8, int16, int32, int64) + - string + - uint variants (uint, uint8, uint16, uint32, uint64) + - struct + - a pointer to one of the above types + - a slice or a pointer to a slice of one of the above types Non-supported types are simply ignored, however custom types can be registered to be converted. diff --git a/vendor/github.com/hashicorp/go-cleanhttp/doc.go b/vendor/github.com/hashicorp/go-cleanhttp/doc.go index 05841092a7b..905859c7fe2 100644 --- a/vendor/github.com/hashicorp/go-cleanhttp/doc.go +++ b/vendor/github.com/hashicorp/go-cleanhttp/doc.go @@ -16,5 +16,4 @@ // connecting to the same hosts repeatedly from the same client, you can use // DefaultPooledClient to receive a client that has connection pooling // semantics similar to http.DefaultClient. -// package cleanhttp diff --git a/vendor/github.com/json-iterator/go/iter_float.go b/vendor/github.com/json-iterator/go/iter_float.go index 8a3d8b6fb43..caf16feec89 100644 --- a/vendor/github.com/json-iterator/go/iter_float.go +++ b/vendor/github.com/json-iterator/go/iter_float.go @@ -66,7 +66,7 @@ func (iter *Iterator) ReadBigInt() (ret *big.Int) { return ret } -//ReadFloat32 read float32 +// ReadFloat32 read float32 func (iter *Iterator) ReadFloat32() (ret float32) { c := iter.nextToken() if c == '-' { diff --git a/vendor/github.com/json-iterator/go/iter_skip_sloppy.go b/vendor/github.com/json-iterator/go/iter_skip_sloppy.go index 9303de41e40..3d993f27731 100644 --- a/vendor/github.com/json-iterator/go/iter_skip_sloppy.go +++ b/vendor/github.com/json-iterator/go/iter_skip_sloppy.go @@ -1,4 +1,5 @@ -//+build jsoniter_sloppy +//go:build jsoniter_sloppy +// +build jsoniter_sloppy package jsoniter diff --git a/vendor/github.com/json-iterator/go/iter_skip_strict.go b/vendor/github.com/json-iterator/go/iter_skip_strict.go index 6cf66d0438d..f1ad6591bb0 100644 --- a/vendor/github.com/json-iterator/go/iter_skip_strict.go +++ b/vendor/github.com/json-iterator/go/iter_skip_strict.go @@ -1,4 +1,5 @@ -//+build !jsoniter_sloppy +//go:build !jsoniter_sloppy +// +build !jsoniter_sloppy package jsoniter diff --git a/vendor/github.com/linuxkit/virtsock/pkg/hvsock/hvsock_fallback.go b/vendor/github.com/linuxkit/virtsock/pkg/hvsock/hvsock_fallback.go index 050419bd365..803e76c36c8 100644 --- a/vendor/github.com/linuxkit/virtsock/pkg/hvsock/hvsock_fallback.go +++ b/vendor/github.com/linuxkit/virtsock/pkg/hvsock/hvsock_fallback.go @@ -1,3 +1,4 @@ +//go:build !linux && !windows // +build !linux,!windows package hvsock diff --git a/vendor/github.com/manifoldco/promptui/keycodes_other.go b/vendor/github.com/manifoldco/promptui/keycodes_other.go index 789feae4c08..d6b00cd318b 100644 --- a/vendor/github.com/manifoldco/promptui/keycodes_other.go +++ b/vendor/github.com/manifoldco/promptui/keycodes_other.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package promptui diff --git a/vendor/github.com/manifoldco/promptui/keycodes_windows.go b/vendor/github.com/manifoldco/promptui/keycodes_windows.go index 737d1566ef5..9919f3a9afe 100644 --- a/vendor/github.com/manifoldco/promptui/keycodes_windows.go +++ b/vendor/github.com/manifoldco/promptui/keycodes_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package promptui diff --git a/vendor/github.com/manifoldco/promptui/prompt.go b/vendor/github.com/manifoldco/promptui/prompt.go index 8e35123b058..9719ecc90f7 100644 --- a/vendor/github.com/manifoldco/promptui/prompt.go +++ b/vendor/github.com/manifoldco/promptui/prompt.go @@ -58,19 +58,22 @@ type Prompt struct { // text/template syntax. Custom state, colors and background color are available for use inside // the templates and are documented inside the Variable section of the docs. // -// Examples +// # Examples // // text/templates use a special notation to display programmable content. Using the double bracket notation, // the value can be printed with specific helper functions. For example // // This displays the value given to the template as pure, unstylized text. -// '{{ . }}' +// +// '{{ . }}' // // This displays the value colored in cyan -// '{{ . | cyan }}' +// +// '{{ . | cyan }}' // // This displays the value colored in red with a cyan background-color -// '{{ . | red | cyan }}' +// +// '{{ . | red | cyan }}' // // See the doc of text/template for more info: https://golang.org/pkg/text/template/ type PromptTemplates struct { diff --git a/vendor/github.com/manifoldco/promptui/select.go b/vendor/github.com/manifoldco/promptui/select.go index b58ed9734ca..ccb0df6cb90 100644 --- a/vendor/github.com/manifoldco/promptui/select.go +++ b/vendor/github.com/manifoldco/promptui/select.go @@ -116,24 +116,27 @@ type Key struct { // text/template syntax. Custom state, colors and background color are available for use inside // the templates and are documented inside the Variable section of the docs. // -// Examples +// # Examples // // text/templates use a special notation to display programmable content. Using the double bracket notation, // the value can be printed with specific helper functions. For example // // This displays the value given to the template as pure, unstylized text. Structs are transformed to string // with this notation. -// '{{ . }}' +// +// '{{ . }}' // // This displays the name property of the value colored in cyan -// '{{ .Name | cyan }}' +// +// '{{ .Name | cyan }}' // // This displays the label property of value colored in red with a cyan background-color -// '{{ .Label | red | cyan }}' +// +// '{{ .Label | red | cyan }}' // // See the doc of text/template for more info: https://golang.org/pkg/text/template/ // -// Notes +// # Notes // // Setting any of these templates will remove the icons from the default templates. They must // be added back in each of their specific templates. The styles.go constants contains the default icons. diff --git a/vendor/github.com/manifoldco/promptui/styles.go b/vendor/github.com/manifoldco/promptui/styles.go index d7698c9cf87..c7400ee6e0c 100644 --- a/vendor/github.com/manifoldco/promptui/styles.go +++ b/vendor/github.com/manifoldco/promptui/styles.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package promptui diff --git a/vendor/github.com/mattn/go-shellwords/util_posix.go b/vendor/github.com/mattn/go-shellwords/util_posix.go index b56a90120a9..4d6b924bbe1 100644 --- a/vendor/github.com/mattn/go-shellwords/util_posix.go +++ b/vendor/github.com/mattn/go-shellwords/util_posix.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows package shellwords diff --git a/vendor/github.com/mattn/go-shellwords/util_windows.go b/vendor/github.com/mattn/go-shellwords/util_windows.go index fd738a72112..0a650f56b02 100644 --- a/vendor/github.com/mattn/go-shellwords/util_windows.go +++ b/vendor/github.com/mattn/go-shellwords/util_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package shellwords diff --git a/vendor/github.com/miekg/pkcs11/params.go b/vendor/github.com/miekg/pkcs11/params.go index 6d9ce96ae8f..a874483f701 100644 --- a/vendor/github.com/miekg/pkcs11/params.go +++ b/vendor/github.com/miekg/pkcs11/params.go @@ -50,13 +50,12 @@ type GCMParams struct { // // Encrypt/Decrypt. As an example: // -// gcmParams := pkcs11.NewGCMParams(make([]byte, 12), nil, 128) -// p.ctx.EncryptInit(session, []*pkcs11.Mechanism{pkcs11.NewMechanism(pkcs11.CKM_AES_GCM, gcmParams)}, -// aesObjHandle) -// ct, _ := p.ctx.Encrypt(session, pt) -// iv := gcmParams.IV() -// gcmParams.Free() -// +// gcmParams := pkcs11.NewGCMParams(make([]byte, 12), nil, 128) +// p.ctx.EncryptInit(session, []*pkcs11.Mechanism{pkcs11.NewMechanism(pkcs11.CKM_AES_GCM, gcmParams)}, +// aesObjHandle) +// ct, _ := p.ctx.Encrypt(session, pt) +// iv := gcmParams.IV() +// gcmParams.Free() func NewGCMParams(iv, aad []byte, tagSize int) *GCMParams { return &GCMParams{ iv: iv, diff --git a/vendor/github.com/modern-go/concurrent/go_above_19.go b/vendor/github.com/modern-go/concurrent/go_above_19.go index aeabf8c4f9c..7db70194549 100644 --- a/vendor/github.com/modern-go/concurrent/go_above_19.go +++ b/vendor/github.com/modern-go/concurrent/go_above_19.go @@ -1,4 +1,5 @@ -//+build go1.9 +//go:build go1.9 +// +build go1.9 package concurrent diff --git a/vendor/github.com/modern-go/concurrent/go_below_19.go b/vendor/github.com/modern-go/concurrent/go_below_19.go index b9c8df7f410..64544f5b35b 100644 --- a/vendor/github.com/modern-go/concurrent/go_below_19.go +++ b/vendor/github.com/modern-go/concurrent/go_below_19.go @@ -1,4 +1,5 @@ -//+build !go1.9 +//go:build !go1.9 +// +build !go1.9 package concurrent diff --git a/vendor/github.com/modern-go/concurrent/log.go b/vendor/github.com/modern-go/concurrent/log.go index 9756fcc75a7..4899eed026d 100644 --- a/vendor/github.com/modern-go/concurrent/log.go +++ b/vendor/github.com/modern-go/concurrent/log.go @@ -1,13 +1,13 @@ package concurrent import ( - "os" - "log" "io/ioutil" + "log" + "os" ) // ErrorLogger is used to print out error, can be set to writer other than stderr var ErrorLogger = log.New(os.Stderr, "", 0) // InfoLogger is used to print informational message, default to off -var InfoLogger = log.New(ioutil.Discard, "", 0) \ No newline at end of file +var InfoLogger = log.New(ioutil.Discard, "", 0) diff --git a/vendor/github.com/modern-go/concurrent/unbounded_executor.go b/vendor/github.com/modern-go/concurrent/unbounded_executor.go index 05a77dceb1e..5ea18eb7bf9 100644 --- a/vendor/github.com/modern-go/concurrent/unbounded_executor.go +++ b/vendor/github.com/modern-go/concurrent/unbounded_executor.go @@ -3,11 +3,11 @@ package concurrent import ( "context" "fmt" + "reflect" "runtime" "runtime/debug" "sync" "time" - "reflect" ) // HandlePanic logs goroutine panic by default diff --git a/vendor/github.com/modern-go/reflect2/go_above_118.go b/vendor/github.com/modern-go/reflect2/go_above_118.go index 2b4116f6c9b..33c825f6d51 100644 --- a/vendor/github.com/modern-go/reflect2/go_above_118.go +++ b/vendor/github.com/modern-go/reflect2/go_above_118.go @@ -1,4 +1,5 @@ -//+build go1.18 +//go:build go1.18 +// +build go1.18 package reflect2 @@ -8,6 +9,7 @@ import ( // m escapes into the return value, but the caller of mapiterinit // doesn't let the return value escape. +// //go:noescape //go:linkname mapiterinit reflect.mapiterinit func mapiterinit(rtype unsafe.Pointer, m unsafe.Pointer, it *hiter) @@ -20,4 +22,4 @@ func (type2 *UnsafeMapType) UnsafeIterate(obj unsafe.Pointer) MapIterator { pKeyRType: type2.pKeyRType, pElemRType: type2.pElemRType, } -} \ No newline at end of file +} diff --git a/vendor/github.com/modern-go/reflect2/go_above_19.go b/vendor/github.com/modern-go/reflect2/go_above_19.go index 974f7685e49..03ccb43c65b 100644 --- a/vendor/github.com/modern-go/reflect2/go_above_19.go +++ b/vendor/github.com/modern-go/reflect2/go_above_19.go @@ -1,4 +1,5 @@ -//+build go1.9 +//go:build go1.9 +// +build go1.9 package reflect2 diff --git a/vendor/github.com/modern-go/reflect2/go_below_118.go b/vendor/github.com/modern-go/reflect2/go_below_118.go index 00003dbd7c5..092ec5b5d29 100644 --- a/vendor/github.com/modern-go/reflect2/go_below_118.go +++ b/vendor/github.com/modern-go/reflect2/go_below_118.go @@ -1,4 +1,5 @@ -//+build !go1.18 +//go:build !go1.18 +// +build !go1.18 package reflect2 @@ -8,6 +9,7 @@ import ( // m escapes into the return value, but the caller of mapiterinit // doesn't let the return value escape. +// //go:noescape //go:linkname mapiterinit reflect.mapiterinit func mapiterinit(rtype unsafe.Pointer, m unsafe.Pointer) (val *hiter) @@ -18,4 +20,4 @@ func (type2 *UnsafeMapType) UnsafeIterate(obj unsafe.Pointer) MapIterator { pKeyRType: type2.pKeyRType, pElemRType: type2.pElemRType, } -} \ No newline at end of file +} diff --git a/vendor/github.com/modern-go/reflect2/reflect2.go b/vendor/github.com/modern-go/reflect2/reflect2.go index c43c8b9d629..b0c281fcac7 100644 --- a/vendor/github.com/modern-go/reflect2/reflect2.go +++ b/vendor/github.com/modern-go/reflect2/reflect2.go @@ -282,6 +282,7 @@ func likePtrType(typ reflect.Type) bool { // output depends on the input. noescape is inlined and currently // compiles down to zero instructions. // USE CAREFULLY! +// //go:nosplit func NoEscape(p unsafe.Pointer) unsafe.Pointer { x := uintptr(p) diff --git a/vendor/github.com/modern-go/reflect2/type_map.go b/vendor/github.com/modern-go/reflect2/type_map.go index 4b13c3155c8..54c8498ef1d 100644 --- a/vendor/github.com/modern-go/reflect2/type_map.go +++ b/vendor/github.com/modern-go/reflect2/type_map.go @@ -1,3 +1,4 @@ +//go:build !gccgo // +build !gccgo package reflect2 @@ -9,6 +10,7 @@ import ( ) // typelinks2 for 1.7 ~ +// //go:linkname typelinks2 reflect.typelinks func typelinks2() (sections []unsafe.Pointer, offset [][]int32) diff --git a/vendor/github.com/modern-go/reflect2/unsafe_link.go b/vendor/github.com/modern-go/reflect2/unsafe_link.go index b49f614efc5..61849bb426f 100644 --- a/vendor/github.com/modern-go/reflect2/unsafe_link.go +++ b/vendor/github.com/modern-go/reflect2/unsafe_link.go @@ -13,6 +13,7 @@ func unsafe_NewArray(rtype unsafe.Pointer, length int) unsafe.Pointer // typedslicecopy copies a slice of elemType values from src to dst, // returning the number of elements copied. +// //go:linkname typedslicecopy reflect.typedslicecopy //go:noescape func typedslicecopy(elemType unsafe.Pointer, dst, src sliceHeader) int diff --git a/vendor/github.com/nxadm/tail/tail.go b/vendor/github.com/nxadm/tail/tail.go index c962599be32..ede0ccc410d 100644 --- a/vendor/github.com/nxadm/tail/tail.go +++ b/vendor/github.com/nxadm/tail/tail.go @@ -2,11 +2,11 @@ // Copyright (c) 2015 HPE Software Inc. All rights reserved. // Copyright (c) 2013 ActiveState Software Inc. All rights reserved. -//nxadm/tail provides a Go library that emulates the features of the BSD `tail` -//program. The library comes with full support for truncation/move detection as -//it is designed to work with log rotation tools. The library works on all -//operating systems supported by Go, including POSIX systems like Linux and -//*BSD, and MS Windows. Go 1.9 is the oldest compiler release supported. +// nxadm/tail provides a Go library that emulates the features of the BSD `tail` +// program. The library comes with full support for truncation/move detection as +// it is designed to work with log rotation tools. The library works on all +// operating systems supported by Go, including POSIX systems like Linux and +// *BSD, and MS Windows. Go 1.9 is the oldest compiler release supported. package tail import ( diff --git a/vendor/github.com/nxadm/tail/tail_posix.go b/vendor/github.com/nxadm/tail/tail_posix.go index 23e071dea16..ca7e2404f91 100644 --- a/vendor/github.com/nxadm/tail/tail_posix.go +++ b/vendor/github.com/nxadm/tail/tail_posix.go @@ -1,4 +1,5 @@ // Copyright (c) 2019 FOSS contributors of https://github.com/nxadm/tail +//go:build !windows // +build !windows package tail diff --git a/vendor/github.com/nxadm/tail/tail_windows.go b/vendor/github.com/nxadm/tail/tail_windows.go index da0d2f39c97..0cbab7d2061 100644 --- a/vendor/github.com/nxadm/tail/tail_windows.go +++ b/vendor/github.com/nxadm/tail/tail_windows.go @@ -1,4 +1,5 @@ // Copyright (c) 2019 FOSS contributors of https://github.com/nxadm/tail +//go:build windows // +build windows package tail diff --git a/vendor/github.com/nxadm/tail/watch/inotify.go b/vendor/github.com/nxadm/tail/watch/inotify.go index cbd11ad8d03..281e6bd6e48 100644 --- a/vendor/github.com/nxadm/tail/watch/inotify.go +++ b/vendor/github.com/nxadm/tail/watch/inotify.go @@ -11,7 +11,7 @@ import ( "github.com/nxadm/tail/util" - "github.com/fsnotify/fsnotify" + "github.com/fsnotify/fsnotify" "gopkg.in/tomb.v1" ) diff --git a/vendor/github.com/nxadm/tail/watch/inotify_tracker.go b/vendor/github.com/nxadm/tail/watch/inotify_tracker.go index cb9572a0302..57da0c09733 100644 --- a/vendor/github.com/nxadm/tail/watch/inotify_tracker.go +++ b/vendor/github.com/nxadm/tail/watch/inotify_tracker.go @@ -13,7 +13,7 @@ import ( "github.com/nxadm/tail/util" - "github.com/fsnotify/fsnotify" + "github.com/fsnotify/fsnotify" ) type InotifyTracker struct { diff --git a/vendor/github.com/nxadm/tail/winfile/winfile.go b/vendor/github.com/nxadm/tail/winfile/winfile.go index 4562ac7c25c..0c4f19900e0 100644 --- a/vendor/github.com/nxadm/tail/winfile/winfile.go +++ b/vendor/github.com/nxadm/tail/winfile/winfile.go @@ -1,4 +1,5 @@ // Copyright (c) 2019 FOSS contributors of https://github.com/nxadm/tail +//go:build windows // +build windows package winfile diff --git a/vendor/github.com/onsi/ginkgo/v2/formatter/colorable_others.go b/vendor/github.com/onsi/ginkgo/v2/formatter/colorable_others.go index 778bfd7c7ca..5576890540d 100644 --- a/vendor/github.com/onsi/ginkgo/v2/formatter/colorable_others.go +++ b/vendor/github.com/onsi/ginkgo/v2/formatter/colorable_others.go @@ -1,3 +1,4 @@ +//go:build !windows // +build !windows /* diff --git a/vendor/github.com/onsi/ginkgo/v2/ginkgo/main.go b/vendor/github.com/onsi/ginkgo/v2/ginkgo/main.go index 419589b48c5..cae532574bf 100644 --- a/vendor/github.com/onsi/ginkgo/v2/ginkgo/main.go +++ b/vendor/github.com/onsi/ginkgo/v2/ginkgo/main.go @@ -2,7 +2,6 @@ package main import ( "fmt" - "os" "github.com/onsi/ginkgo/v2/ginkgo/build" "github.com/onsi/ginkgo/v2/ginkgo/command" "github.com/onsi/ginkgo/v2/ginkgo/generators" @@ -12,6 +11,7 @@ import ( "github.com/onsi/ginkgo/v2/ginkgo/unfocus" "github.com/onsi/ginkgo/v2/ginkgo/watch" "github.com/onsi/ginkgo/v2/types" + "os" ) var program command.Program diff --git a/vendor/github.com/onsi/ginkgo/v2/internal/output_interceptor_win.go b/vendor/github.com/onsi/ginkgo/v2/internal/output_interceptor_win.go index 30c2851a818..9ea845fc3e9 100644 --- a/vendor/github.com/onsi/ginkgo/v2/internal/output_interceptor_win.go +++ b/vendor/github.com/onsi/ginkgo/v2/internal/output_interceptor_win.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package internal diff --git a/vendor/github.com/onsi/ginkgo/v2/internal/reporters/gojson.go b/vendor/github.com/onsi/ginkgo/v2/internal/reporters/gojson.go index 8b7a9ceabf7..cf05af7ab7f 100644 --- a/vendor/github.com/onsi/ginkgo/v2/internal/reporters/gojson.go +++ b/vendor/github.com/onsi/ginkgo/v2/internal/reporters/gojson.go @@ -83,7 +83,7 @@ func goJSONActionFromSpecState(state types.SpecState) GoJSONAction { type gojsonReport struct { o types.Report // Extra calculated fields - goPkg string + goPkg string elapsed float64 } @@ -109,8 +109,8 @@ type gojsonSpecReport struct { o types.SpecReport // extra calculated fields testName string - elapsed float64 - action GoJSONAction + elapsed float64 + action GoJSONAction } func newSpecReport(in types.SpecReport) *gojsonSpecReport { @@ -141,18 +141,18 @@ func suitePathToPkg(dir string) (string, error) { } func createTestName(spec types.SpecReport) string { - name := fmt.Sprintf("[%s]", spec.LeafNodeType) - if spec.FullText() != "" { - name = name + " " + spec.FullText() - } - labels := spec.Labels() - if len(labels) > 0 { - name = name + " [" + strings.Join(labels, ", ") + "]" - } - semVerConstraints := spec.SemVerConstraints() - if len(semVerConstraints) > 0 { - name = name + " [" + strings.Join(semVerConstraints, ", ") + "]" - } - name = strings.TrimSpace(name) - return name + name := fmt.Sprintf("[%s]", spec.LeafNodeType) + if spec.FullText() != "" { + name = name + " " + spec.FullText() + } + labels := spec.Labels() + if len(labels) > 0 { + name = name + " [" + strings.Join(labels, ", ") + "]" + } + semVerConstraints := spec.SemVerConstraints() + if len(semVerConstraints) > 0 { + name = name + " [" + strings.Join(semVerConstraints, ", ") + "]" + } + name = strings.TrimSpace(name) + return name } diff --git a/vendor/github.com/onsi/ginkgo/v2/internal/reporters/gojson_event_writer.go b/vendor/github.com/onsi/ginkgo/v2/internal/reporters/gojson_event_writer.go index ec5311d069c..7760a0c3a8b 100644 --- a/vendor/github.com/onsi/ginkgo/v2/internal/reporters/gojson_event_writer.go +++ b/vendor/github.com/onsi/ginkgo/v2/internal/reporters/gojson_event_writer.go @@ -1,14 +1,14 @@ package reporters type GoJSONEventWriter struct { - enc encoder + enc encoder specSystemErrFn specSystemExtractFn specSystemOutFn specSystemExtractFn } func NewGoJSONEventWriter(enc encoder, errFn specSystemExtractFn, outFn specSystemExtractFn) *GoJSONEventWriter { return &GoJSONEventWriter{ - enc: enc, + enc: enc, specSystemErrFn: errFn, specSystemOutFn: outFn, } diff --git a/vendor/github.com/onsi/ginkgo/v2/internal/reporters/gojson_reporter.go b/vendor/github.com/onsi/ginkgo/v2/internal/reporters/gojson_reporter.go index 633e49b88d5..6eb9a8b299d 100644 --- a/vendor/github.com/onsi/ginkgo/v2/internal/reporters/gojson_reporter.go +++ b/vendor/github.com/onsi/ginkgo/v2/internal/reporters/gojson_reporter.go @@ -8,7 +8,7 @@ type GoJSONReporter struct { ev *GoJSONEventWriter } -type specSystemExtractFn func (spec types.SpecReport) string +type specSystemExtractFn func(spec types.SpecReport) string func NewGoJSONReporter(enc encoder, errFn specSystemExtractFn, outFn specSystemExtractFn) *GoJSONReporter { return &GoJSONReporter{ diff --git a/vendor/github.com/onsi/gomega/gstruct/fields.go b/vendor/github.com/onsi/gomega/gstruct/fields.go index 2f4685fc488..0427f16ab66 100644 --- a/vendor/github.com/onsi/gomega/gstruct/fields.go +++ b/vendor/github.com/onsi/gomega/gstruct/fields.go @@ -64,10 +64,10 @@ func MatchAllFields(fields Fields) types.GomegaMatcher { // })) func MatchFields(options Options, fields Fields) types.GomegaMatcher { return &FieldsMatcher{ - Fields: fields, - IgnoreExtras: options&IgnoreExtras != 0, + Fields: fields, + IgnoreExtras: options&IgnoreExtras != 0, IgnoreUnexportedExtras: options&IgnoreUnexportedExtras != 0, - IgnoreMissing: options&IgnoreMissing != 0, + IgnoreMissing: options&IgnoreMissing != 0, } } @@ -138,8 +138,8 @@ func (m *FieldsMatcher) matchFields(actual any) (errs []error) { } var field any - if _, isIgnoreMatcher := matcher.(*IgnoreMatcher) ; isIgnoreMatcher { - field = struct {}{} // the matcher does not care about the actual value + if _, isIgnoreMatcher := matcher.(*IgnoreMatcher); isIgnoreMatcher { + field = struct{}{} // the matcher does not care about the actual value } else { field = val.Field(i).Interface() } diff --git a/vendor/github.com/opencontainers/go-digest/digest.go b/vendor/github.com/opencontainers/go-digest/digest.go index 518b5e71545..465996ce6cf 100644 --- a/vendor/github.com/opencontainers/go-digest/digest.go +++ b/vendor/github.com/opencontainers/go-digest/digest.go @@ -30,7 +30,7 @@ import ( // // The following is an example of the contents of Digest types: // -// sha256:7173b809ca12ec5dee4506cd86be934c4596dd234ee82c0662eac04a8c2c71dc +// sha256:7173b809ca12ec5dee4506cd86be934c4596dd234ee82c0662eac04a8c2c71dc // // This allows to abstract the digest behind this type and work only in those // terms. diff --git a/vendor/github.com/opencontainers/go-digest/doc.go b/vendor/github.com/opencontainers/go-digest/doc.go index 83d3a936ca6..e2dd44f4666 100644 --- a/vendor/github.com/opencontainers/go-digest/doc.go +++ b/vendor/github.com/opencontainers/go-digest/doc.go @@ -19,16 +19,16 @@ // More importantly, it provides tools and wrappers to work with // hash.Hash-based digests with little effort. // -// Basics +// # Basics // // The format of a digest is simply a string with two parts, dubbed the // "algorithm" and the "digest", separated by a colon: // -// : +// : // // An example of a sha256 digest representation follows: // -// sha256:7173b809ca12ec5dee4506cd86be934c4596dd234ee82c0662eac04a8c2c71dc +// sha256:7173b809ca12ec5dee4506cd86be934c4596dd234ee82c0662eac04a8c2c71dc // // The "algorithm" portion defines both the hashing algorithm used to calculate // the digest and the encoding of the resulting digest, which defaults to "hex" @@ -42,7 +42,7 @@ // obtained, comparisons are cheap, quick and simple to express with the // standard equality operator. // -// Verification +// # Verification // // The main benefit of using the Digest type is simple verification against a // given digest. The Verifier interface, modeled after the stdlib hash.Hash @@ -50,7 +50,7 @@ // writing is complete, calling the Verifier.Verified method will indicate // whether or not the stream of bytes matches the target digest. // -// Missing Features +// # Missing Features // // In addition to the above, we intend to add the following features to this // package: @@ -58,5 +58,4 @@ // 1. A Digester type that supports write sink digest calculation. // // 2. Suspend and resume of ongoing digest calculations to support efficient digest verification in the registry. -// package digest diff --git a/vendor/github.com/pkg/errors/errors.go b/vendor/github.com/pkg/errors/errors.go index 161aea25829..5d90dd4cc18 100644 --- a/vendor/github.com/pkg/errors/errors.go +++ b/vendor/github.com/pkg/errors/errors.go @@ -2,89 +2,89 @@ // // The traditional error handling idiom in Go is roughly akin to // -// if err != nil { -// return err -// } +// if err != nil { +// return err +// } // // which when applied recursively up the call stack results in error reports // without context or debugging information. The errors package allows // programmers to add context to the failure path in their code in a way // that does not destroy the original value of the error. // -// Adding context to an error +// # Adding context to an error // // The errors.Wrap function returns a new error that adds context to the // original error by recording a stack trace at the point Wrap is called, // together with the supplied message. For example // -// _, err := ioutil.ReadAll(r) -// if err != nil { -// return errors.Wrap(err, "read failed") -// } +// _, err := ioutil.ReadAll(r) +// if err != nil { +// return errors.Wrap(err, "read failed") +// } // // If additional control is required, the errors.WithStack and // errors.WithMessage functions destructure errors.Wrap into its component // operations: annotating an error with a stack trace and with a message, // respectively. // -// Retrieving the cause of an error +// # Retrieving the cause of an error // // Using errors.Wrap constructs a stack of errors, adding context to the // preceding error. Depending on the nature of the error it may be necessary // to reverse the operation of errors.Wrap to retrieve the original error // for inspection. Any error value which implements this interface // -// type causer interface { -// Cause() error -// } +// type causer interface { +// Cause() error +// } // // can be inspected by errors.Cause. errors.Cause will recursively retrieve // the topmost error that does not implement causer, which is assumed to be // the original cause. For example: // -// switch err := errors.Cause(err).(type) { -// case *MyError: -// // handle specifically -// default: -// // unknown error -// } +// switch err := errors.Cause(err).(type) { +// case *MyError: +// // handle specifically +// default: +// // unknown error +// } // // Although the causer interface is not exported by this package, it is // considered a part of its stable public interface. // -// Formatted printing of errors +// # Formatted printing of errors // // All error values returned from this package implement fmt.Formatter and can // be formatted by the fmt package. The following verbs are supported: // -// %s print the error. If the error has a Cause it will be -// printed recursively. -// %v see %s -// %+v extended format. Each Frame of the error's StackTrace will -// be printed in detail. +// %s print the error. If the error has a Cause it will be +// printed recursively. +// %v see %s +// %+v extended format. Each Frame of the error's StackTrace will +// be printed in detail. // -// Retrieving the stack trace of an error or wrapper +// # Retrieving the stack trace of an error or wrapper // // New, Errorf, Wrap, and Wrapf record a stack trace at the point they are // invoked. This information can be retrieved with the following interface: // -// type stackTracer interface { -// StackTrace() errors.StackTrace -// } +// type stackTracer interface { +// StackTrace() errors.StackTrace +// } // // The returned errors.StackTrace type is defined as // -// type StackTrace []Frame +// type StackTrace []Frame // // The Frame type represents a call site in the stack trace. Frame supports // the fmt.Formatter interface that can be used for printing information about // the stack trace of this error. For example: // -// if err, ok := err.(stackTracer); ok { -// for _, f := range err.StackTrace() { -// fmt.Printf("%+s:%d\n", f, f) -// } -// } +// if err, ok := err.(stackTracer); ok { +// for _, f := range err.StackTrace() { +// fmt.Printf("%+s:%d\n", f, f) +// } +// } // // Although the stackTracer interface is not exported by this package, it is // considered a part of its stable public interface. @@ -265,9 +265,9 @@ func (w *withMessage) Format(s fmt.State, verb rune) { // An error value has a cause if it implements the following // interface: // -// type causer interface { -// Cause() error -// } +// type causer interface { +// Cause() error +// } // // If the error does not implement Cause, the original error will // be returned. If the error is nil, nil will be returned without further diff --git a/vendor/github.com/pkg/errors/go113.go b/vendor/github.com/pkg/errors/go113.go index be0d10d0c79..2c83c724532 100644 --- a/vendor/github.com/pkg/errors/go113.go +++ b/vendor/github.com/pkg/errors/go113.go @@ -1,3 +1,4 @@ +//go:build go1.13 // +build go1.13 package errors diff --git a/vendor/github.com/pkg/errors/stack.go b/vendor/github.com/pkg/errors/stack.go index 779a8348fb9..82784d70036 100644 --- a/vendor/github.com/pkg/errors/stack.go +++ b/vendor/github.com/pkg/errors/stack.go @@ -51,16 +51,16 @@ func (f Frame) name() string { // Format formats the frame according to the fmt.Formatter interface. // -// %s source file -// %d source line -// %n function name -// %v equivalent to %s:%d +// %s source file +// %d source line +// %n function name +// %v equivalent to %s:%d // // Format accepts flags that alter the printing of some verbs, as follows: // -// %+s function name and path of source file relative to the compile time -// GOPATH separated by \n\t (\n\t) -// %+v equivalent to %+s:%d +// %+s function name and path of source file relative to the compile time +// GOPATH separated by \n\t (\n\t) +// %+v equivalent to %+s:%d func (f Frame) Format(s fmt.State, verb rune) { switch verb { case 's': @@ -98,12 +98,12 @@ type StackTrace []Frame // Format formats the stack of Frames according to the fmt.Formatter interface. // -// %s lists source files for each Frame in the stack -// %v lists the source file and line number for each Frame in the stack +// %s lists source files for each Frame in the stack +// %v lists the source file and line number for each Frame in the stack // // Format accepts flags that alter the printing of some verbs, as follows: // -// %+v Prints filename, function, and line number for each Frame in the stack. +// %+v Prints filename, function, and line number for each Frame in the stack. func (st StackTrace) Format(s fmt.State, verb rune) { switch verb { case 'v': diff --git a/vendor/github.com/pmezard/go-difflib/difflib/difflib.go b/vendor/github.com/pmezard/go-difflib/difflib/difflib.go index 003e99fadb4..2a73737af6d 100644 --- a/vendor/github.com/pmezard/go-difflib/difflib/difflib.go +++ b/vendor/github.com/pmezard/go-difflib/difflib/difflib.go @@ -199,12 +199,15 @@ func (m *SequenceMatcher) isBJunk(s string) bool { // If IsJunk is not defined: // // Return (i,j,k) such that a[i:i+k] is equal to b[j:j+k], where -// alo <= i <= i+k <= ahi -// blo <= j <= j+k <= bhi +// +// alo <= i <= i+k <= ahi +// blo <= j <= j+k <= bhi +// // and for all (i',j',k') meeting those conditions, -// k >= k' -// i <= i' -// and if i == i', j <= j' +// +// k >= k' +// i <= i' +// and if i == i', j <= j' // // In other words, of all maximal matching blocks, return one that // starts earliest in a, and of all those maximal matching blocks that diff --git a/vendor/github.com/segmentio/ksuid/ksuid.go b/vendor/github.com/segmentio/ksuid/ksuid.go index dbe1f9c7f30..be35d89bded 100644 --- a/vendor/github.com/segmentio/ksuid/ksuid.go +++ b/vendor/github.com/segmentio/ksuid/ksuid.go @@ -38,8 +38,9 @@ const ( ) // KSUIDs are 20 bytes: -// 00-03 byte: uint32 BE UTC timestamp with custom epoch -// 04-19 byte: random "payload" +// +// 00-03 byte: uint32 BE UTC timestamp with custom epoch +// 04-19 byte: random "payload" type KSUID [byteLength]byte var ( diff --git a/vendor/github.com/sirupsen/logrus/doc.go b/vendor/github.com/sirupsen/logrus/doc.go index da67aba06de..51392be8f6e 100644 --- a/vendor/github.com/sirupsen/logrus/doc.go +++ b/vendor/github.com/sirupsen/logrus/doc.go @@ -1,25 +1,25 @@ /* Package logrus is a structured logger for Go, completely API compatible with the standard library logger. - The simplest way to use Logrus is simply the package-level exported logger: - package main + package main - import ( - log "github.com/sirupsen/logrus" - ) + import ( + log "github.com/sirupsen/logrus" + ) - func main() { - log.WithFields(log.Fields{ - "animal": "walrus", - "number": 1, - "size": 10, - }).Info("A walrus appears") - } + func main() { + log.WithFields(log.Fields{ + "animal": "walrus", + "number": 1, + "size": 10, + }).Info("A walrus appears") + } Output: - time="2015-09-07T08:48:33Z" level=info msg="A walrus appears" animal=walrus number=1 size=10 + + time="2015-09-07T08:48:33Z" level=info msg="A walrus appears" animal=walrus number=1 size=10 For a full guide visit https://github.com/sirupsen/logrus */ diff --git a/vendor/github.com/sirupsen/logrus/formatter.go b/vendor/github.com/sirupsen/logrus/formatter.go index 408883773eb..8c76155154e 100644 --- a/vendor/github.com/sirupsen/logrus/formatter.go +++ b/vendor/github.com/sirupsen/logrus/formatter.go @@ -30,12 +30,12 @@ type Formatter interface { // This is to not silently overwrite `time`, `msg`, `func` and `level` fields when // dumping it. If this code wasn't there doing: // -// logrus.WithField("level", 1).Info("hello") +// logrus.WithField("level", 1).Info("hello") // // Would just silently drop the user provided level. Instead with this code // it'll logged as: // -// {"level": "info", "fields.level": 1, "msg": "hello", "time": "..."} +// {"level": "info", "fields.level": 1, "msg": "hello", "time": "..."} // // It's not exported because it's still using Data in an opinionated way. It's to // avoid code duplication between the two default formatters. diff --git a/vendor/github.com/sirupsen/logrus/hooks/syslog/syslog.go b/vendor/github.com/sirupsen/logrus/hooks/syslog/syslog.go index 02b8df38055..0f7d15715c7 100644 --- a/vendor/github.com/sirupsen/logrus/hooks/syslog/syslog.go +++ b/vendor/github.com/sirupsen/logrus/hooks/syslog/syslog.go @@ -1,3 +1,4 @@ +//go:build !windows && !nacl && !plan9 // +build !windows,!nacl,!plan9 package syslog diff --git a/vendor/github.com/sirupsen/logrus/logger.go b/vendor/github.com/sirupsen/logrus/logger.go index 5ff0aef6d3f..df059412e93 100644 --- a/vendor/github.com/sirupsen/logrus/logger.go +++ b/vendor/github.com/sirupsen/logrus/logger.go @@ -76,12 +76,12 @@ func (mw *MutexWrap) Disable() { // `Out` and `Hooks` directly on the default logger instance. You can also just // instantiate your own: // -// var log = &logrus.Logger{ -// Out: os.Stderr, -// Formatter: new(logrus.TextFormatter), -// Hooks: make(logrus.LevelHooks), -// Level: logrus.DebugLevel, -// } +// var log = &logrus.Logger{ +// Out: os.Stderr, +// Formatter: new(logrus.TextFormatter), +// Hooks: make(logrus.LevelHooks), +// Level: logrus.DebugLevel, +// } // // It's recommended to make this a global instance called `log`. func New() *Logger { @@ -347,9 +347,9 @@ func (logger *Logger) Exit(code int) { logger.ExitFunc(code) } -//When file is opened with appending mode, it's safe to -//write concurrently to a file (within 4k message on Linux). -//In these cases user can choose to disable the lock. +// When file is opened with appending mode, it's safe to +// write concurrently to a file (within 4k message on Linux). +// In these cases user can choose to disable the lock. func (logger *Logger) SetNoLock() { logger.mu.Disable() } diff --git a/vendor/github.com/sirupsen/logrus/terminal_check_appengine.go b/vendor/github.com/sirupsen/logrus/terminal_check_appengine.go index 2403de98192..45de3e2b676 100644 --- a/vendor/github.com/sirupsen/logrus/terminal_check_appengine.go +++ b/vendor/github.com/sirupsen/logrus/terminal_check_appengine.go @@ -1,3 +1,4 @@ +//go:build appengine // +build appengine package logrus diff --git a/vendor/github.com/sirupsen/logrus/terminal_check_bsd.go b/vendor/github.com/sirupsen/logrus/terminal_check_bsd.go index 499789984d2..e3fa38b7100 100644 --- a/vendor/github.com/sirupsen/logrus/terminal_check_bsd.go +++ b/vendor/github.com/sirupsen/logrus/terminal_check_bsd.go @@ -1,3 +1,4 @@ +//go:build (darwin || dragonfly || freebsd || netbsd || openbsd) && !js // +build darwin dragonfly freebsd netbsd openbsd // +build !js diff --git a/vendor/github.com/sirupsen/logrus/terminal_check_js.go b/vendor/github.com/sirupsen/logrus/terminal_check_js.go index ebdae3ec626..9e951f1b42f 100644 --- a/vendor/github.com/sirupsen/logrus/terminal_check_js.go +++ b/vendor/github.com/sirupsen/logrus/terminal_check_js.go @@ -1,3 +1,4 @@ +//go:build js // +build js package logrus diff --git a/vendor/github.com/sirupsen/logrus/terminal_check_no_terminal.go b/vendor/github.com/sirupsen/logrus/terminal_check_no_terminal.go index 97af92c68ea..04232da1919 100644 --- a/vendor/github.com/sirupsen/logrus/terminal_check_no_terminal.go +++ b/vendor/github.com/sirupsen/logrus/terminal_check_no_terminal.go @@ -1,3 +1,4 @@ +//go:build js || nacl || plan9 // +build js nacl plan9 package logrus diff --git a/vendor/github.com/sirupsen/logrus/terminal_check_notappengine.go b/vendor/github.com/sirupsen/logrus/terminal_check_notappengine.go index 3293fb3caad..1b4a99e325e 100644 --- a/vendor/github.com/sirupsen/logrus/terminal_check_notappengine.go +++ b/vendor/github.com/sirupsen/logrus/terminal_check_notappengine.go @@ -1,3 +1,4 @@ +//go:build !appengine && !js && !windows && !nacl && !plan9 // +build !appengine,!js,!windows,!nacl,!plan9 package logrus diff --git a/vendor/github.com/sirupsen/logrus/terminal_check_unix.go b/vendor/github.com/sirupsen/logrus/terminal_check_unix.go index 04748b8515f..f3154b17fc5 100644 --- a/vendor/github.com/sirupsen/logrus/terminal_check_unix.go +++ b/vendor/github.com/sirupsen/logrus/terminal_check_unix.go @@ -1,3 +1,4 @@ +//go:build (linux || aix || zos) && !js // +build linux aix zos // +build !js diff --git a/vendor/github.com/sirupsen/logrus/terminal_check_windows.go b/vendor/github.com/sirupsen/logrus/terminal_check_windows.go index 2879eb50ea6..893c62410c5 100644 --- a/vendor/github.com/sirupsen/logrus/terminal_check_windows.go +++ b/vendor/github.com/sirupsen/logrus/terminal_check_windows.go @@ -1,3 +1,4 @@ +//go:build !appengine && !js && windows // +build !appengine,!js,windows package logrus diff --git a/vendor/github.com/skratchdot/open-golang/open/exec.go b/vendor/github.com/skratchdot/open-golang/open/exec.go index 1b0e713685c..1b0cdd0ac8e 100644 --- a/vendor/github.com/skratchdot/open-golang/open/exec.go +++ b/vendor/github.com/skratchdot/open-golang/open/exec.go @@ -1,3 +1,4 @@ +//go:build !windows && !darwin // +build !windows,!darwin package open diff --git a/vendor/github.com/skratchdot/open-golang/open/exec_darwin.go b/vendor/github.com/skratchdot/open-golang/open/exec_darwin.go index 16160e6f043..d01fb6bf3e2 100644 --- a/vendor/github.com/skratchdot/open-golang/open/exec_darwin.go +++ b/vendor/github.com/skratchdot/open-golang/open/exec_darwin.go @@ -1,3 +1,4 @@ +//go:build darwin // +build darwin package open diff --git a/vendor/github.com/skratchdot/open-golang/open/exec_windows.go b/vendor/github.com/skratchdot/open-golang/open/exec_windows.go index 6e46c005427..7fdf75dfe0a 100644 --- a/vendor/github.com/skratchdot/open-golang/open/exec_windows.go +++ b/vendor/github.com/skratchdot/open-golang/open/exec_windows.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package open diff --git a/vendor/github.com/skratchdot/open-golang/open/open.go b/vendor/github.com/skratchdot/open-golang/open/open.go index b1f648ff51e..ded608c4171 100644 --- a/vendor/github.com/skratchdot/open-golang/open/open.go +++ b/vendor/github.com/skratchdot/open-golang/open/open.go @@ -1,49 +1,47 @@ /* +Open a file, directory, or URI using the OS's default +application for that object type. Optionally, you can +specify an application to use. - Open a file, directory, or URI using the OS's default - application for that object type. Optionally, you can - specify an application to use. +This is a proxy for the following commands: - This is a proxy for the following commands: - - OSX: "open" - Windows: "start" - Linux/Other: "xdg-open" - - This is a golang port of the node.js module: https://github.com/pwnall/node-open + OSX: "open" + Windows: "start" + Linux/Other: "xdg-open" +This is a golang port of the node.js module: https://github.com/pwnall/node-open */ package open /* - Open a file, directory, or URI using the OS's default - application for that object type. Wait for the open - command to complete. +Open a file, directory, or URI using the OS's default +application for that object type. Wait for the open +command to complete. */ func Run(input string) error { return open(input).Run() } /* - Open a file, directory, or URI using the OS's default - application for that object type. Don't wait for the - open command to complete. +Open a file, directory, or URI using the OS's default +application for that object type. Don't wait for the +open command to complete. */ func Start(input string) error { return open(input).Start() } /* - Open a file, directory, or URI using the specified application. - Wait for the open command to complete. +Open a file, directory, or URI using the specified application. +Wait for the open command to complete. */ func RunWith(input string, appName string) error { return openWith(input, appName).Run() } /* - Open a file, directory, or URI using the specified application. - Don't wait for the open command to complete. +Open a file, directory, or URI using the specified application. +Don't wait for the open command to complete. */ func StartWith(input string, appName string) error { return openWith(input, appName).Start() diff --git a/vendor/github.com/smallstep/pkcs7/ber.go b/vendor/github.com/smallstep/pkcs7/ber.go index 52333215dee..7f1aa2d3202 100644 --- a/vendor/github.com/smallstep/pkcs7/ber.go +++ b/vendor/github.com/smallstep/pkcs7/ber.go @@ -101,12 +101,12 @@ func lengthLength(i int) (numBytes int) { // added to 0x80. The length is encoded in big endian encoding follow after // // Examples: -// length | byte 1 | bytes n -// 0 | 0x00 | - -// 120 | 0x78 | - -// 200 | 0x81 | 0xC8 -// 500 | 0x82 | 0x01 0xF4 // +// length | byte 1 | bytes n +// 0 | 0x00 | - +// 120 | 0x78 | - +// 200 | 0x81 | 0xC8 +// 500 | 0x82 | 0x01 0xF4 func encodeLength(out *bytes.Buffer, length int) (err error) { if length >= 128 { l := lengthLength(length) diff --git a/vendor/github.com/spf13/pflag/golangflag.go b/vendor/github.com/spf13/pflag/golangflag.go index e62eab53810..20594384a02 100644 --- a/vendor/github.com/spf13/pflag/golangflag.go +++ b/vendor/github.com/spf13/pflag/golangflag.go @@ -158,4 +158,3 @@ func ParseSkippedFlags(osArgs []string, goFlagSet *goflag.FlagSet) error { } return goFlagSet.Parse(skippedFlags) } - diff --git a/vendor/github.com/spf13/pflag/string_slice.go b/vendor/github.com/spf13/pflag/string_slice.go index 3cb2e69dba0..d421887e867 100644 --- a/vendor/github.com/spf13/pflag/string_slice.go +++ b/vendor/github.com/spf13/pflag/string_slice.go @@ -98,9 +98,12 @@ func (f *FlagSet) GetStringSlice(name string) ([]string, error) { // The argument p points to a []string variable in which to store the value of the flag. // Compared to StringArray flags, StringSlice flags take comma-separated value as arguments and split them accordingly. // For example: -// --ss="v1,v2" --ss="v3" +// +// --ss="v1,v2" --ss="v3" +// // will result in -// []string{"v1", "v2", "v3"} +// +// []string{"v1", "v2", "v3"} func (f *FlagSet) StringSliceVar(p *[]string, name string, value []string, usage string) { f.VarP(newStringSliceValue(value, p), name, "", usage) } @@ -114,9 +117,12 @@ func (f *FlagSet) StringSliceVarP(p *[]string, name, shorthand string, value []s // The argument p points to a []string variable in which to store the value of the flag. // Compared to StringArray flags, StringSlice flags take comma-separated value as arguments and split them accordingly. // For example: -// --ss="v1,v2" --ss="v3" +// +// --ss="v1,v2" --ss="v3" +// // will result in -// []string{"v1", "v2", "v3"} +// +// []string{"v1", "v2", "v3"} func StringSliceVar(p *[]string, name string, value []string, usage string) { CommandLine.VarP(newStringSliceValue(value, p), name, "", usage) } @@ -130,9 +136,12 @@ func StringSliceVarP(p *[]string, name, shorthand string, value []string, usage // The return value is the address of a []string variable that stores the value of the flag. // Compared to StringArray flags, StringSlice flags take comma-separated value as arguments and split them accordingly. // For example: -// --ss="v1,v2" --ss="v3" +// +// --ss="v1,v2" --ss="v3" +// // will result in -// []string{"v1", "v2", "v3"} +// +// []string{"v1", "v2", "v3"} func (f *FlagSet) StringSlice(name string, value []string, usage string) *[]string { p := []string{} f.StringSliceVarP(&p, name, "", value, usage) @@ -150,9 +159,12 @@ func (f *FlagSet) StringSliceP(name, shorthand string, value []string, usage str // The return value is the address of a []string variable that stores the value of the flag. // Compared to StringArray flags, StringSlice flags take comma-separated value as arguments and split them accordingly. // For example: -// --ss="v1,v2" --ss="v3" +// +// --ss="v1,v2" --ss="v3" +// // will result in -// []string{"v1", "v2", "v3"} +// +// []string{"v1", "v2", "v3"} func StringSlice(name string, value []string, usage string) *[]string { return CommandLine.StringSliceP(name, "", value, usage) } diff --git a/vendor/github.com/vbatts/tar-split/archive/tar/common.go b/vendor/github.com/vbatts/tar-split/archive/tar/common.go index dee9e47e4ae..a7a6539a1b1 100644 --- a/vendor/github.com/vbatts/tar-split/archive/tar/common.go +++ b/vendor/github.com/vbatts/tar-split/archive/tar/common.go @@ -221,9 +221,11 @@ func (s sparseEntry) endOffset() int64 { return s.Offset + s.Length } // that the file has no data in it, which is rather odd. // // As an example, if the underlying raw file contains the 10-byte data: +// // var compactFile = "abcdefgh" // // And the sparse map has the following entries: +// // var spd sparseDatas = []sparseEntry{ // {Offset: 2, Length: 5}, // Data fragment for 2..6 // {Offset: 18, Length: 3}, // Data fragment for 18..20 @@ -235,6 +237,7 @@ func (s sparseEntry) endOffset() int64 { return s.Offset + s.Length } // } // // Then the content of the resulting sparse file with a Header.Size of 25 is: +// // var sparseFile = "\x00"*2 + "abcde" + "\x00"*11 + "fgh" + "\x00"*4 type ( sparseDatas []sparseEntry @@ -293,9 +296,9 @@ func alignSparseEntries(src []sparseEntry, size int64) []sparseEntry { // The input must have been already validated. // // This function mutates src and returns a normalized map where: -// * adjacent fragments are coalesced together -// * only the last fragment may be empty -// * the endOffset of the last fragment is the total size +// - adjacent fragments are coalesced together +// - only the last fragment may be empty +// - the endOffset of the last fragment is the total size func invertSparseEntries(src []sparseEntry, size int64) []sparseEntry { dst := src[:0] var pre sparseEntry diff --git a/vendor/github.com/vbatts/tar-split/archive/tar/stat_actime1.go b/vendor/github.com/vbatts/tar-split/archive/tar/stat_actime1.go index cf9cc79c591..0eb8e2980ae 100644 --- a/vendor/github.com/vbatts/tar-split/archive/tar/stat_actime1.go +++ b/vendor/github.com/vbatts/tar-split/archive/tar/stat_actime1.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build linux || dragonfly || openbsd || solaris // +build linux dragonfly openbsd solaris package tar diff --git a/vendor/github.com/vbatts/tar-split/archive/tar/stat_actime2.go b/vendor/github.com/vbatts/tar-split/archive/tar/stat_actime2.go index 6f17dbe3072..5a9a35cbb4e 100644 --- a/vendor/github.com/vbatts/tar-split/archive/tar/stat_actime2.go +++ b/vendor/github.com/vbatts/tar-split/archive/tar/stat_actime2.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build darwin || freebsd || netbsd // +build darwin freebsd netbsd package tar diff --git a/vendor/github.com/vbatts/tar-split/archive/tar/stat_unix.go b/vendor/github.com/vbatts/tar-split/archive/tar/stat_unix.go index 868105f338e..9ff215944d5 100644 --- a/vendor/github.com/vbatts/tar-split/archive/tar/stat_unix.go +++ b/vendor/github.com/vbatts/tar-split/archive/tar/stat_unix.go @@ -2,6 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. +//go:build linux || darwin || dragonfly || freebsd || openbsd || netbsd || solaris // +build linux darwin dragonfly freebsd openbsd netbsd solaris package tar diff --git a/vendor/github.com/vbatts/tar-split/archive/tar/strconv.go b/vendor/github.com/vbatts/tar-split/archive/tar/strconv.go index d144485a492..2073f7e8a91 100644 --- a/vendor/github.com/vbatts/tar-split/archive/tar/strconv.go +++ b/vendor/github.com/vbatts/tar-split/archive/tar/strconv.go @@ -244,7 +244,7 @@ func formatPAXTime(ts time.Time) (s string) { if secs < 0 { sign = "-" // Remember sign secs = -(secs + 1) // Add a second to secs - nsecs = -(nsecs - 1E9) // Take that second away from nsecs + nsecs = -(nsecs - 1e9) // Take that second away from nsecs } return strings.TrimRight(fmt.Sprintf("%s%d.%09d", sign, secs, nsecs), "0") } @@ -306,6 +306,7 @@ func formatPAXRecord(k, v string) (string, error) { // validPAXRecord reports whether the key-value pair is valid where each // record is formatted as: +// // "%d %s=%s\n" % (size, key, value) // // Keys and values should be UTF-8, but the number of bad writers out there diff --git a/vendor/github.com/vishvananda/netlink/conntrack_linux.go b/vendor/github.com/vishvananda/netlink/conntrack_linux.go index b3d354d75e7..771fa703964 100644 --- a/vendor/github.com/vishvananda/netlink/conntrack_linux.go +++ b/vendor/github.com/vishvananda/netlink/conntrack_linux.go @@ -225,10 +225,11 @@ type ProtoInfo interface { type ProtoInfoTCP struct { State uint8 } + // Protocol returns "tcp". -func (*ProtoInfoTCP) Protocol() string {return "tcp"} +func (*ProtoInfoTCP) Protocol() string { return "tcp" } func (p *ProtoInfoTCP) toNlData() ([]*nl.RtAttr, error) { - ctProtoInfo := nl.NewRtAttr(unix.NLA_F_NESTED | nl.CTA_PROTOINFO, []byte{}) + ctProtoInfo := nl.NewRtAttr(unix.NLA_F_NESTED|nl.CTA_PROTOINFO, []byte{}) ctProtoInfoTCP := nl.NewRtAttr(unix.NLA_F_NESTED|nl.CTA_PROTOINFO_TCP, []byte{}) ctProtoInfoTCPState := nl.NewRtAttr(nl.CTA_PROTOINFO_TCP_STATE, nl.Uint8Attr(p.State)) ctProtoInfoTCP.AddChild(ctProtoInfoTCPState) @@ -238,14 +239,16 @@ func (p *ProtoInfoTCP) toNlData() ([]*nl.RtAttr, error) { } // ProtoInfoSCTP only supports the protocol name. -type ProtoInfoSCTP struct {} +type ProtoInfoSCTP struct{} + // Protocol returns "sctp". -func (*ProtoInfoSCTP) Protocol() string {return "sctp"} +func (*ProtoInfoSCTP) Protocol() string { return "sctp" } // ProtoInfoDCCP only supports the protocol name. -type ProtoInfoDCCP struct {} +type ProtoInfoDCCP struct{} + // Protocol returns "dccp". -func (*ProtoInfoDCCP) Protocol() string {return "dccp"} +func (*ProtoInfoDCCP) Protocol() string { return "dccp" } // The full conntrack flow structure is very complicated and can be found in the file: // http://git.netfilter.org/libnetfilter_conntrack/tree/include/internal/object.h @@ -287,7 +290,7 @@ func (t *IPTuple) toNlData(family uint8) ([]*nl.RtAttr, error) { ctTupleProtoSrcPort := nl.NewRtAttr(nl.CTA_PROTO_SRC_PORT, nl.BEUint16Attr(t.SrcPort)) ctTupleProto.AddChild(ctTupleProtoSrcPort) ctTupleProtoDstPort := nl.NewRtAttr(nl.CTA_PROTO_DST_PORT, nl.BEUint16Attr(t.DstPort)) - ctTupleProto.AddChild(ctTupleProtoDstPort, ) + ctTupleProto.AddChild(ctTupleProtoDstPort) return []*nl.RtAttr{ctTupleIP, ctTupleProto}, nil } @@ -364,7 +367,7 @@ func (s *ConntrackFlow) toNlData() ([]*nl.RtAttr, error) { // // // - + // CTA_TUPLE_ORIG ctTupleOrig := nl.NewRtAttr(unix.NLA_F_NESTED|nl.CTA_TUPLE_ORIG, nil) forwardFlowAttrs, err := s.Forward.toNlData(s.FamilyType) @@ -547,12 +550,12 @@ func parseTimeStamp(r *bytes.Reader, readSize uint16) (tstart, tstop uint64) { func parseProtoInfoTCPState(r *bytes.Reader) (s uint8) { binary.Read(r, binary.BigEndian, &s) - r.Seek(nl.SizeofNfattr - 1, seekCurrent) + r.Seek(nl.SizeofNfattr-1, seekCurrent) return s } // parseProtoInfoTCP reads the entire nested protoinfo structure, but only parses the state attr. -func parseProtoInfoTCP(r *bytes.Reader, attrLen uint16) (*ProtoInfoTCP) { +func parseProtoInfoTCP(r *bytes.Reader, attrLen uint16) *ProtoInfoTCP { p := new(ProtoInfoTCP) bytesRead := 0 for bytesRead < int(attrLen) { @@ -666,7 +669,7 @@ func parseRawData(data []byte) *ConntrackFlow { switch t { case nl.CTA_MARK: s.Mark = parseConnectionMark(reader) - case nl.CTA_LABELS: + case nl.CTA_LABELS: s.Labels = parseConnectionLabels(reader) case nl.CTA_TIMEOUT: s.TimeOut = parseTimeOut(reader) diff --git a/vendor/github.com/vishvananda/netlink/conntrack_unspecified.go b/vendor/github.com/vishvananda/netlink/conntrack_unspecified.go index 0049048dc34..c995d6a652c 100644 --- a/vendor/github.com/vishvananda/netlink/conntrack_unspecified.go +++ b/vendor/github.com/vishvananda/netlink/conntrack_unspecified.go @@ -1,3 +1,4 @@ +//go:build !linux // +build !linux package netlink diff --git a/vendor/github.com/vishvananda/netlink/genetlink_unspecified.go b/vendor/github.com/vishvananda/netlink/genetlink_unspecified.go index 0192b991e31..18f8e6299d6 100644 --- a/vendor/github.com/vishvananda/netlink/genetlink_unspecified.go +++ b/vendor/github.com/vishvananda/netlink/genetlink_unspecified.go @@ -1,3 +1,4 @@ +//go:build !linux // +build !linux package netlink diff --git a/vendor/github.com/vishvananda/netlink/netns_unspecified.go b/vendor/github.com/vishvananda/netlink/netns_unspecified.go index 5c5899e3628..a187cf8ca3e 100644 --- a/vendor/github.com/vishvananda/netlink/netns_unspecified.go +++ b/vendor/github.com/vishvananda/netlink/netns_unspecified.go @@ -1,3 +1,4 @@ +//go:build !linux // +build !linux package netlink diff --git a/vendor/github.com/vishvananda/netlink/nl/conntrack_linux.go b/vendor/github.com/vishvananda/netlink/nl/conntrack_linux.go index 6989d1edc0b..69e6e6822cc 100644 --- a/vendor/github.com/vishvananda/netlink/nl/conntrack_linux.go +++ b/vendor/github.com/vishvananda/netlink/nl/conntrack_linux.go @@ -16,6 +16,7 @@ var L4ProtoMap = map[uint8]string{ } // From https://git.netfilter.org/libnetfilter_conntrack/tree/include/libnetfilter_conntrack/libnetfilter_conntrack_tcp.h +// // enum tcp_state { // TCP_CONNTRACK_NONE, // TCP_CONNTRACK_SYN_SENT, @@ -32,38 +33,38 @@ var L4ProtoMap = map[uint8]string{ // TCP_CONNTRACK_IGNORE // }; const ( - TCP_CONNTRACK_NONE = 0 - TCP_CONNTRACK_SYN_SENT = 1 - TCP_CONNTRACK_SYN_RECV = 2 - TCP_CONNTRACK_ESTABLISHED = 3 - TCP_CONNTRACK_FIN_WAIT = 4 - TCP_CONNTRACK_CLOSE_WAIT = 5 - TCP_CONNTRACK_LAST_ACK = 6 - TCP_CONNTRACK_TIME_WAIT = 7 - TCP_CONNTRACK_CLOSE = 8 - TCP_CONNTRACK_LISTEN = 9 - TCP_CONNTRACK_SYN_SENT2 = 9 - TCP_CONNTRACK_MAX = 10 - TCP_CONNTRACK_IGNORE = 11 + TCP_CONNTRACK_NONE = 0 + TCP_CONNTRACK_SYN_SENT = 1 + TCP_CONNTRACK_SYN_RECV = 2 + TCP_CONNTRACK_ESTABLISHED = 3 + TCP_CONNTRACK_FIN_WAIT = 4 + TCP_CONNTRACK_CLOSE_WAIT = 5 + TCP_CONNTRACK_LAST_ACK = 6 + TCP_CONNTRACK_TIME_WAIT = 7 + TCP_CONNTRACK_CLOSE = 8 + TCP_CONNTRACK_LISTEN = 9 + TCP_CONNTRACK_SYN_SENT2 = 9 + TCP_CONNTRACK_MAX = 10 + TCP_CONNTRACK_IGNORE = 11 ) // All the following constants are coming from: // https://github.com/torvalds/linux/blob/master/include/uapi/linux/netfilter/nfnetlink_conntrack.h -// enum cntl_msg_types { -// IPCTNL_MSG_CT_NEW, -// IPCTNL_MSG_CT_GET, -// IPCTNL_MSG_CT_DELETE, -// IPCTNL_MSG_CT_GET_CTRZERO, -// IPCTNL_MSG_CT_GET_STATS_CPU, -// IPCTNL_MSG_CT_GET_STATS, -// IPCTNL_MSG_CT_GET_DYING, -// IPCTNL_MSG_CT_GET_UNCONFIRMED, +// enum cntl_msg_types { +// IPCTNL_MSG_CT_NEW, +// IPCTNL_MSG_CT_GET, +// IPCTNL_MSG_CT_DELETE, +// IPCTNL_MSG_CT_GET_CTRZERO, +// IPCTNL_MSG_CT_GET_STATS_CPU, +// IPCTNL_MSG_CT_GET_STATS, +// IPCTNL_MSG_CT_GET_DYING, +// IPCTNL_MSG_CT_GET_UNCONFIRMED, // -// IPCTNL_MSG_MAX -// }; +// IPCTNL_MSG_MAX +// }; const ( - IPCTNL_MSG_CT_NEW = 0 + IPCTNL_MSG_CT_NEW = 0 IPCTNL_MSG_CT_GET = 1 IPCTNL_MSG_CT_DELETE = 2 ) @@ -80,36 +81,38 @@ const ( NLA_ALIGNTO uint16 = 4 // #define NLA_ALIGNTO 4 ) -// enum ctattr_type { -// CTA_UNSPEC, -// CTA_TUPLE_ORIG, -// CTA_TUPLE_REPLY, -// CTA_STATUS, -// CTA_PROTOINFO, -// CTA_HELP, -// CTA_NAT_SRC, +// enum ctattr_type { +// CTA_UNSPEC, +// CTA_TUPLE_ORIG, +// CTA_TUPLE_REPLY, +// CTA_STATUS, +// CTA_PROTOINFO, +// CTA_HELP, +// CTA_NAT_SRC, +// // #define CTA_NAT CTA_NAT_SRC /* backwards compatibility */ -// CTA_TIMEOUT, -// CTA_MARK, -// CTA_COUNTERS_ORIG, -// CTA_COUNTERS_REPLY, -// CTA_USE, -// CTA_ID, -// CTA_NAT_DST, -// CTA_TUPLE_MASTER, -// CTA_SEQ_ADJ_ORIG, -// CTA_NAT_SEQ_ADJ_ORIG = CTA_SEQ_ADJ_ORIG, -// CTA_SEQ_ADJ_REPLY, -// CTA_NAT_SEQ_ADJ_REPLY = CTA_SEQ_ADJ_REPLY, -// CTA_SECMARK, /* obsolete */ -// CTA_ZONE, -// CTA_SECCTX, -// CTA_TIMESTAMP, -// CTA_MARK_MASK, -// CTA_LABELS, -// CTA_LABELS_MASK, -// __CTA_MAX -// }; +// +// CTA_TIMEOUT, +// CTA_MARK, +// CTA_COUNTERS_ORIG, +// CTA_COUNTERS_REPLY, +// CTA_USE, +// CTA_ID, +// CTA_NAT_DST, +// CTA_TUPLE_MASTER, +// CTA_SEQ_ADJ_ORIG, +// CTA_NAT_SEQ_ADJ_ORIG = CTA_SEQ_ADJ_ORIG, +// CTA_SEQ_ADJ_REPLY, +// CTA_NAT_SEQ_ADJ_REPLY = CTA_SEQ_ADJ_REPLY, +// CTA_SECMARK, /* obsolete */ +// CTA_ZONE, +// CTA_SECCTX, +// CTA_TIMESTAMP, +// CTA_MARK_MASK, +// CTA_LABELS, +// CTA_LABELS_MASK, +// __CTA_MAX +// }; const ( CTA_TUPLE_ORIG = 1 CTA_TUPLE_REPLY = 2 @@ -127,27 +130,29 @@ const ( CTA_LABELS_MASK = 23 ) -// enum ctattr_tuple { -// CTA_TUPLE_UNSPEC, -// CTA_TUPLE_IP, -// CTA_TUPLE_PROTO, -// CTA_TUPLE_ZONE, -// __CTA_TUPLE_MAX -// }; +// enum ctattr_tuple { +// CTA_TUPLE_UNSPEC, +// CTA_TUPLE_IP, +// CTA_TUPLE_PROTO, +// CTA_TUPLE_ZONE, +// __CTA_TUPLE_MAX +// }; +// // #define CTA_TUPLE_MAX (__CTA_TUPLE_MAX - 1) const ( CTA_TUPLE_IP = 1 CTA_TUPLE_PROTO = 2 ) -// enum ctattr_ip { -// CTA_IP_UNSPEC, -// CTA_IP_V4_SRC, -// CTA_IP_V4_DST, -// CTA_IP_V6_SRC, -// CTA_IP_V6_DST, -// __CTA_IP_MAX -// }; +// enum ctattr_ip { +// CTA_IP_UNSPEC, +// CTA_IP_V4_SRC, +// CTA_IP_V4_DST, +// CTA_IP_V6_SRC, +// CTA_IP_V6_DST, +// __CTA_IP_MAX +// }; +// // #define CTA_IP_MAX (__CTA_IP_MAX - 1) const ( CTA_IP_V4_SRC = 1 @@ -156,19 +161,20 @@ const ( CTA_IP_V6_DST = 4 ) -// enum ctattr_l4proto { -// CTA_PROTO_UNSPEC, -// CTA_PROTO_NUM, -// CTA_PROTO_SRC_PORT, -// CTA_PROTO_DST_PORT, -// CTA_PROTO_ICMP_ID, -// CTA_PROTO_ICMP_TYPE, -// CTA_PROTO_ICMP_CODE, -// CTA_PROTO_ICMPV6_ID, -// CTA_PROTO_ICMPV6_TYPE, -// CTA_PROTO_ICMPV6_CODE, -// __CTA_PROTO_MAX -// }; +// enum ctattr_l4proto { +// CTA_PROTO_UNSPEC, +// CTA_PROTO_NUM, +// CTA_PROTO_SRC_PORT, +// CTA_PROTO_DST_PORT, +// CTA_PROTO_ICMP_ID, +// CTA_PROTO_ICMP_TYPE, +// CTA_PROTO_ICMP_CODE, +// CTA_PROTO_ICMPV6_ID, +// CTA_PROTO_ICMPV6_TYPE, +// CTA_PROTO_ICMPV6_CODE, +// __CTA_PROTO_MAX +// }; +// // #define CTA_PROTO_MAX (__CTA_PROTO_MAX - 1) const ( CTA_PROTO_NUM = 1 @@ -176,30 +182,32 @@ const ( CTA_PROTO_DST_PORT = 3 ) -// enum ctattr_protoinfo { -// CTA_PROTOINFO_UNSPEC, -// CTA_PROTOINFO_TCP, -// CTA_PROTOINFO_DCCP, -// CTA_PROTOINFO_SCTP, -// __CTA_PROTOINFO_MAX -// }; +// enum ctattr_protoinfo { +// CTA_PROTOINFO_UNSPEC, +// CTA_PROTOINFO_TCP, +// CTA_PROTOINFO_DCCP, +// CTA_PROTOINFO_SCTP, +// __CTA_PROTOINFO_MAX +// }; +// // #define CTA_PROTOINFO_MAX (__CTA_PROTOINFO_MAX - 1) const ( CTA_PROTOINFO_UNSPEC = 0 - CTA_PROTOINFO_TCP = 1 - CTA_PROTOINFO_DCCP = 2 - CTA_PROTOINFO_SCTP = 3 + CTA_PROTOINFO_TCP = 1 + CTA_PROTOINFO_DCCP = 2 + CTA_PROTOINFO_SCTP = 3 ) -// enum ctattr_protoinfo_tcp { -// CTA_PROTOINFO_TCP_UNSPEC, -// CTA_PROTOINFO_TCP_STATE, -// CTA_PROTOINFO_TCP_WSCALE_ORIGINAL, -// CTA_PROTOINFO_TCP_WSCALE_REPLY, -// CTA_PROTOINFO_TCP_FLAGS_ORIGINAL, -// CTA_PROTOINFO_TCP_FLAGS_REPLY, -// __CTA_PROTOINFO_TCP_MAX -// }; +// enum ctattr_protoinfo_tcp { +// CTA_PROTOINFO_TCP_UNSPEC, +// CTA_PROTOINFO_TCP_STATE, +// CTA_PROTOINFO_TCP_WSCALE_ORIGINAL, +// CTA_PROTOINFO_TCP_WSCALE_REPLY, +// CTA_PROTOINFO_TCP_FLAGS_ORIGINAL, +// CTA_PROTOINFO_TCP_FLAGS_REPLY, +// __CTA_PROTOINFO_TCP_MAX +// }; +// // #define CTA_PROTOINFO_TCP_MAX (__CTA_PROTOINFO_TCP_MAX - 1) const ( CTA_PROTOINFO_TCP_STATE = 1 @@ -209,15 +217,16 @@ const ( CTA_PROTOINFO_TCP_FLAGS_REPLY = 5 ) -// enum ctattr_counters { -// CTA_COUNTERS_UNSPEC, -// CTA_COUNTERS_PACKETS, /* 64bit counters */ -// CTA_COUNTERS_BYTES, /* 64bit counters */ -// CTA_COUNTERS32_PACKETS, /* old 32bit counters, unused */ -// CTA_COUNTERS32_BYTES, /* old 32bit counters, unused */ -// CTA_COUNTERS_PAD, -// __CTA_COUNTERS_M -// }; +// enum ctattr_counters { +// CTA_COUNTERS_UNSPEC, +// CTA_COUNTERS_PACKETS, /* 64bit counters */ +// CTA_COUNTERS_BYTES, /* 64bit counters */ +// CTA_COUNTERS32_PACKETS, /* old 32bit counters, unused */ +// CTA_COUNTERS32_BYTES, /* old 32bit counters, unused */ +// CTA_COUNTERS_PAD, +// __CTA_COUNTERS_M +// }; +// // #define CTA_COUNTERS_MAX (__CTA_COUNTERS_MAX - 1) const ( CTA_COUNTERS_PACKETS = 1 @@ -233,12 +242,14 @@ const ( ) // /* General form of address family dependent message. -// */ -// struct nfgenmsg { -// __u8 nfgen_family; /* AF_xxx */ -// __u8 version; /* nfnetlink version */ -// __be16 res_id; /* resource id */ -// }; +// +// */ +// +// struct nfgenmsg { +// __u8 nfgen_family; /* AF_xxx */ +// __u8 version; /* nfnetlink version */ +// __be16 res_id; /* resource id */ +// }; type Nfgenmsg struct { NfgenFamily uint8 Version uint8 diff --git a/vendor/github.com/vishvananda/netlink/nl/ip6tnl_linux.go b/vendor/github.com/vishvananda/netlink/nl/ip6tnl_linux.go index d5dd69e0c40..aaef89056f1 100644 --- a/vendor/github.com/vishvananda/netlink/nl/ip6tnl_linux.go +++ b/vendor/github.com/vishvananda/netlink/nl/ip6tnl_linux.go @@ -11,11 +11,7 @@ const ( LWTUNNEL_IP6_HOPLIMIT LWTUNNEL_IP6_TC LWTUNNEL_IP6_FLAGS - LWTUNNEL_IP6_PAD // not implemented + LWTUNNEL_IP6_PAD // not implemented LWTUNNEL_IP6_OPTS // not implemented __LWTUNNEL_IP6_MAX ) - - - - diff --git a/vendor/github.com/vishvananda/netlink/nl/nl_unspecified.go b/vendor/github.com/vishvananda/netlink/nl/nl_unspecified.go index dfc0be6606c..818b93c414b 100644 --- a/vendor/github.com/vishvananda/netlink/nl/nl_unspecified.go +++ b/vendor/github.com/vishvananda/netlink/nl/nl_unspecified.go @@ -1,3 +1,4 @@ +//go:build !linux // +build !linux package nl diff --git a/vendor/github.com/vishvananda/netlink/nl/syscall.go b/vendor/github.com/vishvananda/netlink/nl/syscall.go index b5ba039acb3..b46f9fe200f 100644 --- a/vendor/github.com/vishvananda/netlink/nl/syscall.go +++ b/vendor/github.com/vishvananda/netlink/nl/syscall.go @@ -45,8 +45,8 @@ const ( // socket diags related const ( - SOCK_DIAG_BY_FAMILY = 20 /* linux.sock_diag.h */ - SOCK_DESTROY = 21 + SOCK_DIAG_BY_FAMILY = 20 /* linux.sock_diag.h */ + SOCK_DESTROY = 21 TCPDIAG_NOCOOKIE = 0xFFFFFFFF /* TCPDIAG_NOCOOKIE in net/ipv4/tcp_diag.h*/ ) diff --git a/vendor/github.com/vishvananda/netlink/route_unspecified.go b/vendor/github.com/vishvananda/netlink/route_unspecified.go index db737268958..380d50b2008 100644 --- a/vendor/github.com/vishvananda/netlink/route_unspecified.go +++ b/vendor/github.com/vishvananda/netlink/route_unspecified.go @@ -1,3 +1,4 @@ +//go:build !linux // +build !linux package netlink diff --git a/vendor/github.com/yusufpapurcu/wmi/wmi.go b/vendor/github.com/yusufpapurcu/wmi/wmi.go index 03f386ed59c..1b51529d558 100644 --- a/vendor/github.com/yusufpapurcu/wmi/wmi.go +++ b/vendor/github.com/yusufpapurcu/wmi/wmi.go @@ -467,7 +467,7 @@ func (c *Client) loadEntity(dst interface{}, src *ole.IDispatch) (errFieldMismat Reason: "not a Float64", } } - + default: if f.Kind() == reflect.Slice { switch f.Type().Elem().Kind() { diff --git a/vendor/go.yaml.in/yaml/v2/apic.go b/vendor/go.yaml.in/yaml/v2/apic.go index acf71402cf3..fb2821e1e66 100644 --- a/vendor/go.yaml.in/yaml/v2/apic.go +++ b/vendor/go.yaml.in/yaml/v2/apic.go @@ -143,7 +143,7 @@ func yaml_emitter_set_canonical(emitter *yaml_emitter_t, canonical bool) { emitter.canonical = canonical } -//// Set the indentation increment. +// // Set the indentation increment. func yaml_emitter_set_indent(emitter *yaml_emitter_t, indent int) { if indent < 2 || indent > 9 { indent = 2 diff --git a/vendor/go.yaml.in/yaml/v2/emitterc.go b/vendor/go.yaml.in/yaml/v2/emitterc.go index a1c2cc52627..638a268c79b 100644 --- a/vendor/go.yaml.in/yaml/v2/emitterc.go +++ b/vendor/go.yaml.in/yaml/v2/emitterc.go @@ -130,10 +130,9 @@ func yaml_emitter_emit(emitter *yaml_emitter_t, event *yaml_event_t) bool { // Check if we need to accumulate more events before emitting. // // We accumulate extra -// - 1 event for DOCUMENT-START -// - 2 events for SEQUENCE-START -// - 3 events for MAPPING-START -// +// - 1 event for DOCUMENT-START +// - 2 events for SEQUENCE-START +// - 3 events for MAPPING-START func yaml_emitter_need_more_events(emitter *yaml_emitter_t) bool { if emitter.events_head == len(emitter.events) { return true diff --git a/vendor/go.yaml.in/yaml/v2/parserc.go b/vendor/go.yaml.in/yaml/v2/parserc.go index 81d05dfe573..2883e5c58fa 100644 --- a/vendor/go.yaml.in/yaml/v2/parserc.go +++ b/vendor/go.yaml.in/yaml/v2/parserc.go @@ -170,7 +170,8 @@ func yaml_parser_state_machine(parser *yaml_parser_t, event *yaml_event_t) bool // Parse the production: // stream ::= STREAM-START implicit_document? explicit_document* STREAM-END -// ************ +// +// ************ func yaml_parser_parse_stream_start(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -192,9 +193,12 @@ func yaml_parser_parse_stream_start(parser *yaml_parser_t, event *yaml_event_t) // Parse the productions: // implicit_document ::= block_node DOCUMENT-END* -// * +// +// * +// // explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* -// ************************* +// +// ************************* func yaml_parser_parse_document_start(parser *yaml_parser_t, event *yaml_event_t, implicit bool) bool { token := peek_token(parser) @@ -277,8 +281,8 @@ func yaml_parser_parse_document_start(parser *yaml_parser_t, event *yaml_event_t // Parse the productions: // explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* -// *********** // +// *********** func yaml_parser_parse_document_content(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -299,9 +303,10 @@ func yaml_parser_parse_document_content(parser *yaml_parser_t, event *yaml_event // Parse the productions: // implicit_document ::= block_node DOCUMENT-END* -// ************* -// explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* // +// ************* +// +// explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* func yaml_parser_parse_document_end(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -332,30 +337,41 @@ func yaml_parser_parse_document_end(parser *yaml_parser_t, event *yaml_event_t) // Parse the productions: // block_node_or_indentless_sequence ::= -// ALIAS -// ***** -// | properties (block_content | indentless_block_sequence)? -// ********** * -// | block_content | indentless_block_sequence -// * +// +// ALIAS +// ***** +// | properties (block_content | indentless_block_sequence)? +// ********** * +// | block_content | indentless_block_sequence +// * +// // block_node ::= ALIAS -// ***** -// | properties block_content? -// ********** * -// | block_content -// * +// +// ***** +// | properties block_content? +// ********** * +// | block_content +// * +// // flow_node ::= ALIAS -// ***** -// | properties flow_content? -// ********** * -// | flow_content -// * +// +// ***** +// | properties flow_content? +// ********** * +// | flow_content +// * +// // properties ::= TAG ANCHOR? | ANCHOR TAG? -// ************************* +// +// ************************* +// // block_content ::= block_collection | flow_collection | SCALAR -// ****** +// +// ****** +// // flow_content ::= flow_collection | SCALAR -// ****** +// +// ****** func yaml_parser_parse_node(parser *yaml_parser_t, event *yaml_event_t, block, indentless_sequence bool) bool { //defer trace("yaml_parser_parse_node", "block:", block, "indentless_sequence:", indentless_sequence)() @@ -574,8 +590,8 @@ func yaml_parser_parse_node(parser *yaml_parser_t, event *yaml_event_t, block, i // Parse the productions: // block_sequence ::= BLOCK-SEQUENCE-START (BLOCK-ENTRY block_node?)* BLOCK-END -// ******************** *********** * ********* // +// ******************** *********** * ********* func yaml_parser_parse_block_sequence_entry(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -627,7 +643,8 @@ func yaml_parser_parse_block_sequence_entry(parser *yaml_parser_t, event *yaml_e // Parse the productions: // indentless_sequence ::= (BLOCK-ENTRY block_node?)+ -// *********** * +// +// *********** * func yaml_parser_parse_indentless_sequence_entry(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -664,14 +681,14 @@ func yaml_parser_parse_indentless_sequence_entry(parser *yaml_parser_t, event *y // Parse the productions: // block_mapping ::= BLOCK-MAPPING_START -// ******************* -// ((KEY block_node_or_indentless_sequence?)? -// *** * -// (VALUE block_node_or_indentless_sequence?)?)* // -// BLOCK-END -// ********* +// ******************* +// ((KEY block_node_or_indentless_sequence?)? +// *** * +// (VALUE block_node_or_indentless_sequence?)?)* // +// BLOCK-END +// ********* func yaml_parser_parse_block_mapping_key(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -723,13 +740,11 @@ func yaml_parser_parse_block_mapping_key(parser *yaml_parser_t, event *yaml_even // Parse the productions: // block_mapping ::= BLOCK-MAPPING_START // -// ((KEY block_node_or_indentless_sequence?)? -// -// (VALUE block_node_or_indentless_sequence?)?)* -// ***** * -// BLOCK-END -// +// ((KEY block_node_or_indentless_sequence?)? // +// (VALUE block_node_or_indentless_sequence?)?)* +// ***** * +// BLOCK-END func yaml_parser_parse_block_mapping_value(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -757,16 +772,18 @@ func yaml_parser_parse_block_mapping_value(parser *yaml_parser_t, event *yaml_ev // Parse the productions: // flow_sequence ::= FLOW-SEQUENCE-START -// ******************* -// (flow_sequence_entry FLOW-ENTRY)* -// * ********** -// flow_sequence_entry? -// * -// FLOW-SEQUENCE-END -// ***************** +// +// ******************* +// (flow_sequence_entry FLOW-ENTRY)* +// * ********** +// flow_sequence_entry? +// * +// FLOW-SEQUENCE-END +// ***************** +// // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * // +// * func yaml_parser_parse_flow_sequence_entry(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -825,11 +842,10 @@ func yaml_parser_parse_flow_sequence_entry(parser *yaml_parser_t, event *yaml_ev return true } -// // Parse the productions: // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// *** * // +// *** * func yaml_parser_parse_flow_sequence_entry_mapping_key(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -849,8 +865,8 @@ func yaml_parser_parse_flow_sequence_entry_mapping_key(parser *yaml_parser_t, ev // Parse the productions: // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// ***** * // +// ***** * func yaml_parser_parse_flow_sequence_entry_mapping_value(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -873,8 +889,8 @@ func yaml_parser_parse_flow_sequence_entry_mapping_value(parser *yaml_parser_t, // Parse the productions: // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * // +// * func yaml_parser_parse_flow_sequence_entry_mapping_end(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -891,16 +907,17 @@ func yaml_parser_parse_flow_sequence_entry_mapping_end(parser *yaml_parser_t, ev // Parse the productions: // flow_mapping ::= FLOW-MAPPING-START -// ****************** -// (flow_mapping_entry FLOW-ENTRY)* -// * ********** -// flow_mapping_entry? -// ****************** -// FLOW-MAPPING-END -// **************** -// flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * *** * // +// ****************** +// (flow_mapping_entry FLOW-ENTRY)* +// * ********** +// flow_mapping_entry? +// ****************** +// FLOW-MAPPING-END +// **************** +// +// flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? +// - *** * func yaml_parser_parse_flow_mapping_key(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -965,8 +982,7 @@ func yaml_parser_parse_flow_mapping_key(parser *yaml_parser_t, event *yaml_event // Parse the productions: // flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * ***** * -// +// - ***** * func yaml_parser_parse_flow_mapping_value(parser *yaml_parser_t, event *yaml_event_t, empty bool) bool { token := peek_token(parser) if token == nil { diff --git a/vendor/go.yaml.in/yaml/v2/readerc.go b/vendor/go.yaml.in/yaml/v2/readerc.go index 7c1f5fac3db..b0c436c4a84 100644 --- a/vendor/go.yaml.in/yaml/v2/readerc.go +++ b/vendor/go.yaml.in/yaml/v2/readerc.go @@ -95,7 +95,7 @@ func yaml_parser_update_buffer(parser *yaml_parser_t, length int) bool { // [Go] This function was changed to guarantee the requested length size at EOF. // The fact we need to do this is pretty awful, but the description above implies - // for that to be the case, and there are tests + // for that to be the case, and there are tests // If the EOF flag is set and the raw buffer is empty, do nothing. if parser.eof && parser.raw_buffer_pos == len(parser.raw_buffer) { diff --git a/vendor/go.yaml.in/yaml/v2/resolve.go b/vendor/go.yaml.in/yaml/v2/resolve.go index 4120e0c9160..e29c364b339 100644 --- a/vendor/go.yaml.in/yaml/v2/resolve.go +++ b/vendor/go.yaml.in/yaml/v2/resolve.go @@ -180,7 +180,7 @@ func resolve(tag string, in string) (rtag string, out interface{}) { return yaml_INT_TAG, uintv } } else if strings.HasPrefix(plain, "-0b") { - intv, err := strconv.ParseInt("-" + plain[3:], 2, 64) + intv, err := strconv.ParseInt("-"+plain[3:], 2, 64) if err == nil { if true || intv == int64(int(intv)) { return yaml_INT_TAG, int(intv) diff --git a/vendor/go.yaml.in/yaml/v2/scannerc.go b/vendor/go.yaml.in/yaml/v2/scannerc.go index 0b9bb6030a0..d634dca4b04 100644 --- a/vendor/go.yaml.in/yaml/v2/scannerc.go +++ b/vendor/go.yaml.in/yaml/v2/scannerc.go @@ -1500,11 +1500,11 @@ func yaml_parser_scan_to_next_token(parser *yaml_parser_t) bool { // Scan a YAML-DIRECTIVE or TAG-DIRECTIVE token. // // Scope: -// %YAML 1.1 # a comment \n -// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -// %TAG !yaml! tag:yaml.org,2002: \n -// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ // +// %YAML 1.1 # a comment \n +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +// %TAG !yaml! tag:yaml.org,2002: \n +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ func yaml_parser_scan_directive(parser *yaml_parser_t, token *yaml_token_t) bool { // Eat '%'. start_mark := parser.mark @@ -1601,11 +1601,11 @@ func yaml_parser_scan_directive(parser *yaml_parser_t, token *yaml_token_t) bool // Scan the directive name. // // Scope: -// %YAML 1.1 # a comment \n -// ^^^^ -// %TAG !yaml! tag:yaml.org,2002: \n -// ^^^ // +// %YAML 1.1 # a comment \n +// ^^^^ +// %TAG !yaml! tag:yaml.org,2002: \n +// ^^^ func yaml_parser_scan_directive_name(parser *yaml_parser_t, start_mark yaml_mark_t, name *[]byte) bool { // Consume the directive name. if parser.unread < 1 && !yaml_parser_update_buffer(parser, 1) { @@ -1640,8 +1640,9 @@ func yaml_parser_scan_directive_name(parser *yaml_parser_t, start_mark yaml_mark // Scan the value of VERSION-DIRECTIVE. // // Scope: -// %YAML 1.1 # a comment \n -// ^^^^^^ +// +// %YAML 1.1 # a comment \n +// ^^^^^^ func yaml_parser_scan_version_directive_value(parser *yaml_parser_t, start_mark yaml_mark_t, major, minor *int8) bool { // Eat whitespaces. if parser.unread < 1 && !yaml_parser_update_buffer(parser, 1) { @@ -1679,10 +1680,11 @@ const max_number_length = 2 // Scan the version number of VERSION-DIRECTIVE. // // Scope: -// %YAML 1.1 # a comment \n -// ^ -// %YAML 1.1 # a comment \n -// ^ +// +// %YAML 1.1 # a comment \n +// ^ +// %YAML 1.1 # a comment \n +// ^ func yaml_parser_scan_version_directive_number(parser *yaml_parser_t, start_mark yaml_mark_t, number *int8) bool { // Repeat while the next character is digit. @@ -1716,9 +1718,9 @@ func yaml_parser_scan_version_directive_number(parser *yaml_parser_t, start_mark // Scan the value of a TAG-DIRECTIVE token. // // Scope: -// %TAG !yaml! tag:yaml.org,2002: \n -// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ // +// %TAG !yaml! tag:yaml.org,2002: \n +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ func yaml_parser_scan_tag_directive_value(parser *yaml_parser_t, start_mark yaml_mark_t, handle, prefix *[]byte) bool { var handle_value, prefix_value []byte diff --git a/vendor/go.yaml.in/yaml/v2/sorter.go b/vendor/go.yaml.in/yaml/v2/sorter.go index 4c45e660a8f..2edd734055f 100644 --- a/vendor/go.yaml.in/yaml/v2/sorter.go +++ b/vendor/go.yaml.in/yaml/v2/sorter.go @@ -52,7 +52,7 @@ func (l keyList) Less(i, j int) bool { var ai, bi int var an, bn int64 if ar[i] == '0' || br[i] == '0' { - for j := i-1; j >= 0 && unicode.IsDigit(ar[j]); j-- { + for j := i - 1; j >= 0 && unicode.IsDigit(ar[j]); j-- { if ar[j] != '0' { an = 1 bn = 1 diff --git a/vendor/go.yaml.in/yaml/v2/yaml.go b/vendor/go.yaml.in/yaml/v2/yaml.go index 5248e1263c5..cf0aea15de3 100644 --- a/vendor/go.yaml.in/yaml/v2/yaml.go +++ b/vendor/go.yaml.in/yaml/v2/yaml.go @@ -2,8 +2,7 @@ // // Source code and other details for the project are available at GitHub: // -// https://github.com/yaml/go-yaml -// +// https://github.com/yaml/go-yaml package yaml import ( @@ -67,16 +66,15 @@ type Marshaler interface { // // For example: // -// type T struct { -// F int `yaml:"a,omitempty"` -// B int -// } -// var t T -// yaml.Unmarshal([]byte("a: 1\nb: 2"), &t) +// type T struct { +// F int `yaml:"a,omitempty"` +// B int +// } +// var t T +// yaml.Unmarshal([]byte("a: 1\nb: 2"), &t) // // See the documentation of Marshal for the format of tags and a list of // supported tag options. -// func Unmarshal(in []byte, out interface{}) (err error) { return unmarshal(in, out, false) } @@ -166,36 +164,35 @@ func unmarshal(in []byte, out interface{}, strict bool) (err error) { // // The field tag format accepted is: // -// `(...) yaml:"[][,[,]]" (...)` +// `(...) yaml:"[][,[,]]" (...)` // // The following flags are currently supported: // -// omitempty Only include the field if it's not set to the zero -// value for the type or to empty slices or maps. -// Zero valued structs will be omitted if all their public -// fields are zero, unless they implement an IsZero -// method (see the IsZeroer interface type), in which -// case the field will be excluded if IsZero returns true. +// omitempty Only include the field if it's not set to the zero +// value for the type or to empty slices or maps. +// Zero valued structs will be omitted if all their public +// fields are zero, unless they implement an IsZero +// method (see the IsZeroer interface type), in which +// case the field will be excluded if IsZero returns true. // -// flow Marshal using a flow style (useful for structs, -// sequences and maps). +// flow Marshal using a flow style (useful for structs, +// sequences and maps). // -// inline Inline the field, which must be a struct or a map, -// causing all of its fields or keys to be processed as if -// they were part of the outer struct. For maps, keys must -// not conflict with the yaml keys of other struct fields. +// inline Inline the field, which must be a struct or a map, +// causing all of its fields or keys to be processed as if +// they were part of the outer struct. For maps, keys must +// not conflict with the yaml keys of other struct fields. // // In addition, if the key is "-", the field is ignored. // // For example: // -// type T struct { -// F int `yaml:"a,omitempty"` -// B int -// } -// yaml.Marshal(&T{B: 2}) // Returns "b: 2\n" -// yaml.Marshal(&T{F: 1}} // Returns "a: 1\nb: 0\n" -// +// type T struct { +// F int `yaml:"a,omitempty"` +// B int +// } +// yaml.Marshal(&T{B: 2}) // Returns "b: 2\n" +// yaml.Marshal(&T{F: 1}} // Returns "a: 1\nb: 0\n" func Marshal(in interface{}) (out []byte, err error) { defer handleErr(&err) e := newEncoder() diff --git a/vendor/go.yaml.in/yaml/v2/yamlh.go b/vendor/go.yaml.in/yaml/v2/yamlh.go index f6a9c8e34b1..640f9d95de9 100644 --- a/vendor/go.yaml.in/yaml/v2/yamlh.go +++ b/vendor/go.yaml.in/yaml/v2/yamlh.go @@ -408,7 +408,9 @@ type yaml_document_t struct { // The number of written bytes should be set to the size_read variable. // // [in,out] data A pointer to an application data specified by -// yaml_parser_set_input(). +// +// yaml_parser_set_input(). +// // [out] buffer The buffer to write the data from the source. // [in] size The size of the buffer. // [out] size_read The actual number of bytes read from the source. @@ -604,13 +606,14 @@ type yaml_parser_t struct { // @a buffer to the output. // // @param[in,out] data A pointer to an application data specified by -// yaml_emitter_set_output(). +// +// yaml_emitter_set_output(). +// // @param[in] buffer The buffer with bytes to be written. // @param[in] size The size of the buffer. // // @returns On success, the handler should return @c 1. If the handler failed, // the returned value should be @c 0. -// type yaml_write_handler_t func(emitter *yaml_emitter_t, buffer []byte) error type yaml_emitter_state_t int diff --git a/vendor/gopkg.in/inf.v0/dec.go b/vendor/gopkg.in/inf.v0/dec.go index 26548b63cef..124cce1443b 100644 --- a/vendor/gopkg.in/inf.v0/dec.go +++ b/vendor/gopkg.in/inf.v0/dec.go @@ -9,17 +9,16 @@ // This package is currently in experimental stage and the API may change. // // This package does NOT support: -// - rounding to specific precisions (as opposed to specific decimal positions) -// - the notion of context (each rounding must be explicit) -// - NaN and Inf values, and distinguishing between positive and negative zero -// - conversions to and from float32/64 types +// - rounding to specific precisions (as opposed to specific decimal positions) +// - the notion of context (each rounding must be explicit) +// - NaN and Inf values, and distinguishing between positive and negative zero +// - conversions to and from float32/64 types // // Features considered for possible addition: -// + formatting options -// + Exp method -// + combined operations such as AddRound/MulAdd etc -// + exchanging data in decimal32/64/128 formats -// +// - formatting options +// - Exp method +// - combined operations such as AddRound/MulAdd etc +// - exchanging data in decimal32/64/128 formats package inf // import "gopkg.in/inf.v0" // TODO: @@ -43,19 +42,19 @@ import ( // // The mathematical value of a Dec equals: // -// unscaled * 10**(-scale) +// unscaled * 10**(-scale) // // Note that different Dec representations may have equal mathematical values. // -// unscaled scale String() -// ------------------------- -// 0 0 "0" -// 0 2 "0.00" -// 0 -2 "0" -// 1 0 "1" -// 100 2 "1.00" -// 10 0 "10" -// 1 -1 "10" +// unscaled scale String() +// ------------------------- +// 0 0 "0" +// 0 2 "0.00" +// 0 -2 "0" +// 1 0 "1" +// 100 2 "1.00" +// 10 0 "10" +// 1 -1 "10" // // The zero value for a Dec represents the value 0 with scale 0. // @@ -79,7 +78,6 @@ import ( // QuoRound should be used with a Scale and a Rounder. // QuoExact or QuoRound with RoundExact can be used in the special cases when it // is known that the result is always a finite decimal. -// type Dec struct { unscaled big.Int scale Scale @@ -182,7 +180,6 @@ func (z *Dec) Set(x *Dec) *Dec { // -1 if x < 0 // 0 if x == 0 // +1 if x > 0 -// func (x *Dec) Sign() int { return x.UnscaledBig().Sign() } @@ -196,10 +193,9 @@ func (z *Dec) Neg(x *Dec) *Dec { // Cmp compares x and y and returns: // -// -1 if x < y -// 0 if x == y -// +1 if x > y -// +// -1 if x < y +// 0 if x == y +// +1 if x > y func (x *Dec) Cmp(y *Dec) int { xx, yy := upscale(x, y) return xx.UnscaledBig().Cmp(yy.UnscaledBig()) @@ -252,7 +248,6 @@ func (z *Dec) Round(x *Dec, s Scale, r Rounder) *Dec { // // There is no corresponding Div method; the equivalent can be achieved through // the choice of Rounder used. -// func (z *Dec) QuoRound(x, y *Dec, s Scale, r Rounder) *Dec { return z.quo(x, y, sclr{s}, r) } @@ -290,10 +285,9 @@ func (z *Dec) QuoExact(x, y *Dec) *Dec { // The remainder is normalized to the range -1 < r < 1 to simplify rounding; // that is, the results satisfy the following equation: // -// x / y = z + (remNum/remDen) * 10**(-z.Scale()) +// x / y = z + (remNum/remDen) * 10**(-z.Scale()) // // See Rounder for more details about rounding. -// func (z *Dec) quoRem(x, y *Dec, s Scale, useRem bool, remNum, remDen *big.Int) (*Dec, *big.Int, *big.Int) { // difference (required adjustment) compared to "canonical" result scale diff --git a/vendor/gopkg.in/inf.v0/rounder.go b/vendor/gopkg.in/inf.v0/rounder.go index 3a97ef529b9..866180bf4c6 100644 --- a/vendor/gopkg.in/inf.v0/rounder.go +++ b/vendor/gopkg.in/inf.v0/rounder.go @@ -9,7 +9,6 @@ import ( // Dec.Quo(). // // See the Example for results of using each Rounder with some sample values. -// type Rounder rounder // See http://speleotrove.com/decimal/damodel.html#refround for more detailed diff --git a/vendor/gopkg.in/tomb.v1/tomb.go b/vendor/gopkg.in/tomb.v1/tomb.go index 9aec56d821d..35080f86d28 100644 --- a/vendor/gopkg.in/tomb.v1/tomb.go +++ b/vendor/gopkg.in/tomb.v1/tomb.go @@ -1,10 +1,10 @@ // Copyright (c) 2011 - Gustavo Niemeyer -// +// // All rights reserved. -// +// // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are met: -// +// // * Redistributions of source code must retain the above copyright notice, // this list of conditions and the following disclaimer. // * Redistributions in binary form must reproduce the above copyright notice, @@ -13,7 +13,7 @@ // * Neither the name of the copyright holder nor the names of its // contributors may be used to endorse or promote products derived from // this software without specific prior written permission. -// +// // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR @@ -51,13 +51,12 @@ // // For background and a detailed example, see the following blog post: // -// http://blog.labix.org/2011/10/09/death-of-goroutines-under-control +// http://blog.labix.org/2011/10/09/death-of-goroutines-under-control // // For a more complex code snippet demonstrating the use of multiple // goroutines with a single Tomb, see: // -// http://play.golang.org/p/Xh7qWsDPZP -// +// http://play.golang.org/p/Xh7qWsDPZP package tomb import ( @@ -79,7 +78,7 @@ type Tomb struct { var ( ErrStillAlive = errors.New("tomb: still alive") - ErrDying = errors.New("tomb: dying") + ErrDying = errors.New("tomb: dying") ) func (t *Tomb) init() { diff --git a/vendor/gopkg.in/yaml.v3/apic.go b/vendor/gopkg.in/yaml.v3/apic.go index ae7d049f182..05fd305da16 100644 --- a/vendor/gopkg.in/yaml.v3/apic.go +++ b/vendor/gopkg.in/yaml.v3/apic.go @@ -1,17 +1,17 @@ -// +// // Copyright (c) 2011-2019 Canonical Ltd // Copyright (c) 2006-2010 Kirill Simonov -// +// // Permission is hereby granted, free of charge, to any person obtaining a copy of // this software and associated documentation files (the "Software"), to deal in // the Software without restriction, including without limitation the rights to // use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies // of the Software, and to permit persons to whom the Software is furnished to do // so, subject to the following conditions: -// +// // The above copyright notice and this permission notice shall be included in all // copies or substantial portions of the Software. -// +// // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE diff --git a/vendor/gopkg.in/yaml.v3/emitterc.go b/vendor/gopkg.in/yaml.v3/emitterc.go index 0f47c9ca8ad..dde20e5079d 100644 --- a/vendor/gopkg.in/yaml.v3/emitterc.go +++ b/vendor/gopkg.in/yaml.v3/emitterc.go @@ -162,10 +162,9 @@ func yaml_emitter_emit(emitter *yaml_emitter_t, event *yaml_event_t) bool { // Check if we need to accumulate more events before emitting. // // We accumulate extra -// - 1 event for DOCUMENT-START -// - 2 events for SEQUENCE-START -// - 3 events for MAPPING-START -// +// - 1 event for DOCUMENT-START +// - 2 events for SEQUENCE-START +// - 3 events for MAPPING-START func yaml_emitter_need_more_events(emitter *yaml_emitter_t) bool { if emitter.events_head == len(emitter.events) { return true @@ -241,7 +240,7 @@ func yaml_emitter_increase_indent(emitter *yaml_emitter_t, flow, indentless bool emitter.indent += 2 } else { // Everything else aligns to the chosen indentation. - emitter.indent = emitter.best_indent*((emitter.indent+emitter.best_indent)/emitter.best_indent) + emitter.indent = emitter.best_indent * ((emitter.indent + emitter.best_indent) / emitter.best_indent) } } return true diff --git a/vendor/gopkg.in/yaml.v3/parserc.go b/vendor/gopkg.in/yaml.v3/parserc.go index 268558a0d63..25fe823637a 100644 --- a/vendor/gopkg.in/yaml.v3/parserc.go +++ b/vendor/gopkg.in/yaml.v3/parserc.go @@ -227,7 +227,8 @@ func yaml_parser_state_machine(parser *yaml_parser_t, event *yaml_event_t) bool // Parse the production: // stream ::= STREAM-START implicit_document? explicit_document* STREAM-END -// ************ +// +// ************ func yaml_parser_parse_stream_start(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -249,9 +250,12 @@ func yaml_parser_parse_stream_start(parser *yaml_parser_t, event *yaml_event_t) // Parse the productions: // implicit_document ::= block_node DOCUMENT-END* -// * +// +// * +// // explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* -// ************************* +// +// ************************* func yaml_parser_parse_document_start(parser *yaml_parser_t, event *yaml_event_t, implicit bool) bool { token := peek_token(parser) @@ -356,8 +360,8 @@ func yaml_parser_parse_document_start(parser *yaml_parser_t, event *yaml_event_t // Parse the productions: // explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* -// *********** // +// *********** func yaml_parser_parse_document_content(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -379,9 +383,10 @@ func yaml_parser_parse_document_content(parser *yaml_parser_t, event *yaml_event // Parse the productions: // implicit_document ::= block_node DOCUMENT-END* -// ************* -// explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* // +// ************* +// +// explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END* func yaml_parser_parse_document_end(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -428,30 +433,41 @@ func yaml_parser_set_event_comments(parser *yaml_parser_t, event *yaml_event_t) // Parse the productions: // block_node_or_indentless_sequence ::= -// ALIAS -// ***** -// | properties (block_content | indentless_block_sequence)? -// ********** * -// | block_content | indentless_block_sequence -// * +// +// ALIAS +// ***** +// | properties (block_content | indentless_block_sequence)? +// ********** * +// | block_content | indentless_block_sequence +// * +// // block_node ::= ALIAS -// ***** -// | properties block_content? -// ********** * -// | block_content -// * +// +// ***** +// | properties block_content? +// ********** * +// | block_content +// * +// // flow_node ::= ALIAS -// ***** -// | properties flow_content? -// ********** * -// | flow_content -// * +// +// ***** +// | properties flow_content? +// ********** * +// | flow_content +// * +// // properties ::= TAG ANCHOR? | ANCHOR TAG? -// ************************* +// +// ************************* +// // block_content ::= block_collection | flow_collection | SCALAR -// ****** +// +// ****** +// // flow_content ::= flow_collection | SCALAR -// ****** +// +// ****** func yaml_parser_parse_node(parser *yaml_parser_t, event *yaml_event_t, block, indentless_sequence bool) bool { //defer trace("yaml_parser_parse_node", "block:", block, "indentless_sequence:", indentless_sequence)() @@ -682,8 +698,8 @@ func yaml_parser_parse_node(parser *yaml_parser_t, event *yaml_event_t, block, i // Parse the productions: // block_sequence ::= BLOCK-SEQUENCE-START (BLOCK-ENTRY block_node?)* BLOCK-END -// ******************** *********** * ********* // +// ******************** *********** * ********* func yaml_parser_parse_block_sequence_entry(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -740,7 +756,8 @@ func yaml_parser_parse_block_sequence_entry(parser *yaml_parser_t, event *yaml_e // Parse the productions: // indentless_sequence ::= (BLOCK-ENTRY block_node?)+ -// *********** * +// +// *********** * func yaml_parser_parse_indentless_sequence_entry(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -805,14 +822,14 @@ func yaml_parser_split_stem_comment(parser *yaml_parser_t, stem_len int) { // Parse the productions: // block_mapping ::= BLOCK-MAPPING_START -// ******************* -// ((KEY block_node_or_indentless_sequence?)? -// *** * -// (VALUE block_node_or_indentless_sequence?)?)* // -// BLOCK-END -// ********* +// ******************* +// ((KEY block_node_or_indentless_sequence?)? +// *** * +// (VALUE block_node_or_indentless_sequence?)?)* // +// BLOCK-END +// ********* func yaml_parser_parse_block_mapping_key(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -881,13 +898,11 @@ func yaml_parser_parse_block_mapping_key(parser *yaml_parser_t, event *yaml_even // Parse the productions: // block_mapping ::= BLOCK-MAPPING_START // -// ((KEY block_node_or_indentless_sequence?)? -// -// (VALUE block_node_or_indentless_sequence?)?)* -// ***** * -// BLOCK-END -// +// ((KEY block_node_or_indentless_sequence?)? // +// (VALUE block_node_or_indentless_sequence?)?)* +// ***** * +// BLOCK-END func yaml_parser_parse_block_mapping_value(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -915,16 +930,18 @@ func yaml_parser_parse_block_mapping_value(parser *yaml_parser_t, event *yaml_ev // Parse the productions: // flow_sequence ::= FLOW-SEQUENCE-START -// ******************* -// (flow_sequence_entry FLOW-ENTRY)* -// * ********** -// flow_sequence_entry? -// * -// FLOW-SEQUENCE-END -// ***************** +// +// ******************* +// (flow_sequence_entry FLOW-ENTRY)* +// * ********** +// flow_sequence_entry? +// * +// FLOW-SEQUENCE-END +// ***************** +// // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * // +// * func yaml_parser_parse_flow_sequence_entry(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -987,11 +1004,10 @@ func yaml_parser_parse_flow_sequence_entry(parser *yaml_parser_t, event *yaml_ev return true } -// // Parse the productions: // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// *** * // +// *** * func yaml_parser_parse_flow_sequence_entry_mapping_key(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -1011,8 +1027,8 @@ func yaml_parser_parse_flow_sequence_entry_mapping_key(parser *yaml_parser_t, ev // Parse the productions: // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// ***** * // +// ***** * func yaml_parser_parse_flow_sequence_entry_mapping_value(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -1035,8 +1051,8 @@ func yaml_parser_parse_flow_sequence_entry_mapping_value(parser *yaml_parser_t, // Parse the productions: // flow_sequence_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * // +// * func yaml_parser_parse_flow_sequence_entry_mapping_end(parser *yaml_parser_t, event *yaml_event_t) bool { token := peek_token(parser) if token == nil { @@ -1053,16 +1069,17 @@ func yaml_parser_parse_flow_sequence_entry_mapping_end(parser *yaml_parser_t, ev // Parse the productions: // flow_mapping ::= FLOW-MAPPING-START -// ****************** -// (flow_mapping_entry FLOW-ENTRY)* -// * ********** -// flow_mapping_entry? -// ****************** -// FLOW-MAPPING-END -// **************** -// flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * *** * // +// ****************** +// (flow_mapping_entry FLOW-ENTRY)* +// * ********** +// flow_mapping_entry? +// ****************** +// FLOW-MAPPING-END +// **************** +// +// flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? +// - *** * func yaml_parser_parse_flow_mapping_key(parser *yaml_parser_t, event *yaml_event_t, first bool) bool { if first { token := peek_token(parser) @@ -1128,8 +1145,7 @@ func yaml_parser_parse_flow_mapping_key(parser *yaml_parser_t, event *yaml_event // Parse the productions: // flow_mapping_entry ::= flow_node | KEY flow_node? (VALUE flow_node?)? -// * ***** * -// +// - ***** * func yaml_parser_parse_flow_mapping_value(parser *yaml_parser_t, event *yaml_event_t, empty bool) bool { token := peek_token(parser) if token == nil { diff --git a/vendor/gopkg.in/yaml.v3/readerc.go b/vendor/gopkg.in/yaml.v3/readerc.go index b7de0a89c46..56af245366f 100644 --- a/vendor/gopkg.in/yaml.v3/readerc.go +++ b/vendor/gopkg.in/yaml.v3/readerc.go @@ -1,17 +1,17 @@ -// +// // Copyright (c) 2011-2019 Canonical Ltd // Copyright (c) 2006-2010 Kirill Simonov -// +// // Permission is hereby granted, free of charge, to any person obtaining a copy of // this software and associated documentation files (the "Software"), to deal in // the Software without restriction, including without limitation the rights to // use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies // of the Software, and to permit persons to whom the Software is furnished to do // so, subject to the following conditions: -// +// // The above copyright notice and this permission notice shall be included in all // copies or substantial portions of the Software. -// +// // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE diff --git a/vendor/gopkg.in/yaml.v3/scannerc.go b/vendor/gopkg.in/yaml.v3/scannerc.go index ca0070108f4..30b1f08920a 100644 --- a/vendor/gopkg.in/yaml.v3/scannerc.go +++ b/vendor/gopkg.in/yaml.v3/scannerc.go @@ -1614,11 +1614,11 @@ func yaml_parser_scan_to_next_token(parser *yaml_parser_t) bool { // Scan a YAML-DIRECTIVE or TAG-DIRECTIVE token. // // Scope: -// %YAML 1.1 # a comment \n -// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -// %TAG !yaml! tag:yaml.org,2002: \n -// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ // +// %YAML 1.1 # a comment \n +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +// %TAG !yaml! tag:yaml.org,2002: \n +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ func yaml_parser_scan_directive(parser *yaml_parser_t, token *yaml_token_t) bool { // Eat '%'. start_mark := parser.mark @@ -1719,11 +1719,11 @@ func yaml_parser_scan_directive(parser *yaml_parser_t, token *yaml_token_t) bool // Scan the directive name. // // Scope: -// %YAML 1.1 # a comment \n -// ^^^^ -// %TAG !yaml! tag:yaml.org,2002: \n -// ^^^ // +// %YAML 1.1 # a comment \n +// ^^^^ +// %TAG !yaml! tag:yaml.org,2002: \n +// ^^^ func yaml_parser_scan_directive_name(parser *yaml_parser_t, start_mark yaml_mark_t, name *[]byte) bool { // Consume the directive name. if parser.unread < 1 && !yaml_parser_update_buffer(parser, 1) { @@ -1758,8 +1758,9 @@ func yaml_parser_scan_directive_name(parser *yaml_parser_t, start_mark yaml_mark // Scan the value of VERSION-DIRECTIVE. // // Scope: -// %YAML 1.1 # a comment \n -// ^^^^^^ +// +// %YAML 1.1 # a comment \n +// ^^^^^^ func yaml_parser_scan_version_directive_value(parser *yaml_parser_t, start_mark yaml_mark_t, major, minor *int8) bool { // Eat whitespaces. if parser.unread < 1 && !yaml_parser_update_buffer(parser, 1) { @@ -1797,10 +1798,11 @@ const max_number_length = 2 // Scan the version number of VERSION-DIRECTIVE. // // Scope: -// %YAML 1.1 # a comment \n -// ^ -// %YAML 1.1 # a comment \n -// ^ +// +// %YAML 1.1 # a comment \n +// ^ +// %YAML 1.1 # a comment \n +// ^ func yaml_parser_scan_version_directive_number(parser *yaml_parser_t, start_mark yaml_mark_t, number *int8) bool { // Repeat while the next character is digit. @@ -1834,9 +1836,9 @@ func yaml_parser_scan_version_directive_number(parser *yaml_parser_t, start_mark // Scan the value of a TAG-DIRECTIVE token. // // Scope: -// %TAG !yaml! tag:yaml.org,2002: \n -// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ // +// %TAG !yaml! tag:yaml.org,2002: \n +// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ func yaml_parser_scan_tag_directive_value(parser *yaml_parser_t, start_mark yaml_mark_t, handle, prefix *[]byte) bool { var handle_value, prefix_value []byte @@ -2847,7 +2849,7 @@ func yaml_parser_scan_line_comment(parser *yaml_parser_t, token_mark yaml_mark_t continue } if parser.buffer[parser.buffer_pos+peek] == '#' { - seen := parser.mark.index+peek + seen := parser.mark.index + peek for { if parser.unread < 1 && !yaml_parser_update_buffer(parser, 1) { return false @@ -2876,7 +2878,7 @@ func yaml_parser_scan_line_comment(parser *yaml_parser_t, token_mark yaml_mark_t parser.comments = append(parser.comments, yaml_comment_t{ token_mark: token_mark, start_mark: start_mark, - line: text, + line: text, }) } return true @@ -2910,7 +2912,7 @@ func yaml_parser_scan_comments(parser *yaml_parser_t, scan_mark yaml_mark_t) boo // the foot is the line below it. var foot_line = -1 if scan_mark.line > 0 { - foot_line = parser.mark.line-parser.newlines+1 + foot_line = parser.mark.line - parser.newlines + 1 if parser.newlines == 0 && parser.mark.column > 1 { foot_line++ } @@ -2996,7 +2998,7 @@ func yaml_parser_scan_comments(parser *yaml_parser_t, scan_mark yaml_mark_t) boo recent_empty = false // Consume until after the consumed comment line. - seen := parser.mark.index+peek + seen := parser.mark.index + peek for { if parser.unread < 1 && !yaml_parser_update_buffer(parser, 1) { return false diff --git a/vendor/gopkg.in/yaml.v3/writerc.go b/vendor/gopkg.in/yaml.v3/writerc.go index b8a116bf9a2..266d0b092c0 100644 --- a/vendor/gopkg.in/yaml.v3/writerc.go +++ b/vendor/gopkg.in/yaml.v3/writerc.go @@ -1,17 +1,17 @@ -// +// // Copyright (c) 2011-2019 Canonical Ltd // Copyright (c) 2006-2010 Kirill Simonov -// +// // Permission is hereby granted, free of charge, to any person obtaining a copy of // this software and associated documentation files (the "Software"), to deal in // the Software without restriction, including without limitation the rights to // use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies // of the Software, and to permit persons to whom the Software is furnished to do // so, subject to the following conditions: -// +// // The above copyright notice and this permission notice shall be included in all // copies or substantial portions of the Software. -// +// // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE diff --git a/vendor/gopkg.in/yaml.v3/yaml.go b/vendor/gopkg.in/yaml.v3/yaml.go index 8cec6da48d3..f0bedf3d63c 100644 --- a/vendor/gopkg.in/yaml.v3/yaml.go +++ b/vendor/gopkg.in/yaml.v3/yaml.go @@ -17,8 +17,7 @@ // // Source code and other details for the project are available at GitHub: // -// https://github.com/go-yaml/yaml -// +// https://github.com/go-yaml/yaml package yaml import ( @@ -75,16 +74,15 @@ type Marshaler interface { // // For example: // -// type T struct { -// F int `yaml:"a,omitempty"` -// B int -// } -// var t T -// yaml.Unmarshal([]byte("a: 1\nb: 2"), &t) +// type T struct { +// F int `yaml:"a,omitempty"` +// B int +// } +// var t T +// yaml.Unmarshal([]byte("a: 1\nb: 2"), &t) // // See the documentation of Marshal for the format of tags and a list of // supported tag options. -// func Unmarshal(in []byte, out interface{}) (err error) { return unmarshal(in, out, false) } @@ -185,36 +183,35 @@ func unmarshal(in []byte, out interface{}, strict bool) (err error) { // // The field tag format accepted is: // -// `(...) yaml:"[][,[,]]" (...)` +// `(...) yaml:"[][,[,]]" (...)` // // The following flags are currently supported: // -// omitempty Only include the field if it's not set to the zero -// value for the type or to empty slices or maps. -// Zero valued structs will be omitted if all their public -// fields are zero, unless they implement an IsZero -// method (see the IsZeroer interface type), in which -// case the field will be excluded if IsZero returns true. +// omitempty Only include the field if it's not set to the zero +// value for the type or to empty slices or maps. +// Zero valued structs will be omitted if all their public +// fields are zero, unless they implement an IsZero +// method (see the IsZeroer interface type), in which +// case the field will be excluded if IsZero returns true. // -// flow Marshal using a flow style (useful for structs, -// sequences and maps). +// flow Marshal using a flow style (useful for structs, +// sequences and maps). // -// inline Inline the field, which must be a struct or a map, -// causing all of its fields or keys to be processed as if -// they were part of the outer struct. For maps, keys must -// not conflict with the yaml keys of other struct fields. +// inline Inline the field, which must be a struct or a map, +// causing all of its fields or keys to be processed as if +// they were part of the outer struct. For maps, keys must +// not conflict with the yaml keys of other struct fields. // // In addition, if the key is "-", the field is ignored. // // For example: // -// type T struct { -// F int `yaml:"a,omitempty"` -// B int -// } -// yaml.Marshal(&T{B: 2}) // Returns "b: 2\n" -// yaml.Marshal(&T{F: 1}} // Returns "a: 1\nb: 0\n" -// +// type T struct { +// F int `yaml:"a,omitempty"` +// B int +// } +// yaml.Marshal(&T{B: 2}) // Returns "b: 2\n" +// yaml.Marshal(&T{F: 1}} // Returns "a: 1\nb: 0\n" func Marshal(in interface{}) (out []byte, err error) { defer handleErr(&err) e := newEncoder() @@ -358,22 +355,21 @@ const ( // // For example: // -// var person struct { -// Name string -// Address yaml.Node -// } -// err := yaml.Unmarshal(data, &person) -// -// Or by itself: +// var person struct { +// Name string +// Address yaml.Node +// } +// err := yaml.Unmarshal(data, &person) // -// var person Node -// err := yaml.Unmarshal(data, &person) +// Or by itself: // +// var person Node +// err := yaml.Unmarshal(data, &person) type Node struct { // Kind defines whether the node is a document, a mapping, a sequence, // a scalar value, or an alias to another node. The specific data type of // scalar nodes may be obtained via the ShortTag and LongTag methods. - Kind Kind + Kind Kind // Style allows customizing the apperance of the node in the tree. Style Style @@ -421,7 +417,6 @@ func (n *Node) IsZero() bool { n.HeadComment == "" && n.LineComment == "" && n.FootComment == "" && n.Line == 0 && n.Column == 0 } - // LongTag returns the long form of the tag that indicates the data type for // the node. If the Tag field isn't explicitly defined, one will be computed // based on the node properties. diff --git a/vendor/gopkg.in/yaml.v3/yamlh.go b/vendor/gopkg.in/yaml.v3/yamlh.go index 7c6d0077061..ddcd5513ba7 100644 --- a/vendor/gopkg.in/yaml.v3/yamlh.go +++ b/vendor/gopkg.in/yaml.v3/yamlh.go @@ -438,7 +438,9 @@ type yaml_document_t struct { // The number of written bytes should be set to the size_read variable. // // [in,out] data A pointer to an application data specified by -// yaml_parser_set_input(). +// +// yaml_parser_set_input(). +// // [out] buffer The buffer to write the data from the source. // [in] size The size of the buffer. // [out] size_read The actual number of bytes read from the source. @@ -639,7 +641,6 @@ type yaml_parser_t struct { } type yaml_comment_t struct { - scan_mark yaml_mark_t // Position where scanning for comments started token_mark yaml_mark_t // Position after which tokens will be associated with this comment start_mark yaml_mark_t // Position of '#' comment mark @@ -659,13 +660,14 @@ type yaml_comment_t struct { // @a buffer to the output. // // @param[in,out] data A pointer to an application data specified by -// yaml_emitter_set_output(). +// +// yaml_emitter_set_output(). +// // @param[in] buffer The buffer with bytes to be written. // @param[in] size The size of the buffer. // // @returns On success, the handler should return @c 1. If the handler failed, // the returned value should be @c 0. -// type yaml_write_handler_t func(emitter *yaml_emitter_t, buffer []byte) error type yaml_emitter_state_t int diff --git a/vendor/gopkg.in/yaml.v3/yamlprivateh.go b/vendor/gopkg.in/yaml.v3/yamlprivateh.go index e88f9c54aec..dea1ba9610d 100644 --- a/vendor/gopkg.in/yaml.v3/yamlprivateh.go +++ b/vendor/gopkg.in/yaml.v3/yamlprivateh.go @@ -1,17 +1,17 @@ -// +// // Copyright (c) 2011-2019 Canonical Ltd // Copyright (c) 2006-2010 Kirill Simonov -// +// // Permission is hereby granted, free of charge, to any person obtaining a copy of // this software and associated documentation files (the "Software"), to deal in // the Software without restriction, including without limitation the rights to // use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies // of the Software, and to permit persons to whom the Software is furnished to do // so, subject to the following conditions: -// +// // The above copyright notice and this permission notice shall be included in all // copies or substantial portions of the Software. -// +// // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE @@ -137,8 +137,8 @@ func is_crlf(b []byte, i int) bool { func is_breakz(b []byte, i int) bool { //return is_break(b, i) || is_z(b, i) return ( - // is_break: - b[i] == '\r' || // CR (#xD) + // is_break: + b[i] == '\r' || // CR (#xD) b[i] == '\n' || // LF (#xA) b[i] == 0xC2 && b[i+1] == 0x85 || // NEL (#x85) b[i] == 0xE2 && b[i+1] == 0x80 && b[i+2] == 0xA8 || // LS (#x2028) @@ -151,8 +151,8 @@ func is_breakz(b []byte, i int) bool { func is_spacez(b []byte, i int) bool { //return is_space(b, i) || is_breakz(b, i) return ( - // is_space: - b[i] == ' ' || + // is_space: + b[i] == ' ' || // is_breakz: b[i] == '\r' || // CR (#xD) b[i] == '\n' || // LF (#xA) @@ -166,8 +166,8 @@ func is_spacez(b []byte, i int) bool { func is_blankz(b []byte, i int) bool { //return is_blank(b, i) || is_breakz(b, i) return ( - // is_blank: - b[i] == ' ' || b[i] == '\t' || + // is_blank: + b[i] == ' ' || b[i] == '\t' || // is_breakz: b[i] == '\r' || // CR (#xD) b[i] == '\n' || // LF (#xA)