")
+ case reflect.Struct, reflect.Map, reflect.Slice:
+ return s.encode, nil
+ }
+
+ // If the map value doesn't have a struct/map/slice, just Encode() it.
+ if err := s.enc.Encode(s.s.Interface()); err != nil {
+ return nil, err
+ }
+ s.buff.Truncate(s.buff.Len() - 1) // Remove Encode added \n
+
+ return nil, nil
+}
+
+func (s *sliceEncode) encode() (stateFn, error) {
+ s.buff.WriteByte(leftParen)
+ for i := 0; i < s.s.Len(); i++ {
+ v := s.s.Index(i)
+ switch s.valueBaseType.Kind() {
+ case reflect.Struct:
+ if v.CanAddr() {
+ v = v.Addr()
+ }
+ if err := marshalStruct(v, s.buff, s.enc); err != nil {
+ return nil, err
+ }
+ case reflect.Map:
+ if err := marshalMap(v, s.buff, s.enc); err != nil {
+ return nil, err
+ }
+ case reflect.Slice:
+ if err := marshalSlice(v, s.buff, s.enc); err != nil {
+ return nil, err
+ }
+ default:
+ panic(fmt.Sprintf("critical bug: mapEncode.encode() called with value base type: %v", s.valueBaseType.Kind()))
+ }
+ s.buff.WriteByte(comma)
+ }
+ s.buff.Truncate(s.buff.Len() - 1) // Remove final comma
+ s.buff.WriteByte(rightParen)
+ return nil, nil
+}
+
+// writeAddFields writes the AdditionalFields struct field out to JSON as field
+// values. i must be a map[string]interface{} or this will panic.
+func writeAddFields(i interface{}, buff *bytes.Buffer, enc *json.Encoder) error {
+ m := i.(map[string]interface{})
+
+ x := 0
+ for k, v := range m {
+ buff.WriteString(fmt.Sprintf("%q:", k))
+ if err := enc.Encode(v); err != nil {
+ return err
+ }
+ buff.Truncate(buff.Len() - 1) // Remove Encode() added \n
+
+ if x+1 != len(m) {
+ buff.WriteByte(comma)
+ }
+ x++
+ }
+ return nil
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/json/struct.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/json/struct.go
new file mode 100644
index 00000000000..07751544a28
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/json/struct.go
@@ -0,0 +1,290 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+package json
+
+import (
+ "encoding/json"
+ "fmt"
+ "reflect"
+ "strings"
+)
+
+func unmarshalStruct(jdec *json.Decoder, i interface{}) error {
+ v := reflect.ValueOf(i)
+ if v.Kind() != reflect.Ptr {
+ return fmt.Errorf("Unmarshal() received type %T, which is not a *struct", i)
+ }
+ v = v.Elem()
+ if v.Kind() != reflect.Struct {
+ return fmt.Errorf("Unmarshal() received type %T, which is not a *struct", i)
+ }
+
+ if hasUnmarshalJSON(v) {
+ // Indicates that this type has a custom Unmarshaler.
+ return jdec.Decode(v.Addr().Interface())
+ }
+
+ f := v.FieldByName(addField)
+ if f.Kind() == reflect.Invalid {
+ return fmt.Errorf("Unmarshal(%T) only supports structs that have the field AdditionalFields or implements json.Unmarshaler", i)
+ }
+
+ if f.Kind() != reflect.Map || !f.Type().AssignableTo(mapStrInterType) {
+ return fmt.Errorf("type %T has field 'AdditionalFields' that is not a map[string]interface{}", i)
+ }
+
+ dec := newDecoder(jdec, v)
+ return dec.run()
+}
+
+type decoder struct {
+ dec *json.Decoder
+ value reflect.Value // This will be a reflect.Struct
+ translator translateFields
+ key string
+}
+
+func newDecoder(dec *json.Decoder, value reflect.Value) *decoder {
+ return &decoder{value: value, dec: dec}
+}
+
+// run runs our decoder state machine.
+func (d *decoder) run() error {
+ var state = d.start
+ var err error
+ for {
+ state, err = state()
+ if err != nil {
+ return err
+ }
+ if state == nil {
+ return nil
+ }
+ }
+}
+
+// start looks for our opening delimeter '{' and then transitions to looping through our fields.
+func (d *decoder) start() (stateFn, error) {
+ var err error
+ d.translator, err = findFields(d.value)
+ if err != nil {
+ return nil, err
+ }
+
+ delim, err := d.dec.Token()
+ if err != nil {
+ return nil, err
+ }
+ if !delimIs(delim, '{') {
+ return nil, fmt.Errorf("Unmarshal expected opening {, received %v", delim)
+ }
+
+ return d.next, nil
+}
+
+// next gets the next struct field name from the raw json or stops the machine if we get our closing }.
+func (d *decoder) next() (stateFn, error) {
+ if !d.dec.More() {
+ // Remove the closing }.
+ if _, err := d.dec.Token(); err != nil {
+ return nil, err
+ }
+ return nil, nil
+ }
+
+ key, err := d.dec.Token()
+ if err != nil {
+ return nil, err
+ }
+
+ d.key = key.(string)
+ return d.storeValue, nil
+}
+
+// storeValue takes the next value and stores it our struct. If the field can't be found
+// in the struct, it pushes the operation to storeAdditional().
+func (d *decoder) storeValue() (stateFn, error) {
+ goName := d.translator.goName(d.key)
+ if goName == "" {
+ goName = d.key
+ }
+
+ // We don't have the field in the struct, so it goes in AdditionalFields.
+ f := d.value.FieldByName(goName)
+ if f.Kind() == reflect.Invalid {
+ return d.storeAdditional, nil
+ }
+
+ // Indicates that this type has a custom Unmarshaler.
+ if hasUnmarshalJSON(f) {
+ err := d.dec.Decode(f.Addr().Interface())
+ if err != nil {
+ return nil, err
+ }
+ return d.next, nil
+ }
+
+ t, isPtr, err := fieldBaseType(d.value, goName)
+ if err != nil {
+ return nil, fmt.Errorf("type(%s) had field(%s) %w", d.value.Type().Name(), goName, err)
+ }
+
+ switch t.Kind() {
+ // We need to recursively call ourselves on any *struct or struct.
+ case reflect.Struct:
+ if isPtr {
+ if f.IsNil() {
+ f.Set(reflect.New(t))
+ }
+ } else {
+ f = f.Addr()
+ }
+ if err := unmarshalStruct(d.dec, f.Interface()); err != nil {
+ return nil, err
+ }
+ return d.next, nil
+ case reflect.Map:
+ v := reflect.MakeMap(f.Type())
+ ptr := newValue(f.Type())
+ ptr.Elem().Set(v)
+ if err := unmarshalMap(d.dec, ptr); err != nil {
+ return nil, err
+ }
+ f.Set(ptr.Elem())
+ return d.next, nil
+ case reflect.Slice:
+ v := reflect.MakeSlice(f.Type(), 0, 0)
+ ptr := newValue(f.Type())
+ ptr.Elem().Set(v)
+ if err := unmarshalSlice(d.dec, ptr); err != nil {
+ return nil, err
+ }
+ f.Set(ptr.Elem())
+ return d.next, nil
+ }
+
+ if !isPtr {
+ f = f.Addr()
+ }
+
+ // For values that are pointers, we need them to be non-nil in order
+ // to decode into them.
+ if f.IsNil() {
+ f.Set(reflect.New(t))
+ }
+
+ if err := d.dec.Decode(f.Interface()); err != nil {
+ return nil, err
+ }
+
+ return d.next, nil
+}
+
+// storeAdditional pushes the key/value into our .AdditionalFields map.
+func (d *decoder) storeAdditional() (stateFn, error) {
+ rw := json.RawMessage{}
+ if err := d.dec.Decode(&rw); err != nil {
+ return nil, err
+ }
+ field := d.value.FieldByName(addField)
+ if field.IsNil() {
+ field.Set(reflect.MakeMap(field.Type()))
+ }
+ field.SetMapIndex(reflect.ValueOf(d.key), reflect.ValueOf(rw))
+ return d.next, nil
+}
+
+func fieldBaseType(v reflect.Value, fieldName string) (t reflect.Type, isPtr bool, err error) {
+ sf, ok := v.Type().FieldByName(fieldName)
+ if !ok {
+ return nil, false, fmt.Errorf("bug: fieldBaseType() lookup of field(%s) on type(%s): do not have field", fieldName, v.Type().Name())
+ }
+ t = sf.Type
+ if t.Kind() == reflect.Ptr {
+ t = t.Elem()
+ isPtr = true
+ }
+ if t.Kind() == reflect.Ptr {
+ return nil, isPtr, fmt.Errorf("received pointer to pointer type, not supported")
+ }
+ return t, isPtr, nil
+}
+
+type translateField struct {
+ jsonName string
+ goName string
+}
+
+// translateFields is a list of translateFields with a handy lookup method.
+type translateFields []translateField
+
+// goName loops through a list of fields looking for one contaning the jsonName and
+// returning the goName. If not found, returns the empty string.
+// Note: not a map because at this size slices are faster even in tight loops.
+func (t translateFields) goName(jsonName string) string {
+ for _, entry := range t {
+ if entry.jsonName == jsonName {
+ return entry.goName
+ }
+ }
+ return ""
+}
+
+// jsonName loops through a list of fields looking for one contaning the goName and
+// returning the jsonName. If not found, returns the empty string.
+// Note: not a map because at this size slices are faster even in tight loops.
+func (t translateFields) jsonName(goName string) string {
+ for _, entry := range t {
+ if entry.goName == goName {
+ return entry.jsonName
+ }
+ }
+ return ""
+}
+
+var umarshalerType = reflect.TypeOf((*json.Unmarshaler)(nil)).Elem()
+
+// findFields parses a struct and writes the field tags for lookup. It will return an error
+// if any field has a type of *struct or struct that does not implement json.Marshaler.
+func findFields(v reflect.Value) (translateFields, error) {
+ if v.Kind() == reflect.Ptr {
+ v = v.Elem()
+ }
+ if v.Kind() != reflect.Struct {
+ return nil, fmt.Errorf("findFields received a %s type, expected *struct or struct", v.Type().Name())
+ }
+ tfs := make([]translateField, 0, v.NumField())
+ for i := 0; i < v.NumField(); i++ {
+ tf := translateField{
+ goName: v.Type().Field(i).Name,
+ jsonName: parseTag(v.Type().Field(i).Tag.Get("json")),
+ }
+ switch tf.jsonName {
+ case "", "-":
+ tf.jsonName = tf.goName
+ }
+ tfs = append(tfs, tf)
+
+ f := v.Field(i)
+ if f.Kind() == reflect.Ptr {
+ f = f.Elem()
+ }
+ if f.Kind() == reflect.Struct {
+ if f.Type().Implements(umarshalerType) {
+ return nil, fmt.Errorf("struct type %q which has field %q which "+
+ "doesn't implement json.Unmarshaler", v.Type().Name(), v.Type().Field(i).Name)
+ }
+ }
+ }
+ return tfs, nil
+}
+
+// parseTag just returns the first entry in the tag. tag is the string
+// returned by reflect.StructField.Tag().Get().
+func parseTag(tag string) string {
+ if idx := strings.Index(tag, ","); idx != -1 {
+ return tag[:idx]
+ }
+ return tag
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/json/types/time/time.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/json/types/time/time.go
new file mode 100644
index 00000000000..a1c99621e9f
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/json/types/time/time.go
@@ -0,0 +1,70 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+// Package time provides for custom types to translate time from JSON and other formats
+// into time.Time objects.
+package time
+
+import (
+ "fmt"
+ "strconv"
+ "strings"
+ "time"
+)
+
+// Unix provides a type that can marshal and unmarshal a string representation
+// of the unix epoch into a time.Time object.
+type Unix struct {
+ T time.Time
+}
+
+// MarshalJSON implements encoding/json.MarshalJSON().
+func (u Unix) MarshalJSON() ([]byte, error) {
+ if u.T.IsZero() {
+ return []byte(""), nil
+ }
+ return []byte(fmt.Sprintf("%q", strconv.FormatInt(u.T.Unix(), 10))), nil
+}
+
+// UnmarshalJSON implements encoding/json.UnmarshalJSON().
+func (u *Unix) UnmarshalJSON(b []byte) error {
+ i, err := strconv.Atoi(strings.Trim(string(b), `"`))
+ if err != nil {
+ return fmt.Errorf("unix time(%s) could not be converted from string to int: %w", string(b), err)
+ }
+ u.T = time.Unix(int64(i), 0)
+ return nil
+}
+
+// DurationTime provides a type that can marshal and unmarshal a string representation
+// of a duration from now into a time.Time object.
+// Note: I'm not sure this is the best way to do this. What happens is we get a field
+// called "expires_in" that represents the seconds from now that this expires. We
+// turn that into a time we call .ExpiresOn. But maybe we should be recording
+// when the token was received at .TokenRecieved and .ExpiresIn should remain as a duration.
+// Then we could have a method called ExpiresOn(). Honestly, the whole thing is
+// bad because the server doesn't return a concrete time. I think this is
+// cleaner, but its not great either.
+type DurationTime struct {
+ T time.Time
+}
+
+// MarshalJSON implements encoding/json.MarshalJSON().
+func (d DurationTime) MarshalJSON() ([]byte, error) {
+ if d.T.IsZero() {
+ return []byte(""), nil
+ }
+
+ dt := time.Until(d.T)
+ return []byte(fmt.Sprintf("%d", int64(dt*time.Second))), nil
+}
+
+// UnmarshalJSON implements encoding/json.UnmarshalJSON().
+func (d *DurationTime) UnmarshalJSON(b []byte) error {
+ i, err := strconv.Atoi(strings.Trim(string(b), `"`))
+ if err != nil {
+ return fmt.Errorf("unix time(%s) could not be converted from string to int: %w", string(b), err)
+ }
+ d.T = time.Now().Add(time.Duration(i) * time.Second)
+ return nil
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/local/server.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/local/server.go
new file mode 100644
index 00000000000..04236ff3127
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/local/server.go
@@ -0,0 +1,177 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+// Package local contains a local HTTP server used with interactive authentication.
+package local
+
+import (
+ "context"
+ "fmt"
+ "net"
+ "net/http"
+ "strconv"
+ "strings"
+ "time"
+)
+
+var okPage = []byte(`
+
+
+
+
+ Authentication Complete
+
+
+ Authentication complete. You can return to the application. Feel free to close this browser tab.
+
+
+`)
+
+const failPage = `
+
+
+
+
+ Authentication Failed
+
+
+ Authentication failed. You can return to the application. Feel free to close this browser tab.
+ Error details: error %s error_description: %s
+
+
+`
+
+// Result is the result from the redirect.
+type Result struct {
+ // Code is the code sent by the authority server.
+ Code string
+ // Err is set if there was an error.
+ Err error
+}
+
+// Server is an HTTP server.
+type Server struct {
+ // Addr is the address the server is listening on.
+ Addr string
+ resultCh chan Result
+ s *http.Server
+ reqState string
+}
+
+// New creates a local HTTP server and starts it.
+func New(reqState string, port int) (*Server, error) {
+ var l net.Listener
+ var err error
+ var portStr string
+ if port > 0 {
+ // use port provided by caller
+ l, err = net.Listen("tcp", fmt.Sprintf("localhost:%d", port))
+ portStr = strconv.FormatInt(int64(port), 10)
+ } else {
+ // find a free port
+ for i := 0; i < 10; i++ {
+ l, err = net.Listen("tcp", "localhost:0")
+ if err != nil {
+ continue
+ }
+ addr := l.Addr().String()
+ portStr = addr[strings.LastIndex(addr, ":")+1:]
+ break
+ }
+ }
+ if err != nil {
+ return nil, err
+ }
+
+ serv := &Server{
+ Addr: fmt.Sprintf("http://localhost:%s", portStr),
+ s: &http.Server{Addr: "localhost:0", ReadHeaderTimeout: time.Second},
+ reqState: reqState,
+ resultCh: make(chan Result, 1),
+ }
+ serv.s.Handler = http.HandlerFunc(serv.handler)
+
+ if err := serv.start(l); err != nil {
+ return nil, err
+ }
+
+ return serv, nil
+}
+
+func (s *Server) start(l net.Listener) error {
+ go func() {
+ err := s.s.Serve(l)
+ if err != nil {
+ select {
+ case s.resultCh <- Result{Err: err}:
+ default:
+ }
+ }
+ }()
+
+ return nil
+}
+
+// Result gets the result of the redirect operation. Once a single result is returned, the server
+// is shutdown. ctx deadline will be honored.
+func (s *Server) Result(ctx context.Context) Result {
+ select {
+ case <-ctx.Done():
+ return Result{Err: ctx.Err()}
+ case r := <-s.resultCh:
+ return r
+ }
+}
+
+// Shutdown shuts down the server.
+func (s *Server) Shutdown() {
+ // Note: You might get clever and think you can do this in handler() as a defer, you can't.
+ _ = s.s.Shutdown(context.Background())
+}
+
+func (s *Server) putResult(r Result) {
+ select {
+ case s.resultCh <- r:
+ default:
+ }
+}
+
+func (s *Server) handler(w http.ResponseWriter, r *http.Request) {
+ q := r.URL.Query()
+
+ headerErr := q.Get("error")
+ if headerErr != "" {
+ desc := q.Get("error_description")
+ // Note: It is a little weird we handle some errors by not going to the failPage. If they all should,
+ // change this to s.error() and make s.error() write the failPage instead of an error code.
+ _, _ = w.Write([]byte(fmt.Sprintf(failPage, headerErr, desc)))
+ s.putResult(Result{Err: fmt.Errorf(desc)})
+ return
+ }
+
+ respState := q.Get("state")
+ switch respState {
+ case s.reqState:
+ case "":
+ s.error(w, http.StatusInternalServerError, "server didn't send OAuth state")
+ return
+ default:
+ s.error(w, http.StatusInternalServerError, "mismatched OAuth state, req(%s), resp(%s)", s.reqState, respState)
+ return
+ }
+
+ code := q.Get("code")
+ if code == "" {
+ s.error(w, http.StatusInternalServerError, "authorization code missing in query string")
+ return
+ }
+
+ _, _ = w.Write(okPage)
+ s.putResult(Result{Code: code})
+}
+
+func (s *Server) error(w http.ResponseWriter, code int, str string, i ...interface{}) {
+ err := fmt.Errorf(str, i...)
+ http.Error(w, err.Error(), code)
+ s.putResult(Result{Err: err})
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/oauth.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/oauth.go
new file mode 100644
index 00000000000..f910823544b
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/oauth.go
@@ -0,0 +1,297 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+package oauth
+
+import (
+ "context"
+ "encoding/json"
+ "fmt"
+ "io"
+ "time"
+
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/errors"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/exported"
+ internalTime "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/json/types/time"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/accesstokens"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs"
+ "github.com/google/uuid"
+)
+
+// ResolveEndpointer contains the methods for resolving authority endpoints.
+type ResolveEndpointer interface {
+ ResolveEndpoints(ctx context.Context, authorityInfo authority.Info, userPrincipalName string) (authority.Endpoints, error)
+}
+
+// AccessTokens contains the methods for fetching tokens from different sources.
+type AccessTokens interface {
+ DeviceCodeResult(ctx context.Context, authParameters authority.AuthParams) (accesstokens.DeviceCodeResult, error)
+ FromUsernamePassword(ctx context.Context, authParameters authority.AuthParams) (accesstokens.TokenResponse, error)
+ FromAuthCode(ctx context.Context, req accesstokens.AuthCodeRequest) (accesstokens.TokenResponse, error)
+ FromRefreshToken(ctx context.Context, appType accesstokens.AppType, authParams authority.AuthParams, cc *accesstokens.Credential, refreshToken string) (accesstokens.TokenResponse, error)
+ FromClientSecret(ctx context.Context, authParameters authority.AuthParams, clientSecret string) (accesstokens.TokenResponse, error)
+ FromAssertion(ctx context.Context, authParameters authority.AuthParams, assertion string) (accesstokens.TokenResponse, error)
+ FromUserAssertionClientSecret(ctx context.Context, authParameters authority.AuthParams, userAssertion string, clientSecret string) (accesstokens.TokenResponse, error)
+ FromUserAssertionClientCertificate(ctx context.Context, authParameters authority.AuthParams, userAssertion string, assertion string) (accesstokens.TokenResponse, error)
+ FromDeviceCodeResult(ctx context.Context, authParameters authority.AuthParams, deviceCodeResult accesstokens.DeviceCodeResult) (accesstokens.TokenResponse, error)
+ FromSamlGrant(ctx context.Context, authParameters authority.AuthParams, samlGrant wstrust.SamlTokenInfo) (accesstokens.TokenResponse, error)
+}
+
+// FetchAuthority will be implemented by authority.Authority.
+type FetchAuthority interface {
+ UserRealm(context.Context, authority.AuthParams) (authority.UserRealm, error)
+ AADInstanceDiscovery(context.Context, authority.Info) (authority.InstanceDiscoveryResponse, error)
+}
+
+// FetchWSTrust contains the methods for interacting with WSTrust endpoints.
+type FetchWSTrust interface {
+ Mex(ctx context.Context, federationMetadataURL string) (defs.MexDocument, error)
+ SAMLTokenInfo(ctx context.Context, authParameters authority.AuthParams, cloudAudienceURN string, endpoint defs.Endpoint) (wstrust.SamlTokenInfo, error)
+}
+
+// Client provides tokens for various types of token requests.
+type Client struct {
+ Resolver ResolveEndpointer
+ AccessTokens AccessTokens
+ Authority FetchAuthority
+ WSTrust FetchWSTrust
+}
+
+// New is the constructor for Token.
+func New(httpClient ops.HTTPClient) *Client {
+ r := ops.New(httpClient)
+ return &Client{
+ Resolver: newAuthorityEndpoint(r),
+ AccessTokens: r.AccessTokens(),
+ Authority: r.Authority(),
+ WSTrust: r.WSTrust(),
+ }
+}
+
+// ResolveEndpoints gets the authorization and token endpoints and creates an AuthorityEndpoints instance.
+func (t *Client) ResolveEndpoints(ctx context.Context, authorityInfo authority.Info, userPrincipalName string) (authority.Endpoints, error) {
+ return t.Resolver.ResolveEndpoints(ctx, authorityInfo, userPrincipalName)
+}
+
+func (t *Client) AADInstanceDiscovery(ctx context.Context, authorityInfo authority.Info) (authority.InstanceDiscoveryResponse, error) {
+ return t.Authority.AADInstanceDiscovery(ctx, authorityInfo)
+}
+
+// AuthCode returns a token based on an authorization code.
+func (t *Client) AuthCode(ctx context.Context, req accesstokens.AuthCodeRequest) (accesstokens.TokenResponse, error) {
+ if err := t.resolveEndpoint(ctx, &req.AuthParams, ""); err != nil {
+ return accesstokens.TokenResponse{}, err
+ }
+
+ tResp, err := t.AccessTokens.FromAuthCode(ctx, req)
+ if err != nil {
+ return accesstokens.TokenResponse{}, fmt.Errorf("could not retrieve token from auth code: %w", err)
+ }
+ return tResp, nil
+}
+
+// Credential acquires a token from the authority using a client credentials grant.
+func (t *Client) Credential(ctx context.Context, authParams authority.AuthParams, cred *accesstokens.Credential) (accesstokens.TokenResponse, error) {
+ if cred.TokenProvider != nil {
+ now := time.Now()
+ scopes := make([]string, len(authParams.Scopes))
+ copy(scopes, authParams.Scopes)
+ params := exported.TokenProviderParameters{
+ Claims: authParams.Claims,
+ CorrelationID: uuid.New().String(),
+ Scopes: scopes,
+ TenantID: authParams.AuthorityInfo.Tenant,
+ }
+ tr, err := cred.TokenProvider(ctx, params)
+ if err != nil {
+ return accesstokens.TokenResponse{}, err
+ }
+ return accesstokens.TokenResponse{
+ AccessToken: tr.AccessToken,
+ ExpiresOn: internalTime.DurationTime{
+ T: now.Add(time.Duration(tr.ExpiresInSeconds) * time.Second),
+ },
+ GrantedScopes: accesstokens.Scopes{Slice: authParams.Scopes},
+ }, nil
+ }
+
+ if err := t.resolveEndpoint(ctx, &authParams, ""); err != nil {
+ return accesstokens.TokenResponse{}, err
+ }
+
+ if cred.Secret != "" {
+ return t.AccessTokens.FromClientSecret(ctx, authParams, cred.Secret)
+ }
+ jwt, err := cred.JWT(ctx, authParams)
+ if err != nil {
+ return accesstokens.TokenResponse{}, err
+ }
+ return t.AccessTokens.FromAssertion(ctx, authParams, jwt)
+}
+
+// Credential acquires a token from the authority using a client credentials grant.
+func (t *Client) OnBehalfOf(ctx context.Context, authParams authority.AuthParams, cred *accesstokens.Credential) (accesstokens.TokenResponse, error) {
+ if err := t.resolveEndpoint(ctx, &authParams, ""); err != nil {
+ return accesstokens.TokenResponse{}, err
+ }
+
+ if cred.Secret != "" {
+ return t.AccessTokens.FromUserAssertionClientSecret(ctx, authParams, authParams.UserAssertion, cred.Secret)
+ }
+ jwt, err := cred.JWT(ctx, authParams)
+ if err != nil {
+ return accesstokens.TokenResponse{}, err
+ }
+ return t.AccessTokens.FromUserAssertionClientCertificate(ctx, authParams, authParams.UserAssertion, jwt)
+}
+
+func (t *Client) Refresh(ctx context.Context, reqType accesstokens.AppType, authParams authority.AuthParams, cc *accesstokens.Credential, refreshToken accesstokens.RefreshToken) (accesstokens.TokenResponse, error) {
+ if err := t.resolveEndpoint(ctx, &authParams, ""); err != nil {
+ return accesstokens.TokenResponse{}, err
+ }
+
+ return t.AccessTokens.FromRefreshToken(ctx, reqType, authParams, cc, refreshToken.Secret)
+}
+
+// UsernamePassword retrieves a token where a username and password is used. However, if this is
+// a user realm of "Federated", this uses SAML tokens. If "Managed", uses normal username/password.
+func (t *Client) UsernamePassword(ctx context.Context, authParams authority.AuthParams) (accesstokens.TokenResponse, error) {
+ if authParams.AuthorityInfo.AuthorityType == authority.ADFS {
+ if err := t.resolveEndpoint(ctx, &authParams, authParams.Username); err != nil {
+ return accesstokens.TokenResponse{}, err
+ }
+ return t.AccessTokens.FromUsernamePassword(ctx, authParams)
+ }
+ if err := t.resolveEndpoint(ctx, &authParams, ""); err != nil {
+ return accesstokens.TokenResponse{}, err
+ }
+
+ userRealm, err := t.Authority.UserRealm(ctx, authParams)
+ if err != nil {
+ return accesstokens.TokenResponse{}, fmt.Errorf("problem getting user realm(user: %s) from authority: %w", authParams.Username, err)
+ }
+
+ switch userRealm.AccountType {
+ case authority.Federated:
+ mexDoc, err := t.WSTrust.Mex(ctx, userRealm.FederationMetadataURL)
+ if err != nil {
+ return accesstokens.TokenResponse{}, fmt.Errorf("problem getting mex doc from federated url(%s): %w", userRealm.FederationMetadataURL, err)
+ }
+
+ saml, err := t.WSTrust.SAMLTokenInfo(ctx, authParams, userRealm.CloudAudienceURN, mexDoc.UsernamePasswordEndpoint)
+ if err != nil {
+ return accesstokens.TokenResponse{}, fmt.Errorf("problem getting SAML token info: %w", err)
+ }
+ return t.AccessTokens.FromSamlGrant(ctx, authParams, saml)
+ case authority.Managed:
+ return t.AccessTokens.FromUsernamePassword(ctx, authParams)
+ }
+ return accesstokens.TokenResponse{}, errors.New("unknown account type")
+}
+
+// DeviceCode is the result of a call to Token.DeviceCode().
+type DeviceCode struct {
+ // Result is the device code result from the first call in the device code flow. This allows
+ // the caller to retrieve the displayed code that is used to authorize on the second device.
+ Result accesstokens.DeviceCodeResult
+ authParams authority.AuthParams
+
+ accessTokens AccessTokens
+}
+
+// Token returns a token AFTER the user uses the user code on the second device. This will block
+// until either: (1) the code is input by the user and the service releases a token, (2) the token
+// expires, (3) the Context passed to .DeviceCode() is cancelled or expires, (4) some other service
+// error occurs.
+func (d DeviceCode) Token(ctx context.Context) (accesstokens.TokenResponse, error) {
+ if d.accessTokens == nil {
+ return accesstokens.TokenResponse{}, fmt.Errorf("DeviceCode was either created outside its package or the creating method had an error. DeviceCode is not valid")
+ }
+
+ var cancel context.CancelFunc
+ d.Result.ExpiresOn.Sub(time.Now().UTC())
+ if deadline, ok := ctx.Deadline(); !ok || d.Result.ExpiresOn.Before(deadline) {
+ ctx, cancel = context.WithDeadline(ctx, d.Result.ExpiresOn)
+ } else {
+ ctx, cancel = context.WithCancel(ctx)
+ }
+ defer cancel()
+
+ var interval = 50 * time.Millisecond
+ timer := time.NewTimer(interval)
+ defer timer.Stop()
+
+ for {
+ timer.Reset(interval)
+ select {
+ case <-ctx.Done():
+ return accesstokens.TokenResponse{}, ctx.Err()
+ case <-timer.C:
+ interval += interval * 2
+ if interval > 5*time.Second {
+ interval = 5 * time.Second
+ }
+ }
+
+ token, err := d.accessTokens.FromDeviceCodeResult(ctx, d.authParams, d.Result)
+ if err != nil && isWaitDeviceCodeErr(err) {
+ continue
+ }
+ return token, err // This handles if it was a non-wait error or success
+ }
+}
+
+type deviceCodeError struct {
+ Error string `json:"error"`
+}
+
+func isWaitDeviceCodeErr(err error) bool {
+ var c errors.CallErr
+ if !errors.As(err, &c) {
+ return false
+ }
+ if c.Resp.StatusCode != 400 {
+ return false
+ }
+ var dCErr deviceCodeError
+ defer c.Resp.Body.Close()
+ body, err := io.ReadAll(c.Resp.Body)
+ if err != nil {
+ return false
+ }
+ err = json.Unmarshal(body, &dCErr)
+ if err != nil {
+ return false
+ }
+ if dCErr.Error == "authorization_pending" || dCErr.Error == "slow_down" {
+ return true
+ }
+ return false
+}
+
+// DeviceCode returns a DeviceCode object that can be used to get the code that must be entered on the second
+// device and optionally the token once the code has been entered on the second device.
+func (t *Client) DeviceCode(ctx context.Context, authParams authority.AuthParams) (DeviceCode, error) {
+ if err := t.resolveEndpoint(ctx, &authParams, ""); err != nil {
+ return DeviceCode{}, err
+ }
+
+ dcr, err := t.AccessTokens.DeviceCodeResult(ctx, authParams)
+ if err != nil {
+ return DeviceCode{}, err
+ }
+
+ return DeviceCode{Result: dcr, authParams: authParams, accessTokens: t.AccessTokens}, nil
+}
+
+func (t *Client) resolveEndpoint(ctx context.Context, authParams *authority.AuthParams, userPrincipalName string) error {
+ endpoints, err := t.Resolver.ResolveEndpoints(ctx, authParams.AuthorityInfo, userPrincipalName)
+ if err != nil {
+ return fmt.Errorf("unable to resolve an endpoint: %s", err)
+ }
+ authParams.Endpoints = endpoints
+ return nil
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/accesstokens/accesstokens.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/accesstokens/accesstokens.go
new file mode 100644
index 00000000000..fa6bb61c8ef
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/accesstokens/accesstokens.go
@@ -0,0 +1,451 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+/*
+Package accesstokens exposes a REST client for querying backend systems to get various types of
+access tokens (oauth) for use in authentication.
+
+These calls are of type "application/x-www-form-urlencoded". This means we use url.Values to
+represent arguments and then encode them into the POST body message. We receive JSON in
+return for the requests. The request definition is defined in https://tools.ietf.org/html/rfc7521#section-4.2 .
+*/
+package accesstokens
+
+import (
+ "context"
+ "crypto"
+
+ /* #nosec */
+ "crypto/sha1"
+ "crypto/x509"
+ "encoding/base64"
+ "encoding/json"
+ "fmt"
+ "net/url"
+ "strconv"
+ "strings"
+ "time"
+
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/exported"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/internal/grant"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust"
+ "github.com/golang-jwt/jwt/v4"
+ "github.com/google/uuid"
+)
+
+const (
+ grantType = "grant_type"
+ deviceCode = "device_code"
+ clientID = "client_id"
+ clientInfo = "client_info"
+ clientInfoVal = "1"
+ username = "username"
+ password = "password"
+)
+
+//go:generate stringer -type=AppType
+
+// AppType is whether the authorization code flow is for a public or confidential client.
+type AppType int8
+
+const (
+ // ATUnknown is the zero value when the type hasn't been set.
+ ATUnknown AppType = iota
+ // ATPublic indicates this if for the Public.Client.
+ ATPublic
+ // ATConfidential indicates this if for the Confidential.Client.
+ ATConfidential
+)
+
+type urlFormCaller interface {
+ URLFormCall(ctx context.Context, endpoint string, qv url.Values, resp interface{}) error
+}
+
+// DeviceCodeResponse represents the HTTP response received from the device code endpoint
+type DeviceCodeResponse struct {
+ authority.OAuthResponseBase
+
+ UserCode string `json:"user_code"`
+ DeviceCode string `json:"device_code"`
+ VerificationURL string `json:"verification_url"`
+ ExpiresIn int `json:"expires_in"`
+ Interval int `json:"interval"`
+ Message string `json:"message"`
+
+ AdditionalFields map[string]interface{}
+}
+
+// Convert converts the DeviceCodeResponse to a DeviceCodeResult
+func (dcr DeviceCodeResponse) Convert(clientID string, scopes []string) DeviceCodeResult {
+ expiresOn := time.Now().UTC().Add(time.Duration(dcr.ExpiresIn) * time.Second)
+ return NewDeviceCodeResult(dcr.UserCode, dcr.DeviceCode, dcr.VerificationURL, expiresOn, dcr.Interval, dcr.Message, clientID, scopes)
+}
+
+// Credential represents the credential used in confidential client flows. This can be either
+// a Secret or Cert/Key.
+type Credential struct {
+ // Secret contains the credential secret if we are doing auth by secret.
+ Secret string
+
+ // Cert is the public certificate, if we're authenticating by certificate.
+ Cert *x509.Certificate
+ // Key is the private key for signing, if we're authenticating by certificate.
+ Key crypto.PrivateKey
+ // X5c is the JWT assertion's x5c header value, required for SN/I authentication.
+ X5c []string
+
+ // AssertionCallback is a function provided by the application, if we're authenticating by assertion.
+ AssertionCallback func(context.Context, exported.AssertionRequestOptions) (string, error)
+
+ // TokenProvider is a function provided by the application that implements custom authentication
+ // logic for a confidential client
+ TokenProvider func(context.Context, exported.TokenProviderParameters) (exported.TokenProviderResult, error)
+}
+
+// JWT gets the jwt assertion when the credential is not using a secret.
+func (c *Credential) JWT(ctx context.Context, authParams authority.AuthParams) (string, error) {
+ if c.AssertionCallback != nil {
+ options := exported.AssertionRequestOptions{
+ ClientID: authParams.ClientID,
+ TokenEndpoint: authParams.Endpoints.TokenEndpoint,
+ }
+ return c.AssertionCallback(ctx, options)
+ }
+
+ token := jwt.NewWithClaims(jwt.SigningMethodRS256, jwt.MapClaims{
+ "aud": authParams.Endpoints.TokenEndpoint,
+ "exp": json.Number(strconv.FormatInt(time.Now().Add(10*time.Minute).Unix(), 10)),
+ "iss": authParams.ClientID,
+ "jti": uuid.New().String(),
+ "nbf": json.Number(strconv.FormatInt(time.Now().Unix(), 10)),
+ "sub": authParams.ClientID,
+ })
+ token.Header = map[string]interface{}{
+ "alg": "RS256",
+ "typ": "JWT",
+ "x5t": base64.StdEncoding.EncodeToString(thumbprint(c.Cert)),
+ }
+
+ if authParams.SendX5C {
+ token.Header["x5c"] = c.X5c
+ }
+
+ assertion, err := token.SignedString(c.Key)
+ if err != nil {
+ return "", fmt.Errorf("unable to sign a JWT token using private key: %w", err)
+ }
+ return assertion, nil
+}
+
+// thumbprint runs the asn1.Der bytes through sha1 for use in the x5t parameter of JWT.
+// https://tools.ietf.org/html/rfc7517#section-4.8
+func thumbprint(cert *x509.Certificate) []byte {
+ /* #nosec */
+ a := sha1.Sum(cert.Raw)
+ return a[:]
+}
+
+// Client represents the REST calls to get tokens from token generator backends.
+type Client struct {
+ // Comm provides the HTTP transport client.
+ Comm urlFormCaller
+
+ testing bool
+}
+
+// FromUsernamePassword uses a username and password to get an access token.
+func (c Client) FromUsernamePassword(ctx context.Context, authParameters authority.AuthParams) (TokenResponse, error) {
+ qv := url.Values{}
+ if err := addClaims(qv, authParameters); err != nil {
+ return TokenResponse{}, err
+ }
+ qv.Set(grantType, grant.Password)
+ qv.Set(username, authParameters.Username)
+ qv.Set(password, authParameters.Password)
+ qv.Set(clientID, authParameters.ClientID)
+ qv.Set(clientInfo, clientInfoVal)
+ addScopeQueryParam(qv, authParameters)
+
+ return c.doTokenResp(ctx, authParameters, qv)
+}
+
+// AuthCodeRequest stores the values required to request a token from the authority using an authorization code
+type AuthCodeRequest struct {
+ AuthParams authority.AuthParams
+ Code string
+ CodeChallenge string
+ Credential *Credential
+ AppType AppType
+}
+
+// NewCodeChallengeRequest returns an AuthCodeRequest that uses a code challenge..
+func NewCodeChallengeRequest(params authority.AuthParams, appType AppType, cc *Credential, code, challenge string) (AuthCodeRequest, error) {
+ if appType == ATUnknown {
+ return AuthCodeRequest{}, fmt.Errorf("bug: NewCodeChallengeRequest() called with AppType == ATUnknown")
+ }
+ return AuthCodeRequest{
+ AuthParams: params,
+ AppType: appType,
+ Code: code,
+ CodeChallenge: challenge,
+ Credential: cc,
+ }, nil
+}
+
+// FromAuthCode uses an authorization code to retrieve an access token.
+func (c Client) FromAuthCode(ctx context.Context, req AuthCodeRequest) (TokenResponse, error) {
+ var qv url.Values
+
+ switch req.AppType {
+ case ATUnknown:
+ return TokenResponse{}, fmt.Errorf("bug: Token.AuthCode() received request with AppType == ATUnknown")
+ case ATConfidential:
+ var err error
+ if req.Credential == nil {
+ return TokenResponse{}, fmt.Errorf("AuthCodeRequest had nil Credential for Confidential app")
+ }
+ qv, err = prepURLVals(ctx, req.Credential, req.AuthParams)
+ if err != nil {
+ return TokenResponse{}, err
+ }
+ case ATPublic:
+ qv = url.Values{}
+ default:
+ return TokenResponse{}, fmt.Errorf("bug: Token.AuthCode() received request with AppType == %v, which we do not recongnize", req.AppType)
+ }
+
+ qv.Set(grantType, grant.AuthCode)
+ qv.Set("code", req.Code)
+ qv.Set("code_verifier", req.CodeChallenge)
+ qv.Set("redirect_uri", req.AuthParams.Redirecturi)
+ qv.Set(clientID, req.AuthParams.ClientID)
+ qv.Set(clientInfo, clientInfoVal)
+ addScopeQueryParam(qv, req.AuthParams)
+ if err := addClaims(qv, req.AuthParams); err != nil {
+ return TokenResponse{}, err
+ }
+
+ return c.doTokenResp(ctx, req.AuthParams, qv)
+}
+
+// FromRefreshToken uses a refresh token (for refreshing credentials) to get a new access token.
+func (c Client) FromRefreshToken(ctx context.Context, appType AppType, authParams authority.AuthParams, cc *Credential, refreshToken string) (TokenResponse, error) {
+ qv := url.Values{}
+ if appType == ATConfidential {
+ var err error
+ qv, err = prepURLVals(ctx, cc, authParams)
+ if err != nil {
+ return TokenResponse{}, err
+ }
+ }
+ if err := addClaims(qv, authParams); err != nil {
+ return TokenResponse{}, err
+ }
+ qv.Set(grantType, grant.RefreshToken)
+ qv.Set(clientID, authParams.ClientID)
+ qv.Set(clientInfo, clientInfoVal)
+ qv.Set("refresh_token", refreshToken)
+ addScopeQueryParam(qv, authParams)
+
+ return c.doTokenResp(ctx, authParams, qv)
+}
+
+// FromClientSecret uses a client's secret (aka password) to get a new token.
+func (c Client) FromClientSecret(ctx context.Context, authParameters authority.AuthParams, clientSecret string) (TokenResponse, error) {
+ qv := url.Values{}
+ if err := addClaims(qv, authParameters); err != nil {
+ return TokenResponse{}, err
+ }
+ qv.Set(grantType, grant.ClientCredential)
+ qv.Set("client_secret", clientSecret)
+ qv.Set(clientID, authParameters.ClientID)
+ addScopeQueryParam(qv, authParameters)
+
+ token, err := c.doTokenResp(ctx, authParameters, qv)
+ if err != nil {
+ return token, fmt.Errorf("FromClientSecret(): %w", err)
+ }
+ return token, nil
+}
+
+func (c Client) FromAssertion(ctx context.Context, authParameters authority.AuthParams, assertion string) (TokenResponse, error) {
+ qv := url.Values{}
+ if err := addClaims(qv, authParameters); err != nil {
+ return TokenResponse{}, err
+ }
+ qv.Set(grantType, grant.ClientCredential)
+ qv.Set("client_assertion_type", grant.ClientAssertion)
+ qv.Set("client_assertion", assertion)
+ qv.Set(clientID, authParameters.ClientID)
+ qv.Set(clientInfo, clientInfoVal)
+ addScopeQueryParam(qv, authParameters)
+
+ token, err := c.doTokenResp(ctx, authParameters, qv)
+ if err != nil {
+ return token, fmt.Errorf("FromAssertion(): %w", err)
+ }
+ return token, nil
+}
+
+func (c Client) FromUserAssertionClientSecret(ctx context.Context, authParameters authority.AuthParams, userAssertion string, clientSecret string) (TokenResponse, error) {
+ qv := url.Values{}
+ if err := addClaims(qv, authParameters); err != nil {
+ return TokenResponse{}, err
+ }
+ qv.Set(grantType, grant.JWT)
+ qv.Set(clientID, authParameters.ClientID)
+ qv.Set("client_secret", clientSecret)
+ qv.Set("assertion", userAssertion)
+ qv.Set(clientInfo, clientInfoVal)
+ qv.Set("requested_token_use", "on_behalf_of")
+ addScopeQueryParam(qv, authParameters)
+
+ return c.doTokenResp(ctx, authParameters, qv)
+}
+
+func (c Client) FromUserAssertionClientCertificate(ctx context.Context, authParameters authority.AuthParams, userAssertion string, assertion string) (TokenResponse, error) {
+ qv := url.Values{}
+ if err := addClaims(qv, authParameters); err != nil {
+ return TokenResponse{}, err
+ }
+ qv.Set(grantType, grant.JWT)
+ qv.Set("client_assertion_type", grant.ClientAssertion)
+ qv.Set("client_assertion", assertion)
+ qv.Set(clientID, authParameters.ClientID)
+ qv.Set("assertion", userAssertion)
+ qv.Set(clientInfo, clientInfoVal)
+ qv.Set("requested_token_use", "on_behalf_of")
+ addScopeQueryParam(qv, authParameters)
+
+ return c.doTokenResp(ctx, authParameters, qv)
+}
+
+func (c Client) DeviceCodeResult(ctx context.Context, authParameters authority.AuthParams) (DeviceCodeResult, error) {
+ qv := url.Values{}
+ if err := addClaims(qv, authParameters); err != nil {
+ return DeviceCodeResult{}, err
+ }
+ qv.Set(clientID, authParameters.ClientID)
+ addScopeQueryParam(qv, authParameters)
+
+ endpoint := strings.Replace(authParameters.Endpoints.TokenEndpoint, "token", "devicecode", -1)
+
+ resp := DeviceCodeResponse{}
+ err := c.Comm.URLFormCall(ctx, endpoint, qv, &resp)
+ if err != nil {
+ return DeviceCodeResult{}, err
+ }
+
+ return resp.Convert(authParameters.ClientID, authParameters.Scopes), nil
+}
+
+func (c Client) FromDeviceCodeResult(ctx context.Context, authParameters authority.AuthParams, deviceCodeResult DeviceCodeResult) (TokenResponse, error) {
+ qv := url.Values{}
+ if err := addClaims(qv, authParameters); err != nil {
+ return TokenResponse{}, err
+ }
+ qv.Set(grantType, grant.DeviceCode)
+ qv.Set(deviceCode, deviceCodeResult.DeviceCode)
+ qv.Set(clientID, authParameters.ClientID)
+ qv.Set(clientInfo, clientInfoVal)
+ addScopeQueryParam(qv, authParameters)
+
+ return c.doTokenResp(ctx, authParameters, qv)
+}
+
+func (c Client) FromSamlGrant(ctx context.Context, authParameters authority.AuthParams, samlGrant wstrust.SamlTokenInfo) (TokenResponse, error) {
+ qv := url.Values{}
+ if err := addClaims(qv, authParameters); err != nil {
+ return TokenResponse{}, err
+ }
+ qv.Set(username, authParameters.Username)
+ qv.Set(password, authParameters.Password)
+ qv.Set(clientID, authParameters.ClientID)
+ qv.Set(clientInfo, clientInfoVal)
+ qv.Set("assertion", base64.StdEncoding.WithPadding(base64.StdPadding).EncodeToString([]byte(samlGrant.Assertion)))
+ addScopeQueryParam(qv, authParameters)
+
+ switch samlGrant.AssertionType {
+ case grant.SAMLV1:
+ qv.Set(grantType, grant.SAMLV1)
+ case grant.SAMLV2:
+ qv.Set(grantType, grant.SAMLV2)
+ default:
+ return TokenResponse{}, fmt.Errorf("GetAccessTokenFromSamlGrant returned unknown SAML assertion type: %q", samlGrant.AssertionType)
+ }
+
+ return c.doTokenResp(ctx, authParameters, qv)
+}
+
+func (c Client) doTokenResp(ctx context.Context, authParams authority.AuthParams, qv url.Values) (TokenResponse, error) {
+ resp := TokenResponse{}
+ err := c.Comm.URLFormCall(ctx, authParams.Endpoints.TokenEndpoint, qv, &resp)
+ if err != nil {
+ return resp, err
+ }
+ resp.ComputeScope(authParams)
+ if c.testing {
+ return resp, nil
+ }
+ return resp, resp.Validate()
+}
+
+// prepURLVals returns an url.Values that sets various key/values if we are doing secrets
+// or JWT assertions.
+func prepURLVals(ctx context.Context, cc *Credential, authParams authority.AuthParams) (url.Values, error) {
+ params := url.Values{}
+ if cc.Secret != "" {
+ params.Set("client_secret", cc.Secret)
+ return params, nil
+ }
+
+ jwt, err := cc.JWT(ctx, authParams)
+ if err != nil {
+ return nil, err
+ }
+ params.Set("client_assertion", jwt)
+ params.Set("client_assertion_type", grant.ClientAssertion)
+ return params, nil
+}
+
+// openid required to get an id token
+// offline_access required to get a refresh token
+// profile required to get the client_info field back
+var detectDefaultScopes = map[string]bool{
+ "openid": true,
+ "offline_access": true,
+ "profile": true,
+}
+
+var defaultScopes = []string{"openid", "offline_access", "profile"}
+
+func AppendDefaultScopes(authParameters authority.AuthParams) []string {
+ scopes := make([]string, 0, len(authParameters.Scopes)+len(defaultScopes))
+ for _, scope := range authParameters.Scopes {
+ s := strings.TrimSpace(scope)
+ if s == "" {
+ continue
+ }
+ if detectDefaultScopes[scope] {
+ continue
+ }
+ scopes = append(scopes, scope)
+ }
+ scopes = append(scopes, defaultScopes...)
+ return scopes
+}
+
+// addClaims adds client capabilities and claims from AuthParams to the given url.Values
+func addClaims(v url.Values, ap authority.AuthParams) error {
+ claims, err := ap.MergeCapabilitiesAndClaims()
+ if err == nil && claims != "" {
+ v.Set("claims", claims)
+ }
+ return err
+}
+
+func addScopeQueryParam(queryParams url.Values, authParameters authority.AuthParams) {
+ scopes := AppendDefaultScopes(authParameters)
+ queryParams.Set("scope", strings.Join(scopes, " "))
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/accesstokens/apptype_string.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/accesstokens/apptype_string.go
new file mode 100644
index 00000000000..3bec4a67cf1
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/accesstokens/apptype_string.go
@@ -0,0 +1,25 @@
+// Code generated by "stringer -type=AppType"; DO NOT EDIT.
+
+package accesstokens
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[ATUnknown-0]
+ _ = x[ATPublic-1]
+ _ = x[ATConfidential-2]
+}
+
+const _AppType_name = "ATUnknownATPublicATConfidential"
+
+var _AppType_index = [...]uint8{0, 9, 17, 31}
+
+func (i AppType) String() string {
+ if i < 0 || i >= AppType(len(_AppType_index)-1) {
+ return "AppType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _AppType_name[_AppType_index[i]:_AppType_index[i+1]]
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/accesstokens/tokens.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/accesstokens/tokens.go
new file mode 100644
index 00000000000..b3892bf3f32
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/accesstokens/tokens.go
@@ -0,0 +1,335 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+package accesstokens
+
+import (
+ "bytes"
+ "encoding/base64"
+ "encoding/json"
+ "errors"
+ "fmt"
+ "reflect"
+ "strings"
+ "time"
+
+ internalTime "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/json/types/time"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/shared"
+)
+
+// IDToken consists of all the information used to validate a user.
+// https://docs.microsoft.com/azure/active-directory/develop/id-tokens .
+type IDToken struct {
+ PreferredUsername string `json:"preferred_username,omitempty"`
+ GivenName string `json:"given_name,omitempty"`
+ FamilyName string `json:"family_name,omitempty"`
+ MiddleName string `json:"middle_name,omitempty"`
+ Name string `json:"name,omitempty"`
+ Oid string `json:"oid,omitempty"`
+ TenantID string `json:"tid,omitempty"`
+ Subject string `json:"sub,omitempty"`
+ UPN string `json:"upn,omitempty"`
+ Email string `json:"email,omitempty"`
+ AlternativeID string `json:"alternative_id,omitempty"`
+ Issuer string `json:"iss,omitempty"`
+ Audience string `json:"aud,omitempty"`
+ ExpirationTime int64 `json:"exp,omitempty"`
+ IssuedAt int64 `json:"iat,omitempty"`
+ NotBefore int64 `json:"nbf,omitempty"`
+ RawToken string
+
+ AdditionalFields map[string]interface{}
+}
+
+var null = []byte("null")
+
+// UnmarshalJSON implements json.Unmarshaler.
+func (i *IDToken) UnmarshalJSON(b []byte) error {
+ if bytes.Equal(null, b) {
+ return nil
+ }
+
+ // Because we have a custom unmarshaler, you
+ // cannot directly call json.Unmarshal here. If you do, it will call this function
+ // recursively until reach our recursion limit. We have to create a new type
+ // that doesn't have this method in order to use json.Unmarshal.
+ type idToken2 IDToken
+
+ jwt := strings.Trim(string(b), `"`)
+ jwtArr := strings.Split(jwt, ".")
+ if len(jwtArr) < 2 {
+ return errors.New("IDToken returned from server is invalid")
+ }
+
+ jwtPart := jwtArr[1]
+ jwtDecoded, err := decodeJWT(jwtPart)
+ if err != nil {
+ return fmt.Errorf("unable to unmarshal IDToken, problem decoding JWT: %w", err)
+ }
+
+ token := idToken2{}
+ err = json.Unmarshal(jwtDecoded, &token)
+ if err != nil {
+ return fmt.Errorf("unable to unmarshal IDToken: %w", err)
+ }
+ token.RawToken = jwt
+
+ *i = IDToken(token)
+ return nil
+}
+
+// IsZero indicates if the IDToken is the zero value.
+func (i IDToken) IsZero() bool {
+ v := reflect.ValueOf(i)
+ for i := 0; i < v.NumField(); i++ {
+ field := v.Field(i)
+ if !field.IsZero() {
+ switch field.Kind() {
+ case reflect.Map, reflect.Slice:
+ if field.Len() == 0 {
+ continue
+ }
+ }
+ return false
+ }
+ }
+ return true
+}
+
+// LocalAccountID extracts an account's local account ID from an ID token.
+func (i IDToken) LocalAccountID() string {
+ if i.Oid != "" {
+ return i.Oid
+ }
+ return i.Subject
+}
+
+// jwtDecoder is provided to allow tests to provide their own.
+var jwtDecoder = decodeJWT
+
+// ClientInfo is used to create a Home Account ID for an account.
+type ClientInfo struct {
+ UID string `json:"uid"`
+ UTID string `json:"utid"`
+
+ AdditionalFields map[string]interface{}
+}
+
+// UnmarshalJSON implements json.Unmarshaler.s
+func (c *ClientInfo) UnmarshalJSON(b []byte) error {
+ s := strings.Trim(string(b), `"`)
+ // Client info may be empty in some flows, e.g. certificate exchange.
+ if len(s) == 0 {
+ return nil
+ }
+
+ // Because we have a custom unmarshaler, you
+ // cannot directly call json.Unmarshal here. If you do, it will call this function
+ // recursively until reach our recursion limit. We have to create a new type
+ // that doesn't have this method in order to use json.Unmarshal.
+ type clientInfo2 ClientInfo
+
+ raw, err := jwtDecoder(s)
+ if err != nil {
+ return fmt.Errorf("TokenResponse client_info field had JWT decode error: %w", err)
+ }
+
+ var c2 clientInfo2
+
+ err = json.Unmarshal(raw, &c2)
+ if err != nil {
+ return fmt.Errorf("was unable to unmarshal decoded JWT in TokenRespone to ClientInfo: %w", err)
+ }
+
+ *c = ClientInfo(c2)
+ return nil
+}
+
+// HomeAccountID creates the home account ID.
+func (c ClientInfo) HomeAccountID() string {
+ if c.UID == "" {
+ return ""
+ } else if c.UTID == "" {
+ return fmt.Sprintf("%s.%s", c.UID, c.UID)
+ } else {
+ return fmt.Sprintf("%s.%s", c.UID, c.UTID)
+ }
+}
+
+// Scopes represents scopes in a TokenResponse.
+type Scopes struct {
+ Slice []string
+}
+
+// UnmarshalJSON implements json.Unmarshal.
+func (s *Scopes) UnmarshalJSON(b []byte) error {
+ str := strings.Trim(string(b), `"`)
+ if len(str) == 0 {
+ return nil
+ }
+ sl := strings.Split(str, " ")
+ s.Slice = sl
+ return nil
+}
+
+// TokenResponse is the information that is returned from a token endpoint during a token acquisition flow.
+type TokenResponse struct {
+ authority.OAuthResponseBase
+
+ AccessToken string `json:"access_token"`
+ RefreshToken string `json:"refresh_token"`
+
+ FamilyID string `json:"foci"`
+ IDToken IDToken `json:"id_token"`
+ ClientInfo ClientInfo `json:"client_info"`
+ ExpiresOn internalTime.DurationTime `json:"expires_in"`
+ ExtExpiresOn internalTime.DurationTime `json:"ext_expires_in"`
+ GrantedScopes Scopes `json:"scope"`
+ DeclinedScopes []string // This is derived
+
+ AdditionalFields map[string]interface{}
+
+ scopesComputed bool
+}
+
+// ComputeScope computes the final scopes based on what was granted by the server and
+// what our AuthParams were from the authority server. Per OAuth spec, if no scopes are returned, the response should be treated as if all scopes were granted
+// This behavior can be observed in client assertion flows, but can happen at any time, this check ensures we treat
+// those special responses properly Link to spec: https://tools.ietf.org/html/rfc6749#section-3.3
+func (tr *TokenResponse) ComputeScope(authParams authority.AuthParams) {
+ if len(tr.GrantedScopes.Slice) == 0 {
+ tr.GrantedScopes = Scopes{Slice: authParams.Scopes}
+ } else {
+ tr.DeclinedScopes = findDeclinedScopes(authParams.Scopes, tr.GrantedScopes.Slice)
+ }
+ tr.scopesComputed = true
+}
+
+// Validate validates the TokenResponse has basic valid values. It must be called
+// after ComputeScopes() is called.
+func (tr *TokenResponse) Validate() error {
+ if tr.Error != "" {
+ return fmt.Errorf("%s: %s", tr.Error, tr.ErrorDescription)
+ }
+
+ if tr.AccessToken == "" {
+ return errors.New("response is missing access_token")
+ }
+
+ if !tr.scopesComputed {
+ return fmt.Errorf("TokenResponse hasn't had ScopesComputed() called")
+ }
+ return nil
+}
+
+func (tr *TokenResponse) CacheKey(authParams authority.AuthParams) string {
+ if authParams.AuthorizationType == authority.ATOnBehalfOf {
+ return authParams.AssertionHash()
+ }
+ if authParams.AuthorizationType == authority.ATClientCredentials {
+ return authParams.AppKey()
+ }
+ if authParams.IsConfidentialClient || authParams.AuthorizationType == authority.ATRefreshToken {
+ return tr.ClientInfo.HomeAccountID()
+ }
+ return ""
+}
+
+func findDeclinedScopes(requestedScopes []string, grantedScopes []string) []string {
+ declined := []string{}
+ grantedMap := map[string]bool{}
+ for _, s := range grantedScopes {
+ grantedMap[strings.ToLower(s)] = true
+ }
+ // Comparing the requested scopes with the granted scopes to see if there are any scopes that have been declined.
+ for _, r := range requestedScopes {
+ if !grantedMap[strings.ToLower(r)] {
+ declined = append(declined, r)
+ }
+ }
+ return declined
+}
+
+// decodeJWT decodes a JWT and converts it to a byte array representing a JSON object
+// JWT has headers and payload base64url encoded without padding
+// https://tools.ietf.org/html/rfc7519#section-3 and
+// https://tools.ietf.org/html/rfc7515#section-2
+func decodeJWT(data string) ([]byte, error) {
+ // https://tools.ietf.org/html/rfc7515#appendix-C
+ return base64.RawURLEncoding.DecodeString(data)
+}
+
+// RefreshToken is the JSON representation of a MSAL refresh token for encoding to storage.
+type RefreshToken struct {
+ HomeAccountID string `json:"home_account_id,omitempty"`
+ Environment string `json:"environment,omitempty"`
+ CredentialType string `json:"credential_type,omitempty"`
+ ClientID string `json:"client_id,omitempty"`
+ FamilyID string `json:"family_id,omitempty"`
+ Secret string `json:"secret,omitempty"`
+ Realm string `json:"realm,omitempty"`
+ Target string `json:"target,omitempty"`
+ UserAssertionHash string `json:"user_assertion_hash,omitempty"`
+
+ AdditionalFields map[string]interface{}
+}
+
+// NewRefreshToken is the constructor for RefreshToken.
+func NewRefreshToken(homeID, env, clientID, refreshToken, familyID string) RefreshToken {
+ return RefreshToken{
+ HomeAccountID: homeID,
+ Environment: env,
+ CredentialType: "RefreshToken",
+ ClientID: clientID,
+ FamilyID: familyID,
+ Secret: refreshToken,
+ }
+}
+
+// Key outputs the key that can be used to uniquely look up this entry in a map.
+func (rt RefreshToken) Key() string {
+ var fourth = rt.FamilyID
+ if fourth == "" {
+ fourth = rt.ClientID
+ }
+
+ return strings.Join(
+ []string{rt.HomeAccountID, rt.Environment, rt.CredentialType, fourth},
+ shared.CacheKeySeparator,
+ )
+}
+
+func (rt RefreshToken) GetSecret() string {
+ return rt.Secret
+}
+
+// DeviceCodeResult stores the response from the STS device code endpoint.
+type DeviceCodeResult struct {
+ // UserCode is the code the user needs to provide when authentication at the verification URI.
+ UserCode string
+ // DeviceCode is the code used in the access token request.
+ DeviceCode string
+ // VerificationURL is the the URL where user can authenticate.
+ VerificationURL string
+ // ExpiresOn is the expiration time of device code in seconds.
+ ExpiresOn time.Time
+ // Interval is the interval at which the STS should be polled at.
+ Interval int
+ // Message is the message which should be displayed to the user.
+ Message string
+ // ClientID is the UUID issued by the authorization server for your application.
+ ClientID string
+ // Scopes is the OpenID scopes used to request access a protected API.
+ Scopes []string
+}
+
+// NewDeviceCodeResult creates a DeviceCodeResult instance.
+func NewDeviceCodeResult(userCode, deviceCode, verificationURL string, expiresOn time.Time, interval int, message, clientID string, scopes []string) DeviceCodeResult {
+ return DeviceCodeResult{userCode, deviceCode, verificationURL, expiresOn, interval, message, clientID, scopes}
+}
+
+func (dcr DeviceCodeResult) String() string {
+ return fmt.Sprintf("UserCode: (%v)\nDeviceCode: (%v)\nURL: (%v)\nMessage: (%v)\n", dcr.UserCode, dcr.DeviceCode, dcr.VerificationURL, dcr.Message)
+
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority/authority.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority/authority.go
new file mode 100644
index 00000000000..de5f053f7d1
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority/authority.go
@@ -0,0 +1,545 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+package authority
+
+import (
+ "context"
+ "crypto/sha256"
+ "encoding/base64"
+ "encoding/json"
+ "errors"
+ "fmt"
+ "io"
+ "net/http"
+ "net/url"
+ "os"
+ "path"
+ "strings"
+ "time"
+
+ "github.com/google/uuid"
+)
+
+const (
+ authorizationEndpoint = "https://%v/%v/oauth2/v2.0/authorize"
+ instanceDiscoveryEndpoint = "https://%v/common/discovery/instance"
+ tenantDiscoveryEndpointWithRegion = "https://%s.%s/%s/v2.0/.well-known/openid-configuration"
+ regionName = "REGION_NAME"
+ defaultAPIVersion = "2021-10-01"
+ imdsEndpoint = "http://169.254.169.254/metadata/instance/compute/location?format=text&api-version=" + defaultAPIVersion
+ defaultHost = "login.microsoftonline.com"
+ autoDetectRegion = "TryAutoDetect"
+)
+
+type jsonCaller interface {
+ JSONCall(ctx context.Context, endpoint string, headers http.Header, qv url.Values, body, resp interface{}) error
+}
+
+var aadTrustedHostList = map[string]bool{
+ "login.windows.net": true, // Microsoft Azure Worldwide - Used in validation scenarios where host is not this list
+ "login.chinacloudapi.cn": true, // Microsoft Azure China
+ "login.microsoftonline.de": true, // Microsoft Azure Blackforest
+ "login-us.microsoftonline.com": true, // Microsoft Azure US Government - Legacy
+ "login.microsoftonline.us": true, // Microsoft Azure US Government
+ "login.microsoftonline.com": true, // Microsoft Azure Worldwide
+ "login.cloudgovapi.us": true, // Microsoft Azure US Government
+}
+
+// TrustedHost checks if an AAD host is trusted/valid.
+func TrustedHost(host string) bool {
+ if _, ok := aadTrustedHostList[host]; ok {
+ return true
+ }
+ return false
+}
+
+type OAuthResponseBase struct {
+ Error string `json:"error"`
+ SubError string `json:"suberror"`
+ ErrorDescription string `json:"error_description"`
+ ErrorCodes []int `json:"error_codes"`
+ CorrelationID string `json:"correlation_id"`
+ Claims string `json:"claims"`
+}
+
+// TenantDiscoveryResponse is the tenant endpoints from the OpenID configuration endpoint.
+type TenantDiscoveryResponse struct {
+ OAuthResponseBase
+
+ AuthorizationEndpoint string `json:"authorization_endpoint"`
+ TokenEndpoint string `json:"token_endpoint"`
+ Issuer string `json:"issuer"`
+
+ AdditionalFields map[string]interface{}
+}
+
+// Validate validates that the response had the correct values required.
+func (r *TenantDiscoveryResponse) Validate() error {
+ switch "" {
+ case r.AuthorizationEndpoint:
+ return errors.New("TenantDiscoveryResponse: authorize endpoint was not found in the openid configuration")
+ case r.TokenEndpoint:
+ return errors.New("TenantDiscoveryResponse: token endpoint was not found in the openid configuration")
+ case r.Issuer:
+ return errors.New("TenantDiscoveryResponse: issuer was not found in the openid configuration")
+ }
+ return nil
+}
+
+type InstanceDiscoveryMetadata struct {
+ PreferredNetwork string `json:"preferred_network"`
+ PreferredCache string `json:"preferred_cache"`
+ Aliases []string `json:"aliases"`
+
+ AdditionalFields map[string]interface{}
+}
+
+type InstanceDiscoveryResponse struct {
+ TenantDiscoveryEndpoint string `json:"tenant_discovery_endpoint"`
+ Metadata []InstanceDiscoveryMetadata `json:"metadata"`
+
+ AdditionalFields map[string]interface{}
+}
+
+//go:generate stringer -type=AuthorizeType
+
+// AuthorizeType represents the type of token flow.
+type AuthorizeType int
+
+// These are all the types of token flows.
+const (
+ ATUnknown AuthorizeType = iota
+ ATUsernamePassword
+ ATWindowsIntegrated
+ ATAuthCode
+ ATInteractive
+ ATClientCredentials
+ ATDeviceCode
+ ATRefreshToken
+ AccountByID
+ ATOnBehalfOf
+)
+
+// These are all authority types
+const (
+ AAD = "MSSTS"
+ ADFS = "ADFS"
+)
+
+// AuthParams represents the parameters used for authorization for token acquisition.
+type AuthParams struct {
+ AuthorityInfo Info
+ CorrelationID string
+ Endpoints Endpoints
+ ClientID string
+ // Redirecturi is used for auth flows that specify a redirect URI (e.g. local server for interactive auth flow).
+ Redirecturi string
+ HomeAccountID string
+ // Username is the user-name portion for username/password auth flow.
+ Username string
+ // Password is the password portion for username/password auth flow.
+ Password string
+ // Scopes is the list of scopes the user consents to.
+ Scopes []string
+ // AuthorizationType specifies the auth flow being used.
+ AuthorizationType AuthorizeType
+ // State is a random value used to prevent cross-site request forgery attacks.
+ State string
+ // CodeChallenge is derived from a code verifier and is sent in the auth request.
+ CodeChallenge string
+ // CodeChallengeMethod describes the method used to create the CodeChallenge.
+ CodeChallengeMethod string
+ // Prompt specifies the user prompt type during interactive auth.
+ Prompt string
+ // IsConfidentialClient specifies if it is a confidential client.
+ IsConfidentialClient bool
+ // SendX5C specifies if x5c claim(public key of the certificate) should be sent to STS.
+ SendX5C bool
+ // UserAssertion is the access token used to acquire token on behalf of user
+ UserAssertion string
+ // Capabilities the client will include with each token request, for example "CP1".
+ // Call [NewClientCapabilities] to construct a value for this field.
+ Capabilities ClientCapabilities
+ // Claims required for an access token to satisfy a conditional access policy
+ Claims string
+ // KnownAuthorityHosts don't require metadata discovery because they're known to the user
+ KnownAuthorityHosts []string
+ // LoginHint is a username with which to pre-populate account selection during interactive auth
+ LoginHint string
+ // DomainHint is a directive that can be used to accelerate the user to their federated IdP sign-in page
+ DomainHint string
+}
+
+// NewAuthParams creates an authorization parameters object.
+func NewAuthParams(clientID string, authorityInfo Info) AuthParams {
+ return AuthParams{
+ ClientID: clientID,
+ AuthorityInfo: authorityInfo,
+ CorrelationID: uuid.New().String(),
+ }
+}
+
+// WithTenant returns a copy of the AuthParams having the specified tenant ID. If the given
+// ID is empty, the copy is identical to the original. This function returns an error in
+// several cases:
+// - ID isn't specific (for example, it's "common")
+// - ID is non-empty and the authority doesn't support tenants (for example, it's an ADFS authority)
+// - the client is configured to authenticate only Microsoft accounts via the "consumers" endpoint
+// - the resulting authority URL is invalid
+func (p AuthParams) WithTenant(ID string) (AuthParams, error) {
+ switch ID {
+ case "", p.AuthorityInfo.Tenant:
+ // keep the default tenant because the caller didn't override it
+ return p, nil
+ case "common", "consumers", "organizations":
+ if p.AuthorityInfo.AuthorityType == AAD {
+ return p, fmt.Errorf(`tenant ID must be a specific tenant, not "%s"`, ID)
+ }
+ // else we'll return a better error below
+ }
+ if p.AuthorityInfo.AuthorityType != AAD {
+ return p, errors.New("the authority doesn't support tenants")
+ }
+ if p.AuthorityInfo.Tenant == "consumers" {
+ return p, errors.New(`client is configured to authenticate only personal Microsoft accounts, via the "consumers" endpoint`)
+ }
+ authority := "https://" + path.Join(p.AuthorityInfo.Host, ID)
+ info, err := NewInfoFromAuthorityURI(authority, p.AuthorityInfo.ValidateAuthority, p.AuthorityInfo.InstanceDiscoveryDisabled)
+ if err == nil {
+ info.Region = p.AuthorityInfo.Region
+ p.AuthorityInfo = info
+ }
+ return p, err
+}
+
+// MergeCapabilitiesAndClaims combines client capabilities and challenge claims into a value suitable for an authentication request's "claims" parameter.
+func (p AuthParams) MergeCapabilitiesAndClaims() (string, error) {
+ claims := p.Claims
+ if len(p.Capabilities.asMap) > 0 {
+ if claims == "" {
+ // without claims the result is simply the capabilities
+ return p.Capabilities.asJSON, nil
+ }
+ // Otherwise, merge claims and capabilties into a single JSON object.
+ // We handle the claims challenge as a map because we don't know its structure.
+ var challenge map[string]any
+ if err := json.Unmarshal([]byte(claims), &challenge); err != nil {
+ return "", fmt.Errorf(`claims must be JSON. Are they base64 encoded? json.Unmarshal returned "%v"`, err)
+ }
+ if err := merge(p.Capabilities.asMap, challenge); err != nil {
+ return "", err
+ }
+ b, err := json.Marshal(challenge)
+ if err != nil {
+ return "", err
+ }
+ claims = string(b)
+ }
+ return claims, nil
+}
+
+// merges a into b without overwriting b's values. Returns an error when a and b share a key for which either has a non-object value.
+func merge(a, b map[string]any) error {
+ for k, av := range a {
+ if bv, ok := b[k]; !ok {
+ // b doesn't contain this key => simply set it to a's value
+ b[k] = av
+ } else {
+ // b does contain this key => recursively merge a[k] into b[k], provided both are maps. If a[k] or b[k] isn't
+ // a map, return an error because merging would overwrite some value in b. Errors shouldn't occur in practice
+ // because the challenge will be from AAD, which knows the capabilities format.
+ if A, ok := av.(map[string]any); ok {
+ if B, ok := bv.(map[string]any); ok {
+ return merge(A, B)
+ } else {
+ // b[k] isn't a map
+ return errors.New("challenge claims conflict with client capabilities")
+ }
+ } else {
+ // a[k] isn't a map
+ return errors.New("challenge claims conflict with client capabilities")
+ }
+ }
+ }
+ return nil
+}
+
+// ClientCapabilities stores capabilities in the formats used by AuthParams.MergeCapabilitiesAndClaims.
+// [NewClientCapabilities] precomputes these representations because capabilities are static for the
+// lifetime of a client and are included with every authentication request i.e., these computations
+// always have the same result and would otherwise have to be repeated for every request.
+type ClientCapabilities struct {
+ // asJSON is for the common case: adding the capabilities to an auth request with no challenge claims
+ asJSON string
+ // asMap is for merging the capabilities with challenge claims
+ asMap map[string]any
+}
+
+func NewClientCapabilities(capabilities []string) (ClientCapabilities, error) {
+ c := ClientCapabilities{}
+ var err error
+ if len(capabilities) > 0 {
+ cpbs := make([]string, len(capabilities))
+ for i := 0; i < len(cpbs); i++ {
+ cpbs[i] = fmt.Sprintf(`"%s"`, capabilities[i])
+ }
+ c.asJSON = fmt.Sprintf(`{"access_token":{"xms_cc":{"values":[%s]}}}`, strings.Join(cpbs, ","))
+ // note our JSON is valid but we can't stop users breaking it with garbage like "}"
+ err = json.Unmarshal([]byte(c.asJSON), &c.asMap)
+ }
+ return c, err
+}
+
+// Info consists of information about the authority.
+type Info struct {
+ Host string
+ CanonicalAuthorityURI string
+ AuthorityType string
+ UserRealmURIPrefix string
+ ValidateAuthority bool
+ Tenant string
+ Region string
+ InstanceDiscoveryDisabled bool
+}
+
+func firstPathSegment(u *url.URL) (string, error) {
+ pathParts := strings.Split(u.EscapedPath(), "/")
+ if len(pathParts) >= 2 {
+ return pathParts[1], nil
+ }
+
+ return "", errors.New("authority does not have two segments")
+}
+
+// NewInfoFromAuthorityURI creates an AuthorityInfo instance from the authority URL provided.
+func NewInfoFromAuthorityURI(authorityURI string, validateAuthority bool, instanceDiscoveryDisabled bool) (Info, error) {
+ authorityURI = strings.ToLower(authorityURI)
+ var authorityType string
+ u, err := url.Parse(authorityURI)
+ if err != nil {
+ return Info{}, fmt.Errorf("authorityURI passed could not be parsed: %w", err)
+ }
+ if u.Scheme != "https" {
+ return Info{}, fmt.Errorf("authorityURI(%s) must have scheme https", authorityURI)
+ }
+
+ tenant, err := firstPathSegment(u)
+ if tenant == "adfs" {
+ authorityType = ADFS
+ } else {
+ authorityType = AAD
+ }
+
+ if err != nil {
+ return Info{}, err
+ }
+
+ // u.Host includes the port, if any, which is required for private cloud deployments
+ return Info{
+ Host: u.Host,
+ CanonicalAuthorityURI: fmt.Sprintf("https://%v/%v/", u.Host, tenant),
+ AuthorityType: authorityType,
+ UserRealmURIPrefix: fmt.Sprintf("https://%v/common/userrealm/", u.Hostname()),
+ ValidateAuthority: validateAuthority,
+ Tenant: tenant,
+ InstanceDiscoveryDisabled: instanceDiscoveryDisabled,
+ }, nil
+}
+
+// Endpoints consists of the endpoints from the tenant discovery response.
+type Endpoints struct {
+ AuthorizationEndpoint string
+ TokenEndpoint string
+ selfSignedJwtAudience string
+ authorityHost string
+}
+
+// NewEndpoints creates an Endpoints object.
+func NewEndpoints(authorizationEndpoint string, tokenEndpoint string, selfSignedJwtAudience string, authorityHost string) Endpoints {
+ return Endpoints{authorizationEndpoint, tokenEndpoint, selfSignedJwtAudience, authorityHost}
+}
+
+// UserRealmAccountType refers to the type of user realm.
+type UserRealmAccountType string
+
+// These are the different types of user realms.
+const (
+ Unknown UserRealmAccountType = ""
+ Federated UserRealmAccountType = "Federated"
+ Managed UserRealmAccountType = "Managed"
+)
+
+// UserRealm is used for the username password request to determine user type
+type UserRealm struct {
+ AccountType UserRealmAccountType `json:"account_type"`
+ DomainName string `json:"domain_name"`
+ CloudInstanceName string `json:"cloud_instance_name"`
+ CloudAudienceURN string `json:"cloud_audience_urn"`
+
+ // required if accountType is Federated
+ FederationProtocol string `json:"federation_protocol"`
+ FederationMetadataURL string `json:"federation_metadata_url"`
+
+ AdditionalFields map[string]interface{}
+}
+
+func (u UserRealm) validate() error {
+ switch "" {
+ case string(u.AccountType):
+ return errors.New("the account type (Federated or Managed) is missing")
+ case u.DomainName:
+ return errors.New("domain name of user realm is missing")
+ case u.CloudInstanceName:
+ return errors.New("cloud instance name of user realm is missing")
+ case u.CloudAudienceURN:
+ return errors.New("cloud Instance URN is missing")
+ }
+
+ if u.AccountType == Federated {
+ switch "" {
+ case u.FederationProtocol:
+ return errors.New("federation protocol of user realm is missing")
+ case u.FederationMetadataURL:
+ return errors.New("federation metadata URL of user realm is missing")
+ }
+ }
+ return nil
+}
+
+// Client represents the REST calls to authority backends.
+type Client struct {
+ // Comm provides the HTTP transport client.
+ Comm jsonCaller // *comm.Client
+}
+
+func (c Client) UserRealm(ctx context.Context, authParams AuthParams) (UserRealm, error) {
+ endpoint := fmt.Sprintf("https://%s/common/UserRealm/%s", authParams.Endpoints.authorityHost, url.PathEscape(authParams.Username))
+ qv := url.Values{
+ "api-version": []string{"1.0"},
+ }
+
+ resp := UserRealm{}
+ err := c.Comm.JSONCall(
+ ctx,
+ endpoint,
+ http.Header{"client-request-id": []string{authParams.CorrelationID}},
+ qv,
+ nil,
+ &resp,
+ )
+ if err != nil {
+ return resp, err
+ }
+
+ return resp, resp.validate()
+}
+
+func (c Client) GetTenantDiscoveryResponse(ctx context.Context, openIDConfigurationEndpoint string) (TenantDiscoveryResponse, error) {
+ resp := TenantDiscoveryResponse{}
+ err := c.Comm.JSONCall(
+ ctx,
+ openIDConfigurationEndpoint,
+ http.Header{},
+ nil,
+ nil,
+ &resp,
+ )
+
+ return resp, err
+}
+
+func (c Client) AADInstanceDiscovery(ctx context.Context, authorityInfo Info) (InstanceDiscoveryResponse, error) {
+ region := ""
+ var err error
+ resp := InstanceDiscoveryResponse{}
+ if authorityInfo.Region != "" && authorityInfo.Region != autoDetectRegion {
+ region = authorityInfo.Region
+ } else if authorityInfo.Region == autoDetectRegion {
+ region = detectRegion(ctx)
+ }
+ if region != "" {
+ environment := authorityInfo.Host
+ switch environment {
+ case "login.microsoft.com", "login.windows.net", "sts.windows.net", defaultHost:
+ environment = "r." + defaultHost
+ }
+ resp.TenantDiscoveryEndpoint = fmt.Sprintf(tenantDiscoveryEndpointWithRegion, region, environment, authorityInfo.Tenant)
+ metadata := InstanceDiscoveryMetadata{
+ PreferredNetwork: fmt.Sprintf("%v.%v", region, authorityInfo.Host),
+ PreferredCache: authorityInfo.Host,
+ Aliases: []string{fmt.Sprintf("%v.%v", region, authorityInfo.Host), authorityInfo.Host},
+ }
+ resp.Metadata = []InstanceDiscoveryMetadata{metadata}
+ } else {
+ qv := url.Values{}
+ qv.Set("api-version", "1.1")
+ qv.Set("authorization_endpoint", fmt.Sprintf(authorizationEndpoint, authorityInfo.Host, authorityInfo.Tenant))
+
+ discoveryHost := defaultHost
+ if TrustedHost(authorityInfo.Host) {
+ discoveryHost = authorityInfo.Host
+ }
+
+ endpoint := fmt.Sprintf(instanceDiscoveryEndpoint, discoveryHost)
+ err = c.Comm.JSONCall(ctx, endpoint, http.Header{}, qv, nil, &resp)
+ }
+ return resp, err
+}
+
+func detectRegion(ctx context.Context) string {
+ region := os.Getenv(regionName)
+ if region != "" {
+ region = strings.ReplaceAll(region, " ", "")
+ return strings.ToLower(region)
+ }
+ // HTTP call to IMDS endpoint to get region
+ // Refer : https://identitydivision.visualstudio.com/DevEx/_git/AuthLibrariesApiReview?path=%2FPinAuthToRegion%2FAAD%20SDK%20Proposal%20to%20Pin%20Auth%20to%20region.md&_a=preview&version=GBdev
+ // Set a 2 second timeout for this http client which only does calls to IMDS endpoint
+ client := http.Client{
+ Timeout: time.Duration(2 * time.Second),
+ }
+ req, _ := http.NewRequest("GET", imdsEndpoint, nil)
+ req.Header.Set("Metadata", "true")
+ resp, err := client.Do(req)
+ // If the request times out or there is an error, it is retried once
+ if err != nil || resp.StatusCode != 200 {
+ resp, err = client.Do(req)
+ if err != nil || resp.StatusCode != 200 {
+ return ""
+ }
+ }
+ defer resp.Body.Close()
+ response, err := io.ReadAll(resp.Body)
+ if err != nil {
+ return ""
+ }
+ return string(response)
+}
+
+func (a *AuthParams) CacheKey(isAppCache bool) string {
+ if a.AuthorizationType == ATOnBehalfOf {
+ return a.AssertionHash()
+ }
+ if a.AuthorizationType == ATClientCredentials || isAppCache {
+ return a.AppKey()
+ }
+ if a.AuthorizationType == ATRefreshToken || a.AuthorizationType == AccountByID {
+ return a.HomeAccountID
+ }
+ return ""
+}
+func (a *AuthParams) AssertionHash() string {
+ hasher := sha256.New()
+ // Per documentation this never returns an error : https://pkg.go.dev/hash#pkg-types
+ _, _ = hasher.Write([]byte(a.UserAssertion))
+ sha := base64.URLEncoding.EncodeToString(hasher.Sum(nil))
+ return sha
+}
+
+func (a *AuthParams) AppKey() string {
+ if a.AuthorityInfo.Tenant != "" {
+ return fmt.Sprintf("%s_%s_AppTokenCache", a.ClientID, a.AuthorityInfo.Tenant)
+ }
+ return fmt.Sprintf("%s__AppTokenCache", a.ClientID)
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority/authorizetype_string.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority/authorizetype_string.go
new file mode 100644
index 00000000000..10039773b06
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority/authorizetype_string.go
@@ -0,0 +1,30 @@
+// Code generated by "stringer -type=AuthorizeType"; DO NOT EDIT.
+
+package authority
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[ATUnknown-0]
+ _ = x[ATUsernamePassword-1]
+ _ = x[ATWindowsIntegrated-2]
+ _ = x[ATAuthCode-3]
+ _ = x[ATInteractive-4]
+ _ = x[ATClientCredentials-5]
+ _ = x[ATDeviceCode-6]
+ _ = x[ATRefreshToken-7]
+}
+
+const _AuthorizeType_name = "ATUnknownATUsernamePasswordATWindowsIntegratedATAuthCodeATInteractiveATClientCredentialsATDeviceCodeATRefreshToken"
+
+var _AuthorizeType_index = [...]uint8{0, 9, 27, 46, 56, 69, 88, 100, 114}
+
+func (i AuthorizeType) String() string {
+ if i < 0 || i >= AuthorizeType(len(_AuthorizeType_index)-1) {
+ return "AuthorizeType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _AuthorizeType_name[_AuthorizeType_index[i]:_AuthorizeType_index[i+1]]
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/internal/comm/comm.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/internal/comm/comm.go
new file mode 100644
index 00000000000..7d9ec7cd374
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/internal/comm/comm.go
@@ -0,0 +1,320 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+// Package comm provides helpers for communicating with HTTP backends.
+package comm
+
+import (
+ "bytes"
+ "context"
+ "encoding/json"
+ "encoding/xml"
+ "fmt"
+ "io"
+ "net/http"
+ "net/url"
+ "reflect"
+ "runtime"
+ "strings"
+ "time"
+
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/errors"
+ customJSON "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/json"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/version"
+ "github.com/google/uuid"
+)
+
+// HTTPClient represents an HTTP client.
+// It's usually an *http.Client from the standard library.
+type HTTPClient interface {
+ // Do sends an HTTP request and returns an HTTP response.
+ Do(req *http.Request) (*http.Response, error)
+
+ // CloseIdleConnections closes any idle connections in a "keep-alive" state.
+ CloseIdleConnections()
+}
+
+// Client provides a wrapper to our *http.Client that handles compression and serialization needs.
+type Client struct {
+ client HTTPClient
+}
+
+// New returns a new Client object.
+func New(httpClient HTTPClient) *Client {
+ if httpClient == nil {
+ panic("http.Client cannot == nil")
+ }
+
+ return &Client{client: httpClient}
+}
+
+// JSONCall connects to the REST endpoint passing the HTTP query values, headers and JSON conversion
+// of body in the HTTP body. It automatically handles compression and decompression with gzip. The response is JSON
+// unmarshalled into resp. resp must be a pointer to a struct. If the body struct contains a field called
+// "AdditionalFields" we use a custom marshal/unmarshal engine.
+func (c *Client) JSONCall(ctx context.Context, endpoint string, headers http.Header, qv url.Values, body, resp interface{}) error {
+ if qv == nil {
+ qv = url.Values{}
+ }
+
+ v := reflect.ValueOf(resp)
+ if err := c.checkResp(v); err != nil {
+ return err
+ }
+
+ // Choose a JSON marshal/unmarshal depending on if we have AdditionalFields attribute.
+ var marshal = json.Marshal
+ var unmarshal = json.Unmarshal
+ if _, ok := v.Elem().Type().FieldByName("AdditionalFields"); ok {
+ marshal = customJSON.Marshal
+ unmarshal = customJSON.Unmarshal
+ }
+
+ u, err := url.Parse(endpoint)
+ if err != nil {
+ return fmt.Errorf("could not parse path URL(%s): %w", endpoint, err)
+ }
+ u.RawQuery = qv.Encode()
+
+ addStdHeaders(headers)
+
+ req := &http.Request{Method: http.MethodGet, URL: u, Header: headers}
+
+ if body != nil {
+ // Note: In case your wondering why we are not gzip encoding....
+ // I'm not sure if these various services support gzip on send.
+ headers.Add("Content-Type", "application/json; charset=utf-8")
+ data, err := marshal(body)
+ if err != nil {
+ return fmt.Errorf("bug: conn.Call(): could not marshal the body object: %w", err)
+ }
+ req.Body = io.NopCloser(bytes.NewBuffer(data))
+ req.Method = http.MethodPost
+ }
+
+ data, err := c.do(ctx, req)
+ if err != nil {
+ return err
+ }
+
+ if resp != nil {
+ if err := unmarshal(data, resp); err != nil {
+ return fmt.Errorf("json decode error: %w\njson message bytes were: %s", err, string(data))
+ }
+ }
+ return nil
+}
+
+// XMLCall connects to an endpoint and decodes the XML response into resp. This is used when
+// sending application/xml . If sending XML via SOAP, use SOAPCall().
+func (c *Client) XMLCall(ctx context.Context, endpoint string, headers http.Header, qv url.Values, resp interface{}) error {
+ if err := c.checkResp(reflect.ValueOf(resp)); err != nil {
+ return err
+ }
+
+ if qv == nil {
+ qv = url.Values{}
+ }
+
+ u, err := url.Parse(endpoint)
+ if err != nil {
+ return fmt.Errorf("could not parse path URL(%s): %w", endpoint, err)
+ }
+ u.RawQuery = qv.Encode()
+
+ headers.Set("Content-Type", "application/xml; charset=utf-8") // This was not set in he original Mex(), but...
+ addStdHeaders(headers)
+
+ return c.xmlCall(ctx, u, headers, "", resp)
+}
+
+// SOAPCall returns the SOAP message given an endpoint, action, body of the request and the response object to marshal into.
+func (c *Client) SOAPCall(ctx context.Context, endpoint, action string, headers http.Header, qv url.Values, body string, resp interface{}) error {
+ if body == "" {
+ return fmt.Errorf("cannot make a SOAP call with body set to empty string")
+ }
+
+ if err := c.checkResp(reflect.ValueOf(resp)); err != nil {
+ return err
+ }
+
+ if qv == nil {
+ qv = url.Values{}
+ }
+
+ u, err := url.Parse(endpoint)
+ if err != nil {
+ return fmt.Errorf("could not parse path URL(%s): %w", endpoint, err)
+ }
+ u.RawQuery = qv.Encode()
+
+ headers.Set("Content-Type", "application/soap+xml; charset=utf-8")
+ headers.Set("SOAPAction", action)
+ addStdHeaders(headers)
+
+ return c.xmlCall(ctx, u, headers, body, resp)
+}
+
+// xmlCall sends an XML in body and decodes into resp. This simply does the transport and relies on
+// an upper level call to set things such as SOAP parameters and Content-Type, if required.
+func (c *Client) xmlCall(ctx context.Context, u *url.URL, headers http.Header, body string, resp interface{}) error {
+ req := &http.Request{Method: http.MethodGet, URL: u, Header: headers}
+
+ if len(body) > 0 {
+ req.Method = http.MethodPost
+ req.Body = io.NopCloser(strings.NewReader(body))
+ }
+
+ data, err := c.do(ctx, req)
+ if err != nil {
+ return err
+ }
+
+ return xml.Unmarshal(data, resp)
+}
+
+// URLFormCall is used to make a call where we need to send application/x-www-form-urlencoded data
+// to the backend and receive JSON back. qv will be encoded into the request body.
+func (c *Client) URLFormCall(ctx context.Context, endpoint string, qv url.Values, resp interface{}) error {
+ if len(qv) == 0 {
+ return fmt.Errorf("URLFormCall() requires qv to have non-zero length")
+ }
+
+ if err := c.checkResp(reflect.ValueOf(resp)); err != nil {
+ return err
+ }
+
+ u, err := url.Parse(endpoint)
+ if err != nil {
+ return fmt.Errorf("could not parse path URL(%s): %w", endpoint, err)
+ }
+
+ headers := http.Header{}
+ headers.Set("Content-Type", "application/x-www-form-urlencoded; charset=utf-8")
+ addStdHeaders(headers)
+
+ enc := qv.Encode()
+
+ req := &http.Request{
+ Method: http.MethodPost,
+ URL: u,
+ Header: headers,
+ ContentLength: int64(len(enc)),
+ Body: io.NopCloser(strings.NewReader(enc)),
+ GetBody: func() (io.ReadCloser, error) {
+ return io.NopCloser(strings.NewReader(enc)), nil
+ },
+ }
+
+ data, err := c.do(ctx, req)
+ if err != nil {
+ return err
+ }
+
+ v := reflect.ValueOf(resp)
+ if err := c.checkResp(v); err != nil {
+ return err
+ }
+
+ var unmarshal = json.Unmarshal
+ if _, ok := v.Elem().Type().FieldByName("AdditionalFields"); ok {
+ unmarshal = customJSON.Unmarshal
+ }
+ if resp != nil {
+ if err := unmarshal(data, resp); err != nil {
+ return fmt.Errorf("json decode error: %w\nraw message was: %s", err, string(data))
+ }
+ }
+ return nil
+}
+
+// do makes the HTTP call to the server and returns the contents of the body.
+func (c *Client) do(ctx context.Context, req *http.Request) ([]byte, error) {
+ if _, ok := ctx.Deadline(); !ok {
+ var cancel context.CancelFunc
+ ctx, cancel = context.WithTimeout(ctx, 30*time.Second)
+ defer cancel()
+ }
+ req = req.WithContext(ctx)
+
+ reply, err := c.client.Do(req)
+ if err != nil {
+ return nil, fmt.Errorf("server response error:\n %w", err)
+ }
+ defer reply.Body.Close()
+
+ data, err := c.readBody(reply)
+ if err != nil {
+ return nil, fmt.Errorf("could not read the body of an HTTP Response: %w", err)
+ }
+ reply.Body = io.NopCloser(bytes.NewBuffer(data))
+
+ // NOTE: This doesn't happen immediately after the call so that we can get an error message
+ // from the server and include it in our error.
+ switch reply.StatusCode {
+ case 200, 201:
+ default:
+ sd := strings.TrimSpace(string(data))
+ if sd != "" {
+ // We probably have the error in the body.
+ return nil, errors.CallErr{
+ Req: req,
+ Resp: reply,
+ Err: fmt.Errorf("http call(%s)(%s) error: reply status code was %d:\n%s", req.URL.String(), req.Method, reply.StatusCode, sd),
+ }
+ }
+ return nil, errors.CallErr{
+ Req: req,
+ Resp: reply,
+ Err: fmt.Errorf("http call(%s)(%s) error: reply status code was %d", req.URL.String(), req.Method, reply.StatusCode),
+ }
+ }
+
+ return data, nil
+}
+
+// checkResp checks a response object o make sure it is a pointer to a struct.
+func (c *Client) checkResp(v reflect.Value) error {
+ if v.Kind() != reflect.Ptr {
+ return fmt.Errorf("bug: resp argument must a *struct, was %T", v.Interface())
+ }
+ v = v.Elem()
+ if v.Kind() != reflect.Struct {
+ return fmt.Errorf("bug: resp argument must be a *struct, was %T", v.Interface())
+ }
+ return nil
+}
+
+// readBody reads the body out of an *http.Response. It supports gzip encoded responses.
+func (c *Client) readBody(resp *http.Response) ([]byte, error) {
+ var reader io.Reader = resp.Body
+ switch resp.Header.Get("Content-Encoding") {
+ case "":
+ // Do nothing
+ case "gzip":
+ reader = gzipDecompress(resp.Body)
+ default:
+ return nil, fmt.Errorf("bug: comm.Client.JSONCall(): content was send with unsupported content-encoding %s", resp.Header.Get("Content-Encoding"))
+ }
+ return io.ReadAll(reader)
+}
+
+var testID string
+
+// addStdHeaders adds the standard headers we use on all calls.
+func addStdHeaders(headers http.Header) http.Header {
+ headers.Set("Accept-Encoding", "gzip")
+ // So that I can have a static id for tests.
+ if testID != "" {
+ headers.Set("client-request-id", testID)
+ headers.Set("Return-Client-Request-Id", "false")
+ } else {
+ headers.Set("client-request-id", uuid.New().String())
+ headers.Set("Return-Client-Request-Id", "false")
+ }
+ headers.Set("x-client-sku", "MSAL.Go")
+ headers.Set("x-client-os", runtime.GOOS)
+ headers.Set("x-client-cpu", runtime.GOARCH)
+ headers.Set("x-client-ver", version.Version)
+ return headers
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/internal/comm/compress.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/internal/comm/compress.go
new file mode 100644
index 00000000000..4d3dbfcf0a6
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/internal/comm/compress.go
@@ -0,0 +1,33 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+package comm
+
+import (
+ "compress/gzip"
+ "io"
+)
+
+func gzipDecompress(r io.Reader) io.Reader {
+ gzipReader, _ := gzip.NewReader(r)
+
+ pipeOut, pipeIn := io.Pipe()
+ go func() {
+ // decompression bomb would have to come from Azure services.
+ // If we want to limit, we should do that in comm.do().
+ _, err := io.Copy(pipeIn, gzipReader) //nolint
+ if err != nil {
+ // don't need the error.
+ pipeIn.CloseWithError(err) //nolint
+ gzipReader.Close()
+ return
+ }
+ if err := gzipReader.Close(); err != nil {
+ // don't need the error.
+ pipeIn.CloseWithError(err) //nolint
+ return
+ }
+ pipeIn.Close()
+ }()
+ return pipeOut
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/internal/grant/grant.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/internal/grant/grant.go
new file mode 100644
index 00000000000..b628f61ac08
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/internal/grant/grant.go
@@ -0,0 +1,17 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+// Package grant holds types of grants issued by authorization services.
+package grant
+
+const (
+ Password = "password"
+ JWT = "urn:ietf:params:oauth:grant-type:jwt-bearer"
+ SAMLV1 = "urn:ietf:params:oauth:grant-type:saml1_1-bearer"
+ SAMLV2 = "urn:ietf:params:oauth:grant-type:saml2-bearer"
+ DeviceCode = "device_code"
+ AuthCode = "authorization_code"
+ RefreshToken = "refresh_token"
+ ClientCredential = "client_credentials"
+ ClientAssertion = "urn:ietf:params:oauth:client-assertion-type:jwt-bearer"
+)
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/ops.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/ops.go
new file mode 100644
index 00000000000..1f9c543fa3b
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/ops.go
@@ -0,0 +1,56 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+/*
+Package ops provides operations to various backend services using REST clients.
+
+The REST type provides several clients that can be used to communicate to backends.
+Usage is simple:
+
+ rest := ops.New()
+
+ // Creates an authority client and calls the UserRealm() method.
+ userRealm, err := rest.Authority().UserRealm(ctx, authParameters)
+ if err != nil {
+ // Do something
+ }
+*/
+package ops
+
+import (
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/accesstokens"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/internal/comm"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust"
+)
+
+// HTTPClient represents an HTTP client.
+// It's usually an *http.Client from the standard library.
+type HTTPClient = comm.HTTPClient
+
+// REST provides REST clients for communicating with various backends used by MSAL.
+type REST struct {
+ client *comm.Client
+}
+
+// New is the constructor for REST.
+func New(httpClient HTTPClient) *REST {
+ return &REST{client: comm.New(httpClient)}
+}
+
+// Authority returns a client for querying information about various authorities.
+func (r *REST) Authority() authority.Client {
+ return authority.Client{Comm: r.client}
+}
+
+// AccessTokens returns a client that can be used to get various access tokens for
+// authorization purposes.
+func (r *REST) AccessTokens() accesstokens.Client {
+ return accesstokens.Client{Comm: r.client}
+}
+
+// WSTrust provides access to various metadata in a WSTrust service. This data can
+// be used to gain tokens based on SAML data using the client provided by AccessTokens().
+func (r *REST) WSTrust() wstrust.Client {
+ return wstrust.Client{Comm: r.client}
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/endpointtype_string.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/endpointtype_string.go
new file mode 100644
index 00000000000..a2bb6278ae5
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/endpointtype_string.go
@@ -0,0 +1,25 @@
+// Code generated by "stringer -type=endpointType"; DO NOT EDIT.
+
+package defs
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[etUnknown-0]
+ _ = x[etUsernamePassword-1]
+ _ = x[etWindowsTransport-2]
+}
+
+const _endpointType_name = "etUnknownetUsernamePasswordetWindowsTransport"
+
+var _endpointType_index = [...]uint8{0, 9, 27, 45}
+
+func (i endpointType) String() string {
+ if i < 0 || i >= endpointType(len(_endpointType_index)-1) {
+ return "endpointType(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _endpointType_name[_endpointType_index[i]:_endpointType_index[i+1]]
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/mex_document_definitions.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/mex_document_definitions.go
new file mode 100644
index 00000000000..6497270028d
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/mex_document_definitions.go
@@ -0,0 +1,394 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+package defs
+
+import "encoding/xml"
+
+type Definitions struct {
+ XMLName xml.Name `xml:"definitions"`
+ Text string `xml:",chardata"`
+ Name string `xml:"name,attr"`
+ TargetNamespace string `xml:"targetNamespace,attr"`
+ WSDL string `xml:"wsdl,attr"`
+ XSD string `xml:"xsd,attr"`
+ T string `xml:"t,attr"`
+ SOAPENC string `xml:"soapenc,attr"`
+ SOAP string `xml:"soap,attr"`
+ TNS string `xml:"tns,attr"`
+ MSC string `xml:"msc,attr"`
+ WSAM string `xml:"wsam,attr"`
+ SOAP12 string `xml:"soap12,attr"`
+ WSA10 string `xml:"wsa10,attr"`
+ WSA string `xml:"wsa,attr"`
+ WSAW string `xml:"wsaw,attr"`
+ WSX string `xml:"wsx,attr"`
+ WSAP string `xml:"wsap,attr"`
+ WSU string `xml:"wsu,attr"`
+ Trust string `xml:"trust,attr"`
+ WSP string `xml:"wsp,attr"`
+ Policy []Policy `xml:"Policy"`
+ Types Types `xml:"types"`
+ Message []Message `xml:"message"`
+ PortType []PortType `xml:"portType"`
+ Binding []Binding `xml:"binding"`
+ Service Service `xml:"service"`
+}
+
+type Policy struct {
+ Text string `xml:",chardata"`
+ ID string `xml:"Id,attr"`
+ ExactlyOne ExactlyOne `xml:"ExactlyOne"`
+}
+
+type ExactlyOne struct {
+ Text string `xml:",chardata"`
+ All All `xml:"All"`
+}
+
+type All struct {
+ Text string `xml:",chardata"`
+ NegotiateAuthentication NegotiateAuthentication `xml:"NegotiateAuthentication"`
+ TransportBinding TransportBinding `xml:"TransportBinding"`
+ UsingAddressing Text `xml:"UsingAddressing"`
+ EndorsingSupportingTokens EndorsingSupportingTokens `xml:"EndorsingSupportingTokens"`
+ WSS11 WSS11 `xml:"Wss11"`
+ Trust10 Trust10 `xml:"Trust10"`
+ SignedSupportingTokens SignedSupportingTokens `xml:"SignedSupportingTokens"`
+ Trust13 WSTrust13 `xml:"Trust13"`
+ SignedEncryptedSupportingTokens SignedEncryptedSupportingTokens `xml:"SignedEncryptedSupportingTokens"`
+}
+
+type NegotiateAuthentication struct {
+ Text string `xml:",chardata"`
+ HTTP string `xml:"http,attr"`
+ XMLName xml.Name
+}
+
+type TransportBinding struct {
+ Text string `xml:",chardata"`
+ SP string `xml:"sp,attr"`
+ Policy TransportBindingPolicy `xml:"Policy"`
+}
+
+type TransportBindingPolicy struct {
+ Text string `xml:",chardata"`
+ TransportToken TransportToken `xml:"TransportToken"`
+ AlgorithmSuite AlgorithmSuite `xml:"AlgorithmSuite"`
+ Layout Layout `xml:"Layout"`
+ IncludeTimestamp Text `xml:"IncludeTimestamp"`
+}
+
+type TransportToken struct {
+ Text string `xml:",chardata"`
+ Policy TransportTokenPolicy `xml:"Policy"`
+}
+
+type TransportTokenPolicy struct {
+ Text string `xml:",chardata"`
+ HTTPSToken HTTPSToken `xml:"HttpsToken"`
+}
+
+type HTTPSToken struct {
+ Text string `xml:",chardata"`
+ RequireClientCertificate string `xml:"RequireClientCertificate,attr"`
+}
+
+type AlgorithmSuite struct {
+ Text string `xml:",chardata"`
+ Policy AlgorithmSuitePolicy `xml:"Policy"`
+}
+
+type AlgorithmSuitePolicy struct {
+ Text string `xml:",chardata"`
+ Basic256 Text `xml:"Basic256"`
+ Basic128 Text `xml:"Basic128"`
+}
+
+type Layout struct {
+ Text string `xml:",chardata"`
+ Policy LayoutPolicy `xml:"Policy"`
+}
+
+type LayoutPolicy struct {
+ Text string `xml:",chardata"`
+ Strict Text `xml:"Strict"`
+}
+
+type EndorsingSupportingTokens struct {
+ Text string `xml:",chardata"`
+ SP string `xml:"sp,attr"`
+ Policy EndorsingSupportingTokensPolicy `xml:"Policy"`
+}
+
+type EndorsingSupportingTokensPolicy struct {
+ Text string `xml:",chardata"`
+ X509Token X509Token `xml:"X509Token"`
+ RSAToken RSAToken `xml:"RsaToken"`
+ SignedParts SignedParts `xml:"SignedParts"`
+ KerberosToken KerberosToken `xml:"KerberosToken"`
+ IssuedToken IssuedToken `xml:"IssuedToken"`
+ KeyValueToken KeyValueToken `xml:"KeyValueToken"`
+}
+
+type X509Token struct {
+ Text string `xml:",chardata"`
+ IncludeToken string `xml:"IncludeToken,attr"`
+ Policy X509TokenPolicy `xml:"Policy"`
+}
+
+type X509TokenPolicy struct {
+ Text string `xml:",chardata"`
+ RequireThumbprintReference Text `xml:"RequireThumbprintReference"`
+ WSSX509V3Token10 Text `xml:"WssX509V3Token10"`
+}
+
+type RSAToken struct {
+ Text string `xml:",chardata"`
+ IncludeToken string `xml:"IncludeToken,attr"`
+ Optional string `xml:"Optional,attr"`
+ MSSP string `xml:"mssp,attr"`
+}
+
+type SignedParts struct {
+ Text string `xml:",chardata"`
+ Header SignedPartsHeader `xml:"Header"`
+}
+
+type SignedPartsHeader struct {
+ Text string `xml:",chardata"`
+ Name string `xml:"Name,attr"`
+ Namespace string `xml:"Namespace,attr"`
+}
+
+type KerberosToken struct {
+ Text string `xml:",chardata"`
+ IncludeToken string `xml:"IncludeToken,attr"`
+ Policy KerberosTokenPolicy `xml:"Policy"`
+}
+
+type KerberosTokenPolicy struct {
+ Text string `xml:",chardata"`
+ WSSGSSKerberosV5ApReqToken11 Text `xml:"WssGssKerberosV5ApReqToken11"`
+}
+
+type IssuedToken struct {
+ Text string `xml:",chardata"`
+ IncludeToken string `xml:"IncludeToken,attr"`
+ RequestSecurityTokenTemplate RequestSecurityTokenTemplate `xml:"RequestSecurityTokenTemplate"`
+ Policy IssuedTokenPolicy `xml:"Policy"`
+}
+
+type RequestSecurityTokenTemplate struct {
+ Text string `xml:",chardata"`
+ KeyType Text `xml:"KeyType"`
+ EncryptWith Text `xml:"EncryptWith"`
+ SignatureAlgorithm Text `xml:"SignatureAlgorithm"`
+ CanonicalizationAlgorithm Text `xml:"CanonicalizationAlgorithm"`
+ EncryptionAlgorithm Text `xml:"EncryptionAlgorithm"`
+ KeySize Text `xml:"KeySize"`
+ KeyWrapAlgorithm Text `xml:"KeyWrapAlgorithm"`
+}
+
+type IssuedTokenPolicy struct {
+ Text string `xml:",chardata"`
+ RequireInternalReference Text `xml:"RequireInternalReference"`
+}
+
+type KeyValueToken struct {
+ Text string `xml:",chardata"`
+ IncludeToken string `xml:"IncludeToken,attr"`
+ Optional string `xml:"Optional,attr"`
+}
+
+type WSS11 struct {
+ Text string `xml:",chardata"`
+ SP string `xml:"sp,attr"`
+ Policy Wss11Policy `xml:"Policy"`
+}
+
+type Wss11Policy struct {
+ Text string `xml:",chardata"`
+ MustSupportRefThumbprint Text `xml:"MustSupportRefThumbprint"`
+}
+
+type Trust10 struct {
+ Text string `xml:",chardata"`
+ SP string `xml:"sp,attr"`
+ Policy Trust10Policy `xml:"Policy"`
+}
+
+type Trust10Policy struct {
+ Text string `xml:",chardata"`
+ MustSupportIssuedTokens Text `xml:"MustSupportIssuedTokens"`
+ RequireClientEntropy Text `xml:"RequireClientEntropy"`
+ RequireServerEntropy Text `xml:"RequireServerEntropy"`
+}
+
+type SignedSupportingTokens struct {
+ Text string `xml:",chardata"`
+ SP string `xml:"sp,attr"`
+ Policy SupportingTokensPolicy `xml:"Policy"`
+}
+
+type SupportingTokensPolicy struct {
+ Text string `xml:",chardata"`
+ UsernameToken UsernameToken `xml:"UsernameToken"`
+}
+type UsernameToken struct {
+ Text string `xml:",chardata"`
+ IncludeToken string `xml:"IncludeToken,attr"`
+ Policy UsernameTokenPolicy `xml:"Policy"`
+}
+
+type UsernameTokenPolicy struct {
+ Text string `xml:",chardata"`
+ WSSUsernameToken10 WSSUsernameToken10 `xml:"WssUsernameToken10"`
+}
+
+type WSSUsernameToken10 struct {
+ Text string `xml:",chardata"`
+ XMLName xml.Name
+}
+
+type WSTrust13 struct {
+ Text string `xml:",chardata"`
+ SP string `xml:"sp,attr"`
+ Policy WSTrust13Policy `xml:"Policy"`
+}
+
+type WSTrust13Policy struct {
+ Text string `xml:",chardata"`
+ MustSupportIssuedTokens Text `xml:"MustSupportIssuedTokens"`
+ RequireClientEntropy Text `xml:"RequireClientEntropy"`
+ RequireServerEntropy Text `xml:"RequireServerEntropy"`
+}
+
+type SignedEncryptedSupportingTokens struct {
+ Text string `xml:",chardata"`
+ SP string `xml:"sp,attr"`
+ Policy SupportingTokensPolicy `xml:"Policy"`
+}
+
+type Types struct {
+ Text string `xml:",chardata"`
+ Schema Schema `xml:"schema"`
+}
+
+type Schema struct {
+ Text string `xml:",chardata"`
+ TargetNamespace string `xml:"targetNamespace,attr"`
+ Import []Import `xml:"import"`
+}
+
+type Import struct {
+ Text string `xml:",chardata"`
+ SchemaLocation string `xml:"schemaLocation,attr"`
+ Namespace string `xml:"namespace,attr"`
+}
+
+type Message struct {
+ Text string `xml:",chardata"`
+ Name string `xml:"name,attr"`
+ Part Part `xml:"part"`
+}
+
+type Part struct {
+ Text string `xml:",chardata"`
+ Name string `xml:"name,attr"`
+ Element string `xml:"element,attr"`
+}
+
+type PortType struct {
+ Text string `xml:",chardata"`
+ Name string `xml:"name,attr"`
+ Operation Operation `xml:"operation"`
+}
+
+type Operation struct {
+ Text string `xml:",chardata"`
+ Name string `xml:"name,attr"`
+ Input OperationIO `xml:"input"`
+ Output OperationIO `xml:"output"`
+}
+
+type OperationIO struct {
+ Text string `xml:",chardata"`
+ Action string `xml:"Action,attr"`
+ Message string `xml:"message,attr"`
+ Body OperationIOBody `xml:"body"`
+}
+
+type OperationIOBody struct {
+ Text string `xml:",chardata"`
+ Use string `xml:"use,attr"`
+}
+
+type Binding struct {
+ Text string `xml:",chardata"`
+ Name string `xml:"name,attr"`
+ Type string `xml:"type,attr"`
+ PolicyReference PolicyReference `xml:"PolicyReference"`
+ Binding DefinitionsBinding `xml:"binding"`
+ Operation BindingOperation `xml:"operation"`
+}
+
+type PolicyReference struct {
+ Text string `xml:",chardata"`
+ URI string `xml:"URI,attr"`
+}
+
+type DefinitionsBinding struct {
+ Text string `xml:",chardata"`
+ Transport string `xml:"transport,attr"`
+}
+
+type BindingOperation struct {
+ Text string `xml:",chardata"`
+ Name string `xml:"name,attr"`
+ Operation BindingOperationOperation `xml:"operation"`
+ Input BindingOperationIO `xml:"input"`
+ Output BindingOperationIO `xml:"output"`
+}
+
+type BindingOperationOperation struct {
+ Text string `xml:",chardata"`
+ SoapAction string `xml:"soapAction,attr"`
+ Style string `xml:"style,attr"`
+}
+
+type BindingOperationIO struct {
+ Text string `xml:",chardata"`
+ Body OperationIOBody `xml:"body"`
+}
+
+type Service struct {
+ Text string `xml:",chardata"`
+ Name string `xml:"name,attr"`
+ Port []Port `xml:"port"`
+}
+
+type Port struct {
+ Text string `xml:",chardata"`
+ Name string `xml:"name,attr"`
+ Binding string `xml:"binding,attr"`
+ Address Address `xml:"address"`
+ EndpointReference PortEndpointReference `xml:"EndpointReference"`
+}
+
+type Address struct {
+ Text string `xml:",chardata"`
+ Location string `xml:"location,attr"`
+}
+
+type PortEndpointReference struct {
+ Text string `xml:",chardata"`
+ Address Text `xml:"Address"`
+ Identity Identity `xml:"Identity"`
+}
+
+type Identity struct {
+ Text string `xml:",chardata"`
+ XMLNS string `xml:"xmlns,attr"`
+ SPN Text `xml:"Spn"`
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/saml_assertion_definitions.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/saml_assertion_definitions.go
new file mode 100644
index 00000000000..7d072556577
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/saml_assertion_definitions.go
@@ -0,0 +1,230 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+package defs
+
+import "encoding/xml"
+
+// TODO(msal): Someone (and it ain't gonna be me) needs to document these attributes or
+// at the least put a link to RFC.
+
+type SAMLDefinitions struct {
+ XMLName xml.Name `xml:"Envelope"`
+ Text string `xml:",chardata"`
+ S string `xml:"s,attr"`
+ A string `xml:"a,attr"`
+ U string `xml:"u,attr"`
+ Header Header `xml:"Header"`
+ Body Body `xml:"Body"`
+}
+
+type Header struct {
+ Text string `xml:",chardata"`
+ Action Action `xml:"Action"`
+ Security Security `xml:"Security"`
+}
+
+type Action struct {
+ Text string `xml:",chardata"`
+ MustUnderstand string `xml:"mustUnderstand,attr"`
+}
+
+type Security struct {
+ Text string `xml:",chardata"`
+ MustUnderstand string `xml:"mustUnderstand,attr"`
+ O string `xml:"o,attr"`
+ Timestamp Timestamp `xml:"Timestamp"`
+}
+
+type Timestamp struct {
+ Text string `xml:",chardata"`
+ ID string `xml:"Id,attr"`
+ Created Text `xml:"Created"`
+ Expires Text `xml:"Expires"`
+}
+
+type Text struct {
+ Text string `xml:",chardata"`
+}
+
+type Body struct {
+ Text string `xml:",chardata"`
+ RequestSecurityTokenResponseCollection RequestSecurityTokenResponseCollection `xml:"RequestSecurityTokenResponseCollection"`
+}
+
+type RequestSecurityTokenResponseCollection struct {
+ Text string `xml:",chardata"`
+ Trust string `xml:"trust,attr"`
+ RequestSecurityTokenResponse []RequestSecurityTokenResponse `xml:"RequestSecurityTokenResponse"`
+}
+
+type RequestSecurityTokenResponse struct {
+ Text string `xml:",chardata"`
+ Lifetime Lifetime `xml:"Lifetime"`
+ AppliesTo AppliesTo `xml:"AppliesTo"`
+ RequestedSecurityToken RequestedSecurityToken `xml:"RequestedSecurityToken"`
+ RequestedAttachedReference RequestedAttachedReference `xml:"RequestedAttachedReference"`
+ RequestedUnattachedReference RequestedUnattachedReference `xml:"RequestedUnattachedReference"`
+ TokenType Text `xml:"TokenType"`
+ RequestType Text `xml:"RequestType"`
+ KeyType Text `xml:"KeyType"`
+}
+
+type Lifetime struct {
+ Text string `xml:",chardata"`
+ Created WSUTimestamp `xml:"Created"`
+ Expires WSUTimestamp `xml:"Expires"`
+}
+
+type WSUTimestamp struct {
+ Text string `xml:",chardata"`
+ Wsu string `xml:"wsu,attr"`
+}
+
+type AppliesTo struct {
+ Text string `xml:",chardata"`
+ Wsp string `xml:"wsp,attr"`
+ EndpointReference EndpointReference `xml:"EndpointReference"`
+}
+
+type EndpointReference struct {
+ Text string `xml:",chardata"`
+ Wsa string `xml:"wsa,attr"`
+ Address Text `xml:"Address"`
+}
+
+type RequestedSecurityToken struct {
+ Text string `xml:",chardata"`
+ AssertionRawXML string `xml:",innerxml"`
+ Assertion Assertion `xml:"Assertion"`
+}
+
+type Assertion struct {
+ XMLName xml.Name // Normally its `xml:"Assertion"`, but I think they want to capture the xmlns
+ Text string `xml:",chardata"`
+ MajorVersion string `xml:"MajorVersion,attr"`
+ MinorVersion string `xml:"MinorVersion,attr"`
+ AssertionID string `xml:"AssertionID,attr"`
+ Issuer string `xml:"Issuer,attr"`
+ IssueInstant string `xml:"IssueInstant,attr"`
+ Saml string `xml:"saml,attr"`
+ Conditions Conditions `xml:"Conditions"`
+ AttributeStatement AttributeStatement `xml:"AttributeStatement"`
+ AuthenticationStatement AuthenticationStatement `xml:"AuthenticationStatement"`
+ Signature Signature `xml:"Signature"`
+}
+
+type Conditions struct {
+ Text string `xml:",chardata"`
+ NotBefore string `xml:"NotBefore,attr"`
+ NotOnOrAfter string `xml:"NotOnOrAfter,attr"`
+ AudienceRestrictionCondition AudienceRestrictionCondition `xml:"AudienceRestrictionCondition"`
+}
+
+type AudienceRestrictionCondition struct {
+ Text string `xml:",chardata"`
+ Audience Text `xml:"Audience"`
+}
+
+type AttributeStatement struct {
+ Text string `xml:",chardata"`
+ Subject Subject `xml:"Subject"`
+ Attribute []Attribute `xml:"Attribute"`
+}
+
+type Subject struct {
+ Text string `xml:",chardata"`
+ NameIdentifier NameIdentifier `xml:"NameIdentifier"`
+ SubjectConfirmation SubjectConfirmation `xml:"SubjectConfirmation"`
+}
+
+type NameIdentifier struct {
+ Text string `xml:",chardata"`
+ Format string `xml:"Format,attr"`
+}
+
+type SubjectConfirmation struct {
+ Text string `xml:",chardata"`
+ ConfirmationMethod Text `xml:"ConfirmationMethod"`
+}
+
+type Attribute struct {
+ Text string `xml:",chardata"`
+ AttributeName string `xml:"AttributeName,attr"`
+ AttributeNamespace string `xml:"AttributeNamespace,attr"`
+ AttributeValue Text `xml:"AttributeValue"`
+}
+
+type AuthenticationStatement struct {
+ Text string `xml:",chardata"`
+ AuthenticationMethod string `xml:"AuthenticationMethod,attr"`
+ AuthenticationInstant string `xml:"AuthenticationInstant,attr"`
+ Subject Subject `xml:"Subject"`
+}
+
+type Signature struct {
+ Text string `xml:",chardata"`
+ Ds string `xml:"ds,attr"`
+ SignedInfo SignedInfo `xml:"SignedInfo"`
+ SignatureValue Text `xml:"SignatureValue"`
+ KeyInfo KeyInfo `xml:"KeyInfo"`
+}
+
+type SignedInfo struct {
+ Text string `xml:",chardata"`
+ CanonicalizationMethod Method `xml:"CanonicalizationMethod"`
+ SignatureMethod Method `xml:"SignatureMethod"`
+ Reference Reference `xml:"Reference"`
+}
+
+type Method struct {
+ Text string `xml:",chardata"`
+ Algorithm string `xml:"Algorithm,attr"`
+}
+
+type Reference struct {
+ Text string `xml:",chardata"`
+ URI string `xml:"URI,attr"`
+ Transforms Transforms `xml:"Transforms"`
+ DigestMethod Method `xml:"DigestMethod"`
+ DigestValue Text `xml:"DigestValue"`
+}
+
+type Transforms struct {
+ Text string `xml:",chardata"`
+ Transform []Method `xml:"Transform"`
+}
+
+type KeyInfo struct {
+ Text string `xml:",chardata"`
+ Xmlns string `xml:"xmlns,attr"`
+ X509Data X509Data `xml:"X509Data"`
+}
+
+type X509Data struct {
+ Text string `xml:",chardata"`
+ X509Certificate Text `xml:"X509Certificate"`
+}
+
+type RequestedAttachedReference struct {
+ Text string `xml:",chardata"`
+ SecurityTokenReference SecurityTokenReference `xml:"SecurityTokenReference"`
+}
+
+type SecurityTokenReference struct {
+ Text string `xml:",chardata"`
+ TokenType string `xml:"TokenType,attr"`
+ O string `xml:"o,attr"`
+ K string `xml:"k,attr"`
+ KeyIdentifier KeyIdentifier `xml:"KeyIdentifier"`
+}
+
+type KeyIdentifier struct {
+ Text string `xml:",chardata"`
+ ValueType string `xml:"ValueType,attr"`
+}
+
+type RequestedUnattachedReference struct {
+ Text string `xml:",chardata"`
+ SecurityTokenReference SecurityTokenReference `xml:"SecurityTokenReference"`
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/version_string.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/version_string.go
new file mode 100644
index 00000000000..6fe5efa8a9a
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/version_string.go
@@ -0,0 +1,25 @@
+// Code generated by "stringer -type=Version"; DO NOT EDIT.
+
+package defs
+
+import "strconv"
+
+func _() {
+ // An "invalid array index" compiler error signifies that the constant values have changed.
+ // Re-run the stringer command to generate them again.
+ var x [1]struct{}
+ _ = x[TrustUnknown-0]
+ _ = x[Trust2005-1]
+ _ = x[Trust13-2]
+}
+
+const _Version_name = "TrustUnknownTrust2005Trust13"
+
+var _Version_index = [...]uint8{0, 12, 21, 28}
+
+func (i Version) String() string {
+ if i < 0 || i >= Version(len(_Version_index)-1) {
+ return "Version(" + strconv.FormatInt(int64(i), 10) + ")"
+ }
+ return _Version_name[_Version_index[i]:_Version_index[i+1]]
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/wstrust_endpoint.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/wstrust_endpoint.go
new file mode 100644
index 00000000000..8fad5efb5de
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/wstrust_endpoint.go
@@ -0,0 +1,199 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+package defs
+
+import (
+ "encoding/xml"
+ "fmt"
+ "time"
+
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority"
+ uuid "github.com/google/uuid"
+)
+
+//go:generate stringer -type=Version
+
+type Version int
+
+const (
+ TrustUnknown Version = iota
+ Trust2005
+ Trust13
+)
+
+// Endpoint represents a WSTrust endpoint.
+type Endpoint struct {
+ // Version is the version of the endpoint.
+ Version Version
+ // URL is the URL of the endpoint.
+ URL string
+}
+
+type wsTrustTokenRequestEnvelope struct {
+ XMLName xml.Name `xml:"s:Envelope"`
+ Text string `xml:",chardata"`
+ S string `xml:"xmlns:s,attr"`
+ Wsa string `xml:"xmlns:wsa,attr"`
+ Wsu string `xml:"xmlns:wsu,attr"`
+ Header struct {
+ Text string `xml:",chardata"`
+ Action struct {
+ Text string `xml:",chardata"`
+ MustUnderstand string `xml:"s:mustUnderstand,attr"`
+ } `xml:"wsa:Action"`
+ MessageID struct {
+ Text string `xml:",chardata"`
+ } `xml:"wsa:messageID"`
+ ReplyTo struct {
+ Text string `xml:",chardata"`
+ Address struct {
+ Text string `xml:",chardata"`
+ } `xml:"wsa:Address"`
+ } `xml:"wsa:ReplyTo"`
+ To struct {
+ Text string `xml:",chardata"`
+ MustUnderstand string `xml:"s:mustUnderstand,attr"`
+ } `xml:"wsa:To"`
+ Security struct {
+ Text string `xml:",chardata"`
+ MustUnderstand string `xml:"s:mustUnderstand,attr"`
+ Wsse string `xml:"xmlns:wsse,attr"`
+ Timestamp struct {
+ Text string `xml:",chardata"`
+ ID string `xml:"wsu:Id,attr"`
+ Created struct {
+ Text string `xml:",chardata"`
+ } `xml:"wsu:Created"`
+ Expires struct {
+ Text string `xml:",chardata"`
+ } `xml:"wsu:Expires"`
+ } `xml:"wsu:Timestamp"`
+ UsernameToken struct {
+ Text string `xml:",chardata"`
+ ID string `xml:"wsu:Id,attr"`
+ Username struct {
+ Text string `xml:",chardata"`
+ } `xml:"wsse:Username"`
+ Password struct {
+ Text string `xml:",chardata"`
+ } `xml:"wsse:Password"`
+ } `xml:"wsse:UsernameToken"`
+ } `xml:"wsse:Security"`
+ } `xml:"s:Header"`
+ Body struct {
+ Text string `xml:",chardata"`
+ RequestSecurityToken struct {
+ Text string `xml:",chardata"`
+ Wst string `xml:"xmlns:wst,attr"`
+ AppliesTo struct {
+ Text string `xml:",chardata"`
+ Wsp string `xml:"xmlns:wsp,attr"`
+ EndpointReference struct {
+ Text string `xml:",chardata"`
+ Address struct {
+ Text string `xml:",chardata"`
+ } `xml:"wsa:Address"`
+ } `xml:"wsa:EndpointReference"`
+ } `xml:"wsp:AppliesTo"`
+ KeyType struct {
+ Text string `xml:",chardata"`
+ } `xml:"wst:KeyType"`
+ RequestType struct {
+ Text string `xml:",chardata"`
+ } `xml:"wst:RequestType"`
+ } `xml:"wst:RequestSecurityToken"`
+ } `xml:"s:Body"`
+}
+
+func buildTimeString(t time.Time) string {
+ // Golang time formats are weird: https://stackoverflow.com/questions/20234104/how-to-format-current-time-using-a-yyyymmddhhmmss-format
+ return t.Format("2006-01-02T15:04:05.000Z")
+}
+
+func (wte *Endpoint) buildTokenRequestMessage(authType authority.AuthorizeType, cloudAudienceURN string, username string, password string) (string, error) {
+ var soapAction string
+ var trustNamespace string
+ var keyType string
+ var requestType string
+
+ createdTime := time.Now().UTC()
+ expiresTime := createdTime.Add(10 * time.Minute)
+
+ switch wte.Version {
+ case Trust2005:
+ soapAction = trust2005Spec
+ trustNamespace = "http://schemas.xmlsoap.org/ws/2005/02/trust"
+ keyType = "http://schemas.xmlsoap.org/ws/2005/05/identity/NoProofKey"
+ requestType = "http://schemas.xmlsoap.org/ws/2005/02/trust/Issue"
+ case Trust13:
+ soapAction = trust13Spec
+ trustNamespace = "http://docs.oasis-open.org/ws-sx/ws-trust/200512"
+ keyType = "http://docs.oasis-open.org/ws-sx/ws-trust/200512/Bearer"
+ requestType = "http://docs.oasis-open.org/ws-sx/ws-trust/200512/Issue"
+ default:
+ return "", fmt.Errorf("buildTokenRequestMessage had Version == %q, which is not recognized", wte.Version)
+ }
+
+ var envelope wsTrustTokenRequestEnvelope
+
+ messageUUID := uuid.New()
+
+ envelope.S = "http://www.w3.org/2003/05/soap-envelope"
+ envelope.Wsa = "http://www.w3.org/2005/08/addressing"
+ envelope.Wsu = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
+
+ envelope.Header.Action.MustUnderstand = "1"
+ envelope.Header.Action.Text = soapAction
+ envelope.Header.MessageID.Text = "urn:uuid:" + messageUUID.String()
+ envelope.Header.ReplyTo.Address.Text = "http://www.w3.org/2005/08/addressing/anonymous"
+ envelope.Header.To.MustUnderstand = "1"
+ envelope.Header.To.Text = wte.URL
+
+ switch authType {
+ case authority.ATUnknown:
+ return "", fmt.Errorf("buildTokenRequestMessage had no authority type(%v)", authType)
+ case authority.ATUsernamePassword:
+ endpointUUID := uuid.New()
+
+ var trustID string
+ if wte.Version == Trust2005 {
+ trustID = "UnPwSecTok2005-" + endpointUUID.String()
+ } else {
+ trustID = "UnPwSecTok13-" + endpointUUID.String()
+ }
+
+ envelope.Header.Security.MustUnderstand = "1"
+ envelope.Header.Security.Wsse = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
+ envelope.Header.Security.Timestamp.ID = "MSATimeStamp"
+ envelope.Header.Security.Timestamp.Created.Text = buildTimeString(createdTime)
+ envelope.Header.Security.Timestamp.Expires.Text = buildTimeString(expiresTime)
+ envelope.Header.Security.UsernameToken.ID = trustID
+ envelope.Header.Security.UsernameToken.Username.Text = username
+ envelope.Header.Security.UsernameToken.Password.Text = password
+ default:
+ // This is just to note that we don't do anything for other cases.
+ // We aren't missing anything I know of.
+ }
+
+ envelope.Body.RequestSecurityToken.Wst = trustNamespace
+ envelope.Body.RequestSecurityToken.AppliesTo.Wsp = "http://schemas.xmlsoap.org/ws/2004/09/policy"
+ envelope.Body.RequestSecurityToken.AppliesTo.EndpointReference.Address.Text = cloudAudienceURN
+ envelope.Body.RequestSecurityToken.KeyType.Text = keyType
+ envelope.Body.RequestSecurityToken.RequestType.Text = requestType
+
+ output, err := xml.Marshal(envelope)
+ if err != nil {
+ return "", err
+ }
+
+ return string(output), nil
+}
+
+func (wte *Endpoint) BuildTokenRequestMessageWIA(cloudAudienceURN string) (string, error) {
+ return wte.buildTokenRequestMessage(authority.ATWindowsIntegrated, cloudAudienceURN, "", "")
+}
+
+func (wte *Endpoint) BuildTokenRequestMessageUsernamePassword(cloudAudienceURN string, username string, password string) (string, error) {
+ return wte.buildTokenRequestMessage(authority.ATUsernamePassword, cloudAudienceURN, username, password)
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/wstrust_mex_document.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/wstrust_mex_document.go
new file mode 100644
index 00000000000..e3d19886ebc
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs/wstrust_mex_document.go
@@ -0,0 +1,159 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+package defs
+
+import (
+ "errors"
+ "fmt"
+ "strings"
+)
+
+//go:generate stringer -type=endpointType
+
+type endpointType int
+
+const (
+ etUnknown endpointType = iota
+ etUsernamePassword
+ etWindowsTransport
+)
+
+type wsEndpointData struct {
+ Version Version
+ EndpointType endpointType
+}
+
+const trust13Spec string = "http://docs.oasis-open.org/ws-sx/ws-trust/200512/RST/Issue"
+const trust2005Spec string = "http://schemas.xmlsoap.org/ws/2005/02/trust/RST/Issue"
+
+type MexDocument struct {
+ UsernamePasswordEndpoint Endpoint
+ WindowsTransportEndpoint Endpoint
+ policies map[string]endpointType
+ bindings map[string]wsEndpointData
+}
+
+func updateEndpoint(cached *Endpoint, found Endpoint) {
+ if cached == nil || cached.Version == TrustUnknown {
+ *cached = found
+ return
+ }
+ if (*cached).Version == Trust2005 && found.Version == Trust13 {
+ *cached = found
+ return
+ }
+}
+
+// TODO(msal): Someone needs to write tests for everything below.
+
+// NewFromDef creates a new MexDocument.
+func NewFromDef(defs Definitions) (MexDocument, error) {
+ policies, err := policies(defs)
+ if err != nil {
+ return MexDocument{}, err
+ }
+
+ bindings, err := bindings(defs, policies)
+ if err != nil {
+ return MexDocument{}, err
+ }
+
+ userPass, windows, err := endpoints(defs, bindings)
+ if err != nil {
+ return MexDocument{}, err
+ }
+
+ return MexDocument{
+ UsernamePasswordEndpoint: userPass,
+ WindowsTransportEndpoint: windows,
+ policies: policies,
+ bindings: bindings,
+ }, nil
+}
+
+func policies(defs Definitions) (map[string]endpointType, error) {
+ policies := make(map[string]endpointType, len(defs.Policy))
+
+ for _, policy := range defs.Policy {
+ if policy.ExactlyOne.All.NegotiateAuthentication.XMLName.Local != "" {
+ if policy.ExactlyOne.All.TransportBinding.SP != "" && policy.ID != "" {
+ policies["#"+policy.ID] = etWindowsTransport
+ }
+ }
+
+ if policy.ExactlyOne.All.SignedEncryptedSupportingTokens.Policy.UsernameToken.Policy.WSSUsernameToken10.XMLName.Local != "" {
+ if policy.ExactlyOne.All.TransportBinding.SP != "" && policy.ID != "" {
+ policies["#"+policy.ID] = etUsernamePassword
+ }
+ }
+ if policy.ExactlyOne.All.SignedSupportingTokens.Policy.UsernameToken.Policy.WSSUsernameToken10.XMLName.Local != "" {
+ if policy.ExactlyOne.All.TransportBinding.SP != "" && policy.ID != "" {
+ policies["#"+policy.ID] = etUsernamePassword
+ }
+ }
+ }
+
+ if len(policies) == 0 {
+ return policies, errors.New("no policies for mex document")
+ }
+
+ return policies, nil
+}
+
+func bindings(defs Definitions, policies map[string]endpointType) (map[string]wsEndpointData, error) {
+ bindings := make(map[string]wsEndpointData, len(defs.Binding))
+
+ for _, binding := range defs.Binding {
+ policyName := binding.PolicyReference.URI
+ transport := binding.Binding.Transport
+
+ if transport == "http://schemas.xmlsoap.org/soap/http" {
+ if policy, ok := policies[policyName]; ok {
+ bindingName := binding.Name
+ specVersion := binding.Operation.Operation.SoapAction
+
+ if specVersion == trust13Spec {
+ bindings[bindingName] = wsEndpointData{Trust13, policy}
+ } else if specVersion == trust2005Spec {
+ bindings[bindingName] = wsEndpointData{Trust2005, policy}
+ } else {
+ return nil, errors.New("found unknown spec version in mex document")
+ }
+ }
+ }
+ }
+ return bindings, nil
+}
+
+func endpoints(defs Definitions, bindings map[string]wsEndpointData) (userPass, windows Endpoint, err error) {
+ for _, port := range defs.Service.Port {
+ bindingName := port.Binding
+
+ index := strings.Index(bindingName, ":")
+ if index != -1 {
+ bindingName = bindingName[index+1:]
+ }
+
+ if binding, ok := bindings[bindingName]; ok {
+ url := strings.TrimSpace(port.EndpointReference.Address.Text)
+ if url == "" {
+ return Endpoint{}, Endpoint{}, fmt.Errorf("MexDocument cannot have blank URL endpoint")
+ }
+ if binding.Version == TrustUnknown {
+ return Endpoint{}, Endpoint{}, fmt.Errorf("endpoint version unknown")
+ }
+ endpoint := Endpoint{Version: binding.Version, URL: url}
+
+ switch binding.EndpointType {
+ case etUsernamePassword:
+ updateEndpoint(&userPass, endpoint)
+ case etWindowsTransport:
+ updateEndpoint(&windows, endpoint)
+ default:
+ return Endpoint{}, Endpoint{}, errors.New("found unknown port type in MEX document")
+ }
+ }
+ }
+ return userPass, windows, nil
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/wstrust.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/wstrust.go
new file mode 100644
index 00000000000..47cd4c692d6
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/wstrust.go
@@ -0,0 +1,136 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+/*
+Package wstrust provides a client for communicating with a WSTrust (https://en.wikipedia.org/wiki/WS-Trust#:~:text=WS%2DTrust%20is%20a%20WS,in%20a%20secure%20message%20exchange.)
+for the purposes of extracting metadata from the service. This data can be used to acquire
+tokens using the accesstokens.Client.GetAccessTokenFromSamlGrant() call.
+*/
+package wstrust
+
+import (
+ "context"
+ "errors"
+ "fmt"
+ "net/http"
+ "net/url"
+
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/internal/grant"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/wstrust/defs"
+)
+
+type xmlCaller interface {
+ XMLCall(ctx context.Context, endpoint string, headers http.Header, qv url.Values, resp interface{}) error
+ SOAPCall(ctx context.Context, endpoint, action string, headers http.Header, qv url.Values, body string, resp interface{}) error
+}
+
+type SamlTokenInfo struct {
+ AssertionType string // Should be either constants SAMLV1Grant or SAMLV2Grant.
+ Assertion string
+}
+
+// Client represents the REST calls to get tokens from token generator backends.
+type Client struct {
+ // Comm provides the HTTP transport client.
+ Comm xmlCaller
+}
+
+// TODO(msal): This allows me to call Mex without having a real Def file on line 45.
+// This would fail because policies() would not find a policy. This is easy enough to
+// fix in test data, but.... Definitions is defined with built in structs. That needs
+// to be pulled apart and until then I have this hack in.
+var newFromDef = defs.NewFromDef
+
+// Mex provides metadata about a wstrust service.
+func (c Client) Mex(ctx context.Context, federationMetadataURL string) (defs.MexDocument, error) {
+ resp := defs.Definitions{}
+ err := c.Comm.XMLCall(
+ ctx,
+ federationMetadataURL,
+ http.Header{},
+ nil,
+ &resp,
+ )
+ if err != nil {
+ return defs.MexDocument{}, err
+ }
+
+ return newFromDef(resp)
+}
+
+const (
+ SoapActionDefault = "http://docs.oasis-open.org/ws-sx/ws-trust/200512/RST/Issue"
+
+ // Note: Commented out because this action is not supported. It was in the original code
+ // but only used in a switch where it errored. Since there was only one value, a default
+ // worked better. However, buildTokenRequestMessage() had 2005 support. I'm not actually
+ // sure what's going on here. It like we have half support. For now this is here just
+ // for documentation purposes in case we are going to add support.
+ //
+ // SoapActionWSTrust2005 = "http://schemas.xmlsoap.org/ws/2005/02/trust/RST/Issue"
+)
+
+// SAMLTokenInfo provides SAML information that is used to generate a SAML token.
+func (c Client) SAMLTokenInfo(ctx context.Context, authParameters authority.AuthParams, cloudAudienceURN string, endpoint defs.Endpoint) (SamlTokenInfo, error) {
+ var wsTrustRequestMessage string
+ var err error
+
+ switch authParameters.AuthorizationType {
+ case authority.ATWindowsIntegrated:
+ wsTrustRequestMessage, err = endpoint.BuildTokenRequestMessageWIA(cloudAudienceURN)
+ if err != nil {
+ return SamlTokenInfo{}, err
+ }
+ case authority.ATUsernamePassword:
+ wsTrustRequestMessage, err = endpoint.BuildTokenRequestMessageUsernamePassword(
+ cloudAudienceURN, authParameters.Username, authParameters.Password)
+ if err != nil {
+ return SamlTokenInfo{}, err
+ }
+ default:
+ return SamlTokenInfo{}, fmt.Errorf("unknown auth type %v", authParameters.AuthorizationType)
+ }
+
+ var soapAction string
+ switch endpoint.Version {
+ case defs.Trust13:
+ soapAction = SoapActionDefault
+ case defs.Trust2005:
+ return SamlTokenInfo{}, errors.New("WS Trust 2005 support is not implemented")
+ default:
+ return SamlTokenInfo{}, fmt.Errorf("the SOAP endpoint for a wstrust call had an invalid version: %v", endpoint.Version)
+ }
+
+ resp := defs.SAMLDefinitions{}
+ err = c.Comm.SOAPCall(ctx, endpoint.URL, soapAction, http.Header{}, nil, wsTrustRequestMessage, &resp)
+ if err != nil {
+ return SamlTokenInfo{}, err
+ }
+
+ return c.samlAssertion(resp)
+}
+
+const (
+ samlv1Assertion = "urn:oasis:names:tc:SAML:1.0:assertion"
+ samlv2Assertion = "urn:oasis:names:tc:SAML:2.0:assertion"
+)
+
+func (c Client) samlAssertion(def defs.SAMLDefinitions) (SamlTokenInfo, error) {
+ for _, tokenResponse := range def.Body.RequestSecurityTokenResponseCollection.RequestSecurityTokenResponse {
+ token := tokenResponse.RequestedSecurityToken
+ if token.Assertion.XMLName.Local != "" {
+ assertion := token.AssertionRawXML
+
+ samlVersion := token.Assertion.Saml
+ switch samlVersion {
+ case samlv1Assertion:
+ return SamlTokenInfo{AssertionType: grant.SAMLV1, Assertion: assertion}, nil
+ case samlv2Assertion:
+ return SamlTokenInfo{AssertionType: grant.SAMLV2, Assertion: assertion}, nil
+ }
+ return SamlTokenInfo{}, fmt.Errorf("couldn't parse SAML assertion, version unknown: %q", samlVersion)
+ }
+ }
+ return SamlTokenInfo{}, errors.New("unknown WS-Trust version")
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/resolvers.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/resolvers.go
new file mode 100644
index 00000000000..0ade411797a
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/resolvers.go
@@ -0,0 +1,149 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+// TODO(msal): Write some tests. The original code this came from didn't have tests and I'm too
+// tired at this point to do it. It, like many other *Manager code I found was broken because
+// they didn't have mutex protection.
+
+package oauth
+
+import (
+ "context"
+ "errors"
+ "fmt"
+ "strings"
+ "sync"
+
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority"
+)
+
+// ADFS is an active directory federation service authority type.
+const ADFS = "ADFS"
+
+type cacheEntry struct {
+ Endpoints authority.Endpoints
+ ValidForDomainsInList map[string]bool
+}
+
+func createcacheEntry(endpoints authority.Endpoints) cacheEntry {
+ return cacheEntry{endpoints, map[string]bool{}}
+}
+
+// AuthorityEndpoint retrieves endpoints from an authority for auth and token acquisition.
+type authorityEndpoint struct {
+ rest *ops.REST
+
+ mu sync.Mutex
+ cache map[string]cacheEntry
+}
+
+// newAuthorityEndpoint is the constructor for AuthorityEndpoint.
+func newAuthorityEndpoint(rest *ops.REST) *authorityEndpoint {
+ m := &authorityEndpoint{rest: rest, cache: map[string]cacheEntry{}}
+ return m
+}
+
+// ResolveEndpoints gets the authorization and token endpoints and creates an AuthorityEndpoints instance
+func (m *authorityEndpoint) ResolveEndpoints(ctx context.Context, authorityInfo authority.Info, userPrincipalName string) (authority.Endpoints, error) {
+
+ if endpoints, found := m.cachedEndpoints(authorityInfo, userPrincipalName); found {
+ return endpoints, nil
+ }
+
+ endpoint, err := m.openIDConfigurationEndpoint(ctx, authorityInfo, userPrincipalName)
+ if err != nil {
+ return authority.Endpoints{}, err
+ }
+
+ resp, err := m.rest.Authority().GetTenantDiscoveryResponse(ctx, endpoint)
+ if err != nil {
+ return authority.Endpoints{}, err
+ }
+ if err := resp.Validate(); err != nil {
+ return authority.Endpoints{}, fmt.Errorf("ResolveEndpoints(): %w", err)
+ }
+
+ tenant := authorityInfo.Tenant
+
+ endpoints := authority.NewEndpoints(
+ strings.Replace(resp.AuthorizationEndpoint, "{tenant}", tenant, -1),
+ strings.Replace(resp.TokenEndpoint, "{tenant}", tenant, -1),
+ strings.Replace(resp.Issuer, "{tenant}", tenant, -1),
+ authorityInfo.Host)
+
+ m.addCachedEndpoints(authorityInfo, userPrincipalName, endpoints)
+
+ return endpoints, nil
+}
+
+// cachedEndpoints returns a the cached endpoints if they exists. If not, we return false.
+func (m *authorityEndpoint) cachedEndpoints(authorityInfo authority.Info, userPrincipalName string) (authority.Endpoints, bool) {
+ m.mu.Lock()
+ defer m.mu.Unlock()
+
+ if cacheEntry, ok := m.cache[authorityInfo.CanonicalAuthorityURI]; ok {
+ if authorityInfo.AuthorityType == ADFS {
+ domain, err := adfsDomainFromUpn(userPrincipalName)
+ if err == nil {
+ if _, ok := cacheEntry.ValidForDomainsInList[domain]; ok {
+ return cacheEntry.Endpoints, true
+ }
+ }
+ }
+ return cacheEntry.Endpoints, true
+ }
+ return authority.Endpoints{}, false
+}
+
+func (m *authorityEndpoint) addCachedEndpoints(authorityInfo authority.Info, userPrincipalName string, endpoints authority.Endpoints) {
+ m.mu.Lock()
+ defer m.mu.Unlock()
+
+ updatedCacheEntry := createcacheEntry(endpoints)
+
+ if authorityInfo.AuthorityType == ADFS {
+ // Since we're here, we've made a call to the backend. We want to ensure we're caching
+ // the latest values from the server.
+ if cacheEntry, ok := m.cache[authorityInfo.CanonicalAuthorityURI]; ok {
+ for k := range cacheEntry.ValidForDomainsInList {
+ updatedCacheEntry.ValidForDomainsInList[k] = true
+ }
+ }
+ domain, err := adfsDomainFromUpn(userPrincipalName)
+ if err == nil {
+ updatedCacheEntry.ValidForDomainsInList[domain] = true
+ }
+ }
+
+ m.cache[authorityInfo.CanonicalAuthorityURI] = updatedCacheEntry
+}
+
+func (m *authorityEndpoint) openIDConfigurationEndpoint(ctx context.Context, authorityInfo authority.Info, userPrincipalName string) (string, error) {
+ if authorityInfo.Tenant == "adfs" {
+ return fmt.Sprintf("https://%s/adfs/.well-known/openid-configuration", authorityInfo.Host), nil
+ } else if authorityInfo.ValidateAuthority && !authority.TrustedHost(authorityInfo.Host) {
+ resp, err := m.rest.Authority().AADInstanceDiscovery(ctx, authorityInfo)
+ if err != nil {
+ return "", err
+ }
+ return resp.TenantDiscoveryEndpoint, nil
+ } else if authorityInfo.Region != "" {
+ resp, err := m.rest.Authority().AADInstanceDiscovery(ctx, authorityInfo)
+ if err != nil {
+ return "", err
+ }
+ return resp.TenantDiscoveryEndpoint, nil
+
+ }
+
+ return authorityInfo.CanonicalAuthorityURI + "v2.0/.well-known/openid-configuration", nil
+}
+
+func adfsDomainFromUpn(userPrincipalName string) (string, error) {
+ parts := strings.Split(userPrincipalName, "@")
+ if len(parts) < 2 {
+ return "", errors.New("no @ present in user principal name")
+ }
+ return parts[1], nil
+}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/options/options.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/options/options.go
new file mode 100644
index 00000000000..4561d72db4d
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/options/options.go
@@ -0,0 +1,52 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+package options
+
+import (
+ "errors"
+ "fmt"
+)
+
+// CallOption implements an optional argument to a method call. See
+// https://blog.devgenius.io/go-call-option-that-can-be-used-with-multiple-methods-6c81734f3dbe
+// for an explanation of the usage pattern.
+type CallOption interface {
+ Do(any) error
+ callOption()
+}
+
+// ApplyOptions applies all the callOptions to options. options must be a pointer to a struct and
+// callOptions must be a list of objects that implement CallOption.
+func ApplyOptions[O, C any](options O, callOptions []C) error {
+ for _, o := range callOptions {
+ if t, ok := any(o).(CallOption); !ok {
+ return fmt.Errorf("unexpected option type %T", o)
+ } else if err := t.Do(options); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+// NewCallOption returns a new CallOption whose Do() method calls function "f".
+func NewCallOption(f func(any) error) CallOption {
+ if f == nil {
+ // This isn't a practical concern because only an MSAL maintainer can get
+ // us here, by implementing a do-nothing option. But if someone does that,
+ // the below ensures the method invoked with the option returns an error.
+ return callOption(func(any) error {
+ return errors.New("invalid option: missing implementation")
+ })
+ }
+ return callOption(f)
+}
+
+// callOption is an adapter for a function to a CallOption
+type callOption func(any) error
+
+func (c callOption) Do(a any) error {
+ return c(a)
+}
+
+func (callOption) callOption() {}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/shared/shared.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/shared/shared.go
new file mode 100644
index 00000000000..f7e12a71bf3
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/shared/shared.go
@@ -0,0 +1,71 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+package shared
+
+import (
+ "net/http"
+ "reflect"
+ "strings"
+)
+
+const (
+ // CacheKeySeparator is used in creating the keys of the cache.
+ CacheKeySeparator = "-"
+)
+
+type Account struct {
+ HomeAccountID string `json:"home_account_id,omitempty"`
+ Environment string `json:"environment,omitempty"`
+ Realm string `json:"realm,omitempty"`
+ LocalAccountID string `json:"local_account_id,omitempty"`
+ AuthorityType string `json:"authority_type,omitempty"`
+ PreferredUsername string `json:"username,omitempty"`
+ GivenName string `json:"given_name,omitempty"`
+ FamilyName string `json:"family_name,omitempty"`
+ MiddleName string `json:"middle_name,omitempty"`
+ Name string `json:"name,omitempty"`
+ AlternativeID string `json:"alternative_account_id,omitempty"`
+ RawClientInfo string `json:"client_info,omitempty"`
+ UserAssertionHash string `json:"user_assertion_hash,omitempty"`
+
+ AdditionalFields map[string]interface{}
+}
+
+// NewAccount creates an account.
+func NewAccount(homeAccountID, env, realm, localAccountID, authorityType, username string) Account {
+ return Account{
+ HomeAccountID: homeAccountID,
+ Environment: env,
+ Realm: realm,
+ LocalAccountID: localAccountID,
+ AuthorityType: authorityType,
+ PreferredUsername: username,
+ }
+}
+
+// Key creates the key for storing accounts in the cache.
+func (acc Account) Key() string {
+ return strings.Join([]string{acc.HomeAccountID, acc.Environment, acc.Realm}, CacheKeySeparator)
+}
+
+// IsZero checks the zero value of account.
+func (acc Account) IsZero() bool {
+ v := reflect.ValueOf(acc)
+ for i := 0; i < v.NumField(); i++ {
+ field := v.Field(i)
+ if !field.IsZero() {
+ switch field.Kind() {
+ case reflect.Map, reflect.Slice:
+ if field.Len() == 0 {
+ continue
+ }
+ }
+ return false
+ }
+ }
+ return true
+}
+
+// DefaultClient is our default shared HTTP client.
+var DefaultClient = &http.Client{}
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/version/version.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/version/version.go
new file mode 100644
index 00000000000..c3651e630be
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/version/version.go
@@ -0,0 +1,8 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+// Package version keeps the version number of the client package.
+package version
+
+// Version is the version of this client package that is communicated to the server.
+const Version = "0.8.1"
diff --git a/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/public/public.go b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/public/public.go
new file mode 100644
index 00000000000..0a3ffafff4a
--- /dev/null
+++ b/vendor/github.com/AzureAD/microsoft-authentication-library-for-go/apps/public/public.go
@@ -0,0 +1,716 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT license.
+
+/*
+Package public provides a client for authentication of "public" applications. A "public"
+application is defined as an app that runs on client devices (android, ios, windows, linux, ...).
+These devices are "untrusted" and access resources via web APIs that must authenticate.
+*/
+package public
+
+/*
+Design note:
+
+public.Client uses client.Base as an embedded type. client.Base statically assigns its attributes
+during creation. As it doesn't have any pointers in it, anything borrowed from it, such as
+Base.AuthParams is a copy that is free to be manipulated here.
+*/
+
+// TODO(msal): This should have example code for each method on client using Go's example doc framework.
+// base usage details should be includee in the package documentation.
+
+import (
+ "context"
+ "crypto/rand"
+ "crypto/sha256"
+ "encoding/base64"
+ "fmt"
+ "net/url"
+ "strconv"
+
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/cache"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/base"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/local"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/accesstokens"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/oauth/ops/authority"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/options"
+ "github.com/AzureAD/microsoft-authentication-library-for-go/apps/internal/shared"
+ "github.com/google/uuid"
+ "github.com/pkg/browser"
+)
+
+// AuthResult contains the results of one token acquisition operation.
+// For details see https://aka.ms/msal-net-authenticationresult
+type AuthResult = base.AuthResult
+
+type Account = shared.Account
+
+// Options configures the Client's behavior.
+type Options struct {
+ // Accessor controls cache persistence. By default there is no cache persistence.
+ // This can be set with the WithCache() option.
+ Accessor cache.ExportReplace
+
+ // The host of the Azure Active Directory authority. The default is https://login.microsoftonline.com/common.
+ // This can be changed with the WithAuthority() option.
+ Authority string
+
+ // The HTTP client used for making requests.
+ // It defaults to a shared http.Client.
+ HTTPClient ops.HTTPClient
+
+ capabilities []string
+
+ disableInstanceDiscovery bool
+}
+
+func (p *Options) validate() error {
+ u, err := url.Parse(p.Authority)
+ if err != nil {
+ return fmt.Errorf("Authority options cannot be URL parsed: %w", err)
+ }
+ if u.Scheme != "https" {
+ return fmt.Errorf("Authority(%s) did not start with https://", u.String())
+ }
+ return nil
+}
+
+// Option is an optional argument to the New constructor.
+type Option func(o *Options)
+
+// WithAuthority allows for a custom authority to be set. This must be a valid https url.
+func WithAuthority(authority string) Option {
+ return func(o *Options) {
+ o.Authority = authority
+ }
+}
+
+// WithCache allows you to set some type of cache for storing authentication tokens.
+func WithCache(accessor cache.ExportReplace) Option {
+ return func(o *Options) {
+ o.Accessor = accessor
+ }
+}
+
+// WithClientCapabilities allows configuring one or more client capabilities such as "CP1"
+func WithClientCapabilities(capabilities []string) Option {
+ return func(o *Options) {
+ // there's no danger of sharing the slice's underlying memory with the application because
+ // this slice is simply passed to base.WithClientCapabilities, which copies its data
+ o.capabilities = capabilities
+ }
+}
+
+// WithHTTPClient allows for a custom HTTP client to be set.
+func WithHTTPClient(httpClient ops.HTTPClient) Option {
+ return func(o *Options) {
+ o.HTTPClient = httpClient
+ }
+}
+
+// WithInstanceDiscovery set to false to disable authority validation (to support private cloud scenarios)
+func WithInstanceDiscovery(enabled bool) Option {
+ return func(o *Options) {
+ o.disableInstanceDiscovery = !enabled
+ }
+}
+
+// Client is a representation of authentication client for public applications as defined in the
+// package doc. For more information, visit https://docs.microsoft.com/azure/active-directory/develop/msal-client-applications.
+type Client struct {
+ base base.Client
+}
+
+// New is the constructor for Client.
+func New(clientID string, options ...Option) (Client, error) {
+ opts := Options{
+ Authority: base.AuthorityPublicCloud,
+ HTTPClient: shared.DefaultClient,
+ }
+
+ for _, o := range options {
+ o(&opts)
+ }
+ if err := opts.validate(); err != nil {
+ return Client{}, err
+ }
+
+ base, err := base.New(clientID, opts.Authority, oauth.New(opts.HTTPClient), base.WithCacheAccessor(opts.Accessor), base.WithClientCapabilities(opts.capabilities), base.WithInstanceDiscovery(!opts.disableInstanceDiscovery))
+ if err != nil {
+ return Client{}, err
+ }
+ return Client{base}, nil
+}
+
+// createAuthCodeURLOptions contains options for CreateAuthCodeURL
+type createAuthCodeURLOptions struct {
+ claims, loginHint, tenantID, domainHint string
+}
+
+// CreateAuthCodeURLOption is implemented by options for CreateAuthCodeURL
+type CreateAuthCodeURLOption interface {
+ createAuthCodeURLOption()
+}
+
+// CreateAuthCodeURL creates a URL used to acquire an authorization code.
+//
+// Options: [WithClaims], [WithDomainHint], [WithLoginHint], [WithTenantID]
+func (pca Client) CreateAuthCodeURL(ctx context.Context, clientID, redirectURI string, scopes []string, opts ...CreateAuthCodeURLOption) (string, error) {
+ o := createAuthCodeURLOptions{}
+ if err := options.ApplyOptions(&o, opts); err != nil {
+ return "", err
+ }
+ ap, err := pca.base.AuthParams.WithTenant(o.tenantID)
+ if err != nil {
+ return "", err
+ }
+ ap.Claims = o.claims
+ ap.LoginHint = o.loginHint
+ ap.DomainHint = o.domainHint
+ return pca.base.AuthCodeURL(ctx, clientID, redirectURI, scopes, ap)
+}
+
+// WithClaims sets additional claims to request for the token, such as those required by conditional access policies.
+// Use this option when Azure AD returned a claims challenge for a prior request. The argument must be decoded.
+// This option is valid for any token acquisition method.
+func WithClaims(claims string) interface {
+ AcquireByAuthCodeOption
+ AcquireByDeviceCodeOption
+ AcquireByUsernamePasswordOption
+ AcquireInteractiveOption
+ AcquireSilentOption
+ CreateAuthCodeURLOption
+ options.CallOption
+} {
+ return struct {
+ AcquireByAuthCodeOption
+ AcquireByDeviceCodeOption
+ AcquireByUsernamePasswordOption
+ AcquireInteractiveOption
+ AcquireSilentOption
+ CreateAuthCodeURLOption
+ options.CallOption
+ }{
+ CallOption: options.NewCallOption(
+ func(a any) error {
+ switch t := a.(type) {
+ case *AcquireTokenByAuthCodeOptions:
+ t.claims = claims
+ case *acquireTokenByDeviceCodeOptions:
+ t.claims = claims
+ case *acquireTokenByUsernamePasswordOptions:
+ t.claims = claims
+ case *AcquireTokenSilentOptions:
+ t.claims = claims
+ case *createAuthCodeURLOptions:
+ t.claims = claims
+ case *InteractiveAuthOptions:
+ t.claims = claims
+ default:
+ return fmt.Errorf("unexpected options type %T", a)
+ }
+ return nil
+ },
+ ),
+ }
+}
+
+// WithTenantID specifies a tenant for a single authentication. It may be different than the tenant set in [New] by [WithAuthority].
+// This option is valid for any token acquisition method.
+func WithTenantID(tenantID string) interface {
+ AcquireByAuthCodeOption
+ AcquireByDeviceCodeOption
+ AcquireByUsernamePasswordOption
+ AcquireInteractiveOption
+ AcquireSilentOption
+ CreateAuthCodeURLOption
+ options.CallOption
+} {
+ return struct {
+ AcquireByAuthCodeOption
+ AcquireByDeviceCodeOption
+ AcquireByUsernamePasswordOption
+ AcquireInteractiveOption
+ AcquireSilentOption
+ CreateAuthCodeURLOption
+ options.CallOption
+ }{
+ CallOption: options.NewCallOption(
+ func(a any) error {
+ switch t := a.(type) {
+ case *AcquireTokenByAuthCodeOptions:
+ t.tenantID = tenantID
+ case *acquireTokenByDeviceCodeOptions:
+ t.tenantID = tenantID
+ case *acquireTokenByUsernamePasswordOptions:
+ t.tenantID = tenantID
+ case *AcquireTokenSilentOptions:
+ t.tenantID = tenantID
+ case *createAuthCodeURLOptions:
+ t.tenantID = tenantID
+ case *InteractiveAuthOptions:
+ t.tenantID = tenantID
+ default:
+ return fmt.Errorf("unexpected options type %T", a)
+ }
+ return nil
+ },
+ ),
+ }
+}
+
+// AcquireTokenSilentOptions are all the optional settings to an AcquireTokenSilent() call.
+// These are set by using various AcquireTokenSilentOption functions.
+type AcquireTokenSilentOptions struct {
+ // Account represents the account to use. To set, use the WithSilentAccount() option.
+ Account Account
+
+ claims, tenantID string
+}
+
+// AcquireSilentOption is implemented by options for AcquireTokenSilent
+type AcquireSilentOption interface {
+ acquireSilentOption()
+}
+
+// AcquireTokenSilentOption changes options inside AcquireTokenSilentOptions used in .AcquireTokenSilent().
+type AcquireTokenSilentOption func(a *AcquireTokenSilentOptions)
+
+func (AcquireTokenSilentOption) acquireSilentOption() {}
+
+// WithSilentAccount uses the passed account during an AcquireTokenSilent() call.
+func WithSilentAccount(account Account) interface {
+ AcquireSilentOption
+ options.CallOption
+} {
+ return struct {
+ AcquireSilentOption
+ options.CallOption
+ }{
+ CallOption: options.NewCallOption(
+ func(a any) error {
+ switch t := a.(type) {
+ case *AcquireTokenSilentOptions:
+ t.Account = account
+ default:
+ return fmt.Errorf("unexpected options type %T", a)
+ }
+ return nil
+ },
+ ),
+ }
+}
+
+// AcquireTokenSilent acquires a token from either the cache or using a refresh token.
+//
+// Options: [WithClaims], [WithSilentAccount], [WithTenantID]
+func (pca Client) AcquireTokenSilent(ctx context.Context, scopes []string, opts ...AcquireSilentOption) (AuthResult, error) {
+ o := AcquireTokenSilentOptions{}
+ if err := options.ApplyOptions(&o, opts); err != nil {
+ return AuthResult{}, err
+ }
+
+ silentParameters := base.AcquireTokenSilentParameters{
+ Scopes: scopes,
+ Account: o.Account,
+ Claims: o.claims,
+ RequestType: accesstokens.ATPublic,
+ IsAppCache: false,
+ TenantID: o.tenantID,
+ }
+
+ return pca.base.AcquireTokenSilent(ctx, silentParameters)
+}
+
+// acquireTokenByUsernamePasswordOptions contains optional configuration for AcquireTokenByUsernamePassword
+type acquireTokenByUsernamePasswordOptions struct {
+ claims, tenantID string
+}
+
+// AcquireByUsernamePasswordOption is implemented by options for AcquireTokenByUsernamePassword
+type AcquireByUsernamePasswordOption interface {
+ acquireByUsernamePasswordOption()
+}
+
+// AcquireTokenByUsernamePassword acquires a security token from the authority, via Username/Password Authentication.
+// NOTE: this flow is NOT recommended.
+//
+// Options: [WithClaims], [WithTenantID]
+func (pca Client) AcquireTokenByUsernamePassword(ctx context.Context, scopes []string, username, password string, opts ...AcquireByUsernamePasswordOption) (AuthResult, error) {
+ o := acquireTokenByUsernamePasswordOptions{}
+ if err := options.ApplyOptions(&o, opts); err != nil {
+ return AuthResult{}, err
+ }
+ authParams, err := pca.base.AuthParams.WithTenant(o.tenantID)
+ if err != nil {
+ return AuthResult{}, err
+ }
+ authParams.Scopes = scopes
+ authParams.AuthorizationType = authority.ATUsernamePassword
+ authParams.Claims = o.claims
+ authParams.Username = username
+ authParams.Password = password
+
+ token, err := pca.base.Token.UsernamePassword(ctx, authParams)
+ if err != nil {
+ return AuthResult{}, err
+ }
+ return pca.base.AuthResultFromToken(ctx, authParams, token, true)
+}
+
+type DeviceCodeResult = accesstokens.DeviceCodeResult
+
+// DeviceCode provides the results of the device code flows first stage (containing the code)
+// that must be entered on the second device and provides a method to retrieve the AuthenticationResult
+// once that code has been entered and verified.
+type DeviceCode struct {
+ // Result holds the information about the device code (such as the code).
+ Result DeviceCodeResult
+
+ authParams authority.AuthParams
+ client Client
+ dc oauth.DeviceCode
+}
+
+// AuthenticationResult retreives the AuthenticationResult once the user enters the code
+// on the second device. Until then it blocks until the .AcquireTokenByDeviceCode() context
+// is cancelled or the token expires.
+func (d DeviceCode) AuthenticationResult(ctx context.Context) (AuthResult, error) {
+ token, err := d.dc.Token(ctx)
+ if err != nil {
+ return AuthResult{}, err
+ }
+ return d.client.base.AuthResultFromToken(ctx, d.authParams, token, true)
+}
+
+// acquireTokenByDeviceCodeOptions contains optional configuration for AcquireTokenByDeviceCode
+type acquireTokenByDeviceCodeOptions struct {
+ claims, tenantID string
+}
+
+// AcquireByDeviceCodeOption is implemented by options for AcquireTokenByDeviceCode
+type AcquireByDeviceCodeOption interface {
+ acquireByDeviceCodeOptions()
+}
+
+// AcquireTokenByDeviceCode acquires a security token from the authority, by acquiring a device code and using that to acquire the token.
+// Users need to create an AcquireTokenDeviceCodeParameters instance and pass it in.
+//
+// Options: [WithClaims], [WithTenantID]
+func (pca Client) AcquireTokenByDeviceCode(ctx context.Context, scopes []string, opts ...AcquireByDeviceCodeOption) (DeviceCode, error) {
+ o := acquireTokenByDeviceCodeOptions{}
+ if err := options.ApplyOptions(&o, opts); err != nil {
+ return DeviceCode{}, err
+ }
+ authParams, err := pca.base.AuthParams.WithTenant(o.tenantID)
+ if err != nil {
+ return DeviceCode{}, err
+ }
+ authParams.Scopes = scopes
+ authParams.AuthorizationType = authority.ATDeviceCode
+ authParams.Claims = o.claims
+
+ dc, err := pca.base.Token.DeviceCode(ctx, authParams)
+ if err != nil {
+ return DeviceCode{}, err
+ }
+
+ return DeviceCode{Result: dc.Result, authParams: authParams, client: pca, dc: dc}, nil
+}
+
+// AcquireTokenByAuthCodeOptions contains the optional parameters used to acquire an access token using the authorization code flow.
+type AcquireTokenByAuthCodeOptions struct {
+ Challenge string
+
+ claims, tenantID string
+}
+
+// AcquireByAuthCodeOption is implemented by options for AcquireTokenByAuthCode
+type AcquireByAuthCodeOption interface {
+ acquireByAuthCodeOption()
+}
+
+// AcquireTokenByAuthCodeOption changes options inside AcquireTokenByAuthCodeOptions used in .AcquireTokenByAuthCode().
+type AcquireTokenByAuthCodeOption func(a *AcquireTokenByAuthCodeOptions)
+
+func (AcquireTokenByAuthCodeOption) acquireByAuthCodeOption() {}
+
+// WithChallenge allows you to provide a code for the .AcquireTokenByAuthCode() call.
+func WithChallenge(challenge string) interface {
+ AcquireByAuthCodeOption
+ options.CallOption
+} {
+ return struct {
+ AcquireByAuthCodeOption
+ options.CallOption
+ }{
+ CallOption: options.NewCallOption(
+ func(a any) error {
+ switch t := a.(type) {
+ case *AcquireTokenByAuthCodeOptions:
+ t.Challenge = challenge
+ default:
+ return fmt.Errorf("unexpected options type %T", a)
+ }
+ return nil
+ },
+ ),
+ }
+}
+
+// AcquireTokenByAuthCode is a request to acquire a security token from the authority, using an authorization code.
+// The specified redirect URI must be the same URI that was used when the authorization code was requested.
+//
+// Options: [WithChallenge], [WithClaims], [WithTenantID]
+func (pca Client) AcquireTokenByAuthCode(ctx context.Context, code string, redirectURI string, scopes []string, opts ...AcquireByAuthCodeOption) (AuthResult, error) {
+ o := AcquireTokenByAuthCodeOptions{}
+ if err := options.ApplyOptions(&o, opts); err != nil {
+ return AuthResult{}, err
+ }
+
+ params := base.AcquireTokenAuthCodeParameters{
+ Scopes: scopes,
+ Code: code,
+ Challenge: o.Challenge,
+ Claims: o.claims,
+ AppType: accesstokens.ATPublic,
+ RedirectURI: redirectURI,
+ TenantID: o.tenantID,
+ }
+
+ return pca.base.AcquireTokenByAuthCode(ctx, params)
+}
+
+// Accounts gets all the accounts in the token cache.
+// If there are no accounts in the cache the returned slice is empty.
+func (pca Client) Accounts() []Account {
+ return pca.base.AllAccounts()
+}
+
+// RemoveAccount signs the account out and forgets account from token cache.
+func (pca Client) RemoveAccount(account Account) error {
+ pca.base.RemoveAccount(account)
+ return nil
+}
+
+// InteractiveAuthOptions contains the optional parameters used to acquire an access token for interactive auth code flow.
+type InteractiveAuthOptions struct {
+ // Used to specify a custom port for the local server. http://localhost:portnumber
+ // All other URI components are ignored.
+ RedirectURI string
+
+ claims, loginHint, tenantID, domainHint string
+}
+
+// AcquireInteractiveOption is implemented by options for AcquireTokenInteractive
+type AcquireInteractiveOption interface {
+ acquireInteractiveOption()
+}
+
+// InteractiveAuthOption changes options inside InteractiveAuthOptions used in .AcquireTokenInteractive().
+type InteractiveAuthOption func(*InteractiveAuthOptions)
+
+func (InteractiveAuthOption) acquireInteractiveOption() {}
+
+// WithLoginHint pre-populates the login prompt with a username.
+func WithLoginHint(username string) interface {
+ AcquireInteractiveOption
+ CreateAuthCodeURLOption
+ options.CallOption
+} {
+ return struct {
+ AcquireInteractiveOption
+ CreateAuthCodeURLOption
+ options.CallOption
+ }{
+ CallOption: options.NewCallOption(
+ func(a any) error {
+ switch t := a.(type) {
+ case *createAuthCodeURLOptions:
+ t.loginHint = username
+ case *InteractiveAuthOptions:
+ t.loginHint = username
+ default:
+ return fmt.Errorf("unexpected options type %T", a)
+ }
+ return nil
+ },
+ ),
+ }
+}
+
+// WithDomainHint adds the IdP domain as domain_hint query parameter in the auth url.
+func WithDomainHint(domain string) interface {
+ AcquireInteractiveOption
+ CreateAuthCodeURLOption
+ options.CallOption
+} {
+ return struct {
+ AcquireInteractiveOption
+ CreateAuthCodeURLOption
+ options.CallOption
+ }{
+ CallOption: options.NewCallOption(
+ func(a any) error {
+ switch t := a.(type) {
+ case *createAuthCodeURLOptions:
+ t.domainHint = domain
+ case *InteractiveAuthOptions:
+ t.domainHint = domain
+ default:
+ return fmt.Errorf("unexpected options type %T", a)
+ }
+ return nil
+ },
+ ),
+ }
+}
+
+// WithRedirectURI uses the specified redirect URI for interactive auth.
+func WithRedirectURI(redirectURI string) interface {
+ AcquireInteractiveOption
+ options.CallOption
+} {
+ return struct {
+ AcquireInteractiveOption
+ options.CallOption
+ }{
+ CallOption: options.NewCallOption(
+ func(a any) error {
+ switch t := a.(type) {
+ case *InteractiveAuthOptions:
+ t.RedirectURI = redirectURI
+ default:
+ return fmt.Errorf("unexpected options type %T", a)
+ }
+ return nil
+ },
+ ),
+ }
+}
+
+// AcquireTokenInteractive acquires a security token from the authority using the default web browser to select the account.
+// https://docs.microsoft.com/en-us/azure/active-directory/develop/msal-authentication-flows#interactive-and-non-interactive-authentication
+//
+// Options: [WithDomainHint], [WithLoginHint], [WithRedirectURI], [WithTenantID]
+func (pca Client) AcquireTokenInteractive(ctx context.Context, scopes []string, opts ...AcquireInteractiveOption) (AuthResult, error) {
+ o := InteractiveAuthOptions{}
+ if err := options.ApplyOptions(&o, opts); err != nil {
+ return AuthResult{}, err
+ }
+ // the code verifier is a random 32-byte sequence that's been base-64 encoded without padding.
+ // it's used to prevent MitM attacks during auth code flow, see https://tools.ietf.org/html/rfc7636
+ cv, challenge, err := codeVerifier()
+ if err != nil {
+ return AuthResult{}, err
+ }
+ var redirectURL *url.URL
+ if o.RedirectURI != "" {
+ redirectURL, err = url.Parse(o.RedirectURI)
+ if err != nil {
+ return AuthResult{}, err
+ }
+ }
+ authParams, err := pca.base.AuthParams.WithTenant(o.tenantID)
+ if err != nil {
+ return AuthResult{}, err
+ }
+ authParams.Scopes = scopes
+ authParams.AuthorizationType = authority.ATInteractive
+ authParams.Claims = o.claims
+ authParams.CodeChallenge = challenge
+ authParams.CodeChallengeMethod = "S256"
+ authParams.LoginHint = o.loginHint
+ authParams.DomainHint = o.domainHint
+ authParams.State = uuid.New().String()
+ authParams.Prompt = "select_account"
+ res, err := pca.browserLogin(ctx, redirectURL, authParams)
+ if err != nil {
+ return AuthResult{}, err
+ }
+ authParams.Redirecturi = res.redirectURI
+
+ req, err := accesstokens.NewCodeChallengeRequest(authParams, accesstokens.ATPublic, nil, res.authCode, cv)
+ if err != nil {
+ return AuthResult{}, err
+ }
+
+ token, err := pca.base.Token.AuthCode(ctx, req)
+ if err != nil {
+ return AuthResult{}, err
+ }
+
+ return pca.base.AuthResultFromToken(ctx, authParams, token, true)
+}
+
+type interactiveAuthResult struct {
+ authCode string
+ redirectURI string
+}
+
+// provides a test hook to simulate opening a browser
+var browserOpenURL = func(authURL string) error {
+ return browser.OpenURL(authURL)
+}
+
+// parses the port number from the provided URL.
+// returns 0 if nil or no port is specified.
+func parsePort(u *url.URL) (int, error) {
+ if u == nil {
+ return 0, nil
+ }
+ p := u.Port()
+ if p == "" {
+ return 0, nil
+ }
+ return strconv.Atoi(p)
+}
+
+// browserLogin launches the system browser for interactive login
+func (pca Client) browserLogin(ctx context.Context, redirectURI *url.URL, params authority.AuthParams) (interactiveAuthResult, error) {
+ // start local redirect server so login can call us back
+ port, err := parsePort(redirectURI)
+ if err != nil {
+ return interactiveAuthResult{}, err
+ }
+ srv, err := local.New(params.State, port)
+ if err != nil {
+ return interactiveAuthResult{}, err
+ }
+ defer srv.Shutdown()
+ params.Scopes = accesstokens.AppendDefaultScopes(params)
+ authURL, err := pca.base.AuthCodeURL(ctx, params.ClientID, srv.Addr, params.Scopes, params)
+ if err != nil {
+ return interactiveAuthResult{}, err
+ }
+ // open browser window so user can select credentials
+ if err := browserOpenURL(authURL); err != nil {
+ return interactiveAuthResult{}, err
+ }
+ // now wait until the logic calls us back
+ res := srv.Result(ctx)
+ if res.Err != nil {
+ return interactiveAuthResult{}, res.Err
+ }
+ return interactiveAuthResult{
+ authCode: res.Code,
+ redirectURI: srv.Addr,
+ }, nil
+}
+
+// creates a code verifier string along with its SHA256 hash which
+// is used as the challenge when requesting an auth code.
+// used in interactive auth flow for PKCE.
+func codeVerifier() (codeVerifier string, challenge string, err error) {
+ cvBytes := make([]byte, 32)
+ if _, err = rand.Read(cvBytes); err != nil {
+ return
+ }
+ codeVerifier = base64.RawURLEncoding.EncodeToString(cvBytes)
+ // for PKCE, create a hash of the code verifier
+ cvh := sha256.Sum256([]byte(codeVerifier))
+ challenge = base64.RawURLEncoding.EncodeToString(cvh[:])
+ return
+}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go
index 260a37cbbab..86db488defa 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go
@@ -9,7 +9,7 @@ to refresh the credentials will be synchronized. But, the SDK is unable to
ensure synchronous usage of the AssumeRoleProvider if the value is shared
between multiple Credentials, Sessions or service clients.
-Assume Role
+# Assume Role
To assume an IAM role using STS with the SDK you can create a new Credentials
with the SDKs's stscreds package.
@@ -27,7 +27,7 @@ with the SDKs's stscreds package.
// from assumed role.
svc := s3.New(sess, &aws.Config{Credentials: creds})
-Assume Role with static MFA Token
+# Assume Role with static MFA Token
To assume an IAM role with a MFA token you can either specify a MFA token code
directly or provide a function to prompt the user each time the credentials
@@ -49,7 +49,7 @@ credentials.
// from assumed role.
svc := s3.New(sess, &aws.Config{Credentials: creds})
-Assume Role with MFA Token Provider
+# Assume Role with MFA Token Provider
To assume an IAM role with MFA for longer running tasks where the credentials
may need to be refreshed setting the TokenProvider field of AssumeRoleProvider
@@ -74,7 +74,6 @@ single Credentials with an AssumeRoleProvider can be shared safely.
// Create service client value configured for credentials
// from assumed role.
svc := s3.New(sess, &aws.Config{Credentials: creds})
-
*/
package stscreds
@@ -199,6 +198,10 @@ type AssumeRoleProvider struct {
// or an Amazon Resource Name (ARN) for a virtual device (such as arn:aws:iam::123456789012:mfa/user).
SerialNumber *string
+ // The SourceIdentity which is used to identity a persistent identity through the whole session.
+ // For more details see https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_monitor.html
+ SourceIdentity *string
+
// The value provided by the MFA device, if the trust policy of the role being
// assumed requires MFA (that is, if the policy includes a condition that tests
// for MFA). If the role being assumed requires MFA and if the TokenCode value
@@ -320,6 +323,7 @@ func (p *AssumeRoleProvider) RetrieveWithContext(ctx credentials.Context) (crede
Tags: p.Tags,
PolicyArns: p.PolicyArns,
TransitiveTagKeys: p.TransitiveTagKeys,
+ SourceIdentity: p.SourceIdentity,
}
if p.Policy != nil {
input.Policy = p.Policy
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go
index debf74510cb..2e19166282d 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go
@@ -13,6 +13,7 @@ const (
AwsUsGovPartitionID = "aws-us-gov" // AWS GovCloud (US) partition.
AwsIsoPartitionID = "aws-iso" // AWS ISO (US) partition.
AwsIsoBPartitionID = "aws-iso-b" // AWS ISOB (US) partition.
+ AwsIsoEPartitionID = "aws-iso-e" // AWS ISOE (Europe) partition.
)
// AWS Standard partition's regions.
@@ -69,8 +70,11 @@ const (
UsIsobEast1RegionID = "us-isob-east-1" // US ISOB East (Ohio).
)
+// AWS ISOE (Europe) partition's regions.
+const ()
+
// DefaultResolver returns an Endpoint resolver that will be able
-// to resolve endpoints for: AWS Standard, AWS China, AWS GovCloud (US), AWS ISO (US), and AWS ISOB (US).
+// to resolve endpoints for: AWS Standard, AWS China, AWS GovCloud (US), AWS ISO (US), AWS ISOB (US), and AWS ISOE (Europe).
//
// Use DefaultPartitions() to get the list of the default partitions.
func DefaultResolver() Resolver {
@@ -78,7 +82,7 @@ func DefaultResolver() Resolver {
}
// DefaultPartitions returns a list of the partitions the SDK is bundled
-// with. The available partitions are: AWS Standard, AWS China, AWS GovCloud (US), AWS ISO (US), and AWS ISOB (US).
+// with. The available partitions are: AWS Standard, AWS China, AWS GovCloud (US), AWS ISO (US), AWS ISOB (US), and AWS ISOE (Europe).
//
// partitions := endpoints.DefaultPartitions
// for _, p := range partitions {
@@ -94,6 +98,7 @@ var defaultPartitions = partitions{
awsusgovPartition,
awsisoPartition,
awsisobPartition,
+ awsisoePartition,
}
// AwsPartition returns the Resolver for AWS Standard.
@@ -1867,6 +1872,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -2074,6 +2082,9 @@ var awsPartition = partition{
},
Deprecated: boxedTrue,
},
+ endpointKey{
+ Region: "me-central-1",
+ }: endpoint{},
endpointKey{
Region: "me-south-1",
}: endpoint{},
@@ -3256,6 +3267,12 @@ var awsPartition = partition{
endpointKey{
Region: "ap-northeast-1",
}: endpoint{},
+ endpointKey{
+ Region: "ap-northeast-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-south-1",
+ }: endpoint{},
endpointKey{
Region: "ap-southeast-1",
}: endpoint{},
@@ -3274,6 +3291,12 @@ var awsPartition = partition{
endpointKey{
Region: "eu-west-2",
}: endpoint{},
+ endpointKey{
+ Region: "eu-west-3",
+ }: endpoint{},
+ endpointKey{
+ Region: "sa-east-1",
+ }: endpoint{},
endpointKey{
Region: "us-east-1",
}: endpoint{},
@@ -3317,12 +3340,18 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
endpointKey{
Region: "eu-central-1",
}: endpoint{},
+ endpointKey{
+ Region: "eu-central-2",
+ }: endpoint{},
endpointKey{
Region: "eu-north-1",
}: endpoint{},
@@ -3356,6 +3385,9 @@ var awsPartition = partition{
endpointKey{
Region: "us-east-2",
}: endpoint{},
+ endpointKey{
+ Region: "us-west-1",
+ }: endpoint{},
endpointKey{
Region: "us-west-2",
}: endpoint{},
@@ -3576,6 +3608,12 @@ var awsPartition = partition{
}: endpoint{
Hostname: "athena-fips.us-east-1.amazonaws.com",
},
+ endpointKey{
+ Region: "us-east-1",
+ Variant: fipsVariant | dualStackVariant,
+ }: endpoint{
+ Hostname: "athena-fips.us-east-1.api.aws",
+ },
endpointKey{
Region: "us-east-2",
}: endpoint{},
@@ -3591,6 +3629,12 @@ var awsPartition = partition{
}: endpoint{
Hostname: "athena-fips.us-east-2.amazonaws.com",
},
+ endpointKey{
+ Region: "us-east-2",
+ Variant: fipsVariant | dualStackVariant,
+ }: endpoint{
+ Hostname: "athena-fips.us-east-2.api.aws",
+ },
endpointKey{
Region: "us-west-1",
}: endpoint{},
@@ -3606,6 +3650,12 @@ var awsPartition = partition{
}: endpoint{
Hostname: "athena-fips.us-west-1.amazonaws.com",
},
+ endpointKey{
+ Region: "us-west-1",
+ Variant: fipsVariant | dualStackVariant,
+ }: endpoint{
+ Hostname: "athena-fips.us-west-1.api.aws",
+ },
endpointKey{
Region: "us-west-2",
}: endpoint{},
@@ -3621,6 +3671,12 @@ var awsPartition = partition{
}: endpoint{
Hostname: "athena-fips.us-west-2.amazonaws.com",
},
+ endpointKey{
+ Region: "us-west-2",
+ Variant: fipsVariant | dualStackVariant,
+ }: endpoint{
+ Hostname: "athena-fips.us-west-2.api.aws",
+ },
},
},
"auditmanager": service{
@@ -3860,6 +3916,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -4033,6 +4092,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -5230,6 +5292,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -5901,6 +5966,9 @@ var awsPartition = partition{
endpointKey{
Region: "eu-north-1",
}: endpoint{},
+ endpointKey{
+ Region: "eu-south-1",
+ }: endpoint{},
endpointKey{
Region: "eu-west-1",
}: endpoint{},
@@ -6041,6 +6109,15 @@ var awsPartition = partition{
},
Deprecated: boxedTrue,
},
+ endpointKey{
+ Region: "fips-us-west-1",
+ }: endpoint{
+ Hostname: "cognito-identity-fips.us-west-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-west-1",
+ },
+ Deprecated: boxedTrue,
+ },
endpointKey{
Region: "fips-us-west-2",
}: endpoint{
@@ -6077,6 +6154,12 @@ var awsPartition = partition{
endpointKey{
Region: "us-west-1",
}: endpoint{},
+ endpointKey{
+ Region: "us-west-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "cognito-identity-fips.us-west-1.amazonaws.com",
+ },
endpointKey{
Region: "us-west-2",
}: endpoint{},
@@ -6746,12 +6829,42 @@ var awsPartition = partition{
endpointKey{
Region: "eu-west-2",
}: endpoint{},
+ endpointKey{
+ Region: "fips-us-east-1",
+ }: endpoint{
+ Hostname: "connect-fips.us-east-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-east-1",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "fips-us-west-2",
+ }: endpoint{
+ Hostname: "connect-fips.us-west-2.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-west-2",
+ },
+ Deprecated: boxedTrue,
+ },
endpointKey{
Region: "us-east-1",
}: endpoint{},
+ endpointKey{
+ Region: "us-east-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "connect-fips.us-east-1.amazonaws.com",
+ },
endpointKey{
Region: "us-west-2",
}: endpoint{},
+ endpointKey{
+ Region: "us-west-2",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "connect-fips.us-west-2.amazonaws.com",
+ },
},
},
"connect-campaigns": service{
@@ -6833,12 +6946,21 @@ var awsPartition = partition{
},
"controltower": service{
Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "af-south-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-east-1",
+ }: endpoint{},
endpointKey{
Region: "ap-northeast-1",
}: endpoint{},
endpointKey{
Region: "ap-northeast-2",
}: endpoint{},
+ endpointKey{
+ Region: "ap-northeast-3",
+ }: endpoint{},
endpointKey{
Region: "ap-south-1",
}: endpoint{},
@@ -6848,6 +6970,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-2",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-3",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -6872,6 +6997,9 @@ var awsPartition = partition{
endpointKey{
Region: "eu-north-1",
}: endpoint{},
+ endpointKey{
+ Region: "eu-south-1",
+ }: endpoint{},
endpointKey{
Region: "eu-west-1",
}: endpoint{},
@@ -6881,6 +7009,9 @@ var awsPartition = partition{
endpointKey{
Region: "eu-west-3",
}: endpoint{},
+ endpointKey{
+ Region: "me-south-1",
+ }: endpoint{},
endpointKey{
Region: "sa-east-1",
}: endpoint{},
@@ -6920,6 +7051,24 @@ var awsPartition = partition{
},
Deprecated: boxedTrue,
},
+ endpointKey{
+ Region: "us-west-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-west-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "controltower-fips.us-west-1.amazonaws.com",
+ },
+ endpointKey{
+ Region: "us-west-1-fips",
+ }: endpoint{
+ Hostname: "controltower-fips.us-west-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-west-1",
+ },
+ Deprecated: boxedTrue,
+ },
endpointKey{
Region: "us-west-2",
}: endpoint{},
@@ -7464,6 +7613,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -7664,6 +7816,12 @@ var awsPartition = partition{
endpointKey{
Region: "ca-central-1",
}: endpoint{},
+ endpointKey{
+ Region: "ca-central-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "devops-guru-fips.ca-central-1.amazonaws.com",
+ },
endpointKey{
Region: "eu-central-1",
}: endpoint{},
@@ -7679,6 +7837,15 @@ var awsPartition = partition{
endpointKey{
Region: "eu-west-3",
}: endpoint{},
+ endpointKey{
+ Region: "fips-ca-central-1",
+ }: endpoint{
+ Hostname: "devops-guru-fips.ca-central-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "ca-central-1",
+ },
+ Deprecated: boxedTrue,
+ },
endpointKey{
Region: "fips-us-east-1",
}: endpoint{
@@ -7697,6 +7864,15 @@ var awsPartition = partition{
},
Deprecated: boxedTrue,
},
+ endpointKey{
+ Region: "fips-us-west-1",
+ }: endpoint{
+ Hostname: "devops-guru-fips.us-west-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-west-1",
+ },
+ Deprecated: boxedTrue,
+ },
endpointKey{
Region: "fips-us-west-2",
}: endpoint{
@@ -7730,6 +7906,12 @@ var awsPartition = partition{
endpointKey{
Region: "us-west-1",
}: endpoint{},
+ endpointKey{
+ Region: "us-west-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "devops-guru-fips.us-west-1.amazonaws.com",
+ },
endpointKey{
Region: "us-west-2",
}: endpoint{},
@@ -10724,6 +10906,9 @@ var awsPartition = partition{
},
"emr-serverless": service{
Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "ap-east-1",
+ }: endpoint{},
endpointKey{
Region: "ap-northeast-1",
}: endpoint{},
@@ -10808,6 +10993,9 @@ var awsPartition = partition{
},
Deprecated: boxedTrue,
},
+ endpointKey{
+ Region: "me-south-1",
+ }: endpoint{},
endpointKey{
Region: "sa-east-1",
}: endpoint{},
@@ -11473,6 +11661,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -11978,6 +12169,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -12960,6 +13154,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -13606,21 +13803,11 @@ var awsPartition = partition{
}: endpoint{
Hostname: "internetmonitor.ap-northeast-2.api.aws",
},
- endpointKey{
- Region: "ap-northeast-3",
- }: endpoint{
- Hostname: "internetmonitor.ap-northeast-3.api.aws",
- },
endpointKey{
Region: "ap-south-1",
}: endpoint{
Hostname: "internetmonitor.ap-south-1.api.aws",
},
- endpointKey{
- Region: "ap-south-2",
- }: endpoint{
- Hostname: "internetmonitor.ap-south-2.api.aws",
- },
endpointKey{
Region: "ap-southeast-1",
}: endpoint{
@@ -13631,16 +13818,6 @@ var awsPartition = partition{
}: endpoint{
Hostname: "internetmonitor.ap-southeast-2.api.aws",
},
- endpointKey{
- Region: "ap-southeast-3",
- }: endpoint{
- Hostname: "internetmonitor.ap-southeast-3.api.aws",
- },
- endpointKey{
- Region: "ap-southeast-4",
- }: endpoint{
- Hostname: "internetmonitor.ap-southeast-4.api.aws",
- },
endpointKey{
Region: "ca-central-1",
}: endpoint{
@@ -13651,11 +13828,6 @@ var awsPartition = partition{
}: endpoint{
Hostname: "internetmonitor.eu-central-1.api.aws",
},
- endpointKey{
- Region: "eu-central-2",
- }: endpoint{
- Hostname: "internetmonitor.eu-central-2.api.aws",
- },
endpointKey{
Region: "eu-north-1",
}: endpoint{
@@ -13666,11 +13838,6 @@ var awsPartition = partition{
}: endpoint{
Hostname: "internetmonitor.eu-south-1.api.aws",
},
- endpointKey{
- Region: "eu-south-2",
- }: endpoint{
- Hostname: "internetmonitor.eu-south-2.api.aws",
- },
endpointKey{
Region: "eu-west-1",
}: endpoint{
@@ -13686,11 +13853,6 @@ var awsPartition = partition{
}: endpoint{
Hostname: "internetmonitor.eu-west-3.api.aws",
},
- endpointKey{
- Region: "me-central-1",
- }: endpoint{
- Hostname: "internetmonitor.me-central-1.api.aws",
- },
endpointKey{
Region: "me-south-1",
}: endpoint{
@@ -13724,13 +13886,6 @@ var awsPartition = partition{
},
},
"iot": service{
- Defaults: endpointDefaults{
- defaultKey{}: endpoint{
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
- },
- },
Endpoints: serviceEndpoints{
endpointKey{
Region: "ap-east-1",
@@ -13778,45 +13933,35 @@ var awsPartition = partition{
Region: "fips-ca-central-1",
}: endpoint{
Hostname: "iot-fips.ca-central-1.amazonaws.com",
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
+
Deprecated: boxedTrue,
},
endpointKey{
Region: "fips-us-east-1",
}: endpoint{
Hostname: "iot-fips.us-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
+
Deprecated: boxedTrue,
},
endpointKey{
Region: "fips-us-east-2",
}: endpoint{
Hostname: "iot-fips.us-east-2.amazonaws.com",
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
+
Deprecated: boxedTrue,
},
endpointKey{
Region: "fips-us-west-1",
}: endpoint{
Hostname: "iot-fips.us-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
+
Deprecated: boxedTrue,
},
endpointKey{
Region: "fips-us-west-2",
}: endpoint{
Hostname: "iot-fips.us-west-2.amazonaws.com",
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
+
Deprecated: boxedTrue,
},
endpointKey{
@@ -14656,9 +14801,18 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
+ endpointKey{
+ Region: "ca-central-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "kafka-fips.ca-central-1.amazonaws.com",
+ },
endpointKey{
Region: "eu-central-1",
}: endpoint{},
@@ -14683,6 +14837,51 @@ var awsPartition = partition{
endpointKey{
Region: "eu-west-3",
}: endpoint{},
+ endpointKey{
+ Region: "fips-ca-central-1",
+ }: endpoint{
+ Hostname: "kafka-fips.ca-central-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "ca-central-1",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "fips-us-east-1",
+ }: endpoint{
+ Hostname: "kafka-fips.us-east-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-east-1",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "fips-us-east-2",
+ }: endpoint{
+ Hostname: "kafka-fips.us-east-2.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-east-2",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "fips-us-west-1",
+ }: endpoint{
+ Hostname: "kafka-fips.us-west-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-west-1",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "fips-us-west-2",
+ }: endpoint{
+ Hostname: "kafka-fips.us-west-2.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-west-2",
+ },
+ Deprecated: boxedTrue,
+ },
endpointKey{
Region: "me-central-1",
}: endpoint{},
@@ -14695,15 +14894,39 @@ var awsPartition = partition{
endpointKey{
Region: "us-east-1",
}: endpoint{},
+ endpointKey{
+ Region: "us-east-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "kafka-fips.us-east-1.amazonaws.com",
+ },
endpointKey{
Region: "us-east-2",
}: endpoint{},
+ endpointKey{
+ Region: "us-east-2",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "kafka-fips.us-east-2.amazonaws.com",
+ },
endpointKey{
Region: "us-west-1",
}: endpoint{},
+ endpointKey{
+ Region: "us-west-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "kafka-fips.us-west-1.amazonaws.com",
+ },
endpointKey{
Region: "us-west-2",
}: endpoint{},
+ endpointKey{
+ Region: "us-west-2",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "kafka-fips.us-west-2.amazonaws.com",
+ },
},
},
"kafkaconnect": service{
@@ -15151,6 +15374,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -15624,6 +15850,14 @@ var awsPartition = partition{
},
Deprecated: boxedTrue,
},
+ endpointKey{
+ Region: "il-central-1-fips",
+ }: endpoint{
+ Hostname: "kms-fips.il-central-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "il-central-1",
+ },
+ },
endpointKey{
Region: "me-central-1",
}: endpoint{},
@@ -17582,6 +17816,55 @@ var awsPartition = partition{
}: endpoint{},
},
},
+ "mediapackagev2": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "ap-northeast-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-northeast-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-south-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-central-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-north-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-west-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-west-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-west-3",
+ }: endpoint{},
+ endpointKey{
+ Region: "sa-east-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-east-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-east-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-west-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-west-2",
+ }: endpoint{},
+ },
+ },
"mediastore": service{
Endpoints: serviceEndpoints{
endpointKey{
@@ -17862,6 +18145,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-south-1",
}: endpoint{},
+ endpointKey{
+ Region: "ap-south-2",
+ }: endpoint{},
endpointKey{
Region: "ap-southeast-1",
}: endpoint{},
@@ -17871,6 +18157,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -18413,6 +18702,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-south-1",
}: endpoint{},
+ endpointKey{
+ Region: "ap-south-2",
+ }: endpoint{},
endpointKey{
Region: "ap-southeast-1",
}: endpoint{},
@@ -18422,18 +18714,27 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
endpointKey{
Region: "eu-central-1",
}: endpoint{},
+ endpointKey{
+ Region: "eu-central-2",
+ }: endpoint{},
endpointKey{
Region: "eu-north-1",
}: endpoint{},
endpointKey{
Region: "eu-south-1",
}: endpoint{},
+ endpointKey{
+ Region: "eu-south-2",
+ }: endpoint{},
endpointKey{
Region: "eu-west-1",
}: endpoint{},
@@ -19336,6 +19637,40 @@ var awsPartition = partition{
},
},
},
+ "osis": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "ap-northeast-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-central-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-west-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-west-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-east-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-east-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-west-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-west-2",
+ }: endpoint{},
+ },
+ },
"outposts": service{
Endpoints: serviceEndpoints{
endpointKey{
@@ -20203,18 +20538,63 @@ var awsPartition = partition{
endpointKey{
Region: "ca-central-1",
}: endpoint{},
+ endpointKey{
+ Region: "ca-central-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "profile-fips.ca-central-1.amazonaws.com",
+ },
endpointKey{
Region: "eu-central-1",
}: endpoint{},
endpointKey{
Region: "eu-west-2",
}: endpoint{},
+ endpointKey{
+ Region: "fips-ca-central-1",
+ }: endpoint{
+ Hostname: "profile-fips.ca-central-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "ca-central-1",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "fips-us-east-1",
+ }: endpoint{
+ Hostname: "profile-fips.us-east-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-east-1",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "fips-us-west-2",
+ }: endpoint{
+ Hostname: "profile-fips.us-west-2.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-west-2",
+ },
+ Deprecated: boxedTrue,
+ },
endpointKey{
Region: "us-east-1",
}: endpoint{},
+ endpointKey{
+ Region: "us-east-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "profile-fips.us-east-1.amazonaws.com",
+ },
endpointKey{
Region: "us-west-2",
}: endpoint{},
+ endpointKey{
+ Region: "us-west-2",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "profile-fips.us-west-2.amazonaws.com",
+ },
},
},
"projects.iot1click": service{
@@ -21688,16 +22068,6 @@ var awsPartition = partition{
},
},
Endpoints: serviceEndpoints{
- endpointKey{
- Region: "af-south-1",
- }: endpoint{
- Hostname: "resource-explorer-2.af-south-1.api.aws",
- },
- endpointKey{
- Region: "ap-east-1",
- }: endpoint{
- Hostname: "resource-explorer-2.ap-east-1.api.aws",
- },
endpointKey{
Region: "ap-northeast-1",
}: endpoint{
@@ -22128,6 +22498,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -22362,6 +22735,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -23912,6 +24288,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-southeast-3",
}: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-4",
+ }: endpoint{},
endpointKey{
Region: "ca-central-1",
}: endpoint{},
@@ -24027,6 +24406,12 @@ var awsPartition = partition{
endpointKey{
Region: "ap-northeast-1",
}: endpoint{},
+ endpointKey{
+ Region: "ap-northeast-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-south-1",
+ }: endpoint{},
endpointKey{
Region: "ap-southeast-1",
}: endpoint{},
@@ -24051,6 +24436,9 @@ var awsPartition = partition{
endpointKey{
Region: "us-east-2",
}: endpoint{},
+ endpointKey{
+ Region: "us-west-1",
+ }: endpoint{},
endpointKey{
Region: "us-west-2",
}: endpoint{},
@@ -25007,6 +25395,130 @@ var awsPartition = partition{
},
},
},
+ "signer": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "af-south-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-east-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-northeast-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-northeast-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-south-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "ca-central-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-central-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-north-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-south-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-west-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-west-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "eu-west-3",
+ }: endpoint{},
+ endpointKey{
+ Region: "fips-us-east-1",
+ }: endpoint{
+ Hostname: "signer-fips.us-east-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-east-1",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "fips-us-east-2",
+ }: endpoint{
+ Hostname: "signer-fips.us-east-2.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-east-2",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "fips-us-west-1",
+ }: endpoint{
+ Hostname: "signer-fips.us-west-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-west-1",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "fips-us-west-2",
+ }: endpoint{
+ Hostname: "signer-fips.us-west-2.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-west-2",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "me-south-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "sa-east-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-east-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-east-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "signer-fips.us-east-1.amazonaws.com",
+ },
+ endpointKey{
+ Region: "us-east-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-east-2",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "signer-fips.us-east-2.amazonaws.com",
+ },
+ endpointKey{
+ Region: "us-west-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-west-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "signer-fips.us-west-1.amazonaws.com",
+ },
+ endpointKey{
+ Region: "us-west-2",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-west-2",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "signer-fips.us-west-2.amazonaws.com",
+ },
+ },
+ },
"simspaceweaver": service{
Endpoints: serviceEndpoints{
endpointKey{
@@ -27517,12 +28029,21 @@ var awsPartition = partition{
},
"transcribestreaming": service{
Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "af-south-1",
+ }: endpoint{},
endpointKey{
Region: "ap-northeast-1",
}: endpoint{},
endpointKey{
Region: "ap-northeast-2",
}: endpoint{},
+ endpointKey{
+ Region: "ap-south-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "ap-southeast-1",
+ }: endpoint{},
endpointKey{
Region: "ap-southeast-2",
}: endpoint{},
@@ -27680,6 +28201,9 @@ var awsPartition = partition{
endpointKey{
Region: "ap-south-1",
}: endpoint{},
+ endpointKey{
+ Region: "ap-south-2",
+ }: endpoint{},
endpointKey{
Region: "ap-southeast-1",
}: endpoint{},
@@ -27701,12 +28225,18 @@ var awsPartition = partition{
endpointKey{
Region: "eu-central-1",
}: endpoint{},
+ endpointKey{
+ Region: "eu-central-2",
+ }: endpoint{},
endpointKey{
Region: "eu-north-1",
}: endpoint{},
endpointKey{
Region: "eu-south-1",
}: endpoint{},
+ endpointKey{
+ Region: "eu-south-2",
+ }: endpoint{},
endpointKey{
Region: "eu-west-1",
}: endpoint{},
@@ -28665,6 +29195,14 @@ var awsPartition = partition{
},
Deprecated: boxedTrue,
},
+ endpointKey{
+ Region: "fips-il-central-1",
+ }: endpoint{
+ Hostname: "waf-regional-fips.il-central-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "il-central-1",
+ },
+ },
endpointKey{
Region: "fips-me-central-1",
}: endpoint{
@@ -29371,6 +29909,14 @@ var awsPartition = partition{
},
Deprecated: boxedTrue,
},
+ endpointKey{
+ Region: "fips-il-central-1",
+ }: endpoint{
+ Hostname: "wafv2-fips.il-central-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "il-central-1",
+ },
+ },
endpointKey{
Region: "fips-me-central-1",
}: endpoint{
@@ -30087,6 +30633,16 @@ var awscnPartition = partition{
}: endpoint{},
},
},
+ "airflow": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "cn-north-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "cn-northwest-1",
+ }: endpoint{},
+ },
+ },
"api.ecr": service{
Endpoints: serviceEndpoints{
endpointKey{
@@ -30731,6 +31287,16 @@ var awscnPartition = partition{
}: endpoint{},
},
},
+ "emr-serverless": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "cn-north-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "cn-northwest-1",
+ }: endpoint{},
+ },
+ },
"es": service{
Endpoints: serviceEndpoints{
endpointKey{
@@ -30922,13 +31488,6 @@ var awscnPartition = partition{
},
},
"iot": service{
- Defaults: endpointDefaults{
- defaultKey{}: endpoint{
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
- },
- },
Endpoints: serviceEndpoints{
endpointKey{
Region: "cn-north-1",
@@ -31095,6 +31654,16 @@ var awscnPartition = partition{
}: endpoint{},
},
},
+ "license-manager-linux-subscriptions": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "cn-north-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "cn-northwest-1",
+ }: endpoint{},
+ },
+ },
"logs": service{
Endpoints: serviceEndpoints{
endpointKey{
@@ -31532,6 +32101,16 @@ var awscnPartition = partition{
}: endpoint{},
},
},
+ "signer": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "cn-north-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "cn-northwest-1",
+ }: endpoint{},
+ },
+ },
"sms": service{
Endpoints: serviceEndpoints{
endpointKey{
@@ -32426,13 +33005,45 @@ var awsusgovPartition = partition{
endpointKey{
Region: "us-gov-east-1",
}: endpoint{
+ Hostname: "application-autoscaling.us-gov-east-1.amazonaws.com",
Protocols: []string{"http", "https"},
},
+ endpointKey{
+ Region: "us-gov-east-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "application-autoscaling.us-gov-east-1.amazonaws.com",
+ Protocols: []string{"http", "https"},
+ },
+ endpointKey{
+ Region: "us-gov-east-1-fips",
+ }: endpoint{
+ Hostname: "application-autoscaling.us-gov-east-1.amazonaws.com",
+ Protocols: []string{"http", "https"},
+
+ Deprecated: boxedTrue,
+ },
endpointKey{
Region: "us-gov-west-1",
}: endpoint{
+ Hostname: "application-autoscaling.us-gov-west-1.amazonaws.com",
+ Protocols: []string{"http", "https"},
+ },
+ endpointKey{
+ Region: "us-gov-west-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "application-autoscaling.us-gov-west-1.amazonaws.com",
Protocols: []string{"http", "https"},
},
+ endpointKey{
+ Region: "us-gov-west-1-fips",
+ }: endpoint{
+ Hostname: "application-autoscaling.us-gov-west-1.amazonaws.com",
+ Protocols: []string{"http", "https"},
+
+ Deprecated: boxedTrue,
+ },
},
},
"applicationinsights": service{
@@ -32547,6 +33158,12 @@ var awsusgovPartition = partition{
}: endpoint{
Hostname: "athena-fips.us-gov-east-1.amazonaws.com",
},
+ endpointKey{
+ Region: "us-gov-east-1",
+ Variant: fipsVariant | dualStackVariant,
+ }: endpoint{
+ Hostname: "athena-fips.us-gov-east-1.api.aws",
+ },
endpointKey{
Region: "us-gov-west-1",
}: endpoint{},
@@ -32562,6 +33179,12 @@ var awsusgovPartition = partition{
}: endpoint{
Hostname: "athena-fips.us-gov-west-1.amazonaws.com",
},
+ endpointKey{
+ Region: "us-gov-west-1",
+ Variant: fipsVariant | dualStackVariant,
+ }: endpoint{
+ Hostname: "athena-fips.us-gov-west-1.api.aws",
+ },
},
},
"autoscaling": service{
@@ -33059,6 +33682,9 @@ var awsusgovPartition = partition{
},
Deprecated: boxedTrue,
},
+ endpointKey{
+ Region: "us-gov-east-1",
+ }: endpoint{},
endpointKey{
Region: "us-gov-west-1",
}: endpoint{},
@@ -33233,9 +33859,24 @@ var awsusgovPartition = partition{
},
"connect": service{
Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "fips-us-gov-west-1",
+ }: endpoint{
+ Hostname: "connect.us-gov-west-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-gov-west-1",
+ },
+ Deprecated: boxedTrue,
+ },
endpointKey{
Region: "us-gov-west-1",
}: endpoint{},
+ endpointKey{
+ Region: "us-gov-west-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "connect.us-gov-west-1.amazonaws.com",
+ },
},
},
"controltower": service{
@@ -34753,30 +35394,19 @@ var awsusgovPartition = partition{
},
},
"iot": service{
- Defaults: endpointDefaults{
- defaultKey{}: endpoint{
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
- },
- },
Endpoints: serviceEndpoints{
endpointKey{
Region: "fips-us-gov-east-1",
}: endpoint{
Hostname: "iot-fips.us-gov-east-1.amazonaws.com",
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
+
Deprecated: boxedTrue,
},
endpointKey{
Region: "fips-us-gov-west-1",
}: endpoint{
Hostname: "iot-fips.us-gov-west-1.amazonaws.com",
- CredentialScope: credentialScope{
- Service: "execute-api",
- },
+
Deprecated: boxedTrue,
},
endpointKey{
@@ -34947,10 +35577,56 @@ var awsusgovPartition = partition{
Endpoints: serviceEndpoints{
endpointKey{
Region: "us-gov-east-1",
- }: endpoint{},
+ }: endpoint{
+ Hostname: "kafka.us-gov-east-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-gov-east-1",
+ },
+ },
+ endpointKey{
+ Region: "us-gov-east-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "kafka.us-gov-east-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-gov-east-1",
+ },
+ },
+ endpointKey{
+ Region: "us-gov-east-1-fips",
+ }: endpoint{
+ Hostname: "kafka.us-gov-east-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-gov-east-1",
+ },
+ Deprecated: boxedTrue,
+ },
endpointKey{
Region: "us-gov-west-1",
- }: endpoint{},
+ }: endpoint{
+ Hostname: "kafka.us-gov-west-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-gov-west-1",
+ },
+ },
+ endpointKey{
+ Region: "us-gov-west-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "kafka.us-gov-west-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-gov-west-1",
+ },
+ },
+ endpointKey{
+ Region: "us-gov-west-1-fips",
+ }: endpoint{
+ Hostname: "kafka.us-gov-west-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-gov-west-1",
+ },
+ Deprecated: boxedTrue,
+ },
},
},
"kendra": service{
@@ -35383,6 +36059,46 @@ var awsusgovPartition = partition{
}: endpoint{},
},
},
+ "mgn": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "fips-us-gov-east-1",
+ }: endpoint{
+ Hostname: "mgn-fips.us-gov-east-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-gov-east-1",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "fips-us-gov-west-1",
+ }: endpoint{
+ Hostname: "mgn-fips.us-gov-west-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-gov-west-1",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "us-gov-east-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-gov-east-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "mgn-fips.us-gov-east-1.amazonaws.com",
+ },
+ endpointKey{
+ Region: "us-gov-west-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-gov-west-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "mgn-fips.us-gov-west-1.amazonaws.com",
+ },
+ },
+ },
"models.lex": service{
Defaults: endpointDefaults{
defaultKey{}: endpoint{
@@ -36143,9 +36859,35 @@ var awsusgovPartition = partition{
endpointKey{
Region: "us-gov-east-1",
}: endpoint{},
+ endpointKey{
+ Region: "us-gov-east-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "route53resolver.us-gov-east-1.amazonaws.com",
+ },
+ endpointKey{
+ Region: "us-gov-east-1-fips",
+ }: endpoint{
+ Hostname: "route53resolver.us-gov-east-1.amazonaws.com",
+
+ Deprecated: boxedTrue,
+ },
endpointKey{
Region: "us-gov-west-1",
}: endpoint{},
+ endpointKey{
+ Region: "us-gov-west-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "route53resolver.us-gov-west-1.amazonaws.com",
+ },
+ endpointKey{
+ Region: "us-gov-west-1-fips",
+ }: endpoint{
+ Hostname: "route53resolver.us-gov-west-1.amazonaws.com",
+
+ Deprecated: boxedTrue,
+ },
},
},
"runtime.lex": service{
@@ -36906,14 +37648,14 @@ var awsusgovPartition = partition{
endpointKey{
Region: "us-gov-west-1",
}: endpoint{
- Protocols: []string{"http", "https"},
+ Protocols: []string{"https"},
},
endpointKey{
Region: "us-gov-west-1",
Variant: fipsVariant,
}: endpoint{
Hostname: "sns.us-gov-west-1.amazonaws.com",
- Protocols: []string{"http", "https"},
+ Protocols: []string{"https"},
},
},
},
@@ -37645,6 +38387,15 @@ var awsusgovPartition = partition{
},
"workspaces": service{
Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "fips-us-gov-east-1",
+ }: endpoint{
+ Hostname: "workspaces-fips.us-gov-east-1.amazonaws.com",
+ CredentialScope: credentialScope{
+ Region: "us-gov-east-1",
+ },
+ Deprecated: boxedTrue,
+ },
endpointKey{
Region: "fips-us-gov-west-1",
}: endpoint{
@@ -37654,6 +38405,15 @@ var awsusgovPartition = partition{
},
Deprecated: boxedTrue,
},
+ endpointKey{
+ Region: "us-gov-east-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-gov-east-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "workspaces-fips.us-gov-east-1.amazonaws.com",
+ },
endpointKey{
Region: "us-gov-west-1",
}: endpoint{},
@@ -37816,6 +38576,13 @@ var awsisoPartition = partition{
}: endpoint{},
},
},
+ "athena": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "us-iso-east-1",
+ }: endpoint{},
+ },
+ },
"autoscaling": service{
Endpoints: serviceEndpoints{
endpointKey{
@@ -37828,6 +38595,16 @@ var awsisoPartition = partition{
}: endpoint{},
},
},
+ "cloudcontrolapi": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "us-iso-east-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-iso-west-1",
+ }: endpoint{},
+ },
+ },
"cloudformation": service{
Endpoints: serviceEndpoints{
endpointKey{
@@ -38251,6 +39028,9 @@ var awsisoPartition = partition{
endpointKey{
Region: "us-iso-east-1",
}: endpoint{},
+ endpointKey{
+ Region: "us-iso-west-1",
+ }: endpoint{},
},
},
"logs": service{
@@ -38311,6 +39091,28 @@ var awsisoPartition = partition{
}: endpoint{},
},
},
+ "rbin": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "fips-us-iso-east-1",
+ }: endpoint{
+ Hostname: "rbin-fips.us-iso-east-1.c2s.ic.gov",
+ CredentialScope: credentialScope{
+ Region: "us-iso-east-1",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "us-iso-east-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-iso-east-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "rbin-fips.us-iso-east-1.c2s.ic.gov",
+ },
+ },
+ },
"rds": service{
Endpoints: serviceEndpoints{
endpointKey{
@@ -38350,6 +39152,9 @@ var awsisoPartition = partition{
endpointKey{
Region: "us-iso-east-1",
}: endpoint{},
+ endpointKey{
+ Region: "us-iso-west-1",
+ }: endpoint{},
},
},
"runtime.sagemaker": service{
@@ -38503,6 +39308,9 @@ var awsisoPartition = partition{
endpointKey{
Region: "us-iso-east-1",
}: endpoint{},
+ endpointKey{
+ Region: "us-iso-west-1",
+ }: endpoint{},
},
},
"transcribe": service{
@@ -38972,6 +39780,28 @@ var awsisobPartition = partition{
}: endpoint{},
},
},
+ "rbin": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "fips-us-isob-east-1",
+ }: endpoint{
+ Hostname: "rbin-fips.us-isob-east-1.sc2s.sgov.gov",
+ CredentialScope: credentialScope{
+ Region: "us-isob-east-1",
+ },
+ Deprecated: boxedTrue,
+ },
+ endpointKey{
+ Region: "us-isob-east-1",
+ }: endpoint{},
+ endpointKey{
+ Region: "us-isob-east-1",
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "rbin-fips.us-isob-east-1.sc2s.sgov.gov",
+ },
+ },
+ },
"rds": service{
Endpoints: serviceEndpoints{
endpointKey{
@@ -39027,6 +39857,13 @@ var awsisobPartition = partition{
}: endpoint{},
},
},
+ "secretsmanager": service{
+ Endpoints: serviceEndpoints{
+ endpointKey{
+ Region: "us-isob-east-1",
+ }: endpoint{},
+ },
+ },
"snowball": service{
Endpoints: serviceEndpoints{
endpointKey{
@@ -39138,3 +39975,37 @@ var awsisobPartition = partition{
},
},
}
+
+// AwsIsoEPartition returns the Resolver for AWS ISOE (Europe).
+func AwsIsoEPartition() Partition {
+ return awsisoePartition.Partition()
+}
+
+var awsisoePartition = partition{
+ ID: "aws-iso-e",
+ Name: "AWS ISOE (Europe)",
+ DNSSuffix: "cloud.adc-e.uk",
+ RegionRegex: regionRegex{
+ Regexp: func() *regexp.Regexp {
+ reg, _ := regexp.Compile("^eu\\-isoe\\-\\w+\\-\\d+$")
+ return reg
+ }(),
+ },
+ Defaults: endpointDefaults{
+ defaultKey{}: endpoint{
+ Hostname: "{service}.{region}.{dnsSuffix}",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ defaultKey{
+ Variant: fipsVariant,
+ }: endpoint{
+ Hostname: "{service}-fips.{region}.{dnsSuffix}",
+ DNSSuffix: "cloud.adc-e.uk",
+ Protocols: []string{"https"},
+ SignatureVersions: []string{"v4"},
+ },
+ },
+ Regions: regions{},
+ Services: services{},
+}
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go
index 4d78162c034..0240bd0be35 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go
@@ -3,7 +3,7 @@
// Provides request signing for request that need to be signed with
// AWS V4 Signatures.
//
-// Standalone Signer
+// # Standalone Signer
//
// Generally using the signer outside of the SDK should not require any additional
// logic when using Go v1.5 or higher. The signer does this by taking advantage
@@ -14,10 +14,10 @@
// The signer will first check the URL.Opaque field, and use its value if set.
// The signer does require the URL.Opaque field to be set in the form of:
//
-// "///"
+// "///"
//
-// // e.g.
-// "//example.com/some/path"
+// // e.g.
+// "//example.com/some/path"
//
// The leading "//" and hostname are required or the URL.Opaque escaping will
// not work correctly.
@@ -695,7 +695,8 @@ func (ctx *signingCtx) buildBodyDigest() error {
includeSHA256Header := ctx.unsignedPayload ||
ctx.ServiceName == "s3" ||
ctx.ServiceName == "s3-object-lambda" ||
- ctx.ServiceName == "glacier"
+ ctx.ServiceName == "glacier" ||
+ ctx.ServiceName == "s3-outposts"
s3Presign := ctx.isPresign &&
(ctx.ServiceName == "s3" ||
diff --git a/vendor/github.com/aws/aws-sdk-go/aws/version.go b/vendor/github.com/aws/aws-sdk-go/aws/version.go
index f34d398202f..2b410cc8906 100644
--- a/vendor/github.com/aws/aws-sdk-go/aws/version.go
+++ b/vendor/github.com/aws/aws-sdk-go/aws/version.go
@@ -5,4 +5,4 @@ package aws
const SDKName = "aws-sdk-go"
// SDKVersion is the version of this SDK
-const SDKVersion = "1.44.245"
+const SDKVersion = "1.44.276"
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/restjson/unmarshal_error.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/restjson/unmarshal_error.go
index 4fffd0427ba..5366a646d9c 100644
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/restjson/unmarshal_error.go
+++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/restjson/unmarshal_error.go
@@ -2,6 +2,7 @@ package restjson
import (
"bytes"
+ "encoding/json"
"io"
"io/ioutil"
"net/http"
@@ -40,54 +41,30 @@ func (u *UnmarshalTypedError) UnmarshalError(
resp *http.Response,
respMeta protocol.ResponseMetadata,
) (error, error) {
-
- code := resp.Header.Get(errorTypeHeader)
- msg := resp.Header.Get(errorMessageHeader)
-
- body := resp.Body
- if len(code) == 0 || len(msg) == 0 {
- // If unable to get code from HTTP headers have to parse JSON message
- // to determine what kind of exception this will be.
- var buf bytes.Buffer
- var jsonErr jsonErrorResponse
- teeReader := io.TeeReader(resp.Body, &buf)
- err := jsonutil.UnmarshalJSONError(&jsonErr, teeReader)
- if err != nil {
- return nil, err
- }
-
- body = ioutil.NopCloser(&buf)
- if len(code) == 0 {
- code = jsonErr.Code
- }
- msg = jsonErr.Message
+ code, msg, err := unmarshalErrorInfo(resp)
+ if err != nil {
+ return nil, err
}
- // If code has colon separators remove them so can compare against modeled
- // exception names.
- code = strings.SplitN(code, ":", 2)[0]
-
- if fn, ok := u.exceptions[code]; ok {
- // If exception code is know, use associated constructor to get a value
- // for the exception that the JSON body can be unmarshaled into.
- v := fn(respMeta)
- if err := jsonutil.UnmarshalJSONCaseInsensitive(v, body); err != nil {
- return nil, err
- }
+ fn, ok := u.exceptions[code]
+ if !ok {
+ return awserr.NewRequestFailure(
+ awserr.New(code, msg, nil),
+ respMeta.StatusCode,
+ respMeta.RequestID,
+ ), nil
+ }
- if err := rest.UnmarshalResponse(resp, v, true); err != nil {
- return nil, err
- }
+ v := fn(respMeta)
+ if err := jsonutil.UnmarshalJSONCaseInsensitive(v, resp.Body); err != nil {
+ return nil, err
+ }
- return v, nil
+ if err := rest.UnmarshalResponse(resp, v, true); err != nil {
+ return nil, err
}
- // fallback to unmodeled generic exceptions
- return awserr.NewRequestFailure(
- awserr.New(code, msg, nil),
- respMeta.StatusCode,
- respMeta.RequestID,
- ), nil
+ return v, nil
}
// UnmarshalErrorHandler is a named request handler for unmarshaling restjson
@@ -101,36 +78,80 @@ var UnmarshalErrorHandler = request.NamedHandler{
func UnmarshalError(r *request.Request) {
defer r.HTTPResponse.Body.Close()
- var jsonErr jsonErrorResponse
- err := jsonutil.UnmarshalJSONError(&jsonErr, r.HTTPResponse.Body)
+ code, msg, err := unmarshalErrorInfo(r.HTTPResponse)
if err != nil {
r.Error = awserr.NewRequestFailure(
- awserr.New(request.ErrCodeSerialization,
- "failed to unmarshal response error", err),
+ awserr.New(request.ErrCodeSerialization, "failed to unmarshal response error", err),
r.HTTPResponse.StatusCode,
r.RequestID,
)
return
}
- code := r.HTTPResponse.Header.Get(errorTypeHeader)
- if code == "" {
- code = jsonErr.Code
- }
- msg := r.HTTPResponse.Header.Get(errorMessageHeader)
- if msg == "" {
- msg = jsonErr.Message
- }
-
- code = strings.SplitN(code, ":", 2)[0]
r.Error = awserr.NewRequestFailure(
- awserr.New(code, jsonErr.Message, nil),
+ awserr.New(code, msg, nil),
r.HTTPResponse.StatusCode,
r.RequestID,
)
}
type jsonErrorResponse struct {
+ Type string `json:"__type"`
Code string `json:"code"`
Message string `json:"message"`
}
+
+func (j *jsonErrorResponse) SanitizedCode() string {
+ code := j.Code
+ if len(j.Type) > 0 {
+ code = j.Type
+ }
+ return sanitizeCode(code)
+}
+
+// Remove superfluous components from a restJson error code.
+// - If a : character is present, then take only the contents before the
+// first : character in the value.
+// - If a # character is present, then take only the contents after the first
+// # character in the value.
+//
+// All of the following error values resolve to FooError:
+// - FooError
+// - FooError:http://internal.amazon.com/coral/com.amazon.coral.validate/
+// - aws.protocoltests.restjson#FooError
+// - aws.protocoltests.restjson#FooError:http://internal.amazon.com/coral/com.amazon.coral.validate/
+func sanitizeCode(code string) string {
+ noColon := strings.SplitN(code, ":", 2)[0]
+ hashSplit := strings.SplitN(noColon, "#", 2)
+ return hashSplit[len(hashSplit)-1]
+}
+
+// attempt to garner error details from the response, preferring header values
+// when present
+func unmarshalErrorInfo(resp *http.Response) (code string, msg string, err error) {
+ code = sanitizeCode(resp.Header.Get(errorTypeHeader))
+ msg = resp.Header.Get(errorMessageHeader)
+ if len(code) > 0 && len(msg) > 0 {
+ return
+ }
+
+ // a modeled error will have to be re-deserialized later, so the body must
+ // be preserved
+ var buf bytes.Buffer
+ tee := io.TeeReader(resp.Body, &buf)
+ defer func() { resp.Body = ioutil.NopCloser(&buf) }()
+
+ var jsonErr jsonErrorResponse
+ if decodeErr := json.NewDecoder(tee).Decode(&jsonErr); decodeErr != nil && decodeErr != io.EOF {
+ err = awserr.NewUnmarshalError(decodeErr, "failed to decode response body", buf.Bytes())
+ return
+ }
+
+ if len(code) == 0 {
+ code = jsonErr.SanitizedCode()
+ }
+ if len(msg) == 0 {
+ msg = jsonErr.Message
+ }
+ return
+}
diff --git a/vendor/github.com/aws/aws-sdk-go/service/ec2/api.go b/vendor/github.com/aws/aws-sdk-go/service/ec2/api.go
index 1ed7b2921c2..994d221d318 100644
--- a/vendor/github.com/aws/aws-sdk-go/service/ec2/api.go
+++ b/vendor/github.com/aws/aws-sdk-go/service/ec2/api.go
@@ -2725,9 +2725,8 @@ func (c *EC2) AttachVerifiedAccessTrustProviderRequest(input *AttachVerifiedAcce
// AttachVerifiedAccessTrustProvider API operation for Amazon Elastic Compute Cloud.
//
-// A trust provider is a third-party entity that creates, maintains, and manages
-// identity information for users and devices. One or more trust providers can
-// be attached to an Amazon Web Services Verified Access instance.
+// Attaches the specified Amazon Web Services Verified Access trust provider
+// to the specified Amazon Web Services Verified Access instance.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -10070,10 +10069,9 @@ func (c *EC2) CreateVerifiedAccessGroupRequest(input *CreateVerifiedAccessGroupI
//
// An Amazon Web Services Verified Access group is a collection of Amazon Web
// Services Verified Access endpoints who's associated applications have similar
-// security requirements. Each instance within an Amazon Web Services Verified
-// Access group shares an Amazon Web Services Verified Access policy. For example,
-// you can group all Amazon Web Services Verified Access instances associated
-// with “sales” applications together and use one common Amazon Web Services
+// security requirements. Each instance within a Verified Access group shares
+// an Verified Access policy. For example, you can group all Verified Access
+// instances associated with "sales" applications together and use one common
// Verified Access policy.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
@@ -10224,9 +10222,8 @@ func (c *EC2) CreateVerifiedAccessTrustProviderRequest(input *CreateVerifiedAcce
//
// A trust provider is a third-party entity that creates, maintains, and manages
// identity information for users and devices. When an application request is
-// made, the identity information sent by the trust provider will be evaluated
-// by Amazon Web Services Verified Access, before allowing or denying the application
-// request.
+// made, the identity information sent by the trust provider is evaluated by
+// Verified Access before allowing or denying the application request.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -31874,7 +31871,7 @@ func (c *EC2) DescribeVerifiedAccessEndpointsRequest(input *DescribeVerifiedAcce
// DescribeVerifiedAccessEndpoints API operation for Amazon Elastic Compute Cloud.
//
-// Describe Amazon Web Services Verified Access endpoints.
+// Describes the specified Amazon Web Services Verified Access endpoints.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -32004,7 +32001,7 @@ func (c *EC2) DescribeVerifiedAccessGroupsRequest(input *DescribeVerifiedAccessG
// DescribeVerifiedAccessGroups API operation for Amazon Elastic Compute Cloud.
//
-// Describe details of existing Verified Access groups.
+// Describes the specified Verified Access groups.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -32134,8 +32131,7 @@ func (c *EC2) DescribeVerifiedAccessInstanceLoggingConfigurationsRequest(input *
// DescribeVerifiedAccessInstanceLoggingConfigurations API operation for Amazon Elastic Compute Cloud.
//
-// Describes the current logging configuration for the Amazon Web Services Verified
-// Access instances.
+// Describes the specified Amazon Web Services Verified Access instances.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -32265,7 +32261,7 @@ func (c *EC2) DescribeVerifiedAccessInstancesRequest(input *DescribeVerifiedAcce
// DescribeVerifiedAccessInstances API operation for Amazon Elastic Compute Cloud.
//
-// Describe Verified Access instances.
+// Describes the specified Amazon Web Services Verified Access instances.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -32395,7 +32391,7 @@ func (c *EC2) DescribeVerifiedAccessTrustProvidersRequest(input *DescribeVerifie
// DescribeVerifiedAccessTrustProviders API operation for Amazon Elastic Compute Cloud.
//
-// Describe details of existing Verified Access trust providers.
+// Describes the specified Amazon Web Services Verified Access trust providers.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -34704,7 +34700,8 @@ func (c *EC2) DetachVerifiedAccessTrustProviderRequest(input *DetachVerifiedAcce
// DetachVerifiedAccessTrustProvider API operation for Amazon Elastic Compute Cloud.
//
-// Detach a trust provider from an Amazon Web Services Verified Access instance.
+// Detaches the specified Amazon Web Services Verified Access trust provider
+// from the specified Amazon Web Services Verified Access instance.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -40888,6 +40885,12 @@ func (c *EC2) GetNetworkInsightsAccessScopeAnalysisFindingsRequest(input *GetNet
Name: opGetNetworkInsightsAccessScopeAnalysisFindings,
HTTPMethod: "POST",
HTTPPath: "/",
+ Paginator: &request.Paginator{
+ InputTokens: []string{"NextToken"},
+ OutputTokens: []string{"NextToken"},
+ LimitToken: "MaxResults",
+ TruncationToken: "",
+ },
}
if input == nil {
@@ -40931,6 +40934,57 @@ func (c *EC2) GetNetworkInsightsAccessScopeAnalysisFindingsWithContext(ctx aws.C
return out, req.Send()
}
+// GetNetworkInsightsAccessScopeAnalysisFindingsPages iterates over the pages of a GetNetworkInsightsAccessScopeAnalysisFindings operation,
+// calling the "fn" function with the response data for each page. To stop
+// iterating, return false from the fn function.
+//
+// See GetNetworkInsightsAccessScopeAnalysisFindings method for more information on how to use this operation.
+//
+// Note: This operation can generate multiple requests to a service.
+//
+// // Example iterating over at most 3 pages of a GetNetworkInsightsAccessScopeAnalysisFindings operation.
+// pageNum := 0
+// err := client.GetNetworkInsightsAccessScopeAnalysisFindingsPages(params,
+// func(page *ec2.GetNetworkInsightsAccessScopeAnalysisFindingsOutput, lastPage bool) bool {
+// pageNum++
+// fmt.Println(page)
+// return pageNum <= 3
+// })
+func (c *EC2) GetNetworkInsightsAccessScopeAnalysisFindingsPages(input *GetNetworkInsightsAccessScopeAnalysisFindingsInput, fn func(*GetNetworkInsightsAccessScopeAnalysisFindingsOutput, bool) bool) error {
+ return c.GetNetworkInsightsAccessScopeAnalysisFindingsPagesWithContext(aws.BackgroundContext(), input, fn)
+}
+
+// GetNetworkInsightsAccessScopeAnalysisFindingsPagesWithContext same as GetNetworkInsightsAccessScopeAnalysisFindingsPages except
+// it takes a Context and allows setting request options on the pages.
+//
+// The context must be non-nil and will be used for request cancellation. If
+// the context is nil a panic will occur. In the future the SDK may create
+// sub-contexts for http.Requests. See https://golang.org/pkg/context/
+// for more information on using Contexts.
+func (c *EC2) GetNetworkInsightsAccessScopeAnalysisFindingsPagesWithContext(ctx aws.Context, input *GetNetworkInsightsAccessScopeAnalysisFindingsInput, fn func(*GetNetworkInsightsAccessScopeAnalysisFindingsOutput, bool) bool, opts ...request.Option) error {
+ p := request.Pagination{
+ NewRequest: func() (*request.Request, error) {
+ var inCpy *GetNetworkInsightsAccessScopeAnalysisFindingsInput
+ if input != nil {
+ tmp := *input
+ inCpy = &tmp
+ }
+ req, _ := c.GetNetworkInsightsAccessScopeAnalysisFindingsRequest(inCpy)
+ req.SetContext(ctx)
+ req.ApplyOptions(opts...)
+ return req, nil
+ },
+ }
+
+ for p.Next() {
+ if !fn(p.Page().(*GetNetworkInsightsAccessScopeAnalysisFindingsOutput), !p.HasNextPage()) {
+ break
+ }
+ }
+
+ return p.Err()
+}
+
const opGetNetworkInsightsAccessScopeContent = "GetNetworkInsightsAccessScopeContent"
// GetNetworkInsightsAccessScopeContentRequest generates a "aws/request.Request" representing the
@@ -44638,10 +44692,10 @@ func (c *EC2) ModifyInstanceAttributeRequest(input *ModifyInstanceAttributeInput
// only one attribute at a time.
//
// Note: Using this action to change the security groups associated with an
-// elastic network interface (ENI) attached to an instance in a VPC can result
-// in an error if the instance has more than one ENI. To change the security
-// groups associated with an ENI attached to an instance that has multiple ENIs,
-// we recommend that you use the ModifyNetworkInterfaceAttribute action.
+// elastic network interface (ENI) attached to an instance can result in an
+// error if the instance has more than one ENI. To change the security groups
+// associated with an ENI attached to an instance that has multiple ENIs, we
+// recommend that you use the ModifyNetworkInterfaceAttribute action.
//
// To modify some attributes, the instance must be stopped. For more information,
// see Modify a stopped instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_ChangingAttributesWhileInstanceStopped.html)
@@ -46040,10 +46094,6 @@ func (c *EC2) ModifyReservedInstancesRequest(input *ModifyReservedInstancesInput
// For more information, see Modifying Reserved Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-modifying.html)
// in the Amazon EC2 User Guide.
//
-// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic
-// to a VPC. For more information, see Migrate from EC2-Classic to a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html)
-// in the Amazon Elastic Compute Cloud User Guide.
-//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
// the error.
@@ -46994,7 +47044,8 @@ func (c *EC2) ModifyVerifiedAccessEndpointRequest(input *ModifyVerifiedAccessEnd
// ModifyVerifiedAccessEndpoint API operation for Amazon Elastic Compute Cloud.
//
-// Modifies the configuration of an Amazon Web Services Verified Access endpoint.
+// Modifies the configuration of the specified Amazon Web Services Verified
+// Access endpoint.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -47067,7 +47118,7 @@ func (c *EC2) ModifyVerifiedAccessEndpointPolicyRequest(input *ModifyVerifiedAcc
// ModifyVerifiedAccessEndpointPolicy API operation for Amazon Elastic Compute Cloud.
//
-// Modifies the specified Verified Access endpoint policy.
+// Modifies the specified Amazon Web Services Verified Access endpoint policy.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -47140,7 +47191,7 @@ func (c *EC2) ModifyVerifiedAccessGroupRequest(input *ModifyVerifiedAccessGroupI
// ModifyVerifiedAccessGroup API operation for Amazon Elastic Compute Cloud.
//
-// Modifies the specified Verified Access group configuration.
+// Modifies the specified Amazon Web Services Verified Access group configuration.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -47213,7 +47264,7 @@ func (c *EC2) ModifyVerifiedAccessGroupPolicyRequest(input *ModifyVerifiedAccess
// ModifyVerifiedAccessGroupPolicy API operation for Amazon Elastic Compute Cloud.
//
-// Modifies the specified Verified Access group policy.
+// Modifies the specified Amazon Web Services Verified Access group policy.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -47286,7 +47337,8 @@ func (c *EC2) ModifyVerifiedAccessInstanceRequest(input *ModifyVerifiedAccessIns
// ModifyVerifiedAccessInstance API operation for Amazon Elastic Compute Cloud.
//
-// Modifies the configuration of the specified Verified Access instance.
+// Modifies the configuration of the specified Amazon Web Services Verified
+// Access instance.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
@@ -49243,10 +49295,6 @@ func (c *EC2) PurchaseReservedInstancesOfferingRequest(input *PurchaseReservedIn
// and Reserved Instance Marketplace (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-market-general.html)
// in the Amazon EC2 User Guide.
//
-// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic
-// to a VPC. For more information, see Migrate from EC2-Classic to a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html)
-// in the Amazon Elastic Compute Cloud User Guide.
-//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
// the error.
@@ -51217,10 +51265,6 @@ func (c *EC2) RequestSpotInstancesRequest(input *RequestSpotInstancesInput) (req
// see Which is the best Spot request method to use? (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-best-practices.html#which-spot-request-method-to-use)
// in the Amazon EC2 User Guide for Linux Instances.
//
-// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic
-// to a VPC. For more information, see Migrate from EC2-Classic to a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html)
-// in the Amazon EC2 User Guide for Linux Instances.
-//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
// the error.
@@ -52482,20 +52526,13 @@ func (c *EC2) RunInstancesRequest(input *RunInstancesInput) (req *request.Reques
// You can specify a number of options, or leave the default options. The following
// rules apply:
//
-// - [EC2-VPC] If you don't specify a subnet ID, we choose a default subnet
-// from your default VPC for you. If you don't have a default VPC, you must
-// specify a subnet ID in the request.
-//
-// - [EC2-Classic] If don't specify an Availability Zone, we choose one for
-// you.
+// - If you don't specify a subnet ID, we choose a default subnet from your
+// default VPC for you. If you don't have a default VPC, you must specify
+// a subnet ID in the request.
//
-// - Some instance types must be launched into a VPC. If you do not have
-// a default VPC, or if you do not specify a subnet ID, the request fails.
-// For more information, see Instance types available only in a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-vpc.html#vpc-only-instance-types).
-//
-// - [EC2-VPC] All instances have a network interface with a primary private
-// IPv4 address. If you don't specify this address, we choose one from the
-// IPv4 range of your subnet.
+// - All instances have a network interface with a primary private IPv4 address.
+// If you don't specify this address, we choose one from the IPv4 range of
+// your subnet.
//
// - Not all instance types support IPv6 addresses. For more information,
// see Instance types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html).
@@ -52529,10 +52566,6 @@ func (c *EC2) RunInstancesRequest(input *RunInstancesInput) (req *request.Reques
// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_InstanceStraightToTerminated.html),
// and Troubleshooting connecting to your instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesConnecting.html).
//
-// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic
-// to a VPC. For more information, see Migrate from EC2-Classic to a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html)
-// in the Amazon EC2 User Guide.
-//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
// with awserr.Error's Code and Message methods to get detailed information about
// the error.
@@ -60191,12 +60224,12 @@ type AttachVerifiedAccessTrustProviderInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
//
// VerifiedAccessInstanceId is a required field
VerifiedAccessInstanceId *string `type:"string" required:"true"`
- // The ID of the Amazon Web Services Verified Access trust provider.
+ // The ID of the Verified Access trust provider.
//
// VerifiedAccessTrustProviderId is a required field
VerifiedAccessTrustProviderId *string `type:"string" required:"true"`
@@ -60263,10 +60296,10 @@ func (s *AttachVerifiedAccessTrustProviderInput) SetVerifiedAccessTrustProviderI
type AttachVerifiedAccessTrustProviderOutput struct {
_ struct{} `type:"structure"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
VerifiedAccessInstance *VerifiedAccessInstance `locationName:"verifiedAccessInstance" type:"structure"`
- // The ID of the Amazon Web Services Verified Access trust provider.
+ // The ID of the Verified Access trust provider.
VerifiedAccessTrustProvider *VerifiedAccessTrustProvider `locationName:"verifiedAccessTrustProvider" type:"structure"`
}
@@ -62959,7 +62992,7 @@ type CancelSpotInstanceRequestsInput struct {
// it is UnauthorizedOperation.
DryRun *bool `locationName:"dryRun" type:"boolean"`
- // One or more Spot Instance request IDs.
+ // The IDs of the Spot Instance requests.
//
// SpotInstanceRequestIds is a required field
SpotInstanceRequestIds []*string `locationName:"SpotInstanceRequestId" locationNameList:"SpotInstanceRequestId" type:"list" required:"true"`
@@ -63012,7 +63045,7 @@ func (s *CancelSpotInstanceRequestsInput) SetSpotInstanceRequestIds(v []*string)
type CancelSpotInstanceRequestsOutput struct {
_ struct{} `type:"structure"`
- // One or more Spot Instance requests.
+ // The Spot Instance requests.
CancelledSpotInstanceRequests []*CancelledSpotInstanceRequest `locationName:"spotInstanceRequestSet" locationNameList:"item" type:"list"`
}
@@ -66781,6 +66814,9 @@ func (s *CopySnapshotOutput) SetTags(v []*Tag) *CopySnapshotOutput {
type CpuOptions struct {
_ struct{} `type:"structure"`
+ // Indicates whether the instance is enabled for AMD SEV-SNP.
+ AmdSevSnp *string `locationName:"amdSevSnp" type:"string" enum:"AmdSevSnpSpecification"`
+
// The number of CPU cores for the instance.
CoreCount *int64 `locationName:"coreCount" type:"integer"`
@@ -66806,6 +66842,12 @@ func (s CpuOptions) GoString() string {
return s.String()
}
+// SetAmdSevSnp sets the AmdSevSnp field's value.
+func (s *CpuOptions) SetAmdSevSnp(v string) *CpuOptions {
+ s.AmdSevSnp = &v
+ return s
+}
+
// SetCoreCount sets the CoreCount field's value.
func (s *CpuOptions) SetCoreCount(v int64) *CpuOptions {
s.CoreCount = &v
@@ -66823,6 +66865,10 @@ func (s *CpuOptions) SetThreadsPerCore(v int64) *CpuOptions {
type CpuOptionsRequest struct {
_ struct{} `type:"structure"`
+ // Indicates whether to enable the instance for AMD SEV-SNP. AMD SEV-SNP is
+ // supported with M6a, R6a, and C6a instance types only.
+ AmdSevSnp *string `type:"string" enum:"AmdSevSnpSpecification"`
+
// The number of CPU cores for the instance.
CoreCount *int64 `type:"integer"`
@@ -66849,6 +66895,12 @@ func (s CpuOptionsRequest) GoString() string {
return s.String()
}
+// SetAmdSevSnp sets the AmdSevSnp field's value.
+func (s *CpuOptionsRequest) SetAmdSevSnp(v string) *CpuOptionsRequest {
+ s.AmdSevSnp = &v
+ return s
+}
+
// SetCoreCount sets the CoreCount field's value.
func (s *CpuOptionsRequest) SetCoreCount(v int64) *CpuOptionsRequest {
s.CoreCount = &v
@@ -70825,12 +70877,8 @@ type CreateLaunchTemplateInput struct {
// The information for the launch template.
//
- // LaunchTemplateData is a sensitive parameter and its value will be
- // replaced with "sensitive" in string returned by CreateLaunchTemplateInput's
- // String and GoString methods.
- //
// LaunchTemplateData is a required field
- LaunchTemplateData *RequestLaunchTemplateData `type:"structure" required:"true" sensitive:"true"`
+ LaunchTemplateData *RequestLaunchTemplateData `type:"structure" required:"true"`
// A name for the launch template.
//
@@ -70987,12 +71035,8 @@ type CreateLaunchTemplateVersionInput struct {
// The information for the launch template.
//
- // LaunchTemplateData is a sensitive parameter and its value will be
- // replaced with "sensitive" in string returned by CreateLaunchTemplateVersionInput's
- // String and GoString methods.
- //
// LaunchTemplateData is a required field
- LaunchTemplateData *RequestLaunchTemplateData `type:"structure" required:"true" sensitive:"true"`
+ LaunchTemplateData *RequestLaunchTemplateData `type:"structure" required:"true"`
// The ID of the launch template.
//
@@ -77032,7 +77076,8 @@ func (s *CreateTransitGatewayVpcAttachmentRequestOptions) SetIpv6Support(v strin
return s
}
-// Options for a network interface-type endpoint.
+// Describes the network interface options when creating an Amazon Web Services
+// Verified Access endpoint using the network-interface type.
type CreateVerifiedAccessEndpointEniOptions struct {
_ struct{} `type:"structure"`
@@ -77103,7 +77148,7 @@ type CreateVerifiedAccessEndpointInput struct {
// ApplicationDomain is a required field
ApplicationDomain *string `type:"string" required:"true"`
- // The Amazon Web Services network component Verified Access attaches to.
+ // The type of attachment.
//
// AttachmentType is a required field
AttachmentType *string `type:"string" required:"true" enum:"VerifiedAccessEndpointAttachmentType"`
@@ -77113,7 +77158,7 @@ type CreateVerifiedAccessEndpointInput struct {
// (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html).
ClientToken *string `type:"string" idempotencyToken:"true"`
- // A description for the Amazon Web Services Verified Access endpoint.
+ // A description for the Verified Access endpoint.
Description *string `type:"string"`
// The ARN of the public TLS/SSL certificate in Amazon Web Services Certificate
@@ -77129,33 +77174,32 @@ type CreateVerifiedAccessEndpointInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // A custom identifier that gets prepended to a DNS name that is generated for
+ // A custom identifier that is prepended to the DNS name that is generated for
// the endpoint.
//
// EndpointDomainPrefix is a required field
EndpointDomainPrefix *string `type:"string" required:"true"`
- // The type of Amazon Web Services Verified Access endpoint to create.
+ // The type of Verified Access endpoint to create.
//
// EndpointType is a required field
EndpointType *string `type:"string" required:"true" enum:"VerifiedAccessEndpointType"`
- // The load balancer details if creating the Amazon Web Services Verified Access
- // endpoint as load-balancertype.
+ // The load balancer details. This parameter is required if the endpoint type
+ // is load-balancer.
LoadBalancerOptions *CreateVerifiedAccessEndpointLoadBalancerOptions `type:"structure"`
- // The network interface details if creating the Amazon Web Services Verified
- // Access endpoint as network-interfacetype.
+ // The network interface details. This parameter is required if the endpoint
+ // type is network-interface.
NetworkInterfaceOptions *CreateVerifiedAccessEndpointEniOptions `type:"structure"`
- // The Amazon Web Services Verified Access policy document.
+ // The Verified Access policy document.
PolicyDocument *string `type:"string"`
- // The Amazon EC2 security groups to associate with the Amazon Web Services
- // Verified Access endpoint.
+ // The IDs of the security groups to associate with the Verified Access endpoint.
SecurityGroupIds []*string `locationName:"SecurityGroupId" locationNameList:"item" type:"list"`
- // The tags to assign to the Amazon Web Services Verified Access endpoint.
+ // The tags to assign to the Verified Access endpoint.
TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"`
// The ID of the Verified Access group to associate the endpoint with.
@@ -77304,8 +77348,8 @@ func (s *CreateVerifiedAccessEndpointInput) SetVerifiedAccessGroupId(v string) *
return s
}
-// Describes a load balancer when creating an Amazon Web Services Verified Access
-// endpoint using the load-balancer type.
+// Describes the load balancer options when creating an Amazon Web Services
+// Verified Access endpoint using the load-balancer type.
type CreateVerifiedAccessEndpointLoadBalancerOptions struct {
_ struct{} `type:"structure"`
@@ -77380,7 +77424,7 @@ func (s *CreateVerifiedAccessEndpointLoadBalancerOptions) SetSubnetIds(v []*stri
type CreateVerifiedAccessEndpointOutput struct {
_ struct{} `type:"structure"`
- // The ID of the Amazon Web Services Verified Access endpoint.
+ // The ID of the Verified Access endpoint.
VerifiedAccessEndpoint *VerifiedAccessEndpoint `locationName:"verifiedAccessEndpoint" type:"structure"`
}
@@ -77416,7 +77460,7 @@ type CreateVerifiedAccessGroupInput struct {
// (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html).
ClientToken *string `type:"string" idempotencyToken:"true"`
- // A description for the Amazon Web Services Verified Access group.
+ // A description for the Verified Access group.
Description *string `type:"string"`
// Checks whether you have the required permissions for the action, without
@@ -77425,13 +77469,13 @@ type CreateVerifiedAccessGroupInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The Amazon Web Services Verified Access policy document.
+ // The Verified Access policy document.
PolicyDocument *string `type:"string"`
- // The tags to assign to the Amazon Web Services Verified Access group.
+ // The tags to assign to the Verified Access group.
TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
//
// VerifiedAccessInstanceId is a required field
VerifiedAccessInstanceId *string `type:"string" required:"true"`
@@ -77543,7 +77587,7 @@ type CreateVerifiedAccessInstanceInput struct {
// (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html).
ClientToken *string `type:"string" idempotencyToken:"true"`
- // A description for the Amazon Web Services Verified Access instance.
+ // A description for the Verified Access instance.
Description *string `type:"string"`
// Checks whether you have the required permissions for the action, without
@@ -77552,7 +77596,7 @@ type CreateVerifiedAccessInstanceInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The tags to assign to the Amazon Web Services Verified Access instance.
+ // The tags to assign to the Verified Access instance.
TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"`
}
@@ -77601,7 +77645,7 @@ func (s *CreateVerifiedAccessInstanceInput) SetTagSpecifications(v []*TagSpecifi
type CreateVerifiedAccessInstanceOutput struct {
_ struct{} `type:"structure"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
VerifiedAccessInstance *VerifiedAccessInstance `locationName:"verifiedAccessInstance" type:"structure"`
}
@@ -77629,7 +77673,8 @@ func (s *CreateVerifiedAccessInstanceOutput) SetVerifiedAccessInstance(v *Verifi
return s
}
-// Options for a device-identity type trust provider.
+// Describes the options when creating an Amazon Web Services Verified Access
+// trust provider using the device type.
type CreateVerifiedAccessTrustProviderDeviceOptions struct {
_ struct{} `type:"structure"`
@@ -77669,13 +77714,15 @@ type CreateVerifiedAccessTrustProviderInput struct {
// (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html).
ClientToken *string `type:"string" idempotencyToken:"true"`
- // A description for the Amazon Web Services Verified Access trust provider.
+ // A description for the Verified Access trust provider.
Description *string `type:"string"`
- // The options for device identity based trust providers.
+ // The options for a device-based trust provider. This parameter is required
+ // when the provider type is device.
DeviceOptions *CreateVerifiedAccessTrustProviderDeviceOptions `type:"structure"`
- // The type of device-based trust provider.
+ // The type of device-based trust provider. This parameter is required when
+ // the provider type is device.
DeviceTrustProviderType *string `type:"string" enum:"DeviceTrustProviderType"`
// Checks whether you have the required permissions for the action, without
@@ -77684,7 +77731,8 @@ type CreateVerifiedAccessTrustProviderInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The OpenID Connect details for an oidc-type, user-identity based trust provider.
+ // The options for a OpenID Connect-compatible user-identity trust provider.
+ // This parameter is required when the provider type is user.
OidcOptions *CreateVerifiedAccessTrustProviderOidcOptions `type:"structure"`
// The identifier to be used when working with policy rules.
@@ -77692,15 +77740,16 @@ type CreateVerifiedAccessTrustProviderInput struct {
// PolicyReferenceName is a required field
PolicyReferenceName *string `type:"string" required:"true"`
- // The tags to assign to the Amazon Web Services Verified Access trust provider.
+ // The tags to assign to the Verified Access trust provider.
TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"`
- // The type of trust provider can be either user or device-based.
+ // The type of trust provider.
//
// TrustProviderType is a required field
TrustProviderType *string `type:"string" required:"true" enum:"TrustProviderType"`
- // The type of user-based trust provider.
+ // The type of user-based trust provider. This parameter is required when the
+ // provider type is user.
UserTrustProviderType *string `type:"string" enum:"UserTrustProviderType"`
}
@@ -77798,7 +77847,8 @@ func (s *CreateVerifiedAccessTrustProviderInput) SetUserTrustProviderType(v stri
return s
}
-// Options for an OIDC-based, user-identity type trust provider.
+// Describes the options when creating an Amazon Web Services Verified Access
+// trust provider using the user type.
type CreateVerifiedAccessTrustProviderOidcOptions struct {
_ struct{} `type:"structure"`
@@ -77809,7 +77859,11 @@ type CreateVerifiedAccessTrustProviderOidcOptions struct {
ClientId *string `type:"string"`
// The client secret.
- ClientSecret *string `type:"string"`
+ //
+ // ClientSecret is a sensitive parameter and its value will be
+ // replaced with "sensitive" in string returned by CreateVerifiedAccessTrustProviderOidcOptions's
+ // String and GoString methods.
+ ClientSecret *string `type:"string" sensitive:"true"`
// The OIDC issuer.
Issuer *string `type:"string"`
@@ -77889,7 +77943,7 @@ func (s *CreateVerifiedAccessTrustProviderOidcOptions) SetUserInfoEndpoint(v str
type CreateVerifiedAccessTrustProviderOutput struct {
_ struct{} `type:"structure"`
- // The ID of the Amazon Web Services Verified Access trust provider.
+ // The ID of the Verified Access trust provider.
VerifiedAccessTrustProvider *VerifiedAccessTrustProvider `locationName:"verifiedAccessTrustProvider" type:"structure"`
}
@@ -85553,7 +85607,7 @@ type DeleteVerifiedAccessEndpointInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The ID of the Amazon Web Services Verified Access endpoint.
+ // The ID of the Verified Access endpoint.
//
// VerifiedAccessEndpointId is a required field
VerifiedAccessEndpointId *string `type:"string" required:"true"`
@@ -85611,7 +85665,7 @@ func (s *DeleteVerifiedAccessEndpointInput) SetVerifiedAccessEndpointId(v string
type DeleteVerifiedAccessEndpointOutput struct {
_ struct{} `type:"structure"`
- // The ID of the Amazon Web Services Verified Access endpoint.
+ // The ID of the Verified Access endpoint.
VerifiedAccessEndpoint *VerifiedAccessEndpoint `locationName:"verifiedAccessEndpoint" type:"structure"`
}
@@ -85653,7 +85707,7 @@ type DeleteVerifiedAccessGroupInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The ID of the Amazon Web Services Verified Access group.
+ // The ID of the Verified Access group.
//
// VerifiedAccessGroupId is a required field
VerifiedAccessGroupId *string `type:"string" required:"true"`
@@ -85711,7 +85765,7 @@ func (s *DeleteVerifiedAccessGroupInput) SetVerifiedAccessGroupId(v string) *Del
type DeleteVerifiedAccessGroupOutput struct {
_ struct{} `type:"structure"`
- // The ID of the Amazon Web Services Verified Access group.
+ // The ID of the Verified Access group.
VerifiedAccessGroup *VerifiedAccessGroup `locationName:"verifiedAccessGroup" type:"structure"`
}
@@ -85753,7 +85807,7 @@ type DeleteVerifiedAccessInstanceInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
//
// VerifiedAccessInstanceId is a required field
VerifiedAccessInstanceId *string `type:"string" required:"true"`
@@ -85811,7 +85865,7 @@ func (s *DeleteVerifiedAccessInstanceInput) SetVerifiedAccessInstanceId(v string
type DeleteVerifiedAccessInstanceOutput struct {
_ struct{} `type:"structure"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
VerifiedAccessInstance *VerifiedAccessInstance `locationName:"verifiedAccessInstance" type:"structure"`
}
@@ -85853,7 +85907,7 @@ type DeleteVerifiedAccessTrustProviderInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The ID of the Amazon Web Services Verified Access trust provider.
+ // The ID of the Verified Access trust provider.
//
// VerifiedAccessTrustProviderId is a required field
VerifiedAccessTrustProviderId *string `type:"string" required:"true"`
@@ -85911,7 +85965,7 @@ func (s *DeleteVerifiedAccessTrustProviderInput) SetVerifiedAccessTrustProviderI
type DeleteVerifiedAccessTrustProviderOutput struct {
_ struct{} `type:"structure"`
- // The ID of the Amazon Web Services Verified Access trust provider.
+ // The ID of the Verified Access trust provider.
VerifiedAccessTrustProvider *VerifiedAccessTrustProvider `locationName:"verifiedAccessTrustProvider" type:"structure"`
}
@@ -87094,7 +87148,9 @@ type DeregisterInstanceEventNotificationAttributesInput struct {
DryRun *bool `type:"boolean"`
// Information about the tag keys to deregister.
- InstanceTagAttribute *DeregisterInstanceTagAttributeRequest `type:"structure"`
+ //
+ // InstanceTagAttribute is a required field
+ InstanceTagAttribute *DeregisterInstanceTagAttributeRequest `type:"structure" required:"true"`
}
// String returns the string representation.
@@ -87115,6 +87171,19 @@ func (s DeregisterInstanceEventNotificationAttributesInput) GoString() string {
return s.String()
}
+// Validate inspects the fields of the type to determine if they are valid.
+func (s *DeregisterInstanceEventNotificationAttributesInput) Validate() error {
+ invalidParams := request.ErrInvalidParams{Context: "DeregisterInstanceEventNotificationAttributesInput"}
+ if s.InstanceTagAttribute == nil {
+ invalidParams.Add(request.NewErrParamRequired("InstanceTagAttribute"))
+ }
+
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ }
+ return nil
+}
+
// SetDryRun sets the DryRun field's value.
func (s *DeregisterInstanceEventNotificationAttributesInput) SetDryRun(v bool) *DeregisterInstanceEventNotificationAttributesInput {
s.DryRun = &v
@@ -94400,8 +94469,8 @@ type DescribeInstanceTypesInput struct {
// One or more filters. Filter names and values are case-sensitive.
//
- // * auto-recovery-supported - Indicates whether auto recovery is supported
- // (true | false).
+ // * auto-recovery-supported - Indicates whether Amazon CloudWatch action
+ // based recovery is supported (true | false).
//
// * bare-metal - Indicates whether it is a bare metal instance type (true
// | false).
@@ -94690,12 +94759,6 @@ type DescribeInstancesInput struct {
//
// * dns-name - The public DNS name of the instance.
//
- // * group-id - The ID of the security group for the instance. EC2-Classic
- // only.
- //
- // * group-name - The name of the security group for the instance. EC2-Classic
- // only.
- //
// * hibernation-options.configured - A Boolean that indicates whether the
// instance is enabled for hibernation. A value of true means that the instance
// is enabled for hibernation.
@@ -99700,16 +99763,11 @@ type DescribeReservedInstancesInput struct {
//
// * scope - The scope of the Reserved Instance (Region or Availability Zone).
//
- // * product-description - The Reserved Instance product platform description.
- // Instances that include (Amazon VPC) in the product platform description
- // will only be displayed to EC2-Classic account holders and are for use
- // with Amazon VPC (Linux/UNIX | Linux/UNIX (Amazon VPC) | SUSE Linux | SUSE
- // Linux (Amazon VPC) | Red Hat Enterprise Linux | Red Hat Enterprise Linux
- // (Amazon VPC) | Red Hat Enterprise Linux with HA (Amazon VPC) | Windows
- // | Windows (Amazon VPC) | Windows with SQL Server Standard | Windows with
- // SQL Server Standard (Amazon VPC) | Windows with SQL Server Web | Windows
- // with SQL Server Web (Amazon VPC) | Windows with SQL Server Enterprise
- // | Windows with SQL Server Enterprise (Amazon VPC)).
+ // * product-description - The Reserved Instance product platform description
+ // (Linux/UNIX | Linux with SQL Server Standard | Linux with SQL Server Web
+ // | Linux with SQL Server Enterprise | SUSE Linux | Red Hat Enterprise Linux
+ // | Red Hat Enterprise Linux with HA | Windows | Windows with SQL Server
+ // Standard | Windows with SQL Server Web | Windows with SQL Server Enterprise).
//
// * reserved-instances-id - The ID of the Reserved Instance.
//
@@ -99911,9 +99969,6 @@ type DescribeReservedInstancesModificationsInput struct {
// * modification-result.target-configuration.instance-type - The instance
// type of the new Reserved Instances.
//
- // * modification-result.target-configuration.platform - The network platform
- // of the new Reserved Instances (EC2-Classic | EC2-VPC).
- //
// * reserved-instances-id - The ID of the Reserved Instances modified.
//
// * reserved-instances-modification-id - The ID of the modification request.
@@ -100042,16 +100097,11 @@ type DescribeReservedInstancesOfferingsInput struct {
// all offerings from both Amazon Web Services and the Reserved Instance
// Marketplace are listed.
//
- // * product-description - The Reserved Instance product platform description.
- // Instances that include (Amazon VPC) in the product platform description
- // will only be displayed to EC2-Classic account holders and are for use
- // with Amazon VPC. (Linux/UNIX | Linux/UNIX (Amazon VPC) | SUSE Linux |
- // SUSE Linux (Amazon VPC) | Red Hat Enterprise Linux | Red Hat Enterprise
- // Linux (Amazon VPC) | Red Hat Enterprise Linux with HA (Amazon VPC) | Windows
- // | Windows (Amazon VPC) | Windows with SQL Server Standard | Windows with
- // SQL Server Standard (Amazon VPC) | Windows with SQL Server Web | Windows
- // with SQL Server Web (Amazon VPC) | Windows with SQL Server Enterprise
- // | Windows with SQL Server Enterprise (Amazon VPC))
+ // * product-description - The Reserved Instance product platform description
+ // (Linux/UNIX | Linux with SQL Server Standard | Linux with SQL Server Web
+ // | Linux with SQL Server Enterprise | SUSE Linux | Red Hat Enterprise Linux
+ // | Red Hat Enterprise Linux with HA | Windows | Windows with SQL Server
+ // Standard | Windows with SQL Server Web | Windows with SQL Server Enterprise).
//
// * reserved-instances-offering-id - The Reserved Instances offering ID.
//
@@ -100512,8 +100562,6 @@ type DescribeScheduledInstanceAvailabilityInput struct {
//
// * instance-type - The instance type (for example, c4.large).
//
- // * network-platform - The network platform (EC2-Classic or EC2-VPC).
- //
// * platform - The platform (Linux/UNIX or Windows).
Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"`
@@ -100694,8 +100742,6 @@ type DescribeScheduledInstancesInput struct {
//
// * instance-type - The instance type (for example, c4.large).
//
- // * network-platform - The network platform (EC2-Classic or EC2-VPC).
- //
// * platform - The platform (Linux/UNIX or Windows).
Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"`
@@ -102167,7 +102213,7 @@ type DescribeSpotInstanceRequestsInput struct {
// it is UnauthorizedOperation.
DryRun *bool `locationName:"dryRun" type:"boolean"`
- // One or more filters.
+ // The filters.
//
// * availability-zone-group - The Availability Zone group.
//
@@ -102284,7 +102330,7 @@ type DescribeSpotInstanceRequestsInput struct {
// from the end of the items returned by the previous request.
NextToken *string `type:"string"`
- // One or more Spot Instance request IDs.
+ // The IDs of the Spot Instance requests.
SpotInstanceRequestIds []*string `locationName:"SpotInstanceRequestId" locationNameList:"SpotInstanceRequestId" type:"list"`
}
@@ -102344,7 +102390,7 @@ type DescribeSpotInstanceRequestsOutput struct {
// value is null when there are no more items to return.
NextToken *string `locationName:"nextToken" type:"string"`
- // One or more Spot Instance requests.
+ // The Spot Instance requests.
SpotInstanceRequests []*SpotInstanceRequest `locationName:"spotInstanceRequestSet" locationNameList:"item" type:"list"`
}
@@ -102395,7 +102441,7 @@ type DescribeSpotPriceHistoryInput struct {
// the price history data, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ).
EndTime *time.Time `locationName:"endTime" type:"timestamp"`
- // One or more filters.
+ // The filters.
//
// * availability-zone - The Availability Zone for which prices should be
// returned.
@@ -105087,13 +105133,13 @@ type DescribeVerifiedAccessEndpointsInput struct {
// The token for the next page of results.
NextToken *string `type:"string"`
- // The ID of the Amazon Web Services Verified Access endpoint.
+ // The ID of the Verified Access endpoint.
VerifiedAccessEndpointIds []*string `locationName:"VerifiedAccessEndpointId" locationNameList:"item" type:"list"`
- // The ID of the Amazon Web Services Verified Access group.
+ // The ID of the Verified Access group.
VerifiedAccessGroupId *string `type:"string"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
VerifiedAccessInstanceId *string `type:"string"`
}
@@ -105177,7 +105223,7 @@ type DescribeVerifiedAccessEndpointsOutput struct {
// when there are no more results to return.
NextToken *string `locationName:"nextToken" type:"string"`
- // The ID of the Amazon Web Services Verified Access endpoint.
+ // The ID of the Verified Access endpoint.
VerifiedAccessEndpoints []*VerifiedAccessEndpoint `locationName:"verifiedAccessEndpointSet" locationNameList:"item" type:"list"`
}
@@ -105230,10 +105276,10 @@ type DescribeVerifiedAccessGroupsInput struct {
// The token for the next page of results.
NextToken *string `type:"string"`
- // The ID of the Amazon Web Services Verified Access groups.
+ // The ID of the Verified Access groups.
VerifiedAccessGroupIds []*string `locationName:"VerifiedAccessGroupId" locationNameList:"item" type:"list"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
VerifiedAccessInstanceId *string `type:"string"`
}
@@ -105364,7 +105410,7 @@ type DescribeVerifiedAccessInstanceLoggingConfigurationsInput struct {
// The token for the next page of results.
NextToken *string `type:"string"`
- // The IDs of the Amazon Web Services Verified Access instances.
+ // The IDs of the Verified Access instances.
VerifiedAccessInstanceIds []*string `locationName:"VerifiedAccessInstanceId" locationNameList:"item" type:"list"`
}
@@ -105432,8 +105478,7 @@ func (s *DescribeVerifiedAccessInstanceLoggingConfigurationsInput) SetVerifiedAc
type DescribeVerifiedAccessInstanceLoggingConfigurationsOutput struct {
_ struct{} `type:"structure"`
- // The current logging configuration for the Amazon Web Services Verified Access
- // instances.
+ // The current logging configuration for the Verified Access instances.
LoggingConfigurations []*VerifiedAccessInstanceLoggingConfiguration `locationName:"loggingConfigurationSet" locationNameList:"item" type:"list"`
// The token to use to retrieve the next page of results. This value is null
@@ -105490,7 +105535,7 @@ type DescribeVerifiedAccessInstancesInput struct {
// The token for the next page of results.
NextToken *string `type:"string"`
- // The IDs of the Amazon Web Services Verified Access instances.
+ // The IDs of the Verified Access instances.
VerifiedAccessInstanceIds []*string `locationName:"VerifiedAccessInstanceId" locationNameList:"item" type:"list"`
}
@@ -105562,7 +105607,7 @@ type DescribeVerifiedAccessInstancesOutput struct {
// when there are no more results to return.
NextToken *string `locationName:"nextToken" type:"string"`
- // The IDs of the Amazon Web Services Verified Access instances.
+ // The IDs of the Verified Access instances.
VerifiedAccessInstances []*VerifiedAccessInstance `locationName:"verifiedAccessInstanceSet" locationNameList:"item" type:"list"`
}
@@ -105615,7 +105660,7 @@ type DescribeVerifiedAccessTrustProvidersInput struct {
// The token for the next page of results.
NextToken *string `type:"string"`
- // The IDs of the Amazon Web Services Verified Access trust providers.
+ // The IDs of the Verified Access trust providers.
VerifiedAccessTrustProviderIds []*string `locationName:"VerifiedAccessTrustProviderId" locationNameList:"item" type:"list"`
}
@@ -105687,7 +105732,7 @@ type DescribeVerifiedAccessTrustProvidersOutput struct {
// when there are no more results to return.
NextToken *string `locationName:"nextToken" type:"string"`
- // The IDs of the Amazon Web Services Verified Access trust providers.
+ // The IDs of the Verified Access trust providers.
VerifiedAccessTrustProviders []*VerifiedAccessTrustProvider `locationName:"verifiedAccessTrustProviderSet" locationNameList:"item" type:"list"`
}
@@ -108428,12 +108473,12 @@ type DetachVerifiedAccessTrustProviderInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
//
// VerifiedAccessInstanceId is a required field
VerifiedAccessInstanceId *string `type:"string" required:"true"`
- // The ID of the Amazon Web Services Verified Access trust provider.
+ // The ID of the Verified Access trust provider.
//
// VerifiedAccessTrustProviderId is a required field
VerifiedAccessTrustProviderId *string `type:"string" required:"true"`
@@ -108500,10 +108545,10 @@ func (s *DetachVerifiedAccessTrustProviderInput) SetVerifiedAccessTrustProviderI
type DetachVerifiedAccessTrustProviderOutput struct {
_ struct{} `type:"structure"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
VerifiedAccessInstance *VerifiedAccessInstance `locationName:"verifiedAccessInstance" type:"structure"`
- // The ID of the Amazon Web Services Verified Access trust provider.
+ // The ID of the Verified Access trust provider.
VerifiedAccessTrustProvider *VerifiedAccessTrustProvider `locationName:"verifiedAccessTrustProvider" type:"structure"`
}
@@ -108724,8 +108769,8 @@ func (s DetachVpnGatewayOutput) GoString() string {
return s.String()
}
-// Options for an Amazon Web Services Verified Access device-identity based
-// trust provider.
+// Describes the options for an Amazon Web Services Verified Access device-identity
+// based trust provider.
type DeviceOptions struct {
_ struct{} `type:"structure"`
@@ -111789,7 +111834,11 @@ type DiskImageDescription struct {
//
// For information about the import manifest referenced by this API action,
// see VM Import Manifest (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/manifest.html).
- ImportManifestUrl *string `locationName:"importManifestUrl" type:"string"`
+ //
+ // ImportManifestUrl is a sensitive parameter and its value will be
+ // replaced with "sensitive" in string returned by DiskImageDescription's
+ // String and GoString methods.
+ ImportManifestUrl *string `locationName:"importManifestUrl" type:"string" sensitive:"true"`
// The size of the disk image, in GiB.
Size *int64 `locationName:"size" type:"long"`
@@ -123716,7 +123765,7 @@ type GetVerifiedAccessEndpointPolicyInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The ID of the Amazon Web Services Verified Access endpoint.
+ // The ID of the Verified Access endpoint.
//
// VerifiedAccessEndpointId is a required field
VerifiedAccessEndpointId *string `type:"string" required:"true"`
@@ -123768,7 +123817,7 @@ func (s *GetVerifiedAccessEndpointPolicyInput) SetVerifiedAccessEndpointId(v str
type GetVerifiedAccessEndpointPolicyOutput struct {
_ struct{} `type:"structure"`
- // The Amazon Web Services Verified Access policy document.
+ // The Verified Access policy document.
PolicyDocument *string `locationName:"policyDocument" type:"string"`
// The status of the Verified Access policy.
@@ -123814,7 +123863,7 @@ type GetVerifiedAccessGroupPolicyInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The ID of the Amazon Web Services Verified Access group.
+ // The ID of the Verified Access group.
//
// VerifiedAccessGroupId is a required field
VerifiedAccessGroupId *string `type:"string" required:"true"`
@@ -123866,7 +123915,7 @@ func (s *GetVerifiedAccessGroupPolicyInput) SetVerifiedAccessGroupId(v string) *
type GetVerifiedAccessGroupPolicyOutput struct {
_ struct{} `type:"structure"`
- // The Amazon Web Services Verified Access policy document.
+ // The Verified Access policy document.
PolicyDocument *string `locationName:"policyDocument" type:"string"`
// The status of the Verified Access policy.
@@ -125853,7 +125902,11 @@ type ImageDiskContainer struct {
// The URL to the Amazon S3-based disk image being imported. The URL can either
// be a https URL (https://..) or an Amazon S3 URL (s3://..)
- Url *string `type:"string"`
+ //
+ // Url is a sensitive parameter and its value will be
+ // replaced with "sensitive" in string returned by ImageDiskContainer's
+ // String and GoString methods.
+ Url *string `type:"string" sensitive:"true"`
// The S3 bucket for the disk image.
UserBucket *UserBucket `type:"structure"`
@@ -127913,7 +127966,7 @@ type Instance struct {
// The monitoring for the instance.
Monitoring *Monitoring `locationName:"monitoring" type:"structure"`
- // [EC2-VPC] The network interfaces for the instance.
+ // The network interfaces for the instance.
NetworkInterfaces []*InstanceNetworkInterface `locationName:"networkInterfaceSet" locationNameList:"item" type:"list"`
// The Amazon Resource Name (ARN) of the Outpost.
@@ -127930,14 +127983,14 @@ type Instance struct {
// in the Amazon EC2 User Guide.
PlatformDetails *string `locationName:"platformDetails" type:"string"`
- // (IPv4 only) The private DNS hostname name assigned to the instance. This
+ // [IPv4 only] The private DNS hostname name assigned to the instance. This
// DNS hostname can only be used inside the Amazon EC2 network. This name is
// not available until the instance enters the running state.
//
- // [EC2-VPC] The Amazon-provided DNS server resolves Amazon-provided private
- // DNS hostnames if you've enabled DNS resolution and DNS hostnames in your
- // VPC. If you are not using the Amazon-provided DNS server in your VPC, your
- // custom domain name servers must resolve the hostname as appropriate.
+ // The Amazon-provided DNS server resolves Amazon-provided private DNS hostnames
+ // if you've enabled DNS resolution and DNS hostnames in your VPC. If you are
+ // not using the Amazon-provided DNS server in your VPC, your custom domain
+ // name servers must resolve the hostname as appropriate.
PrivateDnsName *string `locationName:"privateDnsName" type:"string"`
// The options for the instance hostname.
@@ -127949,9 +128002,9 @@ type Instance struct {
// The product codes attached to this instance, if applicable.
ProductCodes []*ProductCode `locationName:"productCodes" locationNameList:"item" type:"list"`
- // (IPv4 only) The public DNS name assigned to the instance. This name is not
- // available until the instance enters the running state. For EC2-VPC, this
- // name is only available if you've enabled DNS hostnames for your VPC.
+ // [IPv4 only] The public DNS name assigned to the instance. This name is not
+ // available until the instance enters the running state. This name is only
+ // available if you've enabled DNS hostnames for your VPC.
PublicDnsName *string `locationName:"dnsName" type:"string"`
// The public IPv4 address, or the Carrier IP address assigned to the instance,
@@ -127993,7 +128046,7 @@ type Instance struct {
// The reason for the most recent state transition. This might be an empty string.
StateTransitionReason *string `locationName:"reason" type:"string"`
- // [EC2-VPC] The ID of the subnet in which the instance is running.
+ // The ID of the subnet in which the instance is running.
SubnetId *string `locationName:"subnetId" type:"string"`
// Any tags assigned to the instance.
@@ -128015,7 +128068,7 @@ type Instance struct {
// The virtualization type of the instance.
VirtualizationType *string `locationName:"virtualizationType" type:"string" enum:"VirtualizationType"`
- // [EC2-VPC] The ID of the VPC in which the instance is running.
+ // The ID of the VPC in which the instance is running.
VpcId *string `locationName:"vpcId" type:"string"`
}
@@ -131808,7 +131861,7 @@ func (s *InstanceTagNotificationAttribute) SetInstanceTagKeys(v []*string) *Inst
type InstanceTypeInfo struct {
_ struct{} `type:"structure"`
- // Indicates whether auto recovery is supported.
+ // Indicates whether Amazon CloudWatch action based recovery is supported.
AutoRecoverySupported *bool `locationName:"autoRecoverySupported" type:"boolean"`
// Indicates whether the instance is a bare metal instance type.
@@ -134884,7 +134937,7 @@ type LaunchSpecification struct {
// Deprecated.
AddressingType *string `locationName:"addressingType" type:"string"`
- // One or more block device mapping entries.
+ // The block device mapping entries.
BlockDeviceMappings []*BlockDeviceMapping `locationName:"blockDeviceMapping" locationNameList:"item" type:"list"`
// Indicates whether the instance is optimized for EBS I/O. This optimization
@@ -134914,8 +134967,8 @@ type LaunchSpecification struct {
// Describes the monitoring of an instance.
Monitoring *RunInstancesMonitoringEnabled `locationName:"monitoring" type:"structure"`
- // One or more network interfaces. If you specify a network interface, you must
- // specify subnet IDs and security group IDs using the network interface.
+ // The network interfaces. If you specify a network interface, you must specify
+ // subnet IDs and security group IDs using the network interface.
NetworkInterfaces []*InstanceNetworkInterfaceSpecification `locationName:"networkInterfaceSet" locationNameList:"item" type:"list"`
// The placement information for the instance.
@@ -134924,9 +134977,7 @@ type LaunchSpecification struct {
// The ID of the RAM disk.
RamdiskId *string `locationName:"ramdiskId" type:"string"`
- // One or more security groups. When requesting instances in a VPC, you must
- // specify the IDs of the security groups. When requesting instances in EC2-Classic,
- // you can specify the names or the IDs of the security groups.
+ // The IDs of the security groups.
SecurityGroups []*GroupIdentifier `locationName:"groupSet" locationNameList:"item" type:"list"`
// The ID of the subnet in which to launch the instance.
@@ -135464,6 +135515,9 @@ func (s *LaunchTemplateConfig) SetOverrides(v []*LaunchTemplateOverrides) *Launc
type LaunchTemplateCpuOptions struct {
_ struct{} `type:"structure"`
+ // Indicates whether the instance is enabled for AMD SEV-SNP.
+ AmdSevSnp *string `locationName:"amdSevSnp" type:"string" enum:"AmdSevSnpSpecification"`
+
// The number of CPU cores for the instance.
CoreCount *int64 `locationName:"coreCount" type:"integer"`
@@ -135489,6 +135543,12 @@ func (s LaunchTemplateCpuOptions) GoString() string {
return s.String()
}
+// SetAmdSevSnp sets the AmdSevSnp field's value.
+func (s *LaunchTemplateCpuOptions) SetAmdSevSnp(v string) *LaunchTemplateCpuOptions {
+ s.AmdSevSnp = &v
+ return s
+}
+
// SetCoreCount sets the CoreCount field's value.
func (s *LaunchTemplateCpuOptions) SetCoreCount(v int64) *LaunchTemplateCpuOptions {
s.CoreCount = &v
@@ -135506,6 +135566,10 @@ func (s *LaunchTemplateCpuOptions) SetThreadsPerCore(v int64) *LaunchTemplateCpu
type LaunchTemplateCpuOptionsRequest struct {
_ struct{} `type:"structure"`
+ // Indicates whether to enable the instance for AMD SEV-SNP. AMD SEV-SNP is
+ // supported with M6a, R6a, and C6a instance types only.
+ AmdSevSnp *string `type:"string" enum:"AmdSevSnpSpecification"`
+
// The number of CPU cores for the instance.
CoreCount *int64 `type:"integer"`
@@ -135532,6 +135596,12 @@ func (s LaunchTemplateCpuOptionsRequest) GoString() string {
return s.String()
}
+// SetAmdSevSnp sets the AmdSevSnp field's value.
+func (s *LaunchTemplateCpuOptionsRequest) SetAmdSevSnp(v string) *LaunchTemplateCpuOptionsRequest {
+ s.AmdSevSnp = &v
+ return s
+}
+
// SetCoreCount sets the CoreCount field's value.
func (s *LaunchTemplateCpuOptionsRequest) SetCoreCount(v int64) *LaunchTemplateCpuOptionsRequest {
s.CoreCount = &v
@@ -137075,8 +137145,8 @@ type LaunchTemplatePlacement struct {
// Reserved for future use.
SpreadDomain *string `locationName:"spreadDomain" type:"string"`
- // The tenancy of the instance (if the instance is running in a VPC). An instance
- // with a tenancy of dedicated runs on single-tenant hardware.
+ // The tenancy of the instance. An instance with a tenancy of dedicated runs
+ // on single-tenant hardware.
Tenancy *string `locationName:"tenancy" type:"string" enum:"Tenancy"`
}
@@ -137184,8 +137254,8 @@ type LaunchTemplatePlacementRequest struct {
// Reserved for future use.
SpreadDomain *string `type:"string"`
- // The tenancy of the instance (if the instance is running in a VPC). An instance
- // with a tenancy of dedicated runs on single-tenant hardware.
+ // The tenancy of the instance. An instance with a tenancy of dedicated runs
+ // on single-tenant hardware.
Tenancy *string `type:"string" enum:"Tenancy"`
}
@@ -141270,10 +141340,9 @@ type ModifyInstanceAttributeInput struct {
// a PV instance can make it unreachable.
EnaSupport *AttributeBooleanValue `locationName:"enaSupport" type:"structure"`
- // [EC2-VPC] Replaces the security groups of the instance with the specified
- // security groups. You must specify at least one security group, even if it's
- // just the default security group for the VPC. You must specify the security
- // group ID, not the security group name.
+ // Replaces the security groups of the instance with the specified security
+ // groups. You must specify the ID of at least one security group, even if it's
+ // just the default security group for the VPC.
Groups []*string `locationName:"GroupId" locationNameList:"groupId" type:"list"`
// The ID of the instance.
@@ -145484,7 +145553,8 @@ func (s *ModifyTransitGatewayVpcAttachmentRequestOptions) SetIpv6Support(v strin
return s
}
-// Options for a network-interface type Verified Access endpoint.
+// Describes the options when modifying a Verified Access endpoint with the
+// network-interface type.
type ModifyVerifiedAccessEndpointEniOptions struct {
_ struct{} `type:"structure"`
@@ -145546,7 +145616,7 @@ type ModifyVerifiedAccessEndpointInput struct {
// (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html).
ClientToken *string `type:"string" idempotencyToken:"true"`
- // A description for the Amazon Web Services Verified Access endpoint.
+ // A description for the Verified Access endpoint.
Description *string `type:"string"`
// Checks whether you have the required permissions for the action, without
@@ -145555,19 +145625,18 @@ type ModifyVerifiedAccessEndpointInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The load balancer details if creating the Amazon Web Services Verified Access
- // endpoint as load-balancertype.
+ // The load balancer details if creating the Verified Access endpoint as load-balancertype.
LoadBalancerOptions *ModifyVerifiedAccessEndpointLoadBalancerOptions `type:"structure"`
// The network interface options.
NetworkInterfaceOptions *ModifyVerifiedAccessEndpointEniOptions `type:"structure"`
- // The ID of the Amazon Web Services Verified Access endpoint.
+ // The ID of the Verified Access endpoint.
//
// VerifiedAccessEndpointId is a required field
VerifiedAccessEndpointId *string `type:"string" required:"true"`
- // The ID of the Amazon Web Services Verified Access group.
+ // The ID of the Verified Access group.
VerifiedAccessGroupId *string `type:"string"`
}
@@ -145721,7 +145790,7 @@ func (s *ModifyVerifiedAccessEndpointLoadBalancerOptions) SetSubnetIds(v []*stri
type ModifyVerifiedAccessEndpointOutput struct {
_ struct{} `type:"structure"`
- // The Amazon Web Services Verified Access endpoint details.
+ // The Verified Access endpoint details.
VerifiedAccessEndpoint *VerifiedAccessEndpoint `locationName:"verifiedAccessEndpoint" type:"structure"`
}
@@ -145763,7 +145832,7 @@ type ModifyVerifiedAccessEndpointPolicyInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The Amazon Web Services Verified Access policy document.
+ // The Verified Access policy document.
PolicyDocument *string `type:"string"`
// The status of the Verified Access policy.
@@ -145771,7 +145840,7 @@ type ModifyVerifiedAccessEndpointPolicyInput struct {
// PolicyEnabled is a required field
PolicyEnabled *bool `type:"boolean" required:"true"`
- // The ID of the Amazon Web Services Verified Access endpoint.
+ // The ID of the Verified Access endpoint.
//
// VerifiedAccessEndpointId is a required field
VerifiedAccessEndpointId *string `type:"string" required:"true"`
@@ -145844,7 +145913,7 @@ func (s *ModifyVerifiedAccessEndpointPolicyInput) SetVerifiedAccessEndpointId(v
type ModifyVerifiedAccessEndpointPolicyOutput struct {
_ struct{} `type:"structure"`
- // The Amazon Web Services Verified Access policy document.
+ // The Verified Access policy document.
PolicyDocument *string `locationName:"policyDocument" type:"string"`
// The status of the Verified Access policy.
@@ -145889,7 +145958,7 @@ type ModifyVerifiedAccessGroupInput struct {
// (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html).
ClientToken *string `type:"string" idempotencyToken:"true"`
- // A description for the Amazon Web Services Verified Access group.
+ // A description for the Verified Access group.
Description *string `type:"string"`
// Checks whether you have the required permissions for the action, without
@@ -145898,12 +145967,12 @@ type ModifyVerifiedAccessGroupInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The ID of the Amazon Web Services Verified Access group.
+ // The ID of the Verified Access group.
//
// VerifiedAccessGroupId is a required field
VerifiedAccessGroupId *string `type:"string" required:"true"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
VerifiedAccessInstanceId *string `type:"string"`
}
@@ -145971,7 +146040,7 @@ func (s *ModifyVerifiedAccessGroupInput) SetVerifiedAccessInstanceId(v string) *
type ModifyVerifiedAccessGroupOutput struct {
_ struct{} `type:"structure"`
- // Details of Amazon Web Services Verified Access group.
+ // Details of Verified Access group.
VerifiedAccessGroup *VerifiedAccessGroup `locationName:"verifiedAccessGroup" type:"structure"`
}
@@ -146013,7 +146082,7 @@ type ModifyVerifiedAccessGroupPolicyInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The Amazon Web Services Verified Access policy document.
+ // The Verified Access policy document.
PolicyDocument *string `type:"string"`
// The status of the Verified Access policy.
@@ -146021,7 +146090,7 @@ type ModifyVerifiedAccessGroupPolicyInput struct {
// PolicyEnabled is a required field
PolicyEnabled *bool `type:"boolean" required:"true"`
- // The ID of the Amazon Web Services Verified Access group.
+ // The ID of the Verified Access group.
//
// VerifiedAccessGroupId is a required field
VerifiedAccessGroupId *string `type:"string" required:"true"`
@@ -146094,7 +146163,7 @@ func (s *ModifyVerifiedAccessGroupPolicyInput) SetVerifiedAccessGroupId(v string
type ModifyVerifiedAccessGroupPolicyOutput struct {
_ struct{} `type:"structure"`
- // The Amazon Web Services Verified Access policy document.
+ // The Verified Access policy document.
PolicyDocument *string `locationName:"policyDocument" type:"string"`
// The status of the Verified Access policy.
@@ -146139,7 +146208,7 @@ type ModifyVerifiedAccessInstanceInput struct {
// (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html).
ClientToken *string `type:"string" idempotencyToken:"true"`
- // A description for the Amazon Web Services Verified Access instance.
+ // A description for the Verified Access instance.
Description *string `type:"string"`
// Checks whether you have the required permissions for the action, without
@@ -146148,7 +146217,7 @@ type ModifyVerifiedAccessInstanceInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
//
// VerifiedAccessInstanceId is a required field
VerifiedAccessInstanceId *string `type:"string" required:"true"`
@@ -146212,7 +146281,7 @@ func (s *ModifyVerifiedAccessInstanceInput) SetVerifiedAccessInstanceId(v string
type ModifyVerifiedAccessInstanceLoggingConfigurationInput struct {
_ struct{} `type:"structure"`
- // The configuration options for Amazon Web Services Verified Access instances.
+ // The configuration options for Verified Access instances.
//
// AccessLogs is a required field
AccessLogs *VerifiedAccessLogOptions `type:"structure" required:"true"`
@@ -146228,7 +146297,7 @@ type ModifyVerifiedAccessInstanceLoggingConfigurationInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
//
// VerifiedAccessInstanceId is a required field
VerifiedAccessInstanceId *string `type:"string" required:"true"`
@@ -146300,7 +146369,7 @@ func (s *ModifyVerifiedAccessInstanceLoggingConfigurationInput) SetVerifiedAcces
type ModifyVerifiedAccessInstanceLoggingConfigurationOutput struct {
_ struct{} `type:"structure"`
- // The logging configuration for Amazon Web Services Verified Access instance.
+ // The logging configuration for the Verified Access instance.
LoggingConfiguration *VerifiedAccessInstanceLoggingConfiguration `locationName:"loggingConfiguration" type:"structure"`
}
@@ -146331,7 +146400,7 @@ func (s *ModifyVerifiedAccessInstanceLoggingConfigurationOutput) SetLoggingConfi
type ModifyVerifiedAccessInstanceOutput struct {
_ struct{} `type:"structure"`
- // The ID of the Amazon Web Services Verified Access instance.
+ // The ID of the Verified Access instance.
VerifiedAccessInstance *VerifiedAccessInstance `locationName:"verifiedAccessInstance" type:"structure"`
}
@@ -146367,7 +146436,7 @@ type ModifyVerifiedAccessTrustProviderInput struct {
// (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html).
ClientToken *string `type:"string" idempotencyToken:"true"`
- // A description for the Amazon Web Services Verified Access trust provider.
+ // A description for the Verified Access trust provider.
Description *string `type:"string"`
// Checks whether you have the required permissions for the action, without
@@ -146376,10 +146445,10 @@ type ModifyVerifiedAccessTrustProviderInput struct {
// it is UnauthorizedOperation.
DryRun *bool `type:"boolean"`
- // The OpenID Connect details for an oidc-type, user-identity based trust provider.
+ // The options for an OpenID Connect-compatible user-identity trust provider.
OidcOptions *ModifyVerifiedAccessTrustProviderOidcOptions `type:"structure"`
- // The ID of the Amazon Web Services Verified Access trust provider.
+ // The ID of the Verified Access trust provider.
//
// VerifiedAccessTrustProviderId is a required field
VerifiedAccessTrustProviderId *string `type:"string" required:"true"`
@@ -146446,14 +146515,36 @@ func (s *ModifyVerifiedAccessTrustProviderInput) SetVerifiedAccessTrustProviderI
return s
}
-// OpenID Connect options for an oidc-type, user-identity based trust provider.
+// Options for an OpenID Connect-compatible user-identity trust provider.
type ModifyVerifiedAccessTrustProviderOidcOptions struct {
_ struct{} `type:"structure"`
+ // The OIDC authorization endpoint.
+ AuthorizationEndpoint *string `type:"string"`
+
+ // The client identifier.
+ ClientId *string `type:"string"`
+
+ // The client secret.
+ //
+ // ClientSecret is a sensitive parameter and its value will be
+ // replaced with "sensitive" in string returned by ModifyVerifiedAccessTrustProviderOidcOptions's
+ // String and GoString methods.
+ ClientSecret *string `type:"string" sensitive:"true"`
+
+ // The OIDC issuer.
+ Issuer *string `type:"string"`
+
// OpenID Connect (OIDC) scopes are used by an application during authentication
// to authorize access to a user's details. Each scope returns a specific set
// of user attributes.
Scope *string `type:"string"`
+
+ // The OIDC token endpoint.
+ TokenEndpoint *string `type:"string"`
+
+ // The OIDC user info endpoint.
+ UserInfoEndpoint *string `type:"string"`
}
// String returns the string representation.
@@ -146474,16 +146565,52 @@ func (s ModifyVerifiedAccessTrustProviderOidcOptions) GoString() string {
return s.String()
}
+// SetAuthorizationEndpoint sets the AuthorizationEndpoint field's value.
+func (s *ModifyVerifiedAccessTrustProviderOidcOptions) SetAuthorizationEndpoint(v string) *ModifyVerifiedAccessTrustProviderOidcOptions {
+ s.AuthorizationEndpoint = &v
+ return s
+}
+
+// SetClientId sets the ClientId field's value.
+func (s *ModifyVerifiedAccessTrustProviderOidcOptions) SetClientId(v string) *ModifyVerifiedAccessTrustProviderOidcOptions {
+ s.ClientId = &v
+ return s
+}
+
+// SetClientSecret sets the ClientSecret field's value.
+func (s *ModifyVerifiedAccessTrustProviderOidcOptions) SetClientSecret(v string) *ModifyVerifiedAccessTrustProviderOidcOptions {
+ s.ClientSecret = &v
+ return s
+}
+
+// SetIssuer sets the Issuer field's value.
+func (s *ModifyVerifiedAccessTrustProviderOidcOptions) SetIssuer(v string) *ModifyVerifiedAccessTrustProviderOidcOptions {
+ s.Issuer = &v
+ return s
+}
+
// SetScope sets the Scope field's value.
func (s *ModifyVerifiedAccessTrustProviderOidcOptions) SetScope(v string) *ModifyVerifiedAccessTrustProviderOidcOptions {
s.Scope = &v
return s
}
+// SetTokenEndpoint sets the TokenEndpoint field's value.
+func (s *ModifyVerifiedAccessTrustProviderOidcOptions) SetTokenEndpoint(v string) *ModifyVerifiedAccessTrustProviderOidcOptions {
+ s.TokenEndpoint = &v
+ return s
+}
+
+// SetUserInfoEndpoint sets the UserInfoEndpoint field's value.
+func (s *ModifyVerifiedAccessTrustProviderOidcOptions) SetUserInfoEndpoint(v string) *ModifyVerifiedAccessTrustProviderOidcOptions {
+ s.UserInfoEndpoint = &v
+ return s
+}
+
type ModifyVerifiedAccessTrustProviderOutput struct {
_ struct{} `type:"structure"`
- // The ID of the Amazon Web Services Verified Access trust provider.
+ // The ID of the Verified Access trust provider.
VerifiedAccessTrustProvider *VerifiedAccessTrustProvider `locationName:"verifiedAccessTrustProvider" type:"structure"`
}
@@ -151149,7 +151276,8 @@ func (s *NewDhcpConfiguration) SetValues(v []*string) *NewDhcpConfiguration {
return s
}
-// Options for OIDC-based, user-identity type trust provider.
+// Describes the options for an OpenID Connect-compatible user-identity trust
+// provider.
type OidcOptions struct {
_ struct{} `type:"structure"`
@@ -151160,7 +151288,11 @@ type OidcOptions struct {
ClientId *string `locationName:"clientId" type:"string"`
// The client secret.
- ClientSecret *string `locationName:"clientSecret" type:"string"`
+ //
+ // ClientSecret is a sensitive parameter and its value will be
+ // replaced with "sensitive" in string returned by OidcOptions's
+ // String and GoString methods.
+ ClientSecret *string `locationName:"clientSecret" type:"string" sensitive:"true"`
// The OIDC issuer.
Issuer *string `locationName:"issuer" type:"string"`
@@ -152725,8 +152857,8 @@ type Placement struct {
// Reserved for future use.
SpreadDomain *string `locationName:"spreadDomain" type:"string"`
- // The tenancy of the instance (if the instance is running in a VPC). An instance
- // with a tenancy of dedicated runs on single-tenant hardware.
+ // The tenancy of the instance. An instance with a tenancy of dedicated runs
+ // on single-tenant hardware.
//
// This parameter is not supported for CreateFleet (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateFleet).
// The host tenancy is not supported for ImportInstance (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ImportInstance.html)
@@ -153729,6 +153861,10 @@ type ProcessorInfo struct {
// The architectures supported by the instance type.
SupportedArchitectures []*string `locationName:"supportedArchitectures" locationNameList:"item" type:"list" enum:"ArchitectureType"`
+ // Indicates whether the instance type supports AMD SEV-SNP. If the request
+ // returns amd-sev-snp, AMD SEV-SNP is supported. Otherwise, it is not supported.
+ SupportedFeatures []*string `locationName:"supportedFeatures" locationNameList:"item" type:"list" enum:"SupportedAdditionalProcessorFeature"`
+
// The speed of the processor, in GHz.
SustainedClockSpeedInGhz *float64 `locationName:"sustainedClockSpeedInGhz" type:"double"`
}
@@ -153757,6 +153893,12 @@ func (s *ProcessorInfo) SetSupportedArchitectures(v []*string) *ProcessorInfo {
return s
}
+// SetSupportedFeatures sets the SupportedFeatures field's value.
+func (s *ProcessorInfo) SetSupportedFeatures(v []*string) *ProcessorInfo {
+ s.SupportedFeatures = v
+ return s
+}
+
// SetSustainedClockSpeedInGhz sets the SustainedClockSpeedInGhz field's value.
func (s *ProcessorInfo) SetSustainedClockSpeedInGhz(v float64) *ProcessorInfo {
s.SustainedClockSpeedInGhz = &v
@@ -155631,7 +155773,9 @@ type RegisterInstanceEventNotificationAttributesInput struct {
DryRun *bool `type:"boolean"`
// Information about the tag keys to register.
- InstanceTagAttribute *RegisterInstanceTagAttributeRequest `type:"structure"`
+ //
+ // InstanceTagAttribute is a required field
+ InstanceTagAttribute *RegisterInstanceTagAttributeRequest `type:"structure" required:"true"`
}
// String returns the string representation.
@@ -155652,6 +155796,19 @@ func (s RegisterInstanceEventNotificationAttributesInput) GoString() string {
return s.String()
}
+// Validate inspects the fields of the type to determine if they are valid.
+func (s *RegisterInstanceEventNotificationAttributesInput) Validate() error {
+ invalidParams := request.ErrInvalidParams{Context: "RegisterInstanceEventNotificationAttributesInput"}
+ if s.InstanceTagAttribute == nil {
+ invalidParams.Add(request.NewErrParamRequired("InstanceTagAttribute"))
+ }
+
+ if invalidParams.Len() > 0 {
+ return invalidParams
+ }
+ return nil
+}
+
// SetDryRun sets the DryRun field's value.
func (s *RegisterInstanceEventNotificationAttributesInput) SetDryRun(v bool) *RegisterInstanceEventNotificationAttributesInput {
s.DryRun = &v
@@ -158114,7 +158271,7 @@ func (s *RequestIpamResourceTag) SetValue(v string) *RequestIpamResourceTag {
//
// You must specify at least one parameter for the launch template data.
type RequestLaunchTemplateData struct {
- _ struct{} `type:"structure" sensitive:"true"`
+ _ struct{} `type:"structure"`
// The block device mapping.
BlockDeviceMappings []*LaunchTemplateBlockDeviceMappingRequest `locationName:"BlockDeviceMapping" locationNameList:"BlockDeviceMapping" type:"list"`
@@ -158188,8 +158345,14 @@ type RequestLaunchTemplateData struct {
//
// * resolve:ssm:parameter-name:label
//
- // For more information, see Use a Systems Manager parameter to find an AMI
- // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/finding-an-ami.html#using-systems-manager-parameter-to-find-AMI)
+ // * resolve:ssm:public-parameter
+ //
+ // Currently, EC2 Fleet and Spot Fleet do not support specifying a Systems Manager
+ // parameter. If the launch template will be used by an EC2 Fleet or Spot Fleet,
+ // you must specify the AMI ID.
+ //
+ // For more information, see Use a Systems Manager parameter instead of an AMI
+ // ID (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/create-launch-template.html#use-an-ssm-parameter-instead-of-an-ami-id)
// in the Amazon Elastic Compute Cloud User Guide.
ImageId *string `type:"string"`
@@ -158301,7 +158464,11 @@ type RequestLaunchTemplateData struct {
// must be provided in the MIME multi-part archive format (https://cloudinit.readthedocs.io/en/latest/topics/format.html#mime-multi-part-archive).
// For more information, see Amazon EC2 user data in launch templates (https://docs.aws.amazon.com/batch/latest/userguide/launch-templates.html)
// in the Batch User Guide.
- UserData *string `type:"string"`
+ //
+ // UserData is a sensitive parameter and its value will be
+ // replaced with "sensitive" in string returned by RequestLaunchTemplateData's
+ // String and GoString methods.
+ UserData *string `type:"string" sensitive:"true"`
}
// String returns the string representation.
@@ -158859,7 +159026,7 @@ func (s *RequestSpotInstancesInput) SetValidUntil(v time.Time) *RequestSpotInsta
type RequestSpotInstancesOutput struct {
_ struct{} `type:"structure"`
- // One or more Spot Instance requests.
+ // The Spot Instance requests.
SpotInstanceRequests []*SpotInstanceRequest `locationName:"spotInstanceRequestSet" locationNameList:"item" type:"list"`
}
@@ -158894,8 +159061,8 @@ type RequestSpotLaunchSpecification struct {
// Deprecated.
AddressingType *string `locationName:"addressingType" type:"string"`
- // One or more block device mapping entries. You can't specify both a snapshot
- // ID and an encryption value. This is because only blank volumes can be encrypted
+ // The block device mapping entries. You can't specify both a snapshot ID and
+ // an encryption value. This is because only blank volumes can be encrypted
// on creation. If a snapshot is the basis for a volume, it is not blank and
// its encryption status is used for the volume encryption status.
BlockDeviceMappings []*BlockDeviceMapping `locationName:"blockDeviceMapping" locationNameList:"item" type:"list"`
@@ -158929,8 +159096,8 @@ type RequestSpotLaunchSpecification struct {
// Default: Disabled
Monitoring *RunInstancesMonitoringEnabled `locationName:"monitoring" type:"structure"`
- // One or more network interfaces. If you specify a network interface, you must
- // specify subnet IDs and security group IDs using the network interface.
+ // The network interfaces. If you specify a network interface, you must specify
+ // subnet IDs and security group IDs using the network interface.
NetworkInterfaces []*InstanceNetworkInterfaceSpecification `locationName:"NetworkInterface" locationNameList:"item" type:"list"`
// The placement information for the instance.
@@ -158939,12 +159106,10 @@ type RequestSpotLaunchSpecification struct {
// The ID of the RAM disk.
RamdiskId *string `locationName:"ramdiskId" type:"string"`
- // One or more security group IDs.
+ // The IDs of the security groups.
SecurityGroupIds []*string `locationName:"SecurityGroupId" locationNameList:"item" type:"list"`
- // One or more security groups. When requesting instances in a VPC, you must
- // specify the IDs of the security groups. When requesting instances in EC2-Classic,
- // you can specify the names or the IDs of the security groups.
+ // Not supported.
SecurityGroups []*string `locationName:"SecurityGroup" locationNameList:"item" type:"list"`
// The ID of the subnet in which to launch the instance.
@@ -159094,7 +159259,7 @@ func (s *RequestSpotLaunchSpecification) SetUserData(v string) *RequestSpotLaunc
type Reservation struct {
_ struct{} `type:"structure"`
- // [EC2-Classic only] The security groups.
+ // Not supported.
Groups []*GroupIdentifier `locationName:"groupSet" locationNameList:"item" type:"list"`
// The instances.
@@ -159614,8 +159779,7 @@ type ReservedInstancesConfiguration struct {
// The instance type for the modified Reserved Instances.
InstanceType *string `locationName:"instanceType" type:"string" enum:"InstanceType"`
- // The network platform of the modified Reserved Instances, which is either
- // EC2-Classic or EC2-VPC.
+ // The network platform of the modified Reserved Instances.
Platform *string `locationName:"platform" type:"string"`
// Whether the Reserved Instance is applied to instances in a Region or instances
@@ -162977,9 +163141,9 @@ type RunInstancesInput struct {
// Default: m1.small
InstanceType *string `type:"string" enum:"InstanceType"`
- // [EC2-VPC] The number of IPv6 addresses to associate with the primary network
- // interface. Amazon EC2 chooses the IPv6 addresses from the range of your subnet.
- // You cannot specify this option and the option to assign specific IPv6 addresses
+ // The number of IPv6 addresses to associate with the primary network interface.
+ // Amazon EC2 chooses the IPv6 addresses from the range of your subnet. You
+ // cannot specify this option and the option to assign specific IPv6 addresses
// in the same request. You can specify this option if you've specified a minimum
// number of instances to launch.
//
@@ -162987,10 +163151,10 @@ type RunInstancesInput struct {
// request.
Ipv6AddressCount *int64 `type:"integer"`
- // [EC2-VPC] The IPv6 addresses from the range of the subnet to associate with
- // the primary network interface. You cannot specify this option and the option
- // to assign a number of IPv6 addresses in the same request. You cannot specify
- // this option if you've specified a minimum number of instances to launch.
+ // The IPv6 addresses from the range of the subnet to associate with the primary
+ // network interface. You cannot specify this option and the option to assign
+ // a number of IPv6 addresses in the same request. You cannot specify this option
+ // if you've specified a minimum number of instances to launch.
//
// You cannot specify this option and the network interfaces option in the same
// request.
@@ -163064,8 +163228,8 @@ type RunInstancesInput struct {
// the subnet.
PrivateDnsNameOptions *PrivateDnsNameOptionsRequest `type:"structure"`
- // [EC2-VPC] The primary IPv4 address. You must specify a value from the IPv4
- // address range of the subnet.
+ // The primary IPv4 address. You must specify a value from the IPv4 address
+ // range of the subnet.
//
// Only one private IP address can be designated as primary. You can't specify
// this option if you've specified the option to designate a private IP address
@@ -163093,7 +163257,7 @@ type RunInstancesInput struct {
// as part of the network interface.
SecurityGroupIds []*string `locationName:"SecurityGroupId" locationNameList:"SecurityGroupId" type:"list"`
- // [EC2-Classic, default VPC] The names of the security groups.
+ // [Default VPC] The names of the security groups.
//
// If you specify a network interface, you must specify any security groups
// as part of the network interface.
@@ -163101,7 +163265,7 @@ type RunInstancesInput struct {
// Default: Amazon EC2 uses the default security group.
SecurityGroups []*string `locationName:"SecurityGroup" locationNameList:"SecurityGroup" type:"list"`
- // [EC2-VPC] The ID of the subnet to launch the instance into.
+ // The ID of the subnet to launch the instance into.
//
// If you specify a network interface, you must specify any subnets as part
// of the network interface.
@@ -163769,7 +163933,7 @@ type ScheduledInstance struct {
// The instance type.
InstanceType *string `locationName:"instanceType" type:"string"`
- // The network platform (EC2-Classic or EC2-VPC).
+ // The network platform.
NetworkPlatform *string `locationName:"networkPlatform" type:"string"`
// The time for the next schedule to start.
@@ -163934,7 +164098,7 @@ type ScheduledInstanceAvailability struct {
// The minimum term. The only possible value is 365 days.
MinTermDurationInDays *int64 `locationName:"minTermDurationInDays" type:"integer"`
- // The network platform (EC2-Classic or EC2-VPC).
+ // The network platform.
NetworkPlatform *string `locationName:"networkPlatform" type:"string"`
// The platform (Linux/UNIX or Windows).
@@ -166628,7 +166792,11 @@ type SnapshotDetail struct {
StatusMessage *string `locationName:"statusMessage" type:"string"`
// The URL used to access the disk image.
- Url *string `locationName:"url" type:"string"`
+ //
+ // Url is a sensitive parameter and its value will be
+ // replaced with "sensitive" in string returned by SnapshotDetail's
+ // String and GoString methods.
+ Url *string `locationName:"url" type:"string" sensitive:"true"`
// The Amazon S3 bucket for the disk image.
UserBucket *UserBucketDetails `locationName:"userBucket" type:"structure"`
@@ -166726,7 +166894,11 @@ type SnapshotDiskContainer struct {
// The URL to the Amazon S3-based disk image being imported. It can either be
// a https URL (https://..) or an Amazon S3 URL (s3://..).
- Url *string `type:"string"`
+ //
+ // Url is a sensitive parameter and its value will be
+ // replaced with "sensitive" in string returned by SnapshotDiskContainer's
+ // String and GoString methods.
+ Url *string `type:"string" sensitive:"true"`
// The Amazon S3 bucket for the disk image.
UserBucket *UserBucket `type:"structure"`
@@ -167001,7 +167173,11 @@ type SnapshotTaskDetail struct {
StatusMessage *string `locationName:"statusMessage" type:"string"`
// The URL of the disk image from which the snapshot is created.
- Url *string `locationName:"url" type:"string"`
+ //
+ // Url is a sensitive parameter and its value will be
+ // replaced with "sensitive" in string returned by SnapshotTaskDetail's
+ // String and GoString methods.
+ Url *string `locationName:"url" type:"string" sensitive:"true"`
// The Amazon S3 bucket for the disk image.
UserBucket *UserBucketDetails `locationName:"userBucket" type:"structure"`
@@ -167423,9 +167599,7 @@ type SpotFleetLaunchSpecification struct {
// Resource Center and search for the kernel ID.
RamdiskId *string `locationName:"ramdiskId" type:"string"`
- // One or more security groups. When requesting instances in a VPC, you must
- // specify the IDs of the security groups. When requesting instances in EC2-Classic,
- // you can specify the names or the IDs of the security groups.
+ // The security groups.
SecurityGroups []*GroupIdentifier `locationName:"groupSet" locationNameList:"item" type:"list"`
// The maximum price per unit hour that you are willing to pay for a Spot Instance.
@@ -177806,7 +177980,7 @@ type VerifiedAccessTrustProvider struct {
// A description for the Amazon Web Services Verified Access trust provider.
Description *string `locationName:"description" type:"string"`
- // The options for device-identity type trust provider.
+ // The options for device-identity trust provider.
DeviceOptions *DeviceOptions `locationName:"deviceOptions" type:"structure"`
// The type of device-based trust provider.
@@ -177815,7 +177989,7 @@ type VerifiedAccessTrustProvider struct {
// The last updated time.
LastUpdatedTime *string `locationName:"lastUpdatedTime" type:"string"`
- // The OpenID Connect details for an oidc-type, user-identity based trust provider.
+ // The options for an OpenID Connect-compatible user-identity trust provider.
OidcOptions *OidcOptions `locationName:"oidcOptions" type:"structure"`
// The identifier to be used when working with policy rules.
@@ -181167,6 +181341,22 @@ func AllowsMultipleInstanceTypes_Values() []string {
}
}
+const (
+ // AmdSevSnpSpecificationEnabled is a AmdSevSnpSpecification enum value
+ AmdSevSnpSpecificationEnabled = "enabled"
+
+ // AmdSevSnpSpecificationDisabled is a AmdSevSnpSpecification enum value
+ AmdSevSnpSpecificationDisabled = "disabled"
+)
+
+// AmdSevSnpSpecification_Values returns all elements of the AmdSevSnpSpecification enum
+func AmdSevSnpSpecification_Values() []string {
+ return []string{
+ AmdSevSnpSpecificationEnabled,
+ AmdSevSnpSpecificationDisabled,
+ }
+}
+
const (
// AnalysisStatusRunning is a AnalysisStatus enum value
AnalysisStatusRunning = "running"
@@ -185600,6 +185790,39 @@ const (
// InstanceTypeR6idnMetal is a InstanceType enum value
InstanceTypeR6idnMetal = "r6idn.metal"
+
+ // InstanceTypeInf2Xlarge is a InstanceType enum value
+ InstanceTypeInf2Xlarge = "inf2.xlarge"
+
+ // InstanceTypeInf28xlarge is a InstanceType enum value
+ InstanceTypeInf28xlarge = "inf2.8xlarge"
+
+ // InstanceTypeInf224xlarge is a InstanceType enum value
+ InstanceTypeInf224xlarge = "inf2.24xlarge"
+
+ // InstanceTypeInf248xlarge is a InstanceType enum value
+ InstanceTypeInf248xlarge = "inf2.48xlarge"
+
+ // InstanceTypeTrn1n32xlarge is a InstanceType enum value
+ InstanceTypeTrn1n32xlarge = "trn1n.32xlarge"
+
+ // InstanceTypeI4gLarge is a InstanceType enum value
+ InstanceTypeI4gLarge = "i4g.large"
+
+ // InstanceTypeI4gXlarge is a InstanceType enum value
+ InstanceTypeI4gXlarge = "i4g.xlarge"
+
+ // InstanceTypeI4g2xlarge is a InstanceType enum value
+ InstanceTypeI4g2xlarge = "i4g.2xlarge"
+
+ // InstanceTypeI4g4xlarge is a InstanceType enum value
+ InstanceTypeI4g4xlarge = "i4g.4xlarge"
+
+ // InstanceTypeI4g8xlarge is a InstanceType enum value
+ InstanceTypeI4g8xlarge = "i4g.8xlarge"
+
+ // InstanceTypeI4g16xlarge is a InstanceType enum value
+ InstanceTypeI4g16xlarge = "i4g.16xlarge"
)
// InstanceType_Values returns all elements of the InstanceType enum
@@ -186248,6 +186471,17 @@ func InstanceType_Values() []string {
InstanceTypeM6idnMetal,
InstanceTypeR6inMetal,
InstanceTypeR6idnMetal,
+ InstanceTypeInf2Xlarge,
+ InstanceTypeInf28xlarge,
+ InstanceTypeInf224xlarge,
+ InstanceTypeInf248xlarge,
+ InstanceTypeTrn1n32xlarge,
+ InstanceTypeI4gLarge,
+ InstanceTypeI4gXlarge,
+ InstanceTypeI4g2xlarge,
+ InstanceTypeI4g4xlarge,
+ InstanceTypeI4g8xlarge,
+ InstanceTypeI4g16xlarge,
}
}
@@ -189123,6 +189357,18 @@ func SummaryStatus_Values() []string {
}
}
+const (
+ // SupportedAdditionalProcessorFeatureAmdSevSnp is a SupportedAdditionalProcessorFeature enum value
+ SupportedAdditionalProcessorFeatureAmdSevSnp = "amd-sev-snp"
+)
+
+// SupportedAdditionalProcessorFeature_Values returns all elements of the SupportedAdditionalProcessorFeature enum
+func SupportedAdditionalProcessorFeature_Values() []string {
+ return []string{
+ SupportedAdditionalProcessorFeatureAmdSevSnp,
+ }
+}
+
const (
// TargetCapacityUnitTypeVcpu is a TargetCapacityUnitType enum value
TargetCapacityUnitTypeVcpu = "vcpu"
diff --git a/vendor/github.com/aws/aws-sdk-go/service/ec2/customizations.go b/vendor/github.com/aws/aws-sdk-go/service/ec2/customizations.go
index 5b5395356fa..621712d29f0 100644
--- a/vendor/github.com/aws/aws-sdk-go/service/ec2/customizations.go
+++ b/vendor/github.com/aws/aws-sdk-go/service/ec2/customizations.go
@@ -11,6 +11,9 @@ import (
)
const (
+ // ec2CopySnapshotPresignedUrlCustomization handler name
+ ec2CopySnapshotPresignedUrlCustomization = "ec2CopySnapshotPresignedUrl"
+
// customRetryerMinRetryDelay sets min retry delay
customRetryerMinRetryDelay = 1 * time.Second
@@ -21,7 +24,10 @@ const (
func init() {
initRequest = func(r *request.Request) {
if r.Operation.Name == opCopySnapshot { // fill the PresignedURL parameter
- r.Handlers.Build.PushFront(fillPresignedURL)
+ r.Handlers.Build.PushFrontNamed(request.NamedHandler{
+ Name: ec2CopySnapshotPresignedUrlCustomization,
+ Fn: fillPresignedURL,
+ })
}
// only set the retryer on request if config doesn't have a retryer
@@ -48,13 +54,15 @@ func fillPresignedURL(r *request.Request) {
origParams := r.Params.(*CopySnapshotInput)
- // Stop if PresignedURL/DestinationRegion is set
- if origParams.PresignedUrl != nil || origParams.DestinationRegion != nil {
+ // Stop if PresignedURL is set
+ if origParams.PresignedUrl != nil {
return
}
+ // Always use config region as destination region for SDKs
origParams.DestinationRegion = r.Config.Region
- newParams := awsutil.CopyOf(r.Params).(*CopySnapshotInput)
+
+ newParams := awsutil.CopyOf(origParams).(*CopySnapshotInput)
// Create a new request based on the existing request. We will use this to
// presign the CopySnapshot request against the source region.
@@ -82,8 +90,12 @@ func fillPresignedURL(r *request.Request) {
clientInfo.Endpoint = resolved.URL
clientInfo.SigningRegion = resolved.SigningRegion
+ // Copy handlers without Presigned URL customization to avoid an infinite loop
+ handlersWithoutPresignCustomization := r.Handlers.Copy()
+ handlersWithoutPresignCustomization.Build.RemoveByName(ec2CopySnapshotPresignedUrlCustomization)
+
// Presign a CopySnapshot request with modified params
- req := request.New(*cfg, clientInfo, r.Handlers, r.Retryer, r.Operation, newParams, r.Data)
+ req := request.New(*cfg, clientInfo, handlersWithoutPresignCustomization, r.Retryer, r.Operation, newParams, r.Data)
url, err := req.Presign(5 * time.Minute) // 5 minutes should be enough.
if err != nil { // bubble error back up to original request
r.Error = err
diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/api.go b/vendor/github.com/aws/aws-sdk-go/service/sts/api.go
index 63729d0a78b..7ac6b93f442 100644
--- a/vendor/github.com/aws/aws-sdk-go/service/sts/api.go
+++ b/vendor/github.com/aws/aws-sdk-go/service/sts/api.go
@@ -85,9 +85,9 @@ func (c *STS) AssumeRoleRequest(input *AssumeRoleInput) (req *request.Request, o
// assumed. For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session)
// in the IAM User Guide.
//
-// When you create a role, you create two policies: A role trust policy that
-// specifies who can assume the role and a permissions policy that specifies
-// what can be done with the role. You specify the trusted principal who is
+// When you create a role, you create two policies: a role trust policy that
+// specifies who can assume the role, and a permissions policy that specifies
+// what can be done with the role. You specify the trusted principal that is
// allowed to assume the role in the role trust policy.
//
// To assume a role from a different account, your Amazon Web Services account
@@ -96,9 +96,9 @@ func (c *STS) AssumeRoleRequest(input *AssumeRoleInput) (req *request.Request, o
// are allowed to delegate that access to users in the account.
//
// A user who wants to access a role in a different account must also have permissions
-// that are delegated from the user account administrator. The administrator
-// must attach a policy that allows the user to call AssumeRole for the ARN
-// of the role in the other account.
+// that are delegated from the account administrator. The administrator must
+// attach a policy that allows the user to call AssumeRole for the ARN of the
+// role in the other account.
//
// To allow a user to assume a role in the same account, you can do either of
// the following:
@@ -517,10 +517,8 @@ func (c *STS) AssumeRoleWithWebIdentityRequest(input *AssumeRoleWithWebIdentityI
// a user. You can also supply the user with a consistent identity throughout
// the lifetime of an application.
//
-// To learn more about Amazon Cognito, see Amazon Cognito Overview (https://docs.aws.amazon.com/mobile/sdkforandroid/developerguide/cognito-auth.html#d0e840)
-// in Amazon Web Services SDK for Android Developer Guide and Amazon Cognito
-// Overview (https://docs.aws.amazon.com/mobile/sdkforios/developerguide/cognito-auth.html#d0e664)
-// in the Amazon Web Services SDK for iOS Developer Guide.
+// To learn more about Amazon Cognito, see Amazon Cognito identity pools (https://docs.aws.amazon.com/cognito/latest/developerguide/cognito-identity.html)
+// in Amazon Cognito Developer Guide.
//
// Calling AssumeRoleWithWebIdentity does not require the use of Amazon Web
// Services security credentials. Therefore, you can distribute an application
@@ -984,11 +982,11 @@ func (c *STS) GetCallerIdentityRequest(input *GetCallerIdentityInput) (req *requ
// call the operation.
//
// No permissions are required to perform this operation. If an administrator
-// adds a policy to your IAM user or role that explicitly denies access to the
-// sts:GetCallerIdentity action, you can still perform this operation. Permissions
-// are not required because the same information is returned when an IAM user
-// or role is denied access. To view an example response, see I Am Not Authorized
-// to Perform: iam:DeleteVirtualMFADevice (https://docs.aws.amazon.com/IAM/latest/UserGuide/troubleshoot_general.html#troubleshoot_general_access-denied-delete-mfa)
+// attaches a policy to your identity that explicitly denies access to the sts:GetCallerIdentity
+// action, you can still perform this operation. Permissions are not required
+// because the same information is returned when access is denied. To view an
+// example response, see I Am Not Authorized to Perform: iam:DeleteVirtualMFADevice
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/troubleshoot_general.html#troubleshoot_general_access-denied-delete-mfa)
// in the IAM User Guide.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
@@ -1063,18 +1061,26 @@ func (c *STS) GetFederationTokenRequest(input *GetFederationTokenInput) (req *re
// GetFederationToken API operation for AWS Security Token Service.
//
// Returns a set of temporary security credentials (consisting of an access
-// key ID, a secret access key, and a security token) for a federated user.
-// A typical use is in a proxy application that gets temporary security credentials
-// on behalf of distributed applications inside a corporate network. You must
-// call the GetFederationToken operation using the long-term security credentials
-// of an IAM user. As a result, this call is appropriate in contexts where those
-// credentials can be safely stored, usually in a server-based application.
+// key ID, a secret access key, and a security token) for a user. A typical
+// use is in a proxy application that gets temporary security credentials on
+// behalf of distributed applications inside a corporate network.
+//
+// You must call the GetFederationToken operation using the long-term security
+// credentials of an IAM user. As a result, this call is appropriate in contexts
+// where those credentials can be safeguarded, usually in a server-based application.
// For a comparison of GetFederationToken with the other API operations that
// produce temporary credentials, see Requesting Temporary Security Credentials
// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html)
// and Comparing the Amazon Web Services STS API operations (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison)
// in the IAM User Guide.
//
+// Although it is possible to call GetFederationToken using the security credentials
+// of an Amazon Web Services account root user rather than an IAM user that
+// you create for the purpose of a proxy application, we do not recommend it.
+// For more information, see Safeguard your root user credentials and don't
+// use them for everyday tasks (https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html#lock-away-credentials)
+// in the IAM User Guide.
+//
// You can create a mobile-based or browser-based app that can authenticate
// users using a web identity provider like Login with Amazon, Facebook, Google,
// or an OpenID Connect-compatible identity provider. In this case, we recommend
@@ -1083,21 +1089,13 @@ func (c *STS) GetFederationTokenRequest(input *GetFederationTokenInput) (req *re
// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity)
// in the IAM User Guide.
//
-// You can also call GetFederationToken using the security credentials of an
-// Amazon Web Services account root user, but we do not recommend it. Instead,
-// we recommend that you create an IAM user for the purpose of the proxy application.
-// Then attach a policy to the IAM user that limits federated users to only
-// the actions and resources that they need to access. For more information,
-// see IAM Best Practices (https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html)
-// in the IAM User Guide.
-//
// # Session duration
//
// The temporary credentials are valid for the specified duration, from 900
// seconds (15 minutes) up to a maximum of 129,600 seconds (36 hours). The default
// session duration is 43,200 seconds (12 hours). Temporary credentials obtained
-// by using the Amazon Web Services account root user credentials have a maximum
-// duration of 3,600 seconds (1 hour).
+// by using the root user credentials have a maximum duration of 3,600 seconds
+// (1 hour).
//
// # Permissions
//
@@ -1267,12 +1265,13 @@ func (c *STS) GetSessionTokenRequest(input *GetSessionTokenInput) (req *request.
// or IAM user. The credentials consist of an access key ID, a secret access
// key, and a security token. Typically, you use GetSessionToken if you want
// to use MFA to protect programmatic calls to specific Amazon Web Services
-// API operations like Amazon EC2 StopInstances. MFA-enabled IAM users would
-// need to call GetSessionToken and submit an MFA code that is associated with
-// their MFA device. Using the temporary security credentials that are returned
-// from the call, IAM users can then make programmatic calls to API operations
-// that require MFA authentication. If you do not supply a correct MFA code,
-// then the API returns an access denied error. For a comparison of GetSessionToken
+// API operations like Amazon EC2 StopInstances.
+//
+// MFA-enabled IAM users must call GetSessionToken and submit an MFA code that
+// is associated with their MFA device. Using the temporary security credentials
+// that the call returns, IAM users can then make programmatic calls to API
+// operations that require MFA authentication. An incorrect MFA code causes
+// the API to return an access denied error. For a comparison of GetSessionToken
// with the other API operations that produce temporary credentials, see Requesting
// Temporary Security Credentials (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html)
// and Comparing the Amazon Web Services STS API operations (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison)
@@ -1287,13 +1286,12 @@ func (c *STS) GetSessionTokenRequest(input *GetSessionTokenInput) (req *request.
// # Session Duration
//
// The GetSessionToken operation must be called by using the long-term Amazon
-// Web Services security credentials of the Amazon Web Services account root
-// user or an IAM user. Credentials that are created by IAM users are valid
-// for the duration that you specify. This duration can range from 900 seconds
-// (15 minutes) up to a maximum of 129,600 seconds (36 hours), with a default
-// of 43,200 seconds (12 hours). Credentials based on account credentials can
-// range from 900 seconds (15 minutes) up to 3,600 seconds (1 hour), with a
-// default of 1 hour.
+// Web Services security credentials of an IAM user. Credentials that are created
+// by IAM users are valid for the duration that you specify. This duration can
+// range from 900 seconds (15 minutes) up to a maximum of 129,600 seconds (36
+// hours), with a default of 43,200 seconds (12 hours). Credentials based on
+// account credentials can range from 900 seconds (15 minutes) up to 3,600 seconds
+// (1 hour), with a default of 1 hour.
//
// # Permissions
//
@@ -1305,20 +1303,20 @@ func (c *STS) GetSessionTokenRequest(input *GetSessionTokenInput) (req *request.
//
// - You cannot call any STS API except AssumeRole or GetCallerIdentity.
//
-// We recommend that you do not call GetSessionToken with Amazon Web Services
-// account root user credentials. Instead, follow our best practices (https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html#create-iam-users)
-// by creating one or more IAM users, giving them the necessary permissions,
-// and using IAM users for everyday interaction with Amazon Web Services.
+// The credentials that GetSessionToken returns are based on permissions associated
+// with the IAM user whose credentials were used to call the operation. The
+// temporary credentials have the same permissions as the IAM user.
//
-// The credentials that are returned by GetSessionToken are based on permissions
-// associated with the user whose credentials were used to call the operation.
-// If GetSessionToken is called using Amazon Web Services account root user
-// credentials, the temporary credentials have root user permissions. Similarly,
-// if GetSessionToken is called using the credentials of an IAM user, the temporary
-// credentials have the same permissions as the IAM user.
+// Although it is possible to call GetSessionToken using the security credentials
+// of an Amazon Web Services account root user rather than an IAM user, we do
+// not recommend it. If GetSessionToken is called using root user credentials,
+// the temporary credentials have root user permissions. For more information,
+// see Safeguard your root user credentials and don't use them for everyday
+// tasks (https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html#lock-away-credentials)
+// in the IAM User Guide
//
// For more information about using GetSessionToken to create temporary credentials,
-// go to Temporary Credentials for Users in Untrusted Environments (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getsessiontoken)
+// see Temporary Credentials for Users in Untrusted Environments (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getsessiontoken)
// in the IAM User Guide.
//
// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
@@ -1900,8 +1898,12 @@ type AssumeRoleWithSAMLInput struct {
// For more information, see Configuring a Relying Party and Adding Claims (https://docs.aws.amazon.com/IAM/latest/UserGuide/create-role-saml-IdP-tasks.html)
// in the IAM User Guide.
//
+ // SAMLAssertion is a sensitive parameter and its value will be
+ // replaced with "sensitive" in string returned by AssumeRoleWithSAMLInput's
+ // String and GoString methods.
+ //
// SAMLAssertion is a required field
- SAMLAssertion *string `min:"4" type:"string" required:"true"`
+ SAMLAssertion *string `min:"4" type:"string" required:"true" sensitive:"true"`
}
// String returns the string representation.
@@ -2036,7 +2038,7 @@ type AssumeRoleWithSAMLOutput struct {
// IAM.
//
// The combination of NameQualifier and Subject can be used to uniquely identify
- // a federated user.
+ // a user.
//
// The following pseudocode shows how the hash value is calculated:
//
@@ -2266,8 +2268,12 @@ type AssumeRoleWithWebIdentityInput struct {
// the user who is using your application with a web identity provider before
// the application makes an AssumeRoleWithWebIdentity call.
//
+ // WebIdentityToken is a sensitive parameter and its value will be
+ // replaced with "sensitive" in string returned by AssumeRoleWithWebIdentityInput's
+ // String and GoString methods.
+ //
// WebIdentityToken is a required field
- WebIdentityToken *string `min:"4" type:"string" required:"true"`
+ WebIdentityToken *string `min:"4" type:"string" required:"true" sensitive:"true"`
}
// String returns the string representation.
@@ -2573,8 +2579,12 @@ type Credentials struct {
// The secret access key that can be used to sign requests.
//
+ // SecretAccessKey is a sensitive parameter and its value will be
+ // replaced with "sensitive" in string returned by Credentials's
+ // String and GoString methods.
+ //
// SecretAccessKey is a required field
- SecretAccessKey *string `type:"string" required:"true"`
+ SecretAccessKey *string `type:"string" required:"true" sensitive:"true"`
// The token that users must pass to the service API to use the temporary credentials.
//
@@ -2922,10 +2932,9 @@ type GetFederationTokenInput struct {
// The duration, in seconds, that the session should last. Acceptable durations
// for federation sessions range from 900 seconds (15 minutes) to 129,600 seconds
// (36 hours), with 43,200 seconds (12 hours) as the default. Sessions obtained
- // using Amazon Web Services account root user credentials are restricted to
- // a maximum of 3,600 seconds (one hour). If the specified duration is longer
- // than one hour, the session obtained by using root user credentials defaults
- // to one hour.
+ // using root user credentials are restricted to a maximum of 3,600 seconds
+ // (one hour). If the specified duration is longer than one hour, the session
+ // obtained by using root user credentials defaults to one hour.
DurationSeconds *int64 `min:"900" type:"integer"`
// The name of the federated user. The name is used as an identifier for the
diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/doc.go b/vendor/github.com/aws/aws-sdk-go/service/sts/doc.go
index c40f5a2a52b..ea1d9eb0ccf 100644
--- a/vendor/github.com/aws/aws-sdk-go/service/sts/doc.go
+++ b/vendor/github.com/aws/aws-sdk-go/service/sts/doc.go
@@ -4,10 +4,9 @@
// requests to AWS Security Token Service.
//
// Security Token Service (STS) enables you to request temporary, limited-privilege
-// credentials for Identity and Access Management (IAM) users or for users that
-// you authenticate (federated users). This guide provides descriptions of the
-// STS API. For more information about using this service, see Temporary Security
-// Credentials (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp.html).
+// credentials for users. This guide provides descriptions of the STS API. For
+// more information about using this service, see Temporary Security Credentials
+// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp.html).
//
// See https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15 for more information on this service.
//
diff --git a/vendor/github.com/digitalocean/godo/CHANGELOG.md b/vendor/github.com/digitalocean/godo/CHANGELOG.md
index 7233c389b06..9c1849b2c08 100644
--- a/vendor/github.com/digitalocean/godo/CHANGELOG.md
+++ b/vendor/github.com/digitalocean/godo/CHANGELOG.md
@@ -1,5 +1,12 @@
# Change Log
+## [v1.99.0] - 2023-04-24
+
+- #616 - @bentranter - Bump CI version for Go 1.20
+- #615 - @bentranter - Remove beta support for tokens API
+- #604 - @dvigueras - Add support for "Validate a Container Registry Name"
+- #613 - @ibilalkayy - updated the README file by showing up the build status icon
+
## [v1.98.0] - 2023-03-09
- #608 - @anitgandhi - client: don't process body upon 204 response
diff --git a/vendor/github.com/digitalocean/godo/README.md b/vendor/github.com/digitalocean/godo/README.md
index 9a3ec2dad2c..4c9ee2d78f5 100644
--- a/vendor/github.com/digitalocean/godo/README.md
+++ b/vendor/github.com/digitalocean/godo/README.md
@@ -1,6 +1,6 @@
# Godo
-[](https://travis-ci.org/digitalocean/godo)
+[](https://github.com/digitalocean/godo/actions/workflows/ci.yml)
[](https://godoc.org/github.com/digitalocean/godo)
Godo is a Go client library for accessing the DigitalOcean V2 API.
diff --git a/vendor/github.com/digitalocean/godo/godo.go b/vendor/github.com/digitalocean/godo/godo.go
index 14fac268c3c..c48a5f788af 100644
--- a/vendor/github.com/digitalocean/godo/godo.go
+++ b/vendor/github.com/digitalocean/godo/godo.go
@@ -21,7 +21,7 @@ import (
)
const (
- libraryVersion = "1.98.0"
+ libraryVersion = "1.99.0"
defaultBaseURL = "https://api.digitalocean.com/"
userAgent = "godo/" + libraryVersion
mediaType = "application/json"
@@ -81,7 +81,6 @@ type Client struct {
Storage StorageService
StorageActions StorageActionsService
Tags TagsService
- Tokens TokensService
UptimeChecks UptimeChecksService
VPCs VPCsService
@@ -252,7 +251,6 @@ func NewClient(httpClient *http.Client) *Client {
c.Storage = &StorageServiceOp{client: c}
c.StorageActions = &StorageActionsServiceOp{client: c}
c.Tags = &TagsServiceOp{client: c}
- c.Tokens = &TokensServiceOp{client: c}
c.UptimeChecks = &UptimeChecksServiceOp{client: c}
c.VPCs = &VPCsServiceOp{client: c}
diff --git a/vendor/github.com/digitalocean/godo/registry.go b/vendor/github.com/digitalocean/godo/registry.go
index 2fe9d2bd9fa..b0c24328180 100644
--- a/vendor/github.com/digitalocean/godo/registry.go
+++ b/vendor/github.com/digitalocean/godo/registry.go
@@ -37,6 +37,7 @@ type RegistryService interface {
GetOptions(context.Context) (*RegistryOptions, *Response, error)
GetSubscription(context.Context) (*RegistrySubscription, *Response, error)
UpdateSubscription(context.Context, *RegistrySubscriptionUpdateRequest) (*RegistrySubscription, *Response, error)
+ ValidateName(context.Context, *RegistryValidateNameRequest) (*Response, error)
}
var _ RegistryService = &RegistryServiceOp{}
@@ -233,6 +234,12 @@ type RegistrySubscriptionUpdateRequest struct {
TierSlug string `json:"tier_slug"`
}
+// RegistryValidateNameRequest represents a request to validate that a
+// container registry name is available for use.
+type RegistryValidateNameRequest struct {
+ Name string `json:"name"`
+}
+
// Get retrieves the details of a Registry.
func (svc *RegistryServiceOp) Get(ctx context.Context) (*Registry, *Response, error) {
req, err := svc.client.NewRequest(ctx, http.MethodGet, registryPath, nil)
@@ -589,3 +596,17 @@ func (svc *RegistryServiceOp) UpdateSubscription(ctx context.Context, request *R
}
return root.Subscription, resp, nil
}
+
+// ValidateName validates that a container registry name is available for use.
+func (svc *RegistryServiceOp) ValidateName(ctx context.Context, request *RegistryValidateNameRequest) (*Response, error) {
+ path := fmt.Sprintf("%s/validate-name", registryPath)
+ req, err := svc.client.NewRequest(ctx, http.MethodPost, path, request)
+ if err != nil {
+ return nil, err
+ }
+ resp, err := svc.client.Do(ctx, req, nil)
+ if err != nil {
+ return resp, err
+ }
+ return resp, nil
+}
diff --git a/vendor/github.com/digitalocean/godo/tokens.go b/vendor/github.com/digitalocean/godo/tokens.go
deleted file mode 100644
index 13aa418dff1..00000000000
--- a/vendor/github.com/digitalocean/godo/tokens.go
+++ /dev/null
@@ -1,228 +0,0 @@
-package godo
-
-import (
- "context"
- "fmt"
- "net/http"
- "time"
-)
-
-const (
- accessTokensBasePath = "v2/tokens"
- tokenScopesBasePath = accessTokensBasePath + "/scopes"
-)
-
-// TokensService is an interface for managing DigitalOcean API access tokens.
-// It is not currently generally available. Follow the release notes for
-// updates: https://docs.digitalocean.com/release-notes/api/
-type TokensService interface {
- List(context.Context, *ListOptions) ([]Token, *Response, error)
- Get(context.Context, int) (*Token, *Response, error)
- Create(context.Context, *TokenCreateRequest) (*Token, *Response, error)
- Update(context.Context, int, *TokenUpdateRequest) (*Token, *Response, error)
- Revoke(context.Context, int) (*Response, error)
- ListScopes(context.Context, *ListOptions) ([]TokenScope, *Response, error)
- ListScopesByNamespace(context.Context, string, *ListOptions) ([]TokenScope, *Response, error)
-}
-
-// TokensServiceOp handles communication with the tokens related methods of the
-// DigitalOcean API.
-type TokensServiceOp struct {
- client *Client
-}
-
-var _ TokensService = &TokensServiceOp{}
-
-// Token represents a DigitalOcean API token.
-type Token struct {
- ID int `json:"id"`
- Name string `json:"name"`
- Scopes []string `json:"scopes"`
- ExpirySeconds *int `json:"expiry_seconds"`
- CreatedAt time.Time `json:"created_at"`
- LastUsedAt string `json:"last_used_at"`
-
- // AccessToken contains the actual Oauth token string. It is only included
- // in the create response.
- AccessToken string `json:"access_token,omitempty"`
-}
-
-// tokenRoot represents a response from the DigitalOcean API
-type tokenRoot struct {
- Token *Token `json:"token"`
-}
-
-type tokensRoot struct {
- Tokens []Token `json:"tokens"`
- Links *Links `json:"links"`
- Meta *Meta `json:"meta"`
-}
-
-// TokenCreateRequest represents a request to create a token.
-type TokenCreateRequest struct {
- Name string `json:"name"`
- Scopes []string `json:"scopes"`
- ExpirySeconds *int `json:"expiry_seconds,omitempty"`
-}
-
-// TokenUpdateRequest represents a request to update a token.
-type TokenUpdateRequest struct {
- Name string `json:"name,omitempty"`
- Scopes []string `json:"scopes,omitempty"`
-}
-
-// TokenScope is a representation of a scope for the public API.
-type TokenScope struct {
- Name string `json:"name"`
-}
-
-type tokenScopesRoot struct {
- TokenScopes []TokenScope `json:"scopes"`
- Links *Links `json:"links"`
- Meta *Meta `json:"meta"`
-}
-
-type tokenScopeNamespaceParam struct {
- Namespace string `url:"namespace,omitempty"`
-}
-
-// List all DigitalOcean API access tokens.
-func (c TokensServiceOp) List(ctx context.Context, opt *ListOptions) ([]Token, *Response, error) {
- path, err := addOptions(accessTokensBasePath, opt)
- if err != nil {
- return nil, nil, err
- }
-
- req, err := c.client.NewRequest(ctx, http.MethodGet, path, nil)
- if err != nil {
- return nil, nil, err
- }
-
- root := new(tokensRoot)
- resp, err := c.client.Do(ctx, req, root)
- if err != nil {
- return nil, resp, err
- }
- if l := root.Links; l != nil {
- resp.Links = l
- }
- if m := root.Meta; m != nil {
- resp.Meta = m
- }
-
- return root.Tokens, resp, err
-}
-
-// Get a specific DigitalOcean API access token.
-func (c TokensServiceOp) Get(ctx context.Context, tokenID int) (*Token, *Response, error) {
- path := fmt.Sprintf("%s/%d", accessTokensBasePath, tokenID)
- req, err := c.client.NewRequest(ctx, http.MethodGet, path, nil)
- if err != nil {
- return nil, nil, err
- }
-
- root := new(tokenRoot)
- resp, err := c.client.Do(ctx, req, root)
- if err != nil {
- return nil, resp, err
- }
-
- return root.Token, resp, err
-}
-
-// Create a new DigitalOcean API access token.
-func (c TokensServiceOp) Create(ctx context.Context, createRequest *TokenCreateRequest) (*Token, *Response, error) {
- req, err := c.client.NewRequest(ctx, http.MethodPost, accessTokensBasePath, createRequest)
- if err != nil {
- return nil, nil, err
- }
-
- root := new(tokenRoot)
- resp, err := c.client.Do(ctx, req, root)
- if err != nil {
- return nil, resp, err
- }
-
- return root.Token, resp, err
-}
-
-// Update the name or scopes of a specific DigitalOcean API access token.
-func (c TokensServiceOp) Update(ctx context.Context, tokenID int, updateRequest *TokenUpdateRequest) (*Token, *Response, error) {
- path := fmt.Sprintf("%s/%d", accessTokensBasePath, tokenID)
- req, err := c.client.NewRequest(ctx, http.MethodPatch, path, updateRequest)
- if err != nil {
- return nil, nil, err
- }
-
- root := new(tokenRoot)
- resp, err := c.client.Do(ctx, req, root)
- if err != nil {
- return nil, resp, err
- }
-
- return root.Token, resp, err
-}
-
-// Revoke a specific DigitalOcean API access token.
-func (c TokensServiceOp) Revoke(ctx context.Context, tokenID int) (*Response, error) {
- path := fmt.Sprintf("%s/%d", accessTokensBasePath, tokenID)
- req, err := c.client.NewRequest(ctx, http.MethodDelete, path, nil)
- if err != nil {
- return nil, err
- }
-
- resp, err := c.client.Do(ctx, req, nil)
-
- return resp, err
-}
-
-// ListScopes lists all available scopes that can be granted to a token.
-func (c TokensServiceOp) ListScopes(ctx context.Context, opt *ListOptions) ([]TokenScope, *Response, error) {
- path, err := addOptions(tokenScopesBasePath, opt)
- if err != nil {
- return nil, nil, err
- }
-
- return listTokenScopes(ctx, c, path)
-}
-
-// ListScopesByNamespace lists available scopes in a namespace that can be granted
-// to a token (e.g. the namespace for the `droplet:read“ scope is `droplet`).
-func (c TokensServiceOp) ListScopesByNamespace(ctx context.Context, namespace string, opt *ListOptions) ([]TokenScope, *Response, error) {
- path, err := addOptions(tokenScopesBasePath, opt)
- if err != nil {
- return nil, nil, err
- }
-
- namespaceOpt := tokenScopeNamespaceParam{
- Namespace: namespace,
- }
-
- path, err = addOptions(path, namespaceOpt)
- if err != nil {
- return nil, nil, err
- }
-
- return listTokenScopes(ctx, c, path)
-}
-
-func listTokenScopes(ctx context.Context, c TokensServiceOp, path string) ([]TokenScope, *Response, error) {
- req, err := c.client.NewRequest(ctx, http.MethodGet, path, nil)
- if err != nil {
- return nil, nil, err
- }
-
- root := new(tokenScopesRoot)
- resp, err := c.client.Do(ctx, req, root)
- if err != nil {
- return nil, resp, err
- }
- if l := root.Links; l != nil {
- resp.Links = l
- }
- if m := root.Meta; m != nil {
- resp.Meta = m
- }
-
- return root.TokenScopes, resp, err
-}
diff --git a/vendor/github.com/docker/docker/AUTHORS b/vendor/github.com/docker/docker/AUTHORS
index 0728bfe18f3..b3141819258 100644
--- a/vendor/github.com/docker/docker/AUTHORS
+++ b/vendor/github.com/docker/docker/AUTHORS
@@ -29,6 +29,7 @@ Adam Pointer
Adam Singer
Adam Walz
Adam Williams
+AdamKorcz
Addam Hardy
Aditi Rajagopal
Aditya
@@ -81,6 +82,7 @@ Alex Goodman
Alex Nordlund
Alex Olshansky
Alex Samorukov
+Alex Stockinger
Alex Warhawk
Alexander Artemenko
Alexander Boyd
@@ -198,6 +200,7 @@ Anusha Ragunathan
Anyu Wang
apocas
Arash Deshmeh
+arcosx
ArikaChen
Arko Dasgupta
Arnaud Lefebvre
@@ -241,6 +244,7 @@ Benjamin Atkin
Benjamin Baker
Benjamin Boudreau
Benjamin Böhmke
+Benjamin Wang
Benjamin Yolken
Benny Ng
Benoit Chesneau
@@ -634,6 +638,7 @@ Eng Zer Jun
Enguerran
Eohyung Lee
epeterso
+er0k
Eric Barch
Eric Curtin
Eric G. Noriega
@@ -754,6 +759,7 @@ Félix Baylac-Jacqué
Félix Cantournet
Gabe Rosenhouse
Gabor Nagy
+Gabriel Adrian Samfira
Gabriel Goller
Gabriel L. Somlo
Gabriel Linder
@@ -855,6 +861,7 @@ Hongbin Lu
Hongxu Jia
Honza Pokorny
Hsing-Hui Hsu
+Hsing-Yu (David) Chen
hsinko <21551195@zju.edu.cn>
Hu Keping
Hu Tao
@@ -887,6 +894,7 @@ Igor Dolzhikov
Igor Karpovich
Iliana Weller
Ilkka Laukkanen
+Illia Antypenko
Illo Abdulrahim
Ilya Dmitrichenko
Ilya Gusev
@@ -938,6 +946,7 @@ Jamie Hannaford
Jamshid Afshar
Jan Breig
Jan Chren
+Jan Garcia
Jan Götte
Jan Keromnes
Jan Koprowski
@@ -1206,6 +1215,7 @@ Kimbro Staken
Kir Kolyshkin
Kiran Gangadharan
Kirill SIbirev
+Kirk Easterson
knappe
Kohei Tsuruta
Koichi Shiraishi
@@ -1240,10 +1250,12 @@ Lars Kellogg-Stedman
Lars R. Damerow
Lars-Magnus Skog
Laszlo Meszaros
+Laura Brehm
Laura Frank
Laurent Bernaille
Laurent Erignoux
Laurie Voss
+Leandro Motta Barros
Leandro Siqueira
Lee Calcote
Lee Chao <932819864@qq.com>
@@ -1563,6 +1575,7 @@ Nick Neisen
Nick Parker
Nick Payne
Nick Russo
+Nick Santos
Nick Stenning
Nick Stinemates
Nick Wood
@@ -1584,6 +1597,7 @@ NikolaMandic
Nikolas Garofil
Nikolay Edigaryev
Nikolay Milovanov
+ningmingxiao
Nirmal Mehta
Nishant Totla
NIWA Hideyuki
@@ -1615,6 +1629,7 @@ Omri Shiv
Onur Filiz
Oriol Francès
Oscar Bonilla <6f6231@gmail.com>
+oscar.chen <2972789494@qq.com>
Oskar Niburski
Otto Kekäläinen
Ouyang Liduo
@@ -1822,6 +1837,7 @@ Rory Hunter
Rory McCune
Ross Boucher
Rovanion Luckey
+Roy Reznik
Royce Remer
Rozhnov Alexandr
Rudolph Gottesheim
@@ -2271,6 +2287,7 @@ Xiaoyu Zhang
xichengliudui <1693291525@qq.com>
xiekeyang
Ximo Guanter Gonzálbez
+xin.li
Xinbo Weng
Xinfeng Liu
Xinzi Zhou
@@ -2282,6 +2299,7 @@ Yahya
yalpul
YAMADA Tsuyoshi
Yamasaki Masahide
+Yamazaki Masashi
Yan Feng
Yan Zhu
Yang Bai
diff --git a/vendor/github.com/docker/docker/api/common.go b/vendor/github.com/docker/docker/api/common.go
index bee9b875a88..cba66bc462b 100644
--- a/vendor/github.com/docker/docker/api/common.go
+++ b/vendor/github.com/docker/docker/api/common.go
@@ -3,7 +3,7 @@ package api // import "github.com/docker/docker/api"
// Common constants for daemon and client.
const (
// DefaultVersion of Current REST API
- DefaultVersion = "1.42"
+ DefaultVersion = "1.43"
// NoBaseImageSpecifier is the symbol used by the FROM
// command to specify that no base image is to be used.
diff --git a/vendor/github.com/docker/docker/api/swagger.yaml b/vendor/github.com/docker/docker/api/swagger.yaml
index afe7a8c371b..c2943888d75 100644
--- a/vendor/github.com/docker/docker/api/swagger.yaml
+++ b/vendor/github.com/docker/docker/api/swagger.yaml
@@ -19,10 +19,10 @@ produces:
consumes:
- "application/json"
- "text/plain"
-basePath: "/v1.42"
+basePath: "/v1.43"
info:
title: "Docker Engine API"
- version: "1.42"
+ version: "1.43"
x-logo:
url: "https://docs.docker.com/assets/images/logo-docker-main.png"
description: |
@@ -55,8 +55,8 @@ info:
the URL is not supported by the daemon, a HTTP `400 Bad Request` error message
is returned.
- If you omit the version-prefix, the current version of the API (v1.42) is used.
- For example, calling `/info` is the same as calling `/v1.42/info`. Using the
+ If you omit the version-prefix, the current version of the API (v1.43) is used.
+ For example, calling `/info` is the same as calling `/v1.43/info`. Using the
API without a version-prefix is deprecated and will be removed in a future release.
Engine releases in the near future should support this version of the API,
@@ -976,6 +976,13 @@ definitions:
items:
type: "integer"
minimum: 0
+ Annotations:
+ type: "object"
+ description: |
+ Arbitrary non-identifying metadata attached to container and
+ provided to the runtime when the container is started.
+ additionalProperties:
+ type: "string"
# Applicable to UNIX platforms
CapAdd:
@@ -1122,6 +1129,7 @@ definitions:
remapping option is enabled.
ShmSize:
type: "integer"
+ format: "int64"
description: |
Size of `/dev/shm` in bytes. If omitted, the system uses 64MB.
minimum: 0
@@ -1610,6 +1618,34 @@ definitions:
"WorkDir": "/var/lib/docker/overlay2/ef749362d13333e65fc95c572eb525abbe0052e16e086cb64bc3b98ae9aa6d74/work"
}
+ FilesystemChange:
+ description: |
+ Change in the container's filesystem.
+ type: "object"
+ required: [Path, Kind]
+ properties:
+ Path:
+ description: |
+ Path to file or directory that has changed.
+ type: "string"
+ x-nullable: false
+ Kind:
+ $ref: "#/definitions/ChangeType"
+
+ ChangeType:
+ description: |
+ Kind of change
+
+ Can be one of:
+
+ - `0`: Modified ("C")
+ - `1`: Added ("A")
+ - `2`: Deleted ("D")
+ type: "integer"
+ format: "uint8"
+ enum: [0, 1, 2]
+ x-nullable: false
+
ImageInspect:
description: |
Information about an image in the local image cache.
@@ -1746,15 +1782,14 @@ definitions:
Total size of the image including all layers it is composed of.
In versions of Docker before v1.10, this field was calculated from
- the image itself and all of its parent images. Docker v1.10 and up
- store images self-contained, and no longer use a parent-chain, making
- this field an equivalent of the Size field.
+ the image itself and all of its parent images. Images are now stored
+ self-contained, and no longer use a parent-chain, making this field
+ an equivalent of the Size field.
- This field is kept for backward compatibility, but may be removed in
- a future version of the API.
+ > **Deprecated**: this field is kept for backward compatibility, but
+ > will be removed in API v1.44.
type: "integer"
format: "int64"
- x-nullable: false
example: 1239828
GraphDriver:
$ref: "#/definitions/GraphDriverData"
@@ -1802,7 +1837,6 @@ definitions:
- Created
- Size
- SharedSize
- - VirtualSize
- Labels
- Containers
properties:
@@ -1888,19 +1922,17 @@ definitions:
x-nullable: false
example: 1239828
VirtualSize:
- description: |
+ description: |-
Total size of the image including all layers it is composed of.
In versions of Docker before v1.10, this field was calculated from
- the image itself and all of its parent images. Docker v1.10 and up
- store images self-contained, and no longer use a parent-chain, making
- this field an equivalent of the Size field.
+ the image itself and all of its parent images. Images are now stored
+ self-contained, and no longer use a parent-chain, making this field
+ an equivalent of the Size field.
- This field is kept for backward compatibility, but may be removed in
- a future version of the API.
+ Deprecated: this field is kept for backward compatibility, and will be removed in API v1.44.
type: "integer"
format: "int64"
- x-nullable: false
example: 172064416
Labels:
description: "User-defined key/value metadata."
@@ -4652,7 +4684,8 @@ definitions:
example: false
OOMKilled:
description: |
- Whether this container has been killed because it ran out of memory.
+ Whether a process within this container has been killed because it ran
+ out of memory since the container was last started.
type: "boolean"
example: false
Dead:
@@ -5242,7 +5275,8 @@ definitions:
SecurityOptions:
description: |
List of security features that are enabled on the daemon, such as
- apparmor, seccomp, SELinux, user-namespaces (userns), and rootless.
+ apparmor, seccomp, SELinux, user-namespaces (userns), rootless and
+ no-new-privileges.
Additional configuration options for each security feature may
be present, and are included as a comma-separated list of key/value
@@ -6875,9 +6909,9 @@ paths:
Returns which files in a container's filesystem have been added, deleted,
or modified. The `Kind` of modification can be one of:
- - `0`: Modified
- - `1`: Added
- - `2`: Deleted
+ - `0`: Modified ("C")
+ - `1`: Added ("A")
+ - `2`: Deleted ("D")
operationId: "ContainerChanges"
produces: ["application/json"]
responses:
@@ -6886,22 +6920,7 @@ paths:
schema:
type: "array"
items:
- type: "object"
- x-go-name: "ContainerChangeResponseItem"
- title: "ContainerChangeResponseItem"
- description: "change item in response to ContainerChanges operation"
- required: [Path, Kind]
- properties:
- Path:
- description: "Path to file that has changed"
- type: "string"
- x-nullable: false
- Kind:
- description: "Kind of change"
- type: "integer"
- format: "uint8"
- enum: [0, 1, 2]
- x-nullable: false
+ $ref: "#/definitions/FilesystemChange"
examples:
application/json:
- Path: "/dev"
@@ -8228,7 +8247,7 @@ paths:
Available filters:
- - `until=`: duration relative to daemon's time, during which build cache was not used, in Go's duration format (e.g., '24h')
+ - `until=` remove cache older than ``. The `` can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed relative to the daemon's local time.
- `id=`
- `parent=`
- `type=`
diff --git a/vendor/github.com/docker/docker/api/types/auth.go b/vendor/github.com/docker/docker/api/types/auth.go
index ddf15bb182d..9ee329a2fba 100644
--- a/vendor/github.com/docker/docker/api/types/auth.go
+++ b/vendor/github.com/docker/docker/api/types/auth.go
@@ -1,22 +1,7 @@
package types // import "github.com/docker/docker/api/types"
+import "github.com/docker/docker/api/types/registry"
-// AuthConfig contains authorization information for connecting to a Registry
-type AuthConfig struct {
- Username string `json:"username,omitempty"`
- Password string `json:"password,omitempty"`
- Auth string `json:"auth,omitempty"`
-
- // Email is an optional value associated with the username.
- // This field is deprecated and will be removed in a later
- // version of docker.
- Email string `json:"email,omitempty"`
-
- ServerAddress string `json:"serveraddress,omitempty"`
-
- // IdentityToken is used to authenticate the user and get
- // an access token for the registry.
- IdentityToken string `json:"identitytoken,omitempty"`
-
- // RegistryToken is a bearer token to be sent to a registry
- RegistryToken string `json:"registrytoken,omitempty"`
-}
+// AuthConfig contains authorization information for connecting to a Registry.
+//
+// Deprecated: use github.com/docker/docker/api/types/registry.AuthConfig
+type AuthConfig = registry.AuthConfig
diff --git a/vendor/github.com/docker/docker/api/types/client.go b/vendor/github.com/docker/docker/api/types/client.go
index 97aca023064..d8cd3061354 100644
--- a/vendor/github.com/docker/docker/api/types/client.go
+++ b/vendor/github.com/docker/docker/api/types/client.go
@@ -7,6 +7,7 @@ import (
"github.com/docker/docker/api/types/container"
"github.com/docker/docker/api/types/filters"
+ "github.com/docker/docker/api/types/registry"
units "github.com/docker/go-units"
)
@@ -180,7 +181,7 @@ type ImageBuildOptions struct {
// at all (nil). See the parsing of buildArgs in
// api/server/router/build/build_routes.go for even more info.
BuildArgs map[string]*string
- AuthConfigs map[string]AuthConfig
+ AuthConfigs map[string]registry.AuthConfig
Context io.Reader
Labels map[string]string
// squash the resulting image's layers to the parent
diff --git a/vendor/github.com/docker/docker/api/types/container/change_response_deprecated.go b/vendor/github.com/docker/docker/api/types/container/change_response_deprecated.go
new file mode 100644
index 00000000000..6b4b47390d4
--- /dev/null
+++ b/vendor/github.com/docker/docker/api/types/container/change_response_deprecated.go
@@ -0,0 +1,6 @@
+package container
+
+// ContainerChangeResponseItem change item in response to ContainerChanges operation
+//
+// Deprecated: use [FilesystemChange].
+type ContainerChangeResponseItem = FilesystemChange
diff --git a/vendor/github.com/docker/docker/api/types/container/change_type.go b/vendor/github.com/docker/docker/api/types/container/change_type.go
new file mode 100644
index 00000000000..fe8d6d36966
--- /dev/null
+++ b/vendor/github.com/docker/docker/api/types/container/change_type.go
@@ -0,0 +1,15 @@
+package container
+
+// This file was generated by the swagger tool.
+// Editing this file might prove futile when you re-run the swagger generate command
+
+// ChangeType Kind of change
+//
+// Can be one of:
+//
+// - `0`: Modified ("C")
+// - `1`: Added ("A")
+// - `2`: Deleted ("D")
+//
+// swagger:model ChangeType
+type ChangeType uint8
diff --git a/vendor/github.com/docker/docker/api/types/container/change_types.go b/vendor/github.com/docker/docker/api/types/container/change_types.go
new file mode 100644
index 00000000000..3a3a83866ec
--- /dev/null
+++ b/vendor/github.com/docker/docker/api/types/container/change_types.go
@@ -0,0 +1,23 @@
+package container
+
+const (
+ // ChangeModify represents the modify operation.
+ ChangeModify ChangeType = 0
+ // ChangeAdd represents the add operation.
+ ChangeAdd ChangeType = 1
+ // ChangeDelete represents the delete operation.
+ ChangeDelete ChangeType = 2
+)
+
+func (ct ChangeType) String() string {
+ switch ct {
+ case ChangeModify:
+ return "C"
+ case ChangeAdd:
+ return "A"
+ case ChangeDelete:
+ return "D"
+ default:
+ return ""
+ }
+}
diff --git a/vendor/github.com/docker/docker/api/types/container/container_changes.go b/vendor/github.com/docker/docker/api/types/container/container_changes.go
deleted file mode 100644
index 16dd5019eef..00000000000
--- a/vendor/github.com/docker/docker/api/types/container/container_changes.go
+++ /dev/null
@@ -1,20 +0,0 @@
-package container // import "github.com/docker/docker/api/types/container"
-
-// ----------------------------------------------------------------------------
-// Code generated by `swagger generate operation`. DO NOT EDIT.
-//
-// See hack/generate-swagger-api.sh
-// ----------------------------------------------------------------------------
-
-// ContainerChangeResponseItem change item in response to ContainerChanges operation
-// swagger:model ContainerChangeResponseItem
-type ContainerChangeResponseItem struct {
-
- // Kind of change
- // Required: true
- Kind uint8 `json:"Kind"`
-
- // Path to file that has changed
- // Required: true
- Path string `json:"Path"`
-}
diff --git a/vendor/github.com/docker/docker/api/types/container/deprecated.go b/vendor/github.com/docker/docker/api/types/container/deprecated.go
deleted file mode 100644
index 0cb70e36381..00000000000
--- a/vendor/github.com/docker/docker/api/types/container/deprecated.go
+++ /dev/null
@@ -1,16 +0,0 @@
-package container // import "github.com/docker/docker/api/types/container"
-
-// ContainerCreateCreatedBody OK response to ContainerCreate operation
-//
-// Deprecated: use CreateResponse
-type ContainerCreateCreatedBody = CreateResponse
-
-// ContainerWaitOKBody OK response to ContainerWait operation
-//
-// Deprecated: use WaitResponse
-type ContainerWaitOKBody = WaitResponse
-
-// ContainerWaitOKBodyError container waiting error, if any
-//
-// Deprecated: use WaitExitError
-type ContainerWaitOKBodyError = WaitExitError
diff --git a/vendor/github.com/docker/docker/api/types/container/filesystem_change.go b/vendor/github.com/docker/docker/api/types/container/filesystem_change.go
new file mode 100644
index 00000000000..9e9c2ad1d58
--- /dev/null
+++ b/vendor/github.com/docker/docker/api/types/container/filesystem_change.go
@@ -0,0 +1,19 @@
+package container
+
+// This file was generated by the swagger tool.
+// Editing this file might prove futile when you re-run the swagger generate command
+
+// FilesystemChange Change in the container's filesystem.
+//
+// swagger:model FilesystemChange
+type FilesystemChange struct {
+
+ // kind
+ // Required: true
+ Kind ChangeType `json:"Kind"`
+
+ // Path to file or directory that has changed.
+ //
+ // Required: true
+ Path string `json:"Path"`
+}
diff --git a/vendor/github.com/docker/docker/api/types/container/host_config.go b/vendor/github.com/docker/docker/api/types/container/hostconfig.go
similarity index 84%
rename from vendor/github.com/docker/docker/api/types/container/host_config.go
rename to vendor/github.com/docker/docker/api/types/container/hostconfig.go
index 100f434ce7f..d4e6f55375a 100644
--- a/vendor/github.com/docker/docker/api/types/container/host_config.go
+++ b/vendor/github.com/docker/docker/api/types/container/hostconfig.go
@@ -101,7 +101,8 @@ func (n IpcMode) IsShareable() bool {
// IsContainer indicates whether the container uses another container's ipc namespace.
func (n IpcMode) IsContainer() bool {
- return strings.HasPrefix(string(n), string(IPCModeContainer)+":")
+ _, ok := containerID(string(n))
+ return ok
}
// IsNone indicates whether container IpcMode is set to "none".
@@ -116,15 +117,14 @@ func (n IpcMode) IsEmpty() bool {
// Valid indicates whether the ipc mode is valid.
func (n IpcMode) Valid() bool {
+ // TODO(thaJeztah): align with PidMode, and consider container-mode without a container name/ID to be invalid.
return n.IsEmpty() || n.IsNone() || n.IsPrivate() || n.IsHost() || n.IsShareable() || n.IsContainer()
}
// Container returns the name of the container ipc stack is going to be used.
-func (n IpcMode) Container() string {
- if n.IsContainer() {
- return strings.TrimPrefix(string(n), string(IPCModeContainer)+":")
- }
- return ""
+func (n IpcMode) Container() (idOrName string) {
+ idOrName, _ = containerID(string(n))
+ return idOrName
}
// NetworkMode represents the container network stack.
@@ -147,17 +147,14 @@ func (n NetworkMode) IsPrivate() bool {
// IsContainer indicates whether container uses a container network stack.
func (n NetworkMode) IsContainer() bool {
- parts := strings.SplitN(string(n), ":", 2)
- return len(parts) > 1 && parts[0] == "container"
+ _, ok := containerID(string(n))
+ return ok
}
// ConnectedContainer is the id of the container which network this container is connected to.
-func (n NetworkMode) ConnectedContainer() string {
- parts := strings.SplitN(string(n), ":", 2)
- if len(parts) > 1 {
- return parts[1]
- }
- return ""
+func (n NetworkMode) ConnectedContainer() (idOrName string) {
+ idOrName, _ = containerID(string(n))
+ return idOrName
}
// UserDefined indicates user-created network
@@ -178,18 +175,12 @@ func (n UsernsMode) IsHost() bool {
// IsPrivate indicates whether the container uses the a private userns.
func (n UsernsMode) IsPrivate() bool {
- return !(n.IsHost())
+ return !n.IsHost()
}
// Valid indicates whether the userns is valid.
func (n UsernsMode) Valid() bool {
- parts := strings.Split(string(n), ":")
- switch mode := parts[0]; mode {
- case "", "host":
- default:
- return false
- }
- return true
+ return n == "" || n.IsHost()
}
// CgroupSpec represents the cgroup to use for the container.
@@ -197,22 +188,20 @@ type CgroupSpec string
// IsContainer indicates whether the container is using another container cgroup
func (c CgroupSpec) IsContainer() bool {
- parts := strings.SplitN(string(c), ":", 2)
- return len(parts) > 1 && parts[0] == "container"
+ _, ok := containerID(string(c))
+ return ok
}
// Valid indicates whether the cgroup spec is valid.
func (c CgroupSpec) Valid() bool {
- return c.IsContainer() || c == ""
+ // TODO(thaJeztah): align with PidMode, and consider container-mode without a container name/ID to be invalid.
+ return c == "" || c.IsContainer()
}
-// Container returns the name of the container whose cgroup will be used.
-func (c CgroupSpec) Container() string {
- parts := strings.SplitN(string(c), ":", 2)
- if len(parts) > 1 {
- return parts[1]
- }
- return ""
+// Container returns the ID or name of the container whose cgroup will be used.
+func (c CgroupSpec) Container() (idOrName string) {
+ idOrName, _ = containerID(string(c))
+ return idOrName
}
// UTSMode represents the UTS namespace of the container.
@@ -220,7 +209,7 @@ type UTSMode string
// IsPrivate indicates whether the container uses its private UTS namespace.
func (n UTSMode) IsPrivate() bool {
- return !(n.IsHost())
+ return !n.IsHost()
}
// IsHost indicates whether the container uses the host's UTS namespace.
@@ -230,13 +219,7 @@ func (n UTSMode) IsHost() bool {
// Valid indicates whether the UTS namespace is valid.
func (n UTSMode) Valid() bool {
- parts := strings.Split(string(n), ":")
- switch mode := parts[0]; mode {
- case "", "host":
- default:
- return false
- }
- return true
+ return n == "" || n.IsHost()
}
// PidMode represents the pid namespace of the container.
@@ -254,32 +237,19 @@ func (n PidMode) IsHost() bool {
// IsContainer indicates whether the container uses a container's pid namespace.
func (n PidMode) IsContainer() bool {
- parts := strings.SplitN(string(n), ":", 2)
- return len(parts) > 1 && parts[0] == "container"
+ _, ok := containerID(string(n))
+ return ok
}
// Valid indicates whether the pid namespace is valid.
func (n PidMode) Valid() bool {
- parts := strings.Split(string(n), ":")
- switch mode := parts[0]; mode {
- case "", "host":
- case "container":
- if len(parts) != 2 || parts[1] == "" {
- return false
- }
- default:
- return false
- }
- return true
+ return n == "" || n.IsHost() || validContainer(string(n))
}
// Container returns the name of the container whose pid namespace is going to be used.
-func (n PidMode) Container() string {
- parts := strings.SplitN(string(n), ":", 2)
- if len(parts) > 1 {
- return parts[1]
- }
- return ""
+func (n PidMode) Container() (idOrName string) {
+ idOrName, _ = containerID(string(n))
+ return idOrName
}
// DeviceRequest represents a request for devices from a device driver.
@@ -408,16 +378,17 @@ type UpdateConfig struct {
// Portable information *should* appear in Config.
type HostConfig struct {
// Applicable to all platforms
- Binds []string // List of volume bindings for this container
- ContainerIDFile string // File (path) where the containerId is written
- LogConfig LogConfig // Configuration of the logs for this container
- NetworkMode NetworkMode // Network mode to use for the container
- PortBindings nat.PortMap // Port mapping between the exposed port (container) and the host
- RestartPolicy RestartPolicy // Restart policy to be used for the container
- AutoRemove bool // Automatically remove container when it exits
- VolumeDriver string // Name of the volume driver used to mount volumes
- VolumesFrom []string // List of volumes to take from other container
- ConsoleSize [2]uint // Initial console size (height,width)
+ Binds []string // List of volume bindings for this container
+ ContainerIDFile string // File (path) where the containerId is written
+ LogConfig LogConfig // Configuration of the logs for this container
+ NetworkMode NetworkMode // Network mode to use for the container
+ PortBindings nat.PortMap // Port mapping between the exposed port (container) and the host
+ RestartPolicy RestartPolicy // Restart policy to be used for the container
+ AutoRemove bool // Automatically remove container when it exits
+ VolumeDriver string // Name of the volume driver used to mount volumes
+ VolumesFrom []string // List of volumes to take from other container
+ ConsoleSize [2]uint // Initial console size (height,width)
+ Annotations map[string]string `json:",omitempty"` // Arbitrary non-identifying metadata attached to container and provided to the runtime
// Applicable to UNIX platforms
CapAdd strslice.StrSlice // List of kernel capabilities to add to the container
@@ -463,3 +434,23 @@ type HostConfig struct {
// Run a custom init inside the container, if null, use the daemon's configured settings
Init *bool `json:",omitempty"`
}
+
+// containerID splits "container:" values. It returns the container
+// ID or name, and whether an ID/name was found. It returns an empty string and
+// a "false" if the value does not have a "container:" prefix. Further validation
+// of the returned, including checking if the value is empty, should be handled
+// by the caller.
+func containerID(val string) (idOrName string, ok bool) {
+ k, v, hasSep := strings.Cut(val, ":")
+ if !hasSep || k != "container" {
+ return "", false
+ }
+ return v, true
+}
+
+// validContainer checks if the given value is a "container:" mode with
+// a non-empty name/ID.
+func validContainer(val string) bool {
+ id, ok := containerID(val)
+ return ok && id != ""
+}
diff --git a/vendor/github.com/docker/docker/api/types/deprecated.go b/vendor/github.com/docker/docker/api/types/deprecated.go
deleted file mode 100644
index 216d1df0ffa..00000000000
--- a/vendor/github.com/docker/docker/api/types/deprecated.go
+++ /dev/null
@@ -1,14 +0,0 @@
-package types // import "github.com/docker/docker/api/types"
-
-import "github.com/docker/docker/api/types/volume"
-
-// Volume volume
-//
-// Deprecated: use github.com/docker/docker/api/types/volume.Volume
-type Volume = volume.Volume
-
-// VolumeUsageData Usage details about the volume. This information is used by the
-// `GET /system/df` endpoint, and omitted in other endpoints.
-//
-// Deprecated: use github.com/docker/docker/api/types/volume.UsageData
-type VolumeUsageData = volume.UsageData
diff --git a/vendor/github.com/docker/docker/api/types/filters/errors.go b/vendor/github.com/docker/docker/api/types/filters/errors.go
new file mode 100644
index 00000000000..f52f6944089
--- /dev/null
+++ b/vendor/github.com/docker/docker/api/types/filters/errors.go
@@ -0,0 +1,37 @@
+package filters
+
+import "fmt"
+
+// invalidFilter indicates that the provided filter or its value is invalid
+type invalidFilter struct {
+ Filter string
+ Value []string
+}
+
+func (e invalidFilter) Error() string {
+ msg := "invalid filter"
+ if e.Filter != "" {
+ msg += " '" + e.Filter
+ if e.Value != nil {
+ msg = fmt.Sprintf("%s=%s", msg, e.Value)
+ }
+ msg += "'"
+ }
+ return msg
+}
+
+// InvalidParameter marks this error as ErrInvalidParameter
+func (e invalidFilter) InvalidParameter() {}
+
+// unreachableCode is an error indicating that the code path was not expected to be reached.
+type unreachableCode struct {
+ Filter string
+ Value []string
+}
+
+// System marks this error as ErrSystem
+func (e unreachableCode) System() {}
+
+func (e unreachableCode) Error() string {
+ return fmt.Sprintf("unreachable code reached for filter: %q with values: %s", e.Filter, e.Value)
+}
diff --git a/vendor/github.com/docker/docker/api/types/filters/parse.go b/vendor/github.com/docker/docker/api/types/filters/parse.go
index f8fe7940741..887648cf3e3 100644
--- a/vendor/github.com/docker/docker/api/types/filters/parse.go
+++ b/vendor/github.com/docker/docker/api/types/filters/parse.go
@@ -10,7 +10,6 @@ import (
"strings"
"github.com/docker/docker/api/types/versions"
- "github.com/pkg/errors"
)
// Args stores a mapping of keys to a set of multiple values.
@@ -99,7 +98,7 @@ func FromJSON(p string) (Args, error) {
// Fallback to parsing arguments in the legacy slice format
deprecated := map[string][]string{}
if legacyErr := json.Unmarshal(raw, &deprecated); legacyErr != nil {
- return args, invalidFilter{errors.Wrap(err, "invalid filter")}
+ return args, invalidFilter{}
}
args.fields = deprecatedArgs(deprecated)
@@ -163,13 +162,13 @@ func (args Args) MatchKVList(key string, sources map[string]string) bool {
}
for value := range fieldValues {
- testKV := strings.SplitN(value, "=", 2)
+ testK, testV, hasValue := strings.Cut(value, "=")
- v, ok := sources[testKV[0]]
+ v, ok := sources[testK]
if !ok {
return false
}
- if len(testKV) == 2 && testKV[1] != v {
+ if hasValue && testV != v {
return false
}
}
@@ -196,6 +195,38 @@ func (args Args) Match(field, source string) bool {
return false
}
+// GetBoolOrDefault returns a boolean value of the key if the key is present
+// and is intepretable as a boolean value. Otherwise the default value is returned.
+// Error is not nil only if the filter values are not valid boolean or are conflicting.
+func (args Args) GetBoolOrDefault(key string, defaultValue bool) (bool, error) {
+ fieldValues, ok := args.fields[key]
+
+ if !ok {
+ return defaultValue, nil
+ }
+
+ if len(fieldValues) == 0 {
+ return defaultValue, invalidFilter{key, nil}
+ }
+
+ isFalse := fieldValues["0"] || fieldValues["false"]
+ isTrue := fieldValues["1"] || fieldValues["true"]
+
+ conflicting := isFalse && isTrue
+ invalid := !isFalse && !isTrue
+
+ if conflicting || invalid {
+ return defaultValue, invalidFilter{key, args.Get(key)}
+ } else if isFalse {
+ return false, nil
+ } else if isTrue {
+ return true, nil
+ }
+
+ // This code shouldn't be reached.
+ return defaultValue, unreachableCode{Filter: key, Value: args.Get(key)}
+}
+
// ExactMatch returns true if the source matches exactly one of the values.
func (args Args) ExactMatch(key, source string) bool {
fieldValues, ok := args.fields[key]
@@ -246,20 +277,12 @@ func (args Args) Contains(field string) bool {
return ok
}
-type invalidFilter struct{ error }
-
-func (e invalidFilter) Error() string {
- return e.error.Error()
-}
-
-func (invalidFilter) InvalidParameter() {}
-
// Validate compared the set of accepted keys against the keys in the mapping.
// An error is returned if any mapping keys are not in the accepted set.
func (args Args) Validate(accepted map[string]bool) error {
for name := range args.fields {
if !accepted[name] {
- return invalidFilter{errors.New("invalid filter '" + name + "'")}
+ return invalidFilter{name, nil}
}
}
return nil
diff --git a/vendor/github.com/docker/docker/api/types/image/opts.go b/vendor/github.com/docker/docker/api/types/image/opts.go
new file mode 100644
index 00000000000..a24f9059ab4
--- /dev/null
+++ b/vendor/github.com/docker/docker/api/types/image/opts.go
@@ -0,0 +1,9 @@
+package image
+
+import specs "github.com/opencontainers/image-spec/specs-go/v1"
+
+// GetImageOpts holds parameters to inspect an image.
+type GetImageOpts struct {
+ Platform *specs.Platform
+ Details bool
+}
diff --git a/vendor/github.com/docker/docker/api/types/image_summary.go b/vendor/github.com/docker/docker/api/types/image_summary.go
index 90b983a25cc..0f6f144840e 100644
--- a/vendor/github.com/docker/docker/api/types/image_summary.go
+++ b/vendor/github.com/docker/docker/api/types/image_summary.go
@@ -85,13 +85,10 @@ type ImageSummary struct {
// Total size of the image including all layers it is composed of.
//
// In versions of Docker before v1.10, this field was calculated from
- // the image itself and all of its parent images. Docker v1.10 and up
- // store images self-contained, and no longer use a parent-chain, making
- // this field an equivalent of the Size field.
+ // the image itself and all of its parent images. Images are now stored
+ // self-contained, and no longer use a parent-chain, making this field
+ // an equivalent of the Size field.
//
- // This field is kept for backward compatibility, but may be removed in
- // a future version of the API.
- //
- // Required: true
- VirtualSize int64 `json:"VirtualSize"`
+ // Deprecated: this field is kept for backward compatibility, and will be removed in API v1.44.
+ VirtualSize int64 `json:"VirtualSize,omitempty"`
}
diff --git a/vendor/github.com/docker/docker/api/types/registry/authconfig.go b/vendor/github.com/docker/docker/api/types/registry/authconfig.go
new file mode 100644
index 00000000000..97a924e3747
--- /dev/null
+++ b/vendor/github.com/docker/docker/api/types/registry/authconfig.go
@@ -0,0 +1,99 @@
+package registry // import "github.com/docker/docker/api/types/registry"
+import (
+ "encoding/base64"
+ "encoding/json"
+ "io"
+ "strings"
+
+ "github.com/pkg/errors"
+)
+
+// AuthHeader is the name of the header used to send encoded registry
+// authorization credentials for registry operations (push/pull).
+const AuthHeader = "X-Registry-Auth"
+
+// AuthConfig contains authorization information for connecting to a Registry.
+type AuthConfig struct {
+ Username string `json:"username,omitempty"`
+ Password string `json:"password,omitempty"`
+ Auth string `json:"auth,omitempty"`
+
+ // Email is an optional value associated with the username.
+ // This field is deprecated and will be removed in a later
+ // version of docker.
+ Email string `json:"email,omitempty"`
+
+ ServerAddress string `json:"serveraddress,omitempty"`
+
+ // IdentityToken is used to authenticate the user and get
+ // an access token for the registry.
+ IdentityToken string `json:"identitytoken,omitempty"`
+
+ // RegistryToken is a bearer token to be sent to a registry
+ RegistryToken string `json:"registrytoken,omitempty"`
+}
+
+// EncodeAuthConfig serializes the auth configuration as a base64url encoded
+// RFC4648, section 5) JSON string for sending through the X-Registry-Auth header.
+//
+// For details on base64url encoding, see:
+// - RFC4648, section 5: https://tools.ietf.org/html/rfc4648#section-5
+func EncodeAuthConfig(authConfig AuthConfig) (string, error) {
+ buf, err := json.Marshal(authConfig)
+ if err != nil {
+ return "", errInvalidParameter{err}
+ }
+ return base64.URLEncoding.EncodeToString(buf), nil
+}
+
+// DecodeAuthConfig decodes base64url encoded (RFC4648, section 5) JSON
+// authentication information as sent through the X-Registry-Auth header.
+//
+// This function always returns an AuthConfig, even if an error occurs. It is up
+// to the caller to decide if authentication is required, and if the error can
+// be ignored.
+//
+// For details on base64url encoding, see:
+// - RFC4648, section 5: https://tools.ietf.org/html/rfc4648#section-5
+func DecodeAuthConfig(authEncoded string) (*AuthConfig, error) {
+ if authEncoded == "" {
+ return &AuthConfig{}, nil
+ }
+
+ authJSON := base64.NewDecoder(base64.URLEncoding, strings.NewReader(authEncoded))
+ return decodeAuthConfigFromReader(authJSON)
+}
+
+// DecodeAuthConfigBody decodes authentication information as sent as JSON in the
+// body of a request. This function is to provide backward compatibility with old
+// clients and API versions. Current clients and API versions expect authentication
+// to be provided through the X-Registry-Auth header.
+//
+// Like DecodeAuthConfig, this function always returns an AuthConfig, even if an
+// error occurs. It is up to the caller to decide if authentication is required,
+// and if the error can be ignored.
+func DecodeAuthConfigBody(rdr io.ReadCloser) (*AuthConfig, error) {
+ return decodeAuthConfigFromReader(rdr)
+}
+
+func decodeAuthConfigFromReader(rdr io.Reader) (*AuthConfig, error) {
+ authConfig := &AuthConfig{}
+ if err := json.NewDecoder(rdr).Decode(authConfig); err != nil {
+ // always return an (empty) AuthConfig to increase compatibility with
+ // the existing API.
+ return &AuthConfig{}, invalid(err)
+ }
+ return authConfig, nil
+}
+
+func invalid(err error) error {
+ return errInvalidParameter{errors.Wrap(err, "invalid X-Registry-Auth header")}
+}
+
+type errInvalidParameter struct{ error }
+
+func (errInvalidParameter) InvalidParameter() {}
+
+func (e errInvalidParameter) Cause() error { return e.error }
+
+func (e errInvalidParameter) Unwrap() error { return e.error }
diff --git a/vendor/github.com/docker/docker/api/types/time/timestamp.go b/vendor/github.com/docker/docker/api/types/time/timestamp.go
index 2a74b7a5979..cab5c32e3ff 100644
--- a/vendor/github.com/docker/docker/api/types/time/timestamp.go
+++ b/vendor/github.com/docker/docker/api/types/time/timestamp.go
@@ -95,37 +95,37 @@ func GetTimestamp(value string, reference time.Time) (string, error) {
return fmt.Sprintf("%d.%09d", t.Unix(), int64(t.Nanosecond())), nil
}
-// ParseTimestamps returns seconds and nanoseconds from a timestamp that has the
-// format "%d.%09d", time.Unix(), int64(time.Nanosecond()))
-// if the incoming nanosecond portion is longer or shorter than 9 digits it is
-// converted to nanoseconds. The expectation is that the seconds and
-// seconds will be used to create a time variable. For example:
+// ParseTimestamps returns seconds and nanoseconds from a timestamp that has
+// the format ("%d.%09d", time.Unix(), int64(time.Nanosecond())).
+// If the incoming nanosecond portion is longer than 9 digits it is truncated.
+// The expectation is that the seconds and nanoseconds will be used to create a
+// time variable. For example:
//
-// seconds, nanoseconds, err := ParseTimestamp("1136073600.000000001",0)
-// if err == nil since := time.Unix(seconds, nanoseconds)
+// seconds, nanoseconds, _ := ParseTimestamp("1136073600.000000001",0)
+// since := time.Unix(seconds, nanoseconds)
//
-// returns seconds as def(aultSeconds) if value == ""
-func ParseTimestamps(value string, def int64) (int64, int64, error) {
+// returns seconds as defaultSeconds if value == ""
+func ParseTimestamps(value string, defaultSeconds int64) (seconds int64, nanoseconds int64, err error) {
if value == "" {
- return def, 0, nil
+ return defaultSeconds, 0, nil
}
return parseTimestamp(value)
}
-func parseTimestamp(value string) (int64, int64, error) {
- sa := strings.SplitN(value, ".", 2)
- s, err := strconv.ParseInt(sa[0], 10, 64)
+func parseTimestamp(value string) (sec int64, nsec int64, err error) {
+ s, n, ok := strings.Cut(value, ".")
+ sec, err = strconv.ParseInt(s, 10, 64)
if err != nil {
- return s, 0, err
+ return sec, 0, err
}
- if len(sa) != 2 {
- return s, 0, nil
+ if !ok {
+ return sec, 0, nil
}
- n, err := strconv.ParseInt(sa[1], 10, 64)
+ nsec, err = strconv.ParseInt(n, 10, 64)
if err != nil {
- return s, n, err
+ return sec, nsec, err
}
// should already be in nanoseconds but just in case convert n to nanoseconds
- n = int64(float64(n) * math.Pow(float64(10), float64(9-len(sa[1]))))
- return s, n, nil
+ nsec = int64(float64(nsec) * math.Pow(float64(10), float64(9-len(n))))
+ return sec, nsec, nil
}
diff --git a/vendor/github.com/docker/docker/api/types/types.go b/vendor/github.com/docker/docker/api/types/types.go
index 036405299ea..b413e020006 100644
--- a/vendor/github.com/docker/docker/api/types/types.go
+++ b/vendor/github.com/docker/docker/api/types/types.go
@@ -123,9 +123,8 @@ type ImageInspect struct {
// store images self-contained, and no longer use a parent-chain, making
// this field an equivalent of the Size field.
//
- // This field is kept for backward compatibility, but may be removed in
- // a future version of the API.
- VirtualSize int64 // TODO(thaJeztah): deprecate this field
+ // Deprecated: Unused in API 1.43 and up, but kept for backward compatibility with older API versions.
+ VirtualSize int64 `json:"VirtualSize,omitempty"`
// GraphDriver holds information about the storage driver used to store the
// container's and image's filesystem.
@@ -297,8 +296,6 @@ type Info struct {
Labels []string
ExperimentalBuild bool
ServerVersion string
- ClusterStore string `json:",omitempty"` // Deprecated: host-discovery and overlay networks with external k/v stores are deprecated
- ClusterAdvertise string `json:",omitempty"` // Deprecated: host-discovery and overlay networks with external k/v stores are deprecated
Runtimes map[string]Runtime
DefaultRuntime string
Swarm swarm.Info
@@ -350,20 +347,19 @@ func DecodeSecurityOptions(opts []string) ([]SecurityOpt, error) {
continue
}
secopt := SecurityOpt{}
- split := strings.Split(opt, ",")
- for _, s := range split {
- kv := strings.SplitN(s, "=", 2)
- if len(kv) != 2 {
+ for _, s := range strings.Split(opt, ",") {
+ k, v, ok := strings.Cut(s, "=")
+ if !ok {
return nil, fmt.Errorf("invalid security option %q", s)
}
- if kv[0] == "" || kv[1] == "" {
+ if k == "" || v == "" {
return nil, errors.New("invalid empty security option")
}
- if kv[0] == "name" {
- secopt.Name = kv[1]
+ if k == "name" {
+ secopt.Name = v
continue
}
- secopt.Options = append(secopt.Options, KeyValue{Key: kv[0], Value: kv[1]})
+ secopt.Options = append(secopt.Options, KeyValue{Key: k, Value: v})
}
so = append(so, secopt)
}
@@ -656,12 +652,18 @@ type Checkpoint struct {
// Runtime describes an OCI runtime
type Runtime struct {
- Path string `json:"path"`
+ // "Legacy" runtime configuration for runc-compatible runtimes.
+
+ Path string `json:"path,omitempty"`
Args []string `json:"runtimeArgs,omitempty"`
+ // Shimv2 runtime configuration. Mutually exclusive with the legacy config above.
+
+ Type string `json:"runtimeType,omitempty"`
+ Options map[string]interface{} `json:"options,omitempty"`
+
// This is exposed here only for internal use
- // It is not currently supported to specify custom shim configs
- Shim *ShimConfig `json:"-"`
+ ShimConfig *ShimConfig `json:"-"`
}
// ShimConfig is used by runtime to configure containerd shims
diff --git a/vendor/github.com/docker/docker/api/types/volume/deprecated.go b/vendor/github.com/docker/docker/api/types/volume/deprecated.go
deleted file mode 100644
index ab622d8ccb4..00000000000
--- a/vendor/github.com/docker/docker/api/types/volume/deprecated.go
+++ /dev/null
@@ -1,11 +0,0 @@
-package volume // import "github.com/docker/docker/api/types/volume"
-
-// VolumeCreateBody Volume configuration
-//
-// Deprecated: use CreateOptions
-type VolumeCreateBody = CreateOptions
-
-// VolumeListOKBody Volume list response
-//
-// Deprecated: use ListResponse
-type VolumeListOKBody = ListResponse
diff --git a/vendor/github.com/docker/docker/client/build_prune.go b/vendor/github.com/docker/docker/client/build_prune.go
index 397d67cdcf1..2b6606236eb 100644
--- a/vendor/github.com/docker/docker/client/build_prune.go
+++ b/vendor/github.com/docker/docker/client/build_prune.go
@@ -3,8 +3,8 @@ package client // import "github.com/docker/docker/client"
import (
"context"
"encoding/json"
- "fmt"
"net/url"
+ "strconv"
"github.com/docker/docker/api/types"
"github.com/docker/docker/api/types/filters"
@@ -23,12 +23,12 @@ func (cli *Client) BuildCachePrune(ctx context.Context, opts types.BuildCachePru
if opts.All {
query.Set("all", "1")
}
- query.Set("keep-storage", fmt.Sprintf("%d", opts.KeepStorage))
- filters, err := filters.ToJSON(opts.Filters)
+ query.Set("keep-storage", strconv.Itoa(int(opts.KeepStorage)))
+ f, err := filters.ToJSON(opts.Filters)
if err != nil {
return nil, errors.Wrap(err, "prune could not marshal filters option")
}
- query.Set("filters", filters)
+ query.Set("filters", f)
serverResp, err := cli.post(ctx, "/build/prune", query, nil, nil)
defer ensureReaderClosed(serverResp)
@@ -38,7 +38,7 @@ func (cli *Client) BuildCachePrune(ctx context.Context, opts types.BuildCachePru
}
if err := json.NewDecoder(serverResp.body).Decode(&report); err != nil {
- return nil, fmt.Errorf("Error retrieving disk usage: %v", err)
+ return nil, errors.Wrap(err, "error retrieving disk usage")
}
return &report, nil
diff --git a/vendor/github.com/docker/docker/client/client.go b/vendor/github.com/docker/docker/client/client.go
index 26a0fa27562..1c081a51ae6 100644
--- a/vendor/github.com/docker/docker/client/client.go
+++ b/vendor/github.com/docker/docker/client/client.go
@@ -6,9 +6,10 @@ https://docs.docker.com/engine/api/
# Usage
-You use the library by creating a client object and calling methods on it. The
-client can be created either from environment variables with NewClientWithOpts(client.FromEnv),
-or configured manually with NewClient().
+You use the library by constructing a client object using [NewClientWithOpts]
+and calling methods on it. The client can be configured from environment
+variables by passing the [FromEnv] option, or configured manually by passing any
+of the other available [Opts].
For example, to list running containers (the equivalent of "docker ps"):
@@ -125,7 +126,12 @@ func CheckRedirect(req *http.Request, via []*http.Request) error {
// client.WithAPIVersionNegotiation(),
// )
func NewClientWithOpts(ops ...Opt) (*Client, error) {
- client, err := defaultHTTPClient(DefaultDockerHost)
+ hostURL, err := ParseHostURL(DefaultDockerHost)
+ if err != nil {
+ return nil, err
+ }
+
+ client, err := defaultHTTPClient(hostURL)
if err != nil {
return nil, err
}
@@ -133,8 +139,8 @@ func NewClientWithOpts(ops ...Opt) (*Client, error) {
host: DefaultDockerHost,
version: api.DefaultVersion,
client: client,
- proto: defaultProto,
- addr: defaultAddr,
+ proto: hostURL.Scheme,
+ addr: hostURL.Host,
}
for _, op := range ops {
@@ -160,13 +166,12 @@ func NewClientWithOpts(ops ...Opt) (*Client, error) {
return c, nil
}
-func defaultHTTPClient(host string) (*http.Client, error) {
- hostURL, err := ParseHostURL(host)
+func defaultHTTPClient(hostURL *url.URL) (*http.Client, error) {
+ transport := &http.Transport{}
+ err := sockets.ConfigureTransport(transport, hostURL.Scheme, hostURL.Host)
if err != nil {
return nil, err
}
- transport := &http.Transport{}
- _ = sockets.ConfigureTransport(transport, hostURL.Scheme, hostURL.Host)
return &http.Client{
Transport: transport,
CheckRedirect: CheckRedirect,
@@ -282,13 +287,12 @@ func (cli *Client) HTTPClient() *http.Client {
// ParseHostURL parses a url string, validates the string is a host url, and
// returns the parsed URL
func ParseHostURL(host string) (*url.URL, error) {
- protoAddrParts := strings.SplitN(host, "://", 2)
- if len(protoAddrParts) == 1 {
+ proto, addr, ok := strings.Cut(host, "://")
+ if !ok || addr == "" {
return nil, errors.Errorf("unable to parse docker host `%s`", host)
}
var basePath string
- proto, addr := protoAddrParts[0], protoAddrParts[1]
if proto == "tcp" {
parsed, err := url.Parse("tcp://" + addr)
if err != nil {
diff --git a/vendor/github.com/docker/docker/client/client_deprecated.go b/vendor/github.com/docker/docker/client/client_deprecated.go
index 54cdfc29a84..9e366ce20d1 100644
--- a/vendor/github.com/docker/docker/client/client_deprecated.go
+++ b/vendor/github.com/docker/docker/client/client_deprecated.go
@@ -9,7 +9,11 @@ import "net/http"
// It won't send any version information if the version number is empty. It is
// highly recommended that you set a version or your client may break if the
// server is upgraded.
-// Deprecated: use NewClientWithOpts
+//
+// Deprecated: use [NewClientWithOpts] passing the [WithHost], [WithVersion],
+// [WithHTTPClient] and [WithHTTPHeaders] options. We recommend enabling API
+// version negotiation by passing the [WithAPIVersionNegotiation] option instead
+// of WithVersion.
func NewClient(host string, version string, client *http.Client, httpHeaders map[string]string) (*Client, error) {
return NewClientWithOpts(WithHost(host), WithVersion(version), WithHTTPClient(client), WithHTTPHeaders(httpHeaders))
}
@@ -17,7 +21,7 @@ func NewClient(host string, version string, client *http.Client, httpHeaders map
// NewEnvClient initializes a new API client based on environment variables.
// See FromEnv for a list of support environment variables.
//
-// Deprecated: use NewClientWithOpts(FromEnv)
+// Deprecated: use [NewClientWithOpts] passing the [FromEnv] option.
func NewEnvClient() (*Client, error) {
return NewClientWithOpts(FromEnv)
}
diff --git a/vendor/github.com/docker/docker/client/client_unix.go b/vendor/github.com/docker/docker/client/client_unix.go
index f0783f70858..319b738d3e2 100644
--- a/vendor/github.com/docker/docker/client/client_unix.go
+++ b/vendor/github.com/docker/docker/client/client_unix.go
@@ -1,11 +1,8 @@
-//go:build linux || freebsd || openbsd || netbsd || darwin || solaris || illumos || dragonfly
-// +build linux freebsd openbsd netbsd darwin solaris illumos dragonfly
+//go:build !windows
+// +build !windows
package client // import "github.com/docker/docker/client"
// DefaultDockerHost defines OS-specific default host if the DOCKER_HOST
// (EnvOverrideHost) environment variable is unset or empty.
const DefaultDockerHost = "unix:///var/run/docker.sock"
-
-const defaultProto = "unix"
-const defaultAddr = "/var/run/docker.sock"
diff --git a/vendor/github.com/docker/docker/client/client_windows.go b/vendor/github.com/docker/docker/client/client_windows.go
index 5abe60457d5..56572d1a27f 100644
--- a/vendor/github.com/docker/docker/client/client_windows.go
+++ b/vendor/github.com/docker/docker/client/client_windows.go
@@ -3,6 +3,3 @@ package client // import "github.com/docker/docker/client"
// DefaultDockerHost defines OS-specific default host if the DOCKER_HOST
// (EnvOverrideHost) environment variable is unset or empty.
const DefaultDockerHost = "npipe:////./pipe/docker_engine"
-
-const defaultProto = "npipe"
-const defaultAddr = "//./pipe/docker_engine"
diff --git a/vendor/github.com/docker/docker/client/container_diff.go b/vendor/github.com/docker/docker/client/container_diff.go
index 29dac8491df..c22c819a798 100644
--- a/vendor/github.com/docker/docker/client/container_diff.go
+++ b/vendor/github.com/docker/docker/client/container_diff.go
@@ -9,8 +9,8 @@ import (
)
// ContainerDiff shows differences in a container filesystem since it was started.
-func (cli *Client) ContainerDiff(ctx context.Context, containerID string) ([]container.ContainerChangeResponseItem, error) {
- var changes []container.ContainerChangeResponseItem
+func (cli *Client) ContainerDiff(ctx context.Context, containerID string) ([]container.FilesystemChange, error) {
+ var changes []container.FilesystemChange
serverResp, err := cli.get(ctx, "/containers/"+containerID+"/changes", url.Values{}, nil)
defer ensureReaderClosed(serverResp)
diff --git a/vendor/github.com/docker/docker/client/distribution_inspect.go b/vendor/github.com/docker/docker/client/distribution_inspect.go
index 7f36c99a016..efab066d3bd 100644
--- a/vendor/github.com/docker/docker/client/distribution_inspect.go
+++ b/vendor/github.com/docker/docker/client/distribution_inspect.go
@@ -5,13 +5,13 @@ import (
"encoding/json"
"net/url"
- registrytypes "github.com/docker/docker/api/types/registry"
+ "github.com/docker/docker/api/types/registry"
)
// DistributionInspect returns the image digest with the full manifest.
-func (cli *Client) DistributionInspect(ctx context.Context, image, encodedRegistryAuth string) (registrytypes.DistributionInspect, error) {
+func (cli *Client) DistributionInspect(ctx context.Context, image, encodedRegistryAuth string) (registry.DistributionInspect, error) {
// Contact the registry to retrieve digest and platform information
- var distributionInspect registrytypes.DistributionInspect
+ var distributionInspect registry.DistributionInspect
if image == "" {
return distributionInspect, objectNotFoundError{object: "distribution", id: image}
}
@@ -23,7 +23,7 @@ func (cli *Client) DistributionInspect(ctx context.Context, image, encodedRegist
if encodedRegistryAuth != "" {
headers = map[string][]string{
- "X-Registry-Auth": {encodedRegistryAuth},
+ registry.AuthHeader: {encodedRegistryAuth},
}
}
diff --git a/vendor/github.com/docker/docker/client/errors.go b/vendor/github.com/docker/docker/client/errors.go
index e5a8a865f9f..6878144c41e 100644
--- a/vendor/github.com/docker/docker/client/errors.go
+++ b/vendor/github.com/docker/docker/client/errors.go
@@ -58,31 +58,6 @@ func (e objectNotFoundError) Error() string {
return fmt.Sprintf("Error: No such %s: %s", e.object, e.id)
}
-// IsErrUnauthorized returns true if the error is caused
-// when a remote registry authentication fails
-//
-// Deprecated: use errdefs.IsUnauthorized
-func IsErrUnauthorized(err error) bool {
- return errdefs.IsUnauthorized(err)
-}
-
-type pluginPermissionDenied struct {
- name string
-}
-
-func (e pluginPermissionDenied) Error() string {
- return "Permission denied while installing plugin " + e.name
-}
-
-// IsErrNotImplemented returns true if the error is a NotImplemented error.
-// This is returned by the API when a requested feature has not been
-// implemented.
-//
-// Deprecated: use errdefs.IsNotImplemented
-func IsErrNotImplemented(err error) bool {
- return errdefs.IsNotImplemented(err)
-}
-
// NewVersionError returns an error if the APIVersion required
// if less than the current supported version
func (cli *Client) NewVersionError(APIrequired, feature string) error {
diff --git a/vendor/github.com/docker/docker/client/image_create.go b/vendor/github.com/docker/docker/client/image_create.go
index b1c0227775c..6a9b708f7d4 100644
--- a/vendor/github.com/docker/docker/client/image_create.go
+++ b/vendor/github.com/docker/docker/client/image_create.go
@@ -8,6 +8,7 @@ import (
"github.com/docker/distribution/reference"
"github.com/docker/docker/api/types"
+ "github.com/docker/docker/api/types/registry"
)
// ImageCreate creates a new image based on the parent options.
@@ -32,6 +33,6 @@ func (cli *Client) ImageCreate(ctx context.Context, parentReference string, opti
}
func (cli *Client) tryImageCreate(ctx context.Context, query url.Values, registryAuth string) (serverResponse, error) {
- headers := map[string][]string{"X-Registry-Auth": {registryAuth}}
+ headers := map[string][]string{registry.AuthHeader: {registryAuth}}
return cli.post(ctx, "/images/create", query, nil, headers)
}
diff --git a/vendor/github.com/docker/docker/client/image_push.go b/vendor/github.com/docker/docker/client/image_push.go
index 845580d4a4c..dd1b8f34716 100644
--- a/vendor/github.com/docker/docker/client/image_push.go
+++ b/vendor/github.com/docker/docker/client/image_push.go
@@ -8,6 +8,7 @@ import (
"github.com/docker/distribution/reference"
"github.com/docker/docker/api/types"
+ "github.com/docker/docker/api/types/registry"
"github.com/docker/docker/errdefs"
)
@@ -49,6 +50,6 @@ func (cli *Client) ImagePush(ctx context.Context, image string, options types.Im
}
func (cli *Client) tryImagePush(ctx context.Context, imageID string, query url.Values, registryAuth string) (serverResponse, error) {
- headers := map[string][]string{"X-Registry-Auth": {registryAuth}}
+ headers := map[string][]string{registry.AuthHeader: {registryAuth}}
return cli.post(ctx, "/images/"+imageID+"/push", query, nil, headers)
}
diff --git a/vendor/github.com/docker/docker/client/image_search.go b/vendor/github.com/docker/docker/client/image_search.go
index e69fa372258..5f0c49ed30c 100644
--- a/vendor/github.com/docker/docker/client/image_search.go
+++ b/vendor/github.com/docker/docker/client/image_search.go
@@ -48,6 +48,6 @@ func (cli *Client) ImageSearch(ctx context.Context, term string, options types.I
}
func (cli *Client) tryImageSearch(ctx context.Context, query url.Values, registryAuth string) (serverResponse, error) {
- headers := map[string][]string{"X-Registry-Auth": {registryAuth}}
+ headers := map[string][]string{registry.AuthHeader: {registryAuth}}
return cli.get(ctx, "/images/search", query, headers)
}
diff --git a/vendor/github.com/docker/docker/client/interface.go b/vendor/github.com/docker/docker/client/interface.go
index e9c1ed722ee..64877d16416 100644
--- a/vendor/github.com/docker/docker/client/interface.go
+++ b/vendor/github.com/docker/docker/client/interface.go
@@ -48,7 +48,7 @@ type ContainerAPIClient interface {
ContainerAttach(ctx context.Context, container string, options types.ContainerAttachOptions) (types.HijackedResponse, error)
ContainerCommit(ctx context.Context, container string, options types.ContainerCommitOptions) (types.IDResponse, error)
ContainerCreate(ctx context.Context, config *container.Config, hostConfig *container.HostConfig, networkingConfig *network.NetworkingConfig, platform *specs.Platform, containerName string) (container.CreateResponse, error)
- ContainerDiff(ctx context.Context, container string) ([]container.ContainerChangeResponseItem, error)
+ ContainerDiff(ctx context.Context, container string) ([]container.FilesystemChange, error)
ContainerExecAttach(ctx context.Context, execID string, config types.ExecStartCheck) (types.HijackedResponse, error)
ContainerExecCreate(ctx context.Context, container string, config types.ExecConfig) (types.IDResponse, error)
ContainerExecInspect(ctx context.Context, execID string) (types.ContainerExecInspect, error)
@@ -166,7 +166,7 @@ type SwarmAPIClient interface {
type SystemAPIClient interface {
Events(ctx context.Context, options types.EventsOptions) (<-chan events.Message, <-chan error)
Info(ctx context.Context) (types.Info, error)
- RegistryLogin(ctx context.Context, auth types.AuthConfig) (registry.AuthenticateOKBody, error)
+ RegistryLogin(ctx context.Context, auth registry.AuthConfig) (registry.AuthenticateOKBody, error)
DiskUsage(ctx context.Context, options types.DiskUsageOptions) (types.DiskUsage, error)
Ping(ctx context.Context) (types.Ping, error)
}
@@ -176,7 +176,7 @@ type VolumeAPIClient interface {
VolumeCreate(ctx context.Context, options volume.CreateOptions) (volume.Volume, error)
VolumeInspect(ctx context.Context, volumeID string) (volume.Volume, error)
VolumeInspectWithRaw(ctx context.Context, volumeID string) (volume.Volume, []byte, error)
- VolumeList(ctx context.Context, filter filters.Args) (volume.ListResponse, error)
+ VolumeList(ctx context.Context, options volume.ListOptions) (volume.ListResponse, error)
VolumeRemove(ctx context.Context, volumeID string, force bool) error
VolumesPrune(ctx context.Context, pruneFilter filters.Args) (types.VolumesPruneReport, error)
VolumeUpdate(ctx context.Context, volumeID string, version swarm.Version, options volume.UpdateOptions) error
diff --git a/vendor/github.com/docker/docker/client/login.go b/vendor/github.com/docker/docker/client/login.go
index f0585206382..19e985e0b9c 100644
--- a/vendor/github.com/docker/docker/client/login.go
+++ b/vendor/github.com/docker/docker/client/login.go
@@ -5,13 +5,12 @@ import (
"encoding/json"
"net/url"
- "github.com/docker/docker/api/types"
"github.com/docker/docker/api/types/registry"
)
// RegistryLogin authenticates the docker server with a given docker registry.
// It returns unauthorizedError when the authentication fails.
-func (cli *Client) RegistryLogin(ctx context.Context, auth types.AuthConfig) (registry.AuthenticateOKBody, error) {
+func (cli *Client) RegistryLogin(ctx context.Context, auth registry.AuthConfig) (registry.AuthenticateOKBody, error) {
resp, err := cli.post(ctx, "/auth", url.Values{}, auth, nil)
defer ensureReaderClosed(resp)
diff --git a/vendor/github.com/docker/docker/client/ping.go b/vendor/github.com/docker/docker/client/ping.go
index 27e8695cb54..347ae71e027 100644
--- a/vendor/github.com/docker/docker/client/ping.go
+++ b/vendor/github.com/docker/docker/client/ping.go
@@ -64,10 +64,10 @@ func parsePingResponse(cli *Client, resp serverResponse) (types.Ping, error) {
ping.BuilderVersion = types.BuilderVersion(bv)
}
if si := resp.header.Get("Swarm"); si != "" {
- parts := strings.SplitN(si, "/", 2)
+ state, role, _ := strings.Cut(si, "/")
ping.SwarmStatus = &swarm.Status{
- NodeState: swarm.LocalNodeState(parts[0]),
- ControlAvailable: len(parts) == 2 && parts[1] == "manager",
+ NodeState: swarm.LocalNodeState(state),
+ ControlAvailable: role == "manager",
}
}
err := cli.checkResponseErr(resp)
diff --git a/vendor/github.com/docker/docker/client/plugin_install.go b/vendor/github.com/docker/docker/client/plugin_install.go
index 012afe61cac..3a740ec4f60 100644
--- a/vendor/github.com/docker/docker/client/plugin_install.go
+++ b/vendor/github.com/docker/docker/client/plugin_install.go
@@ -8,6 +8,7 @@ import (
"github.com/docker/distribution/reference"
"github.com/docker/docker/api/types"
+ "github.com/docker/docker/api/types/registry"
"github.com/docker/docker/errdefs"
"github.com/pkg/errors"
)
@@ -67,12 +68,12 @@ func (cli *Client) PluginInstall(ctx context.Context, name string, options types
}
func (cli *Client) tryPluginPrivileges(ctx context.Context, query url.Values, registryAuth string) (serverResponse, error) {
- headers := map[string][]string{"X-Registry-Auth": {registryAuth}}
+ headers := map[string][]string{registry.AuthHeader: {registryAuth}}
return cli.get(ctx, "/plugins/privileges", query, headers)
}
func (cli *Client) tryPluginPull(ctx context.Context, query url.Values, privileges types.PluginPrivileges, registryAuth string) (serverResponse, error) {
- headers := map[string][]string{"X-Registry-Auth": {registryAuth}}
+ headers := map[string][]string{registry.AuthHeader: {registryAuth}}
return cli.post(ctx, "/plugins/pull", query, privileges, headers)
}
@@ -106,7 +107,7 @@ func (cli *Client) checkPluginPermissions(ctx context.Context, query url.Values,
return nil, err
}
if !accept {
- return nil, pluginPermissionDenied{options.RemoteRef}
+ return nil, errors.Errorf("permission denied while installing plugin %s", options.RemoteRef)
}
}
return privileges, nil
diff --git a/vendor/github.com/docker/docker/client/plugin_push.go b/vendor/github.com/docker/docker/client/plugin_push.go
index d20bfe84479..18f9754c4c2 100644
--- a/vendor/github.com/docker/docker/client/plugin_push.go
+++ b/vendor/github.com/docker/docker/client/plugin_push.go
@@ -3,11 +3,13 @@ package client // import "github.com/docker/docker/client"
import (
"context"
"io"
+
+ "github.com/docker/docker/api/types/registry"
)
// PluginPush pushes a plugin to a registry
func (cli *Client) PluginPush(ctx context.Context, name string, registryAuth string) (io.ReadCloser, error) {
- headers := map[string][]string{"X-Registry-Auth": {registryAuth}}
+ headers := map[string][]string{registry.AuthHeader: {registryAuth}}
resp, err := cli.post(ctx, "/plugins/"+name+"/push", nil, nil, headers)
if err != nil {
return nil, err
diff --git a/vendor/github.com/docker/docker/client/plugin_upgrade.go b/vendor/github.com/docker/docker/client/plugin_upgrade.go
index 115cea945ba..995d1fd2ca1 100644
--- a/vendor/github.com/docker/docker/client/plugin_upgrade.go
+++ b/vendor/github.com/docker/docker/client/plugin_upgrade.go
@@ -7,6 +7,7 @@ import (
"github.com/docker/distribution/reference"
"github.com/docker/docker/api/types"
+ "github.com/docker/docker/api/types/registry"
"github.com/pkg/errors"
)
@@ -34,6 +35,6 @@ func (cli *Client) PluginUpgrade(ctx context.Context, name string, options types
}
func (cli *Client) tryPluginUpgrade(ctx context.Context, query url.Values, privileges types.PluginPrivileges, name, registryAuth string) (serverResponse, error) {
- headers := map[string][]string{"X-Registry-Auth": {registryAuth}}
+ headers := map[string][]string{registry.AuthHeader: {registryAuth}}
return cli.post(ctx, "/plugins/"+name+"/upgrade", query, privileges, headers)
}
diff --git a/vendor/github.com/docker/docker/client/service_create.go b/vendor/github.com/docker/docker/client/service_create.go
index 23024d0f8fb..b6065b8eefd 100644
--- a/vendor/github.com/docker/docker/client/service_create.go
+++ b/vendor/github.com/docker/docker/client/service_create.go
@@ -8,6 +8,7 @@ import (
"github.com/docker/distribution/reference"
"github.com/docker/docker/api/types"
+ "github.com/docker/docker/api/types/registry"
"github.com/docker/docker/api/types/swarm"
"github.com/opencontainers/go-digest"
"github.com/pkg/errors"
@@ -21,7 +22,7 @@ func (cli *Client) ServiceCreate(ctx context.Context, service swarm.ServiceSpec,
}
if options.EncodedRegistryAuth != "" {
- headers["X-Registry-Auth"] = []string{options.EncodedRegistryAuth}
+ headers[registry.AuthHeader] = []string{options.EncodedRegistryAuth}
}
// Make sure containerSpec is not nil when no runtime is set or the runtime is set to container
diff --git a/vendor/github.com/docker/docker/client/service_update.go b/vendor/github.com/docker/docker/client/service_update.go
index 8014b862584..ff8cded8be3 100644
--- a/vendor/github.com/docker/docker/client/service_update.go
+++ b/vendor/github.com/docker/docker/client/service_update.go
@@ -6,6 +6,7 @@ import (
"net/url"
"github.com/docker/docker/api/types"
+ "github.com/docker/docker/api/types/registry"
"github.com/docker/docker/api/types/swarm"
)
@@ -23,7 +24,7 @@ func (cli *Client) ServiceUpdate(ctx context.Context, serviceID string, version
}
if options.EncodedRegistryAuth != "" {
- headers["X-Registry-Auth"] = []string{options.EncodedRegistryAuth}
+ headers[registry.AuthHeader] = []string{options.EncodedRegistryAuth}
}
if options.RegistryAuthFrom != "" {
diff --git a/vendor/github.com/docker/docker/client/volume_list.go b/vendor/github.com/docker/docker/client/volume_list.go
index d8204f8db5d..d5ea9827c72 100644
--- a/vendor/github.com/docker/docker/client/volume_list.go
+++ b/vendor/github.com/docker/docker/client/volume_list.go
@@ -10,13 +10,13 @@ import (
)
// VolumeList returns the volumes configured in the docker host.
-func (cli *Client) VolumeList(ctx context.Context, filter filters.Args) (volume.ListResponse, error) {
+func (cli *Client) VolumeList(ctx context.Context, options volume.ListOptions) (volume.ListResponse, error) {
var volumes volume.ListResponse
query := url.Values{}
- if filter.Len() > 0 {
+ if options.Filters.Len() > 0 {
//nolint:staticcheck // ignore SA1019 for old code
- filterJSON, err := filters.ToParamWithVersion(cli.version, filter)
+ filterJSON, err := filters.ToParamWithVersion(cli.version, options.Filters)
if err != nil {
return volumes, err
}
diff --git a/vendor/github.com/envoyproxy/protoc-gen-validate/NOTICE b/vendor/github.com/envoyproxy/protoc-gen-validate/NOTICE
deleted file mode 100644
index 60884a05905..00000000000
--- a/vendor/github.com/envoyproxy/protoc-gen-validate/NOTICE
+++ /dev/null
@@ -1,4 +0,0 @@
-protoc-gen-validate
-Copyright 2019 Envoy Project Authors
-
-Licensed under Apache License 2.0. See LICENSE for terms.
diff --git a/vendor/github.com/go-logr/logr/.golangci.yaml b/vendor/github.com/go-logr/logr/.golangci.yaml
index 94ff801df1a..0cffafa7bf9 100644
--- a/vendor/github.com/go-logr/logr/.golangci.yaml
+++ b/vendor/github.com/go-logr/logr/.golangci.yaml
@@ -6,7 +6,6 @@ linters:
disable-all: true
enable:
- asciicheck
- - deadcode
- errcheck
- forcetypeassert
- gocritic
@@ -18,10 +17,8 @@ linters:
- misspell
- revive
- staticcheck
- - structcheck
- typecheck
- unused
- - varcheck
issues:
exclude-use-default: false
diff --git a/vendor/github.com/go-logr/logr/discard.go b/vendor/github.com/go-logr/logr/discard.go
index 9d92a38f1d7..99fe8be93c1 100644
--- a/vendor/github.com/go-logr/logr/discard.go
+++ b/vendor/github.com/go-logr/logr/discard.go
@@ -20,35 +20,5 @@ package logr
// used whenever the caller is not interested in the logs. Logger instances
// produced by this function always compare as equal.
func Discard() Logger {
- return Logger{
- level: 0,
- sink: discardLogSink{},
- }
-}
-
-// discardLogSink is a LogSink that discards all messages.
-type discardLogSink struct{}
-
-// Verify that it actually implements the interface
-var _ LogSink = discardLogSink{}
-
-func (l discardLogSink) Init(RuntimeInfo) {
-}
-
-func (l discardLogSink) Enabled(int) bool {
- return false
-}
-
-func (l discardLogSink) Info(int, string, ...interface{}) {
-}
-
-func (l discardLogSink) Error(error, string, ...interface{}) {
-}
-
-func (l discardLogSink) WithValues(...interface{}) LogSink {
- return l
-}
-
-func (l discardLogSink) WithName(string) LogSink {
- return l
+ return New(nil)
}
diff --git a/vendor/github.com/go-logr/logr/funcr/funcr.go b/vendor/github.com/go-logr/logr/funcr/funcr.go
index 7accdb0c400..e52f0cd01e2 100644
--- a/vendor/github.com/go-logr/logr/funcr/funcr.go
+++ b/vendor/github.com/go-logr/logr/funcr/funcr.go
@@ -21,13 +21,13 @@ limitations under the License.
// github.com/go-logr/logr.LogSink with output through an arbitrary
// "write" function. See New and NewJSON for details.
//
-// Custom LogSinks
+// # Custom LogSinks
//
// For users who need more control, a funcr.Formatter can be embedded inside
// your own custom LogSink implementation. This is useful when the LogSink
// needs to implement additional methods, for example.
//
-// Formatting
+// # Formatting
//
// This will respect logr.Marshaler, fmt.Stringer, and error interfaces for
// values which are being logged. When rendering a struct, funcr will use Go's
@@ -37,6 +37,7 @@ package funcr
import (
"bytes"
"encoding"
+ "encoding/json"
"fmt"
"path/filepath"
"reflect"
@@ -217,7 +218,7 @@ func newFormatter(opts Options, outfmt outputFormat) Formatter {
prefix: "",
values: nil,
depth: 0,
- opts: opts,
+ opts: &opts,
}
return f
}
@@ -231,7 +232,7 @@ type Formatter struct {
values []interface{}
valuesStr string
depth int
- opts Options
+ opts *Options
}
// outputFormat indicates which outputFormat to use.
@@ -447,6 +448,7 @@ func (f Formatter) prettyWithFlags(value interface{}, flags uint32, depth int) s
if flags&flagRawStruct == 0 {
buf.WriteByte('{')
}
+ printComma := false // testing i>0 is not enough because of JSON omitted fields
for i := 0; i < t.NumField(); i++ {
fld := t.Field(i)
if fld.PkgPath != "" {
@@ -478,9 +480,10 @@ func (f Formatter) prettyWithFlags(value interface{}, flags uint32, depth int) s
if omitempty && isEmpty(v.Field(i)) {
continue
}
- if i > 0 {
+ if printComma {
buf.WriteByte(',')
}
+ printComma = true // if we got here, we are rendering a field
if fld.Anonymous && fld.Type.Kind() == reflect.Struct && name == "" {
buf.WriteString(f.prettyWithFlags(v.Field(i).Interface(), flags|flagRawStruct, depth+1))
continue
@@ -500,6 +503,20 @@ func (f Formatter) prettyWithFlags(value interface{}, flags uint32, depth int) s
}
return buf.String()
case reflect.Slice, reflect.Array:
+ // If this is outputing as JSON make sure this isn't really a json.RawMessage.
+ // If so just emit "as-is" and don't pretty it as that will just print
+ // it as [X,Y,Z,...] which isn't terribly useful vs the string form you really want.
+ if f.outputFormat == outputJSON {
+ if rm, ok := value.(json.RawMessage); ok {
+ // If it's empty make sure we emit an empty value as the array style would below.
+ if len(rm) > 0 {
+ buf.Write(rm)
+ } else {
+ buf.WriteString("null")
+ }
+ return buf.String()
+ }
+ }
buf.WriteByte('[')
for i := 0; i < v.Len(); i++ {
if i > 0 {
diff --git a/vendor/github.com/go-logr/logr/logr.go b/vendor/github.com/go-logr/logr/logr.go
index c3b56b3d2c5..e027aea3fd3 100644
--- a/vendor/github.com/go-logr/logr/logr.go
+++ b/vendor/github.com/go-logr/logr/logr.go
@@ -21,7 +21,7 @@ limitations under the License.
// to back that API. Packages in the Go ecosystem can depend on this package,
// while callers can implement logging with whatever backend is appropriate.
//
-// Usage
+// # Usage
//
// Logging is done using a Logger instance. Logger is a concrete type with
// methods, which defers the actual logging to a LogSink interface. The main
@@ -30,16 +30,20 @@ limitations under the License.
// "structured logging".
//
// With Go's standard log package, we might write:
-// log.Printf("setting target value %s", targetValue)
+//
+// log.Printf("setting target value %s", targetValue)
//
// With logr's structured logging, we'd write:
-// logger.Info("setting target", "value", targetValue)
+//
+// logger.Info("setting target", "value", targetValue)
//
// Errors are much the same. Instead of:
-// log.Printf("failed to open the pod bay door for user %s: %v", user, err)
+//
+// log.Printf("failed to open the pod bay door for user %s: %v", user, err)
//
// We'd write:
-// logger.Error(err, "failed to open the pod bay door", "user", user)
+//
+// logger.Error(err, "failed to open the pod bay door", "user", user)
//
// Info() and Error() are very similar, but they are separate methods so that
// LogSink implementations can choose to do things like attach additional
@@ -47,7 +51,7 @@ limitations under the License.
// always logged, regardless of the current verbosity. If there is no error
// instance available, passing nil is valid.
//
-// Verbosity
+// # Verbosity
//
// Often we want to log information only when the application in "verbose
// mode". To write log lines that are more verbose, Logger has a V() method.
@@ -58,20 +62,22 @@ limitations under the License.
// Error messages do not have a verbosity level and are always logged.
//
// Where we might have written:
-// if flVerbose >= 2 {
-// log.Printf("an unusual thing happened")
-// }
+//
+// if flVerbose >= 2 {
+// log.Printf("an unusual thing happened")
+// }
//
// We can write:
-// logger.V(2).Info("an unusual thing happened")
//
-// Logger Names
+// logger.V(2).Info("an unusual thing happened")
+//
+// # Logger Names
//
// Logger instances can have name strings so that all messages logged through
// that instance have additional context. For example, you might want to add
// a subsystem name:
//
-// logger.WithName("compactor").Info("started", "time", time.Now())
+// logger.WithName("compactor").Info("started", "time", time.Now())
//
// The WithName() method returns a new Logger, which can be passed to
// constructors or other functions for further use. Repeated use of WithName()
@@ -82,25 +88,27 @@ limitations under the License.
// joining operation (e.g. whitespace, commas, periods, slashes, brackets,
// quotes, etc).
//
-// Saved Values
+// # Saved Values
//
// Logger instances can store any number of key/value pairs, which will be
// logged alongside all messages logged through that instance. For example,
// you might want to create a Logger instance per managed object:
//
// With the standard log package, we might write:
-// log.Printf("decided to set field foo to value %q for object %s/%s",
-// targetValue, object.Namespace, object.Name)
+//
+// log.Printf("decided to set field foo to value %q for object %s/%s",
+// targetValue, object.Namespace, object.Name)
//
// With logr we'd write:
-// // Elsewhere: set up the logger to log the object name.
-// obj.logger = mainLogger.WithValues(
-// "name", obj.name, "namespace", obj.namespace)
//
-// // later on...
-// obj.logger.Info("setting foo", "value", targetValue)
+// // Elsewhere: set up the logger to log the object name.
+// obj.logger = mainLogger.WithValues(
+// "name", obj.name, "namespace", obj.namespace)
+//
+// // later on...
+// obj.logger.Info("setting foo", "value", targetValue)
//
-// Best Practices
+// # Best Practices
//
// Logger has very few hard rules, with the goal that LogSink implementations
// might have a lot of freedom to differentiate. There are, however, some
@@ -124,15 +132,15 @@ limitations under the License.
// around. For cases where passing a logger is optional, a pointer to Logger
// should be used.
//
-// Key Naming Conventions
+// # Key Naming Conventions
//
// Keys are not strictly required to conform to any specification or regex, but
// it is recommended that they:
-// * be human-readable and meaningful (not auto-generated or simple ordinals)
-// * be constant (not dependent on input data)
-// * contain only printable characters
-// * not contain whitespace or punctuation
-// * use lower case for simple keys and lowerCamelCase for more complex ones
+// - be human-readable and meaningful (not auto-generated or simple ordinals)
+// - be constant (not dependent on input data)
+// - contain only printable characters
+// - not contain whitespace or punctuation
+// - use lower case for simple keys and lowerCamelCase for more complex ones
//
// These guidelines help ensure that log data is processed properly regardless
// of the log implementation. For example, log implementations will try to
@@ -141,51 +149,54 @@ limitations under the License.
// While users are generally free to use key names of their choice, it's
// generally best to avoid using the following keys, as they're frequently used
// by implementations:
-// * "caller": the calling information (file/line) of a particular log line
-// * "error": the underlying error value in the `Error` method
-// * "level": the log level
-// * "logger": the name of the associated logger
-// * "msg": the log message
-// * "stacktrace": the stack trace associated with a particular log line or
-// error (often from the `Error` message)
-// * "ts": the timestamp for a log line
+// - "caller": the calling information (file/line) of a particular log line
+// - "error": the underlying error value in the `Error` method
+// - "level": the log level
+// - "logger": the name of the associated logger
+// - "msg": the log message
+// - "stacktrace": the stack trace associated with a particular log line or
+// error (often from the `Error` message)
+// - "ts": the timestamp for a log line
//
// Implementations are encouraged to make use of these keys to represent the
// above concepts, when necessary (for example, in a pure-JSON output form, it
// would be necessary to represent at least message and timestamp as ordinary
// named values).
//
-// Break Glass
+// # Break Glass
//
// Implementations may choose to give callers access to the underlying
// logging implementation. The recommended pattern for this is:
-// // Underlier exposes access to the underlying logging implementation.
-// // Since callers only have a logr.Logger, they have to know which
-// // implementation is in use, so this interface is less of an abstraction
-// // and more of way to test type conversion.
-// type Underlier interface {
-// GetUnderlying()
-// }
+//
+// // Underlier exposes access to the underlying logging implementation.
+// // Since callers only have a logr.Logger, they have to know which
+// // implementation is in use, so this interface is less of an abstraction
+// // and more of way to test type conversion.
+// type Underlier interface {
+// GetUnderlying()
+// }
//
// Logger grants access to the sink to enable type assertions like this:
-// func DoSomethingWithImpl(log logr.Logger) {
-// if underlier, ok := log.GetSink()(impl.Underlier) {
-// implLogger := underlier.GetUnderlying()
-// ...
-// }
-// }
+//
+// func DoSomethingWithImpl(log logr.Logger) {
+// if underlier, ok := log.GetSink().(impl.Underlier); ok {
+// implLogger := underlier.GetUnderlying()
+// ...
+// }
+// }
//
// Custom `With*` functions can be implemented by copying the complete
// Logger struct and replacing the sink in the copy:
-// // WithFooBar changes the foobar parameter in the log sink and returns a
-// // new logger with that modified sink. It does nothing for loggers where
-// // the sink doesn't support that parameter.
-// func WithFoobar(log logr.Logger, foobar int) logr.Logger {
-// if foobarLogSink, ok := log.GetSink()(FoobarSink); ok {
-// log = log.WithSink(foobarLogSink.WithFooBar(foobar))
-// }
-// return log
-// }
+//
+// // WithFooBar changes the foobar parameter in the log sink and returns a
+// // new logger with that modified sink. It does nothing for loggers where
+// // the sink doesn't support that parameter.
+// func WithFoobar(log logr.Logger, foobar int) logr.Logger {
+// if foobarLogSink, ok := log.GetSink().(FoobarSink); ok {
+// log = log.WithSink(foobarLogSink.WithFooBar(foobar))
+// }
+// return log
+// }
//
// Don't use New to construct a new Logger with a LogSink retrieved from an
// existing Logger. Source code attribution might not work correctly and
@@ -201,11 +212,14 @@ import (
)
// New returns a new Logger instance. This is primarily used by libraries
-// implementing LogSink, rather than end users.
+// implementing LogSink, rather than end users. Passing a nil sink will create
+// a Logger which discards all log lines.
func New(sink LogSink) Logger {
logger := Logger{}
logger.setSink(sink)
- sink.Init(runtimeInfo)
+ if sink != nil {
+ sink.Init(runtimeInfo)
+ }
return logger
}
@@ -244,7 +258,7 @@ type Logger struct {
// Enabled tests whether this Logger is enabled. For example, commandline
// flags might be used to set the logging verbosity and disable some info logs.
func (l Logger) Enabled() bool {
- return l.sink.Enabled(l.level)
+ return l.sink != nil && l.sink.Enabled(l.level)
}
// Info logs a non-error message with the given key/value pairs as context.
@@ -254,6 +268,9 @@ func (l Logger) Enabled() bool {
// information. The key/value pairs must alternate string keys and arbitrary
// values.
func (l Logger) Info(msg string, keysAndValues ...interface{}) {
+ if l.sink == nil {
+ return
+ }
if l.Enabled() {
if withHelper, ok := l.sink.(CallStackHelperLogSink); ok {
withHelper.GetCallStackHelper()()
@@ -273,6 +290,9 @@ func (l Logger) Info(msg string, keysAndValues ...interface{}) {
// triggered this log line, if present. The err parameter is optional
// and nil may be passed instead of an error instance.
func (l Logger) Error(err error, msg string, keysAndValues ...interface{}) {
+ if l.sink == nil {
+ return
+ }
if withHelper, ok := l.sink.(CallStackHelperLogSink); ok {
withHelper.GetCallStackHelper()()
}
@@ -284,6 +304,9 @@ func (l Logger) Error(err error, msg string, keysAndValues ...interface{}) {
// level means a log message is less important. Negative V-levels are treated
// as 0.
func (l Logger) V(level int) Logger {
+ if l.sink == nil {
+ return l
+ }
if level < 0 {
level = 0
}
@@ -294,6 +317,9 @@ func (l Logger) V(level int) Logger {
// WithValues returns a new Logger instance with additional key/value pairs.
// See Info for documentation on how key/value pairs work.
func (l Logger) WithValues(keysAndValues ...interface{}) Logger {
+ if l.sink == nil {
+ return l
+ }
l.setSink(l.sink.WithValues(keysAndValues...))
return l
}
@@ -304,6 +330,9 @@ func (l Logger) WithValues(keysAndValues ...interface{}) Logger {
// contain only letters, digits, and hyphens (see the package documentation for
// more information).
func (l Logger) WithName(name string) Logger {
+ if l.sink == nil {
+ return l
+ }
l.setSink(l.sink.WithName(name))
return l
}
@@ -324,6 +353,9 @@ func (l Logger) WithName(name string) Logger {
// WithCallDepth(1) because it works with implementions that support the
// CallDepthLogSink and/or CallStackHelperLogSink interfaces.
func (l Logger) WithCallDepth(depth int) Logger {
+ if l.sink == nil {
+ return l
+ }
if withCallDepth, ok := l.sink.(CallDepthLogSink); ok {
l.setSink(withCallDepth.WithCallDepth(depth))
}
@@ -345,6 +377,9 @@ func (l Logger) WithCallDepth(depth int) Logger {
// implementation does not support either of these, the original Logger will be
// returned.
func (l Logger) WithCallStackHelper() (func(), Logger) {
+ if l.sink == nil {
+ return func() {}, l
+ }
var helper func()
if withCallDepth, ok := l.sink.(CallDepthLogSink); ok {
l.setSink(withCallDepth.WithCallDepth(1))
@@ -357,6 +392,11 @@ func (l Logger) WithCallStackHelper() (func(), Logger) {
return helper, l
}
+// IsZero returns true if this logger is an uninitialized zero value
+func (l Logger) IsZero() bool {
+ return l.sink == nil
+}
+
// contextKey is how we find Loggers in a context.Context.
type contextKey struct{}
@@ -442,7 +482,7 @@ type LogSink interface {
WithName(name string) LogSink
}
-// CallDepthLogSink represents a Logger that knows how to climb the call stack
+// CallDepthLogSink represents a LogSink that knows how to climb the call stack
// to identify the original call site and can offset the depth by a specified
// number of frames. This is useful for users who have helper functions
// between the "real" call site and the actual calls to Logger methods.
@@ -467,7 +507,7 @@ type CallDepthLogSink interface {
WithCallDepth(depth int) LogSink
}
-// CallStackHelperLogSink represents a Logger that knows how to climb
+// CallStackHelperLogSink represents a LogSink that knows how to climb
// the call stack to identify the original call site and can skip
// intermediate helper functions if they mark themselves as
// helper. Go's testing package uses that approach.
diff --git a/vendor/github.com/golang/glog/glog.go b/vendor/github.com/golang/glog/glog.go
index 718c34f886e..e108ae8b4f8 100644
--- a/vendor/github.com/golang/glog/glog.go
+++ b/vendor/github.com/golang/glog/glog.go
@@ -1,6 +1,6 @@
-// Go support for leveled logs, analogous to https://code.google.com/p/google-glog/
+// Go support for leveled logs, analogous to https://github.com/google/glog.
//
-// Copyright 2013 Google Inc. All Rights Reserved.
+// Copyright 2023 Google Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -50,15 +50,15 @@
// Log files will be written to this directory instead of the
// default temporary directory.
//
-// Other flags provide aids to debugging.
+// Other flags provide aids to debugging.
//
// -log_backtrace_at=""
-// When set to a file and line number holding a logging statement,
-// such as
+// A comma-separated list of file and line numbers holding a logging
+// statement, such as
// -log_backtrace_at=gopherflakes.go:234
-// a stack trace will be written to the Info log whenever execution
-// hits that statement. (Unlike with -vmodule, the ".go" must be
-// present.)
+// A stack trace will be written to the Info log whenever execution
+// hits one of these statements. (Unlike with -vmodule, the ".go"
+// must bepresent.)
// -v=0
// Enable V-leveled logging at the specified level.
// -vmodule=""
@@ -66,100 +66,47 @@
// where pattern is a literal file name (minus the ".go" suffix) or
// "glob" pattern and N is a V level. For instance,
// -vmodule=gopher*=3
-// sets the V level to 3 in all Go files whose names begin "gopher".
-//
+// sets the V level to 3 in all Go files whose names begin with "gopher",
+// and
+// -vmodule=/path/to/glog/glog_test=1
+// sets the V level to 1 in the Go file /path/to/glog/glog_test.go.
+// If a glob pattern contains a slash, it is matched against the full path,
+// and the file name. Otherwise, the pattern is
+// matched only against the file's basename. When both -vmodule and -v
+// are specified, the -vmodule values take precedence for the specified
+// modules.
package glog
+// This file contains the parts of the log package that are shared among all
+// implementations (file, envelope, and appengine).
+
import (
- "bufio"
"bytes"
"errors"
- "flag"
"fmt"
- "io"
stdLog "log"
"os"
- "path/filepath"
+ "reflect"
"runtime"
+ "runtime/pprof"
"strconv"
- "strings"
"sync"
"sync/atomic"
+ "syscall"
"time"
-)
-
-// severity identifies the sort of log: info, warning etc. It also implements
-// the flag.Value interface. The -stderrthreshold flag is of type severity and
-// should be modified only through the flag.Value interface. The values match
-// the corresponding constants in C++.
-type severity int32 // sync/atomic int32
-// These constants identify the log levels in order of increasing severity.
-// A message written to a high-severity log file is also written to each
-// lower-severity log file.
-const (
- infoLog severity = iota
- warningLog
- errorLog
- fatalLog
- numSeverity = 4
+ "github.com/golang/glog/internal/logsink"
+ "github.com/golang/glog/internal/stackdump"
)
-const severityChar = "IWEF"
-
-var severityName = []string{
- infoLog: "INFO",
- warningLog: "WARNING",
- errorLog: "ERROR",
- fatalLog: "FATAL",
-}
-
-// get returns the value of the severity.
-func (s *severity) get() severity {
- return severity(atomic.LoadInt32((*int32)(s)))
-}
-
-// set sets the value of the severity.
-func (s *severity) set(val severity) {
- atomic.StoreInt32((*int32)(s), int32(val))
-}
-
-// String is part of the flag.Value interface.
-func (s *severity) String() string {
- return strconv.FormatInt(int64(*s), 10)
-}
-
-// Get is part of the flag.Value interface.
-func (s *severity) Get() interface{} {
- return *s
-}
+var timeNow = time.Now // Stubbed out for testing.
-// Set is part of the flag.Value interface.
-func (s *severity) Set(value string) error {
- var threshold severity
- // Is it a known name?
- if v, ok := severityByName(value); ok {
- threshold = v
- } else {
- v, err := strconv.Atoi(value)
- if err != nil {
- return err
- }
- threshold = severity(v)
- }
- logging.stderrThreshold.set(threshold)
- return nil
-}
+// MaxSize is the maximum size of a log file in bytes.
+var MaxSize uint64 = 1024 * 1024 * 1800
-func severityByName(s string) (severity, bool) {
- s = strings.ToUpper(s)
- for i, name := range severityName {
- if name == s {
- return severity(i), true
- }
- }
- return 0, false
-}
+// ErrNoLog is the error we return if no log file has yet been created
+// for the specified log type.
+var ErrNoLog = errors.New("log file not yet created")
// OutputStats tracks the number of output lines and bytes written.
type OutputStats struct {
@@ -183,724 +130,99 @@ var Stats struct {
Info, Warning, Error OutputStats
}
-var severityStats = [numSeverity]*OutputStats{
- infoLog: &Stats.Info,
- warningLog: &Stats.Warning,
- errorLog: &Stats.Error,
+var severityStats = [...]*OutputStats{
+ logsink.Info: &Stats.Info,
+ logsink.Warning: &Stats.Warning,
+ logsink.Error: &Stats.Error,
+ logsink.Fatal: nil,
}
-// Level is exported because it appears in the arguments to V and is
-// the type of the v flag, which can be set programmatically.
-// It's a distinct type because we want to discriminate it from logType.
-// Variables of type level are only changed under logging.mu.
-// The -v flag is read only with atomic ops, so the state of the logging
-// module is consistent.
-
-// Level is treated as a sync/atomic int32.
-
-// Level specifies a level of verbosity for V logs. *Level implements
-// flag.Value; the -v flag is of type Level and should be modified
-// only through the flag.Value interface.
+// Level specifies a level of verbosity for V logs. The -v flag is of type
+// Level and should be modified only through the flag.Value interface.
type Level int32
-// get returns the value of the Level.
-func (l *Level) get() Level {
- return Level(atomic.LoadInt32((*int32)(l)))
-}
-
-// set sets the value of the Level.
-func (l *Level) set(val Level) {
- atomic.StoreInt32((*int32)(l), int32(val))
-}
-
-// String is part of the flag.Value interface.
-func (l *Level) String() string {
- return strconv.FormatInt(int64(*l), 10)
-}
+var metaPool sync.Pool // Pool of *logsink.Meta.
-// Get is part of the flag.Value interface.
-func (l *Level) Get() interface{} {
- return *l
-}
-
-// Set is part of the flag.Value interface.
-func (l *Level) Set(value string) error {
- v, err := strconv.Atoi(value)
- if err != nil {
- return err
- }
- logging.mu.Lock()
- defer logging.mu.Unlock()
- logging.setVState(Level(v), logging.vmodule.filter, false)
- return nil
-}
-
-// moduleSpec represents the setting of the -vmodule flag.
-type moduleSpec struct {
- filter []modulePat
-}
-
-// modulePat contains a filter for the -vmodule flag.
-// It holds a verbosity level and a file pattern to match.
-type modulePat struct {
- pattern string
- literal bool // The pattern is a literal string
- level Level
-}
-
-// match reports whether the file matches the pattern. It uses a string
-// comparison if the pattern contains no metacharacters.
-func (m *modulePat) match(file string) bool {
- if m.literal {
- return file == m.pattern
- }
- match, _ := filepath.Match(m.pattern, file)
- return match
-}
-
-func (m *moduleSpec) String() string {
- // Lock because the type is not atomic. TODO: clean this up.
- logging.mu.Lock()
- defer logging.mu.Unlock()
- var b bytes.Buffer
- for i, f := range m.filter {
- if i > 0 {
- b.WriteRune(',')
- }
- fmt.Fprintf(&b, "%s=%d", f.pattern, f.level)
+// metaPoolGet returns a *logsink.Meta from metaPool as both an interface and a
+// pointer, allocating a new one if necessary. (Returning the interface value
+// directly avoids an allocation if there was an existing pointer in the pool.)
+func metaPoolGet() (any, *logsink.Meta) {
+ if metai := metaPool.Get(); metai != nil {
+ return metai, metai.(*logsink.Meta)
}
- return b.String()
-}
-
-// Get is part of the (Go 1.2) flag.Getter interface. It always returns nil for this flag type since the
-// struct is not exported.
-func (m *moduleSpec) Get() interface{} {
- return nil
+ meta := new(logsink.Meta)
+ return meta, meta
}
-var errVmoduleSyntax = errors.New("syntax error: expect comma-separated list of filename=N")
-
-// Syntax: -vmodule=recordio=2,file=1,gfs*=3
-func (m *moduleSpec) Set(value string) error {
- var filter []modulePat
- for _, pat := range strings.Split(value, ",") {
- if len(pat) == 0 {
- // Empty strings such as from a trailing comma can be ignored.
- continue
- }
- patLev := strings.Split(pat, "=")
- if len(patLev) != 2 || len(patLev[0]) == 0 || len(patLev[1]) == 0 {
- return errVmoduleSyntax
- }
- pattern := patLev[0]
- v, err := strconv.Atoi(patLev[1])
- if err != nil {
- return errors.New("syntax error: expect comma-separated list of filename=N")
- }
- if v < 0 {
- return errors.New("negative value for vmodule level")
- }
- if v == 0 {
- continue // Ignore. It's harmless but no point in paying the overhead.
- }
- // TODO: check syntax of filter?
- filter = append(filter, modulePat{pattern, isLiteral(pattern), Level(v)})
- }
- logging.mu.Lock()
- defer logging.mu.Unlock()
- logging.setVState(logging.verbosity, filter, true)
- return nil
-}
-
-// isLiteral reports whether the pattern is a literal string, that is, has no metacharacters
-// that require filepath.Match to be called to match the pattern.
-func isLiteral(pattern string) bool {
- return !strings.ContainsAny(pattern, `\*?[]`)
-}
-
-// traceLocation represents the setting of the -log_backtrace_at flag.
-type traceLocation struct {
- file string
- line int
-}
-
-// isSet reports whether the trace location has been specified.
-// logging.mu is held.
-func (t *traceLocation) isSet() bool {
- return t.line > 0
-}
+type stack bool
-// match reports whether the specified file and line matches the trace location.
-// The argument file name is the full path, not the basename specified in the flag.
-// logging.mu is held.
-func (t *traceLocation) match(file string, line int) bool {
- if t.line != line {
- return false
- }
- if i := strings.LastIndex(file, "/"); i >= 0 {
- file = file[i+1:]
- }
- return t.file == file
-}
-
-func (t *traceLocation) String() string {
- // Lock because the type is not atomic. TODO: clean this up.
- logging.mu.Lock()
- defer logging.mu.Unlock()
- return fmt.Sprintf("%s:%d", t.file, t.line)
-}
-
-// Get is part of the (Go 1.2) flag.Getter interface. It always returns nil for this flag type since the
-// struct is not exported
-func (t *traceLocation) Get() interface{} {
- return nil
-}
-
-var errTraceSyntax = errors.New("syntax error: expect file.go:234")
-
-// Syntax: -log_backtrace_at=gopherflakes.go:234
-// Note that unlike vmodule the file extension is included here.
-func (t *traceLocation) Set(value string) error {
- if value == "" {
- // Unset.
- t.line = 0
- t.file = ""
- }
- fields := strings.Split(value, ":")
- if len(fields) != 2 {
- return errTraceSyntax
- }
- file, line := fields[0], fields[1]
- if !strings.Contains(file, ".") {
- return errTraceSyntax
- }
- v, err := strconv.Atoi(line)
- if err != nil {
- return errTraceSyntax
- }
- if v <= 0 {
- return errors.New("negative or zero value for level")
- }
- logging.mu.Lock()
- defer logging.mu.Unlock()
- t.line = v
- t.file = file
- return nil
-}
-
-// flushSyncWriter is the interface satisfied by logging destinations.
-type flushSyncWriter interface {
- Flush() error
- Sync() error
- io.Writer
-}
-
-func init() {
- flag.BoolVar(&logging.toStderr, "logtostderr", false, "log to standard error instead of files")
- flag.BoolVar(&logging.alsoToStderr, "alsologtostderr", false, "log to standard error as well as files")
- flag.Var(&logging.verbosity, "v", "log level for V logs")
- flag.Var(&logging.stderrThreshold, "stderrthreshold", "logs at or above this threshold go to stderr")
- flag.Var(&logging.vmodule, "vmodule", "comma-separated list of pattern=N settings for file-filtered logging")
- flag.Var(&logging.traceLocation, "log_backtrace_at", "when logging hits line file:N, emit a stack trace")
-
- // Default stderrThreshold is ERROR.
- logging.stderrThreshold = errorLog
-
- logging.setVState(0, nil, false)
- go logging.flushDaemon()
-}
-
-// Flush flushes all pending log I/O.
-func Flush() {
- logging.lockAndFlushAll()
-}
-
-// loggingT collects all the global state of the logging setup.
-type loggingT struct {
- // Boolean flags. Not handled atomically because the flag.Value interface
- // does not let us avoid the =true, and that shorthand is necessary for
- // compatibility. TODO: does this matter enough to fix? Seems unlikely.
- toStderr bool // The -logtostderr flag.
- alsoToStderr bool // The -alsologtostderr flag.
-
- // Level flag. Handled atomically.
- stderrThreshold severity // The -stderrthreshold flag.
-
- // freeList is a list of byte buffers, maintained under freeListMu.
- freeList *buffer
- // freeListMu maintains the free list. It is separate from the main mutex
- // so buffers can be grabbed and printed to without holding the main lock,
- // for better parallelization.
- freeListMu sync.Mutex
-
- // mu protects the remaining elements of this structure and is
- // used to synchronize logging.
- mu sync.Mutex
- // file holds writer for each of the log types.
- file [numSeverity]flushSyncWriter
- // pcs is used in V to avoid an allocation when computing the caller's PC.
- pcs [1]uintptr
- // vmap is a cache of the V Level for each V() call site, identified by PC.
- // It is wiped whenever the vmodule flag changes state.
- vmap map[uintptr]Level
- // filterLength stores the length of the vmodule filter chain. If greater
- // than zero, it means vmodule is enabled. It may be read safely
- // using sync.LoadInt32, but is only modified under mu.
- filterLength int32
- // traceLocation is the state of the -log_backtrace_at flag.
- traceLocation traceLocation
- // These flags are modified only under lock, although verbosity may be fetched
- // safely using atomic.LoadInt32.
- vmodule moduleSpec // The state of the -vmodule flag.
- verbosity Level // V logging level, the value of the -v flag/
-}
-
-// buffer holds a byte Buffer for reuse. The zero value is ready for use.
-type buffer struct {
- bytes.Buffer
- tmp [64]byte // temporary byte array for creating headers.
- next *buffer
-}
-
-var logging loggingT
-
-// setVState sets a consistent state for V logging.
-// l.mu is held.
-func (l *loggingT) setVState(verbosity Level, filter []modulePat, setFilter bool) {
- // Turn verbosity off so V will not fire while we are in transition.
- logging.verbosity.set(0)
- // Ditto for filter length.
- atomic.StoreInt32(&logging.filterLength, 0)
-
- // Set the new filters and wipe the pc->Level map if the filter has changed.
- if setFilter {
- logging.vmodule.filter = filter
- logging.vmap = make(map[uintptr]Level)
- }
-
- // Things are consistent now, so enable filtering and verbosity.
- // They are enabled in order opposite to that in V.
- atomic.StoreInt32(&logging.filterLength, int32(len(filter)))
- logging.verbosity.set(verbosity)
-}
-
-// getBuffer returns a new, ready-to-use buffer.
-func (l *loggingT) getBuffer() *buffer {
- l.freeListMu.Lock()
- b := l.freeList
- if b != nil {
- l.freeList = b.next
- }
- l.freeListMu.Unlock()
- if b == nil {
- b = new(buffer)
- } else {
- b.next = nil
- b.Reset()
- }
- return b
-}
-
-// putBuffer returns a buffer to the free list.
-func (l *loggingT) putBuffer(b *buffer) {
- if b.Len() >= 256 {
- // Let big buffers die a natural death.
- return
- }
- l.freeListMu.Lock()
- b.next = l.freeList
- l.freeList = b
- l.freeListMu.Unlock()
-}
-
-var timeNow = time.Now // Stubbed out for testing.
+const (
+ noStack = stack(false)
+ withStack = stack(true)
+)
-/*
-header formats a log header as defined by the C++ implementation.
-It returns a buffer containing the formatted header and the user's file and line number.
-The depth specifies how many stack frames above lives the source line to be identified in the log message.
-
-Log lines have this form:
- Lmmdd hh:mm:ss.uuuuuu threadid file:line] msg...
-where the fields are defined as follows:
- L A single character, representing the log level (eg 'I' for INFO)
- mm The month (zero padded; ie May is '05')
- dd The day (zero padded)
- hh:mm:ss.uuuuuu Time in hours, minutes and fractional seconds
- threadid The space-padded thread ID as returned by GetTID()
- file The file name
- line The line number
- msg The user-supplied message
-*/
-func (l *loggingT) header(s severity, depth int) (*buffer, string, int) {
- _, file, line, ok := runtime.Caller(3 + depth)
+func appendBacktrace(depth int, format string, args []any) (string, []any) {
+ // Capture a backtrace as a stackdump.Stack (both text and PC slice).
+ // Structured log sinks can extract the backtrace in whichever format they
+ // prefer (PCs or text), and Text sinks will include it as just another part
+ // of the log message.
+ //
+ // Use depth instead of depth+1 so that the backtrace always includes the
+ // log function itself - otherwise the reason for the trace appearing in the
+ // log may not be obvious to the reader.
+ dump := stackdump.Caller(depth)
+
+ // Add an arg and an entry in the format string for the stack dump.
+ //
+ // Copy the "args" slice to avoid a rare but serious aliasing bug
+ // (corrupting the caller's slice if they passed it to a non-Fatal call
+ // using "...").
+ format = format + "\n\n%v\n"
+ args = append(append([]any(nil), args...), dump)
+
+ return format, args
+}
+
+// logf writes a log message for a log function call (or log function wrapper)
+// at the given depth in the current goroutine's stack.
+func logf(depth int, severity logsink.Severity, verbose bool, stack stack, format string, args ...any) {
+ now := timeNow()
+ _, file, line, ok := runtime.Caller(depth + 1)
if !ok {
file = "???"
line = 1
- } else {
- slash := strings.LastIndex(file, "/")
- if slash >= 0 {
- file = file[slash+1:]
- }
}
- return l.formatHeader(s, file, line), file, line
-}
-// formatHeader formats a log header using the provided file name and line number.
-func (l *loggingT) formatHeader(s severity, file string, line int) *buffer {
- now := timeNow()
- if line < 0 {
- line = 0 // not a real line number, but acceptable to someDigits
+ if stack == withStack || backtraceAt(file, line) {
+ format, args = appendBacktrace(depth+1, format, args)
}
- if s > fatalLog {
- s = infoLog // for safety.
- }
- buf := l.getBuffer()
-
- // Avoid Fprintf, for speed. The format is so simple that we can do it quickly by hand.
- // It's worth about 3X. Fprintf is hard.
- _, month, day := now.Date()
- hour, minute, second := now.Clock()
- // Lmmdd hh:mm:ss.uuuuuu threadid file:line]
- buf.tmp[0] = severityChar[s]
- buf.twoDigits(1, int(month))
- buf.twoDigits(3, day)
- buf.tmp[5] = ' '
- buf.twoDigits(6, hour)
- buf.tmp[8] = ':'
- buf.twoDigits(9, minute)
- buf.tmp[11] = ':'
- buf.twoDigits(12, second)
- buf.tmp[14] = '.'
- buf.nDigits(6, 15, now.Nanosecond()/1000, '0')
- buf.tmp[21] = ' '
- buf.nDigits(7, 22, pid, ' ') // TODO: should be TID
- buf.tmp[29] = ' '
- buf.Write(buf.tmp[:30])
- buf.WriteString(file)
- buf.tmp[0] = ':'
- n := buf.someDigits(1, line)
- buf.tmp[n+1] = ']'
- buf.tmp[n+2] = ' '
- buf.Write(buf.tmp[:n+3])
- return buf
-}
-
-// Some custom tiny helper functions to print the log header efficiently.
-
-const digits = "0123456789"
-// twoDigits formats a zero-prefixed two-digit integer at buf.tmp[i].
-func (buf *buffer) twoDigits(i, d int) {
- buf.tmp[i+1] = digits[d%10]
- d /= 10
- buf.tmp[i] = digits[d%10]
-}
-
-// nDigits formats an n-digit integer at buf.tmp[i],
-// padding with pad on the left.
-// It assumes d >= 0.
-func (buf *buffer) nDigits(n, i, d int, pad byte) {
- j := n - 1
- for ; j >= 0 && d > 0; j-- {
- buf.tmp[i+j] = digits[d%10]
- d /= 10
- }
- for ; j >= 0; j-- {
- buf.tmp[i+j] = pad
- }
-}
-
-// someDigits formats a zero-prefixed variable-width integer at buf.tmp[i].
-func (buf *buffer) someDigits(i, d int) int {
- // Print into the top, then copy down. We know there's space for at least
- // a 10-digit number.
- j := len(buf.tmp)
- for {
- j--
- buf.tmp[j] = digits[d%10]
- d /= 10
- if d == 0 {
- break
- }
+ metai, meta := metaPoolGet()
+ *meta = logsink.Meta{
+ Time: now,
+ File: file,
+ Line: line,
+ Depth: depth + 1,
+ Severity: severity,
+ Verbose: verbose,
+ Thread: int64(pid),
}
- return copy(buf.tmp[i:], buf.tmp[j:])
+ sinkf(meta, format, args...)
+ metaPool.Put(metai)
}
-func (l *loggingT) println(s severity, args ...interface{}) {
- buf, file, line := l.header(s, 0)
- fmt.Fprintln(buf, args...)
- l.output(s, buf, file, line, false)
-}
-
-func (l *loggingT) print(s severity, args ...interface{}) {
- l.printDepth(s, 1, args...)
-}
-
-func (l *loggingT) printDepth(s severity, depth int, args ...interface{}) {
- buf, file, line := l.header(s, depth)
- fmt.Fprint(buf, args...)
- if buf.Bytes()[buf.Len()-1] != '\n' {
- buf.WriteByte('\n')
- }
- l.output(s, buf, file, line, false)
-}
-
-func (l *loggingT) printf(s severity, format string, args ...interface{}) {
- buf, file, line := l.header(s, 0)
- fmt.Fprintf(buf, format, args...)
- if buf.Bytes()[buf.Len()-1] != '\n' {
- buf.WriteByte('\n')
- }
- l.output(s, buf, file, line, false)
-}
-
-// printWithFileLine behaves like print but uses the provided file and line number. If
-// alsoLogToStderr is true, the log message always appears on standard error; it
-// will also appear in the log file unless --logtostderr is set.
-func (l *loggingT) printWithFileLine(s severity, file string, line int, alsoToStderr bool, args ...interface{}) {
- buf := l.formatHeader(s, file, line)
- fmt.Fprint(buf, args...)
- if buf.Bytes()[buf.Len()-1] != '\n' {
- buf.WriteByte('\n')
- }
- l.output(s, buf, file, line, alsoToStderr)
-}
-
-// output writes the data to the log files and releases the buffer.
-func (l *loggingT) output(s severity, buf *buffer, file string, line int, alsoToStderr bool) {
- l.mu.Lock()
- if l.traceLocation.isSet() {
- if l.traceLocation.match(file, line) {
- buf.Write(stacks(false))
- }
- }
- data := buf.Bytes()
- if !flag.Parsed() {
- os.Stderr.Write([]byte("ERROR: logging before flag.Parse: "))
- os.Stderr.Write(data)
- } else if l.toStderr {
- os.Stderr.Write(data)
- } else {
- if alsoToStderr || l.alsoToStderr || s >= l.stderrThreshold.get() {
- os.Stderr.Write(data)
- }
- if l.file[s] == nil {
- if err := l.createFiles(s); err != nil {
- os.Stderr.Write(data) // Make sure the message appears somewhere.
- l.exit(err)
- }
- }
- switch s {
- case fatalLog:
- l.file[fatalLog].Write(data)
- fallthrough
- case errorLog:
- l.file[errorLog].Write(data)
- fallthrough
- case warningLog:
- l.file[warningLog].Write(data)
- fallthrough
- case infoLog:
- l.file[infoLog].Write(data)
- }
- }
- if s == fatalLog {
- // If we got here via Exit rather than Fatal, print no stacks.
- if atomic.LoadUint32(&fatalNoStacks) > 0 {
- l.mu.Unlock()
- timeoutFlush(10 * time.Second)
- os.Exit(1)
- }
- // Dump all goroutine stacks before exiting.
- // First, make sure we see the trace for the current goroutine on standard error.
- // If -logtostderr has been specified, the loop below will do that anyway
- // as the first stack in the full dump.
- if !l.toStderr {
- os.Stderr.Write(stacks(false))
- }
- // Write the stack trace for all goroutines to the files.
- trace := stacks(true)
- logExitFunc = func(error) {} // If we get a write error, we'll still exit below.
- for log := fatalLog; log >= infoLog; log-- {
- if f := l.file[log]; f != nil { // Can be nil if -logtostderr is set.
- f.Write(trace)
- }
- }
- l.mu.Unlock()
- timeoutFlush(10 * time.Second)
- os.Exit(255) // C++ uses -1, which is silly because it's anded with 255 anyway.
- }
- l.putBuffer(buf)
- l.mu.Unlock()
- if stats := severityStats[s]; stats != nil {
+func sinkf(meta *logsink.Meta, format string, args ...any) {
+ meta.Depth++
+ n, err := logsink.Printf(meta, format, args...)
+ if stats := severityStats[meta.Severity]; stats != nil {
atomic.AddInt64(&stats.lines, 1)
- atomic.AddInt64(&stats.bytes, int64(len(data)))
- }
-}
-
-// timeoutFlush calls Flush and returns when it completes or after timeout
-// elapses, whichever happens first. This is needed because the hooks invoked
-// by Flush may deadlock when glog.Fatal is called from a hook that holds
-// a lock.
-func timeoutFlush(timeout time.Duration) {
- done := make(chan bool, 1)
- go func() {
- Flush() // calls logging.lockAndFlushAll()
- done <- true
- }()
- select {
- case <-done:
- case <-time.After(timeout):
- fmt.Fprintln(os.Stderr, "glog: Flush took longer than", timeout)
- }
-}
-
-// stacks is a wrapper for runtime.Stack that attempts to recover the data for all goroutines.
-func stacks(all bool) []byte {
- // We don't know how big the traces are, so grow a few times if they don't fit. Start large, though.
- n := 10000
- if all {
- n = 100000
- }
- var trace []byte
- for i := 0; i < 5; i++ {
- trace = make([]byte, n)
- nbytes := runtime.Stack(trace, all)
- if nbytes < len(trace) {
- return trace[:nbytes]
- }
- n *= 2
- }
- return trace
-}
-
-// logExitFunc provides a simple mechanism to override the default behavior
-// of exiting on error. Used in testing and to guarantee we reach a required exit
-// for fatal logs. Instead, exit could be a function rather than a method but that
-// would make its use clumsier.
-var logExitFunc func(error)
-
-// exit is called if there is trouble creating or writing log files.
-// It flushes the logs and exits the program; there's no point in hanging around.
-// l.mu is held.
-func (l *loggingT) exit(err error) {
- fmt.Fprintf(os.Stderr, "log: exiting because of error: %s\n", err)
- // If logExitFunc is set, we do that instead of exiting.
- if logExitFunc != nil {
- logExitFunc(err)
- return
- }
- l.flushAll()
- os.Exit(2)
-}
-
-// syncBuffer joins a bufio.Writer to its underlying file, providing access to the
-// file's Sync method and providing a wrapper for the Write method that provides log
-// file rotation. There are conflicting methods, so the file cannot be embedded.
-// l.mu is held for all its methods.
-type syncBuffer struct {
- logger *loggingT
- *bufio.Writer
- file *os.File
- sev severity
- nbytes uint64 // The number of bytes written to this file
-}
-
-func (sb *syncBuffer) Sync() error {
- return sb.file.Sync()
-}
-
-func (sb *syncBuffer) Write(p []byte) (n int, err error) {
- if sb.nbytes+uint64(len(p)) >= MaxSize {
- if err := sb.rotateFile(time.Now()); err != nil {
- sb.logger.exit(err)
- }
+ atomic.AddInt64(&stats.bytes, int64(n))
}
- n, err = sb.Writer.Write(p)
- sb.nbytes += uint64(n)
- if err != nil {
- sb.logger.exit(err)
- }
- return
-}
-// rotateFile closes the syncBuffer's file and starts a new one.
-func (sb *syncBuffer) rotateFile(now time.Time) error {
- if sb.file != nil {
- sb.Flush()
- sb.file.Close()
- }
- var err error
- sb.file, _, err = create(severityName[sb.sev], now)
- sb.nbytes = 0
if err != nil {
- return err
- }
-
- sb.Writer = bufio.NewWriterSize(sb.file, bufferSize)
-
- // Write header.
- var buf bytes.Buffer
- fmt.Fprintf(&buf, "Log file created at: %s\n", now.Format("2006/01/02 15:04:05"))
- fmt.Fprintf(&buf, "Running on machine: %s\n", host)
- fmt.Fprintf(&buf, "Binary: Built with %s %s for %s/%s\n", runtime.Compiler, runtime.Version(), runtime.GOOS, runtime.GOARCH)
- fmt.Fprintf(&buf, "Log line format: [IWEF]mmdd hh:mm:ss.uuuuuu threadid file:line] msg\n")
- n, err := sb.file.Write(buf.Bytes())
- sb.nbytes += uint64(n)
- return err
-}
-
-// bufferSize sizes the buffer associated with each log file. It's large
-// so that log records can accumulate without the logging thread blocking
-// on disk I/O. The flushDaemon will block instead.
-const bufferSize = 256 * 1024
-
-// createFiles creates all the log files for severity from sev down to infoLog.
-// l.mu is held.
-func (l *loggingT) createFiles(sev severity) error {
- now := time.Now()
- // Files are created in decreasing severity order, so as soon as we find one
- // has already been created, we can stop.
- for s := sev; s >= infoLog && l.file[s] == nil; s-- {
- sb := &syncBuffer{
- logger: l,
- sev: s,
- }
- if err := sb.rotateFile(now); err != nil {
- return err
- }
- l.file[s] = sb
- }
- return nil
-}
-
-const flushInterval = 30 * time.Second
-
-// flushDaemon periodically flushes the log file buffers.
-func (l *loggingT) flushDaemon() {
- for range time.NewTicker(flushInterval).C {
- l.lockAndFlushAll()
- }
-}
-
-// lockAndFlushAll is like flushAll but locks l.mu first.
-func (l *loggingT) lockAndFlushAll() {
- l.mu.Lock()
- l.flushAll()
- l.mu.Unlock()
-}
-
-// flushAll flushes all the logs and attempts to "sync" their data to disk.
-// l.mu is held.
-func (l *loggingT) flushAll() {
- // Flush from fatal down, in case there's trouble flushing.
- for s := fatalLog; s >= infoLog; s-- {
- file := l.file[s]
- if file != nil {
- file.Flush() // ignore error
- file.Sync() // ignore error
- }
+ logsink.Printf(meta, "glog: exiting because of error: %s", err)
+ sinks.file.Flush()
+ os.Exit(2)
}
}
@@ -912,9 +234,9 @@ func (l *loggingT) flushAll() {
// Valid names are "INFO", "WARNING", "ERROR", and "FATAL". If the name is not
// recognized, CopyStandardLogTo panics.
func CopyStandardLogTo(name string) {
- sev, ok := severityByName(name)
- if !ok {
- panic(fmt.Sprintf("log.CopyStandardLogTo(%q): unrecognized severity name", name))
+ sev, err := logsink.ParseSeverity(name)
+ if err != nil {
+ panic(fmt.Sprintf("log.CopyStandardLogTo(%q): %v", name, err))
}
// Set a log format that captures the user's file and line:
// d.go:23: message
@@ -922,9 +244,22 @@ func CopyStandardLogTo(name string) {
stdLog.SetOutput(logBridge(sev))
}
+// NewStandardLogger returns a Logger that writes to the Google logs for the
+// named and lower severities.
+//
+// Valid names are "INFO", "WARNING", "ERROR", and "FATAL". If the name is not
+// recognized, NewStandardLogger panics.
+func NewStandardLogger(name string) *stdLog.Logger {
+ sev, err := logsink.ParseSeverity(name)
+ if err != nil {
+ panic(fmt.Sprintf("log.NewStandardLogger(%q): %v", name, err))
+ }
+ return stdLog.New(logBridge(sev), "", stdLog.Lshortfile)
+}
+
// logBridge provides the Write method that enables CopyStandardLogTo to connect
// Go's standard logs to the logs provided by this package.
-type logBridge severity
+type logBridge logsink.Severity
// Write parses the standard logging line and passes its components to the
// logger for severity(lb).
@@ -946,36 +281,72 @@ func (lb logBridge) Write(b []byte) (n int, err error) {
line = 1
}
}
- // printWithFileLine with alsoToStderr=true, so standard log messages
- // always appear on standard error.
- logging.printWithFileLine(severity(lb), file, line, true, text)
+
+ // The depth below hard-codes details of how stdlog gets here. The alternative would be to walk
+ // up the stack looking for src/log/log.go but that seems like it would be
+ // unfortunately slow.
+ const stdLogDepth = 4
+
+ metai, meta := metaPoolGet()
+ *meta = logsink.Meta{
+ Time: timeNow(),
+ File: file,
+ Line: line,
+ Depth: stdLogDepth,
+ Severity: logsink.Severity(lb),
+ Thread: int64(pid),
+ }
+
+ format := "%s"
+ args := []any{text}
+ if backtraceAt(file, line) {
+ format, args = appendBacktrace(meta.Depth, format, args)
+ }
+
+ sinkf(meta, format, args...)
+ metaPool.Put(metai)
+
return len(b), nil
}
-// setV computes and remembers the V level for a given PC
-// when vmodule is enabled.
-// File pattern matching takes the basename of the file, stripped
-// of its .go suffix, and uses filepath.Match, which is a little more
-// general than the *? matching used in C++.
-// l.mu is held.
-func (l *loggingT) setV(pc uintptr) Level {
- fn := runtime.FuncForPC(pc)
- file, _ := fn.FileLine(pc)
- // The file is something like /a/b/c/d.go. We want just the d.
- if strings.HasSuffix(file, ".go") {
- file = file[:len(file)-3]
+// defaultFormat returns a fmt.Printf format specifier that formats its
+// arguments as if they were passed to fmt.Print.
+func defaultFormat(args []any) string {
+ n := len(args)
+ switch n {
+ case 0:
+ return ""
+ case 1:
+ return "%v"
+ }
+
+ b := make([]byte, 0, n*3-1)
+ wasString := true // Suppress leading space.
+ for _, arg := range args {
+ isString := arg != nil && reflect.TypeOf(arg).Kind() == reflect.String
+ if wasString || isString {
+ b = append(b, "%v"...)
+ } else {
+ b = append(b, " %v"...)
+ }
+ wasString = isString
}
- if slash := strings.LastIndex(file, "/"); slash >= 0 {
- file = file[slash+1:]
+ return string(b)
+}
+
+// lnFormat returns a fmt.Printf format specifier that formats its arguments
+// as if they were passed to fmt.Println.
+func lnFormat(args []any) string {
+ if len(args) == 0 {
+ return "\n"
}
- for _, filter := range l.vmodule.filter {
- if filter.match(file) {
- l.vmap[pc] = filter.level
- return filter.level
- }
+
+ b := make([]byte, 0, len(args)*3)
+ for range args {
+ b = append(b, "%v "...)
}
- l.vmap[pc] = 0
- return 0
+ b[len(b)-1] = '\n' // Replace the last space with a newline.
+ return string(b)
}
// Verbose is a boolean type that implements Infof (like Printf) etc.
@@ -986,9 +357,13 @@ type Verbose bool
// The returned value is a boolean of type Verbose, which implements Info, Infoln
// and Infof. These methods will write to the Info log if called.
// Thus, one may write either
+//
// if glog.V(2) { glog.Info("log this") }
+//
// or
+//
// glog.V(2).Info("log this")
+//
// The second form is shorter but the first is cheaper if logging is off because it does
// not evaluate its arguments.
//
@@ -997,184 +372,250 @@ type Verbose bool
// V is at most the value of -v, or of -vmodule for the source file containing the
// call, the V call will log.
func V(level Level) Verbose {
- // This function tries hard to be cheap unless there's work to do.
- // The fast path is two atomic loads and compares.
+ return VDepth(1, level)
+}
- // Here is a cheap but safe test to see if V logging is enabled globally.
- if logging.verbosity.get() >= level {
- return Verbose(true)
- }
+// VDepth acts as V but uses depth to determine which call frame to check vmodule for.
+// VDepth(0, level) is the same as V(level).
+func VDepth(depth int, level Level) Verbose {
+ return Verbose(verboseEnabled(depth+1, level))
+}
- // It's off globally but it vmodule may still be set.
- // Here is another cheap but safe test to see if vmodule is enabled.
- if atomic.LoadInt32(&logging.filterLength) > 0 {
- // Now we need a proper lock to use the logging structure. The pcs field
- // is shared so we must lock before accessing it. This is fairly expensive,
- // but if V logging is enabled we're slow anyway.
- logging.mu.Lock()
- defer logging.mu.Unlock()
- if runtime.Callers(2, logging.pcs[:]) == 0 {
- return Verbose(false)
- }
- v, ok := logging.vmap[logging.pcs[0]]
- if !ok {
- v = logging.setV(logging.pcs[0])
- }
- return Verbose(v >= level)
+// Info is equivalent to the global Info function, guarded by the value of v.
+// See the documentation of V for usage.
+func (v Verbose) Info(args ...any) {
+ v.InfoDepth(1, args...)
+}
+
+// InfoDepth is equivalent to the global InfoDepth function, guarded by the value of v.
+// See the documentation of V for usage.
+func (v Verbose) InfoDepth(depth int, args ...any) {
+ if v {
+ logf(depth+1, logsink.Info, true, noStack, defaultFormat(args), args...)
}
- return Verbose(false)
}
-// Info is equivalent to the global Info function, guarded by the value of v.
+// InfoDepthf is equivalent to the global InfoDepthf function, guarded by the value of v.
// See the documentation of V for usage.
-func (v Verbose) Info(args ...interface{}) {
+func (v Verbose) InfoDepthf(depth int, format string, args ...any) {
if v {
- logging.print(infoLog, args...)
+ logf(depth+1, logsink.Info, true, noStack, format, args...)
}
}
// Infoln is equivalent to the global Infoln function, guarded by the value of v.
// See the documentation of V for usage.
-func (v Verbose) Infoln(args ...interface{}) {
+func (v Verbose) Infoln(args ...any) {
if v {
- logging.println(infoLog, args...)
+ logf(1, logsink.Info, true, noStack, lnFormat(args), args...)
}
}
// Infof is equivalent to the global Infof function, guarded by the value of v.
// See the documentation of V for usage.
-func (v Verbose) Infof(format string, args ...interface{}) {
+func (v Verbose) Infof(format string, args ...any) {
if v {
- logging.printf(infoLog, format, args...)
+ logf(1, logsink.Info, true, noStack, format, args...)
}
}
// Info logs to the INFO log.
// Arguments are handled in the manner of fmt.Print; a newline is appended if missing.
-func Info(args ...interface{}) {
- logging.print(infoLog, args...)
+func Info(args ...any) {
+ InfoDepth(1, args...)
+}
+
+// InfoDepth calls Info from a different depth in the call stack.
+// This enables a callee to emit logs that use the callsite information of its caller
+// or any other callers in the stack. When depth == 0, the original callee's line
+// information is emitted. When depth > 0, depth frames are skipped in the call stack
+// and the final frame is treated like the original callee to Info.
+func InfoDepth(depth int, args ...any) {
+ logf(depth+1, logsink.Info, false, noStack, defaultFormat(args), args...)
}
-// InfoDepth acts as Info but uses depth to determine which call frame to log.
-// InfoDepth(0, "msg") is the same as Info("msg").
-func InfoDepth(depth int, args ...interface{}) {
- logging.printDepth(infoLog, depth, args...)
+// InfoDepthf acts as InfoDepth but with format string.
+func InfoDepthf(depth int, format string, args ...any) {
+ logf(depth+1, logsink.Info, false, noStack, format, args...)
}
// Infoln logs to the INFO log.
// Arguments are handled in the manner of fmt.Println; a newline is appended if missing.
-func Infoln(args ...interface{}) {
- logging.println(infoLog, args...)
+func Infoln(args ...any) {
+ logf(1, logsink.Info, false, noStack, lnFormat(args), args...)
}
// Infof logs to the INFO log.
// Arguments are handled in the manner of fmt.Printf; a newline is appended if missing.
-func Infof(format string, args ...interface{}) {
- logging.printf(infoLog, format, args...)
+func Infof(format string, args ...any) {
+ logf(1, logsink.Info, false, noStack, format, args...)
}
// Warning logs to the WARNING and INFO logs.
// Arguments are handled in the manner of fmt.Print; a newline is appended if missing.
-func Warning(args ...interface{}) {
- logging.print(warningLog, args...)
+func Warning(args ...any) {
+ WarningDepth(1, args...)
}
// WarningDepth acts as Warning but uses depth to determine which call frame to log.
// WarningDepth(0, "msg") is the same as Warning("msg").
-func WarningDepth(depth int, args ...interface{}) {
- logging.printDepth(warningLog, depth, args...)
+func WarningDepth(depth int, args ...any) {
+ logf(depth+1, logsink.Warning, false, noStack, defaultFormat(args), args...)
+}
+
+// WarningDepthf acts as Warningf but uses depth to determine which call frame to log.
+// WarningDepthf(0, "msg") is the same as Warningf("msg").
+func WarningDepthf(depth int, format string, args ...any) {
+ logf(depth+1, logsink.Warning, false, noStack, format, args...)
}
// Warningln logs to the WARNING and INFO logs.
// Arguments are handled in the manner of fmt.Println; a newline is appended if missing.
-func Warningln(args ...interface{}) {
- logging.println(warningLog, args...)
+func Warningln(args ...any) {
+ logf(1, logsink.Warning, false, noStack, lnFormat(args), args...)
}
// Warningf logs to the WARNING and INFO logs.
// Arguments are handled in the manner of fmt.Printf; a newline is appended if missing.
-func Warningf(format string, args ...interface{}) {
- logging.printf(warningLog, format, args...)
+func Warningf(format string, args ...any) {
+ logf(1, logsink.Warning, false, noStack, format, args...)
}
// Error logs to the ERROR, WARNING, and INFO logs.
// Arguments are handled in the manner of fmt.Print; a newline is appended if missing.
-func Error(args ...interface{}) {
- logging.print(errorLog, args...)
+func Error(args ...any) {
+ ErrorDepth(1, args...)
}
// ErrorDepth acts as Error but uses depth to determine which call frame to log.
// ErrorDepth(0, "msg") is the same as Error("msg").
-func ErrorDepth(depth int, args ...interface{}) {
- logging.printDepth(errorLog, depth, args...)
+func ErrorDepth(depth int, args ...any) {
+ logf(depth+1, logsink.Error, false, noStack, defaultFormat(args), args...)
+}
+
+// ErrorDepthf acts as Errorf but uses depth to determine which call frame to log.
+// ErrorDepthf(0, "msg") is the same as Errorf("msg").
+func ErrorDepthf(depth int, format string, args ...any) {
+ logf(depth+1, logsink.Error, false, noStack, format, args...)
}
// Errorln logs to the ERROR, WARNING, and INFO logs.
// Arguments are handled in the manner of fmt.Println; a newline is appended if missing.
-func Errorln(args ...interface{}) {
- logging.println(errorLog, args...)
+func Errorln(args ...any) {
+ logf(1, logsink.Error, false, noStack, lnFormat(args), args...)
}
// Errorf logs to the ERROR, WARNING, and INFO logs.
// Arguments are handled in the manner of fmt.Printf; a newline is appended if missing.
-func Errorf(format string, args ...interface{}) {
- logging.printf(errorLog, format, args...)
+func Errorf(format string, args ...any) {
+ logf(1, logsink.Error, false, noStack, format, args...)
+}
+
+func fatalf(depth int, format string, args ...any) {
+ logf(depth+1, logsink.Fatal, false, withStack, format, args...)
+ sinks.file.Flush()
+
+ err := abortProcess() // Should not return.
+
+ // Failed to abort the process using signals. Dump a stack trace and exit.
+ Errorf("abortProcess returned unexpectedly: %v", err)
+ sinks.file.Flush()
+ pprof.Lookup("goroutine").WriteTo(os.Stderr, 1)
+ os.Exit(2) // Exit with the same code as the default SIGABRT handler.
+}
+
+// abortProcess attempts to kill the current process in a way that will dump the
+// currently-running goroutines someplace useful (Coroner or stderr).
+//
+// It does this by sending SIGABRT to the current process. Unfortunately, the
+// signal may or may not be delivered to the current thread; in order to do that
+// portably, we would need to add a cgo dependency and call pthread_kill.
+//
+// If successful, abortProcess does not return.
+func abortProcess() error {
+ p, err := os.FindProcess(os.Getpid())
+ if err != nil {
+ return err
+ }
+ if err := p.Signal(syscall.SIGABRT); err != nil {
+ return err
+ }
+
+ // Sent the signal. Now we wait for it to arrive and any SIGABRT handlers to
+ // run (and eventually terminate the process themselves).
+ //
+ // We could just "select{}" here, but there's an outside chance that would
+ // trigger the runtime's deadlock detector if there happen not to be any
+ // background goroutines running. So we'll sleep a while first to give
+ // the signal some time.
+ time.Sleep(10 * time.Second)
+ select {}
}
// Fatal logs to the FATAL, ERROR, WARNING, and INFO logs,
-// including a stack trace of all running goroutines, then calls os.Exit(255).
+// including a stack trace of all running goroutines, then calls os.Exit(2).
// Arguments are handled in the manner of fmt.Print; a newline is appended if missing.
-func Fatal(args ...interface{}) {
- logging.print(fatalLog, args...)
+func Fatal(args ...any) {
+ FatalDepth(1, args...)
}
// FatalDepth acts as Fatal but uses depth to determine which call frame to log.
// FatalDepth(0, "msg") is the same as Fatal("msg").
-func FatalDepth(depth int, args ...interface{}) {
- logging.printDepth(fatalLog, depth, args...)
+func FatalDepth(depth int, args ...any) {
+ fatalf(depth+1, defaultFormat(args), args...)
+}
+
+// FatalDepthf acts as Fatalf but uses depth to determine which call frame to log.
+// FatalDepthf(0, "msg") is the same as Fatalf("msg").
+func FatalDepthf(depth int, format string, args ...any) {
+ fatalf(depth+1, format, args...)
}
// Fatalln logs to the FATAL, ERROR, WARNING, and INFO logs,
-// including a stack trace of all running goroutines, then calls os.Exit(255).
+// including a stack trace of all running goroutines, then calls os.Exit(2).
// Arguments are handled in the manner of fmt.Println; a newline is appended if missing.
-func Fatalln(args ...interface{}) {
- logging.println(fatalLog, args...)
+func Fatalln(args ...any) {
+ fatalf(1, lnFormat(args), args...)
}
// Fatalf logs to the FATAL, ERROR, WARNING, and INFO logs,
-// including a stack trace of all running goroutines, then calls os.Exit(255).
+// including a stack trace of all running goroutines, then calls os.Exit(2).
// Arguments are handled in the manner of fmt.Printf; a newline is appended if missing.
-func Fatalf(format string, args ...interface{}) {
- logging.printf(fatalLog, format, args...)
+func Fatalf(format string, args ...any) {
+ fatalf(1, format, args...)
}
-// fatalNoStacks is non-zero if we are to exit without dumping goroutine stacks.
-// It allows Exit and relatives to use the Fatal logs.
-var fatalNoStacks uint32
+func exitf(depth int, format string, args ...any) {
+ logf(depth+1, logsink.Fatal, false, noStack, format, args...)
+ sinks.file.Flush()
+ os.Exit(1)
+}
// Exit logs to the FATAL, ERROR, WARNING, and INFO logs, then calls os.Exit(1).
// Arguments are handled in the manner of fmt.Print; a newline is appended if missing.
-func Exit(args ...interface{}) {
- atomic.StoreUint32(&fatalNoStacks, 1)
- logging.print(fatalLog, args...)
+func Exit(args ...any) {
+ ExitDepth(1, args...)
}
// ExitDepth acts as Exit but uses depth to determine which call frame to log.
// ExitDepth(0, "msg") is the same as Exit("msg").
-func ExitDepth(depth int, args ...interface{}) {
- atomic.StoreUint32(&fatalNoStacks, 1)
- logging.printDepth(fatalLog, depth, args...)
+func ExitDepth(depth int, args ...any) {
+ exitf(depth+1, defaultFormat(args), args...)
+}
+
+// ExitDepthf acts as Exitf but uses depth to determine which call frame to log.
+// ExitDepthf(0, "msg") is the same as Exitf("msg").
+func ExitDepthf(depth int, format string, args ...any) {
+ exitf(depth+1, format, args...)
}
// Exitln logs to the FATAL, ERROR, WARNING, and INFO logs, then calls os.Exit(1).
-func Exitln(args ...interface{}) {
- atomic.StoreUint32(&fatalNoStacks, 1)
- logging.println(fatalLog, args...)
+func Exitln(args ...any) {
+ exitf(1, lnFormat(args), args...)
}
// Exitf logs to the FATAL, ERROR, WARNING, and INFO logs, then calls os.Exit(1).
// Arguments are handled in the manner of fmt.Printf; a newline is appended if missing.
-func Exitf(format string, args ...interface{}) {
- atomic.StoreUint32(&fatalNoStacks, 1)
- logging.printf(fatalLog, format, args...)
+func Exitf(format string, args ...any) {
+ exitf(1, format, args...)
}
diff --git a/vendor/github.com/golang/glog/glog_file.go b/vendor/github.com/golang/glog/glog_file.go
index 65075d28111..af1c934b820 100644
--- a/vendor/github.com/golang/glog/glog_file.go
+++ b/vendor/github.com/golang/glog/glog_file.go
@@ -1,6 +1,6 @@
-// Go support for leveled logs, analogous to https://code.google.com/p/google-glog/
+// Go support for leveled logs, analogous to https://github.com/google/glog.
//
-// Copyright 2013 Google Inc. All Rights Reserved.
+// Copyright 2023 Google Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -19,26 +19,34 @@
package glog
import (
+ "bufio"
+ "bytes"
"errors"
"flag"
"fmt"
+ "io"
"os"
"os/user"
"path/filepath"
+ "runtime"
"strings"
"sync"
"time"
-)
-// MaxSize is the maximum size of a log file in bytes.
-var MaxSize uint64 = 1024 * 1024 * 1800
+ "github.com/golang/glog/internal/logsink"
+)
// logDirs lists the candidate directories for new log files.
var logDirs []string
-// If non-empty, overrides the choice of directory in which to write logs.
-// See createLogDirs for the full list of possible destinations.
-var logDir = flag.String("log_dir", "", "If non-empty, write log files in this directory")
+var (
+ // If non-empty, overrides the choice of directory in which to write logs.
+ // See createLogDirs for the full list of possible destinations.
+ logDir = flag.String("log_dir", "", "If non-empty, write log files in this directory")
+ logLink = flag.String("log_link", "", "If non-empty, add symbolic links in this directory to the log files")
+ logBufLevel = flag.Int("logbuflevel", int(logsink.Info), "Buffer log messages logged at this level or lower"+
+ " (-1 means don't buffer; 0 means buffer INFO only; ...). Has limited applicability on non-prod platforms.")
+)
func createLogDirs() {
if *logDir != "" {
@@ -64,9 +72,17 @@ func init() {
if err == nil {
userName = current.Username
}
-
- // Sanitize userName since it may contain filepath separators on Windows.
- userName = strings.Replace(userName, `\`, "_", -1)
+ // Sanitize userName since it is used to construct file paths.
+ userName = strings.Map(func(r rune) rune {
+ switch {
+ case r >= 'a' && r <= 'z':
+ case r >= 'A' && r <= 'Z':
+ case r >= '0' && r <= '9':
+ default:
+ return '_'
+ }
+ return r
+ }, userName)
}
// shortHostname returns its argument, truncating at the first period.
@@ -122,3 +138,270 @@ func create(tag string, t time.Time) (f *os.File, filename string, err error) {
}
return nil, "", fmt.Errorf("log: cannot create log: %v", lastErr)
}
+
+// flushSyncWriter is the interface satisfied by logging destinations.
+type flushSyncWriter interface {
+ Flush() error
+ Sync() error
+ io.Writer
+ filenames() []string
+}
+
+var sinks struct {
+ stderr stderrSink
+ file fileSink
+}
+
+func init() {
+ sinks.stderr.w = os.Stderr
+
+ // Register stderr first: that way if we crash during file-writing at least
+ // the log will have gone somewhere.
+ logsink.TextSinks = append(logsink.TextSinks, &sinks.stderr, &sinks.file)
+
+ sinks.file.flushChan = make(chan logsink.Severity, 1)
+ go sinks.file.flushDaemon()
+}
+
+// stderrSink is a logsink.Text that writes log entries to stderr
+// if they meet certain conditions.
+type stderrSink struct {
+ mu sync.Mutex
+ w io.Writer
+}
+
+// Enabled implements logsink.Text.Enabled. It returns true if any of the
+// various stderr flags are enabled for logs of the given severity, if the log
+// message is from the standard "log" package, or if google.Init has not yet run
+// (and hence file logging is not yet initialized).
+func (s *stderrSink) Enabled(m *logsink.Meta) bool {
+ return toStderr || alsoToStderr || m.Severity >= stderrThreshold.get()
+}
+
+// Emit implements logsink.Text.Emit.
+func (s *stderrSink) Emit(m *logsink.Meta, data []byte) (n int, err error) {
+ s.mu.Lock()
+ defer s.mu.Unlock()
+
+ dn, err := s.w.Write(data)
+ n += dn
+ return n, err
+}
+
+// severityWriters is an array of flushSyncWriter with a value for each
+// logsink.Severity.
+type severityWriters [4]flushSyncWriter
+
+// fileSink is a logsink.Text that prints to a set of Google log files.
+type fileSink struct {
+ mu sync.Mutex
+ // file holds writer for each of the log types.
+ file severityWriters
+ flushChan chan logsink.Severity
+}
+
+// Enabled implements logsink.Text.Enabled. It returns true if google.Init
+// has run and both --disable_log_to_disk and --logtostderr are false.
+func (s *fileSink) Enabled(m *logsink.Meta) bool {
+ return !toStderr
+}
+
+// Emit implements logsink.Text.Emit
+func (s *fileSink) Emit(m *logsink.Meta, data []byte) (n int, err error) {
+ s.mu.Lock()
+ defer s.mu.Unlock()
+
+ if err = s.createMissingFiles(m.Severity); err != nil {
+ return 0, err
+ }
+ for sev := m.Severity; sev >= logsink.Info; sev-- {
+ if _, fErr := s.file[sev].Write(data); fErr != nil && err == nil {
+ err = fErr // Take the first error.
+ }
+ }
+ n = len(data)
+ if int(m.Severity) > *logBufLevel {
+ select {
+ case s.flushChan <- m.Severity:
+ default:
+ }
+ }
+
+ return n, err
+}
+
+// syncBuffer joins a bufio.Writer to its underlying file, providing access to the
+// file's Sync method and providing a wrapper for the Write method that provides log
+// file rotation. There are conflicting methods, so the file cannot be embedded.
+// s.mu is held for all its methods.
+type syncBuffer struct {
+ sink *fileSink
+ *bufio.Writer
+ file *os.File
+ names []string
+ sev logsink.Severity
+ nbytes uint64 // The number of bytes written to this file
+}
+
+func (sb *syncBuffer) Sync() error {
+ return sb.file.Sync()
+}
+
+func (sb *syncBuffer) Write(p []byte) (n int, err error) {
+ if sb.nbytes+uint64(len(p)) >= MaxSize {
+ if err := sb.rotateFile(time.Now()); err != nil {
+ return 0, err
+ }
+ }
+ n, err = sb.Writer.Write(p)
+ sb.nbytes += uint64(n)
+ return n, err
+}
+
+func (sb *syncBuffer) filenames() []string {
+ return sb.names
+}
+
+const footer = "\nCONTINUED IN NEXT FILE\n"
+
+// rotateFile closes the syncBuffer's file and starts a new one.
+func (sb *syncBuffer) rotateFile(now time.Time) error {
+ var err error
+ pn := ""
+ file, name, err := create(sb.sev.String(), now)
+
+ if sb.file != nil {
+ // The current log file becomes the previous log at the end of
+ // this block, so save its name for use in the header of the next
+ // file.
+ pn = sb.file.Name()
+ sb.Flush()
+ // If there's an existing file, write a footer with the name of
+ // the next file in the chain, followed by the constant string
+ // \nCONTINUED IN NEXT FILE\n to make continuation detection simple.
+ sb.file.Write([]byte("Next log: "))
+ sb.file.Write([]byte(name))
+ sb.file.Write([]byte(footer))
+ sb.file.Close()
+ }
+
+ sb.file = file
+ sb.names = append(sb.names, name)
+ sb.nbytes = 0
+ if err != nil {
+ return err
+ }
+
+ sb.Writer = bufio.NewWriterSize(sb.file, bufferSize)
+
+ // Write header.
+ var buf bytes.Buffer
+ fmt.Fprintf(&buf, "Log file created at: %s\n", now.Format("2006/01/02 15:04:05"))
+ fmt.Fprintf(&buf, "Running on machine: %s\n", host)
+ fmt.Fprintf(&buf, "Binary: Built with %s %s for %s/%s\n", runtime.Compiler, runtime.Version(), runtime.GOOS, runtime.GOARCH)
+ fmt.Fprintf(&buf, "Previous log: %s\n", pn)
+ fmt.Fprintf(&buf, "Log line format: [IWEF]mmdd hh:mm:ss.uuuuuu threadid file:line] msg\n")
+ n, err := sb.file.Write(buf.Bytes())
+ sb.nbytes += uint64(n)
+ return err
+}
+
+// bufferSize sizes the buffer associated with each log file. It's large
+// so that log records can accumulate without the logging thread blocking
+// on disk I/O. The flushDaemon will block instead.
+const bufferSize = 256 * 1024
+
+// createMissingFiles creates all the log files for severity from infoLog up to
+// upTo that have not already been created.
+// s.mu is held.
+func (s *fileSink) createMissingFiles(upTo logsink.Severity) error {
+ if s.file[upTo] != nil {
+ return nil
+ }
+ now := time.Now()
+ // Files are created in increasing severity order, so we can be assured that
+ // if a high severity logfile exists, then so do all of lower severity.
+ for sev := logsink.Info; sev <= upTo; sev++ {
+ if s.file[sev] != nil {
+ continue
+ }
+ sb := &syncBuffer{
+ sink: s,
+ sev: sev,
+ }
+ if err := sb.rotateFile(now); err != nil {
+ return err
+ }
+ s.file[sev] = sb
+ }
+ return nil
+}
+
+// flushDaemon periodically flushes the log file buffers.
+func (s *fileSink) flushDaemon() {
+ tick := time.NewTicker(30 * time.Second)
+ defer tick.Stop()
+ for {
+ select {
+ case <-tick.C:
+ s.Flush()
+ case sev := <-s.flushChan:
+ s.flush(sev)
+ }
+ }
+}
+
+// Flush flushes all pending log I/O.
+func Flush() {
+ sinks.file.Flush()
+}
+
+// Flush flushes all the logs and attempts to "sync" their data to disk.
+func (s *fileSink) Flush() error {
+ return s.flush(logsink.Info)
+}
+
+// flush flushes all logs of severity threshold or greater.
+func (s *fileSink) flush(threshold logsink.Severity) error {
+ s.mu.Lock()
+ defer s.mu.Unlock()
+
+ var firstErr error
+ updateErr := func(err error) {
+ if err != nil && firstErr == nil {
+ firstErr = err
+ }
+ }
+
+ // Flush from fatal down, in case there's trouble flushing.
+ for sev := logsink.Fatal; sev >= threshold; sev-- {
+ file := s.file[sev]
+ if file != nil {
+ updateErr(file.Flush())
+ updateErr(file.Sync())
+ }
+ }
+
+ return firstErr
+}
+
+// Names returns the names of the log files holding the FATAL, ERROR,
+// WARNING, or INFO logs. Returns ErrNoLog if the log for the given
+// level doesn't exist (e.g. because no messages of that level have been
+// written). This may return multiple names if the log type requested
+// has rolled over.
+func Names(s string) ([]string, error) {
+ severity, err := logsink.ParseSeverity(s)
+ if err != nil {
+ return nil, err
+ }
+
+ sinks.file.mu.Lock()
+ defer sinks.file.mu.Unlock()
+ f := sinks.file.file[severity]
+ if f == nil {
+ return nil, ErrNoLog
+ }
+
+ return f.filenames(), nil
+}
diff --git a/vendor/github.com/golang/glog/glog_flags.go b/vendor/github.com/golang/glog/glog_flags.go
new file mode 100644
index 00000000000..3060e54d9dc
--- /dev/null
+++ b/vendor/github.com/golang/glog/glog_flags.go
@@ -0,0 +1,395 @@
+// Go support for leveled logs, analogous to https://github.com/google/glog.
+//
+// Copyright 2023 Google Inc. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package glog
+
+import (
+ "bytes"
+ "errors"
+ "flag"
+ "fmt"
+ "path/filepath"
+ "runtime"
+ "strconv"
+ "strings"
+ "sync"
+ "sync/atomic"
+
+ "github.com/golang/glog/internal/logsink"
+)
+
+// modulePat contains a filter for the -vmodule flag.
+// It holds a verbosity level and a file pattern to match.
+type modulePat struct {
+ pattern string
+ literal bool // The pattern is a literal string
+ full bool // The pattern wants to match the full path
+ level Level
+}
+
+// match reports whether the file matches the pattern. It uses a string
+// comparison if the pattern contains no metacharacters.
+func (m *modulePat) match(full, file string) bool {
+ if m.literal {
+ if m.full {
+ return full == m.pattern
+ }
+ return file == m.pattern
+ }
+ if m.full {
+ match, _ := filepath.Match(m.pattern, full)
+ return match
+ }
+ match, _ := filepath.Match(m.pattern, file)
+ return match
+}
+
+// isLiteral reports whether the pattern is a literal string, that is, has no metacharacters
+// that require filepath.Match to be called to match the pattern.
+func isLiteral(pattern string) bool {
+ return !strings.ContainsAny(pattern, `\*?[]`)
+}
+
+// isFull reports whether the pattern matches the full file path, that is,
+// whether it contains /.
+func isFull(pattern string) bool {
+ return strings.ContainsRune(pattern, '/')
+}
+
+// verboseFlags represents the setting of the -v and -vmodule flags.
+type verboseFlags struct {
+ // moduleLevelCache is a sync.Map storing the -vmodule Level for each V()
+ // call site, identified by PC. If there is no matching -vmodule filter,
+ // the cached value is exactly v. moduleLevelCache is replaced with a new
+ // Map whenever the -vmodule or -v flag changes state.
+ moduleLevelCache atomic.Value
+
+ // mu guards all fields below.
+ mu sync.Mutex
+
+ // v stores the value of the -v flag. It may be read safely using
+ // sync.LoadInt32, but is only modified under mu.
+ v Level
+
+ // module stores the parsed -vmodule flag.
+ module []modulePat
+
+ // moduleLength caches len(module). If greater than zero, it
+ // means vmodule is enabled. It may be read safely using sync.LoadInt32, but
+ // is only modified under mu.
+ moduleLength int32
+}
+
+// NOTE: For compatibility with the open-sourced v1 version of this
+// package (github.com/golang/glog) we need to retain that flag.Level
+// implements the flag.Value interface. See also go/log-vs-glog.
+
+// String is part of the flag.Value interface.
+func (l *Level) String() string {
+ return strconv.FormatInt(int64(l.Get().(Level)), 10)
+}
+
+// Get is part of the flag.Value interface.
+func (l *Level) Get() any {
+ if l == &vflags.v {
+ // l is the value registered for the -v flag.
+ return Level(atomic.LoadInt32((*int32)(l)))
+ }
+ return *l
+}
+
+// Set is part of the flag.Value interface.
+func (l *Level) Set(value string) error {
+ v, err := strconv.Atoi(value)
+ if err != nil {
+ return err
+ }
+ if l == &vflags.v {
+ // l is the value registered for the -v flag.
+ vflags.mu.Lock()
+ defer vflags.mu.Unlock()
+ vflags.moduleLevelCache.Store(&sync.Map{})
+ atomic.StoreInt32((*int32)(l), int32(v))
+ return nil
+ }
+ *l = Level(v)
+ return nil
+}
+
+// vModuleFlag is the flag.Value for the --vmodule flag.
+type vModuleFlag struct{ *verboseFlags }
+
+func (f vModuleFlag) String() string {
+ f.mu.Lock()
+ defer f.mu.Unlock()
+
+ var b bytes.Buffer
+ for i, f := range f.module {
+ if i > 0 {
+ b.WriteRune(',')
+ }
+ fmt.Fprintf(&b, "%s=%d", f.pattern, f.level)
+ }
+ return b.String()
+}
+
+// Get returns nil for this flag type since the struct is not exported.
+func (f vModuleFlag) Get() any { return nil }
+
+var errVmoduleSyntax = errors.New("syntax error: expect comma-separated list of filename=N")
+
+// Syntax: -vmodule=recordio=2,foo/bar/baz=1,gfs*=3
+func (f vModuleFlag) Set(value string) error {
+ var filter []modulePat
+ for _, pat := range strings.Split(value, ",") {
+ if len(pat) == 0 {
+ // Empty strings such as from a trailing comma can be ignored.
+ continue
+ }
+ patLev := strings.Split(pat, "=")
+ if len(patLev) != 2 || len(patLev[0]) == 0 || len(patLev[1]) == 0 {
+ return errVmoduleSyntax
+ }
+ pattern := patLev[0]
+ v, err := strconv.Atoi(patLev[1])
+ if err != nil {
+ return errors.New("syntax error: expect comma-separated list of filename=N")
+ }
+ // TODO: check syntax of filter?
+ filter = append(filter, modulePat{pattern, isLiteral(pattern), isFull(pattern), Level(v)})
+ }
+
+ f.mu.Lock()
+ defer f.mu.Unlock()
+ f.module = filter
+ atomic.StoreInt32((*int32)(&f.moduleLength), int32(len(f.module)))
+ f.moduleLevelCache.Store(&sync.Map{})
+ return nil
+}
+
+func (f *verboseFlags) levelForPC(pc uintptr) Level {
+ if level, ok := f.moduleLevelCache.Load().(*sync.Map).Load(pc); ok {
+ return level.(Level)
+ }
+
+ f.mu.Lock()
+ defer f.mu.Unlock()
+ level := Level(f.v)
+ fn := runtime.FuncForPC(pc)
+ file, _ := fn.FileLine(pc)
+ // The file is something like /a/b/c/d.go. We want just the d for
+ // regular matches, /a/b/c/d for full matches.
+ if strings.HasSuffix(file, ".go") {
+ file = file[:len(file)-3]
+ }
+ full := file
+ if slash := strings.LastIndex(file, "/"); slash >= 0 {
+ file = file[slash+1:]
+ }
+ for _, filter := range f.module {
+ if filter.match(full, file) {
+ level = filter.level
+ break // Use the first matching level.
+ }
+ }
+ f.moduleLevelCache.Load().(*sync.Map).Store(pc, level)
+ return level
+}
+
+func (f *verboseFlags) enabled(callerDepth int, level Level) bool {
+ if atomic.LoadInt32(&f.moduleLength) == 0 {
+ // No vmodule values specified, so compare against v level.
+ return Level(atomic.LoadInt32((*int32)(&f.v))) >= level
+ }
+
+ pcs := [1]uintptr{}
+ if runtime.Callers(callerDepth+2, pcs[:]) < 1 {
+ return false
+ }
+ frame, _ := runtime.CallersFrames(pcs[:]).Next()
+ return f.levelForPC(frame.Entry) >= level
+}
+
+// traceLocation represents an entry in the -log_backtrace_at flag.
+type traceLocation struct {
+ file string
+ line int
+}
+
+var errTraceSyntax = errors.New("syntax error: expect file.go:234")
+
+func parseTraceLocation(value string) (traceLocation, error) {
+ fields := strings.Split(value, ":")
+ if len(fields) != 2 {
+ return traceLocation{}, errTraceSyntax
+ }
+ file, lineStr := fields[0], fields[1]
+ if !strings.Contains(file, ".") {
+ return traceLocation{}, errTraceSyntax
+ }
+ line, err := strconv.Atoi(lineStr)
+ if err != nil {
+ return traceLocation{}, errTraceSyntax
+ }
+ if line < 0 {
+ return traceLocation{}, errors.New("negative value for line")
+ }
+ return traceLocation{file, line}, nil
+}
+
+// match reports whether the specified file and line matches the trace location.
+// The argument file name is the full path, not the basename specified in the flag.
+func (t traceLocation) match(file string, line int) bool {
+ if t.line != line {
+ return false
+ }
+ if i := strings.LastIndex(file, "/"); i >= 0 {
+ file = file[i+1:]
+ }
+ return t.file == file
+}
+
+func (t traceLocation) String() string {
+ return fmt.Sprintf("%s:%d", t.file, t.line)
+}
+
+// traceLocations represents the -log_backtrace_at flag.
+// Syntax: -log_backtrace_at=recordio.go:234,sstable.go:456
+// Note that unlike vmodule the file extension is included here.
+type traceLocations struct {
+ mu sync.Mutex
+ locsLen int32 // Safe for atomic read without mu.
+ locs []traceLocation
+}
+
+func (t *traceLocations) String() string {
+ t.mu.Lock()
+ defer t.mu.Unlock()
+
+ var buf bytes.Buffer
+ for i, tl := range t.locs {
+ if i > 0 {
+ buf.WriteString(",")
+ }
+ buf.WriteString(tl.String())
+ }
+ return buf.String()
+}
+
+// Get always returns nil for this flag type since the struct is not exported
+func (t *traceLocations) Get() any { return nil }
+
+func (t *traceLocations) Set(value string) error {
+ var locs []traceLocation
+ for _, s := range strings.Split(value, ",") {
+ if s == "" {
+ continue
+ }
+ loc, err := parseTraceLocation(s)
+ if err != nil {
+ return err
+ }
+ locs = append(locs, loc)
+ }
+
+ t.mu.Lock()
+ defer t.mu.Unlock()
+ atomic.StoreInt32(&t.locsLen, int32(len(locs)))
+ t.locs = locs
+ return nil
+}
+
+func (t *traceLocations) match(file string, line int) bool {
+ if atomic.LoadInt32(&t.locsLen) == 0 {
+ return false
+ }
+
+ t.mu.Lock()
+ defer t.mu.Unlock()
+ for _, tl := range t.locs {
+ if tl.match(file, line) {
+ return true
+ }
+ }
+ return false
+}
+
+// severityFlag is an atomic flag.Value implementation for logsink.Severity.
+type severityFlag int32
+
+func (s *severityFlag) get() logsink.Severity {
+ return logsink.Severity(atomic.LoadInt32((*int32)(s)))
+}
+func (s *severityFlag) String() string { return strconv.FormatInt(int64(*s), 10) }
+func (s *severityFlag) Get() any { return s.get() }
+func (s *severityFlag) Set(value string) error {
+ threshold, err := logsink.ParseSeverity(value)
+ if err != nil {
+ // Not a severity name. Try a raw number.
+ v, err := strconv.Atoi(value)
+ if err != nil {
+ return err
+ }
+ threshold = logsink.Severity(v)
+ if threshold < logsink.Info || threshold > logsink.Fatal {
+ return fmt.Errorf("Severity %d out of range (min %d, max %d).", v, logsink.Info, logsink.Fatal)
+ }
+ }
+ atomic.StoreInt32((*int32)(s), int32(threshold))
+ return nil
+}
+
+var (
+ vflags verboseFlags // The -v and -vmodule flags.
+
+ logBacktraceAt traceLocations // The -log_backtrace_at flag.
+
+ // Boolean flags. Not handled atomically because the flag.Value interface
+ // does not let us avoid the =true, and that shorthand is necessary for
+ // compatibility. TODO: does this matter enough to fix? Seems unlikely.
+ toStderr bool // The -logtostderr flag.
+ alsoToStderr bool // The -alsologtostderr flag.
+
+ stderrThreshold severityFlag // The -stderrthreshold flag.
+)
+
+// verboseEnabled returns whether the caller at the given depth should emit
+// verbose logs at the given level, with depth 0 identifying the caller of
+// verboseEnabled.
+func verboseEnabled(callerDepth int, level Level) bool {
+ return vflags.enabled(callerDepth+1, level)
+}
+
+// backtraceAt returns whether the logging call at the given function and line
+// should also emit a backtrace of the current call stack.
+func backtraceAt(file string, line int) bool {
+ return logBacktraceAt.match(file, line)
+}
+
+func init() {
+ vflags.moduleLevelCache.Store(&sync.Map{})
+
+ flag.Var(&vflags.v, "v", "log level for V logs")
+ flag.Var(vModuleFlag{&vflags}, "vmodule", "comma-separated list of pattern=N settings for file-filtered logging")
+
+ flag.Var(&logBacktraceAt, "log_backtrace_at", "when logging hits line file:N, emit a stack trace")
+
+ stderrThreshold = severityFlag(logsink.Error)
+
+ flag.BoolVar(&toStderr, "logtostderr", false, "log to standard error instead of files")
+ flag.BoolVar(&alsoToStderr, "alsologtostderr", false, "log to standard error as well as files")
+ flag.Var(&stderrThreshold, "stderrthreshold", "logs at or above this threshold go to stderr")
+}
diff --git a/vendor/github.com/golang/glog/internal/logsink/logsink.go b/vendor/github.com/golang/glog/internal/logsink/logsink.go
new file mode 100644
index 00000000000..53758e1c9f5
--- /dev/null
+++ b/vendor/github.com/golang/glog/internal/logsink/logsink.go
@@ -0,0 +1,387 @@
+// Copyright 2023 Google Inc. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package logsink
+
+import (
+ "bytes"
+ "fmt"
+ "strconv"
+ "strings"
+ "sync"
+ "time"
+
+ "github.com/golang/glog/internal/stackdump"
+)
+
+// MaxLogMessageLen is the limit on length of a formatted log message, including
+// the standard line prefix and trailing newline.
+//
+// Chosen to match C++ glog.
+const MaxLogMessageLen = 15000
+
+// A Severity is a severity at which a message can be logged.
+type Severity int8
+
+// These constants identify the log levels in order of increasing severity.
+// A message written to a high-severity log file is also written to each
+// lower-severity log file.
+const (
+ Info Severity = iota
+ Warning
+ Error
+
+ // Fatal contains logs written immediately before the process terminates.
+ //
+ // Sink implementations should not terminate the process themselves: the log
+ // package will perform any necessary cleanup and terminate the process as
+ // appropriate.
+ Fatal
+)
+
+func (s Severity) String() string {
+ switch s {
+ case Info:
+ return "INFO"
+ case Warning:
+ return "WARNING"
+ case Error:
+ return "ERROR"
+ case Fatal:
+ return "FATAL"
+ }
+ return fmt.Sprintf("%T(%d)", s, s)
+}
+
+// ParseSeverity returns the case-insensitive Severity value for the given string.
+func ParseSeverity(name string) (Severity, error) {
+ name = strings.ToUpper(name)
+ for s := Info; s <= Fatal; s++ {
+ if s.String() == name {
+ return s, nil
+ }
+ }
+ return -1, fmt.Errorf("logsink: invalid severity %q", name)
+}
+
+// Meta is metadata about a logging call.
+type Meta struct {
+ // Time is the time at which the log call was made.
+ Time time.Time
+
+ // File is the source file from which the log entry originates.
+ File string
+ // Line is the line offset within the source file.
+ Line int
+ // Depth is the number of stack frames between the logsink and the log call.
+ Depth int
+
+ Severity Severity
+
+ // Verbose indicates whether the call was made via "log.V". Log entries below
+ // the current verbosity threshold are not sent to the sink.
+ Verbose bool
+
+ // Thread ID. This can be populated with a thread ID from another source,
+ // such as a system we are importing logs from. In the normal case, this
+ // will be set to the process ID (PID), since Go doesn't have threads.
+ Thread int64
+
+ // Stack trace starting in the logging function. May be nil.
+ // A logsink should implement the StackWanter interface to request this.
+ //
+ // Even if WantStack returns false, this field may be set (e.g. if another
+ // sink wants a stack trace).
+ Stack *stackdump.Stack
+}
+
+// Structured is a logging destination that accepts structured data as input.
+type Structured interface {
+ // Printf formats according to a fmt.Printf format specifier and writes a log
+ // entry. The precise result of formatting depends on the sink, but should
+ // aim for consistency with fmt.Printf.
+ //
+ // Printf returns the number of bytes occupied by the log entry, which
+ // may not be equal to the total number of bytes written.
+ //
+ // Printf returns any error encountered *if* it is severe enough that the log
+ // package should terminate the process.
+ //
+ // The sink must not modify the *Meta parameter, nor reference it after
+ // Printf has returned: it may be reused in subsequent calls.
+ Printf(meta *Meta, format string, a ...any) (n int, err error)
+}
+
+// StackWanter can be implemented by a logsink.Structured to indicate that it
+// wants a stack trace to accompany at least some of the log messages it receives.
+type StackWanter interface {
+ // WantStack returns true if the sink requires a stack trace for a log message
+ // with this metadata.
+ //
+ // NOTE: Returning true implies that meta.Stack will be non-nil. Returning
+ // false does NOT imply that meta.Stack will be nil.
+ WantStack(meta *Meta) bool
+}
+
+// Text is a logging destination that accepts pre-formatted log lines (instead of
+// structured data).
+type Text interface {
+ // Enabled returns whether this sink should output messages for the given
+ // Meta. If the sink returns false for a given Meta, the Printf function will
+ // not call Emit on it for the corresponding log message.
+ Enabled(*Meta) bool
+
+ // Emit writes a pre-formatted text log entry (including any applicable
+ // header) to the log. It returns the number of bytes occupied by the entry
+ // (which may differ from the length of the passed-in slice).
+ //
+ // Emit returns any error encountered *if* it is severe enough that the log
+ // package should terminate the process.
+ //
+ // The sink must not modify the *Meta parameter, nor reference it after
+ // Printf has returned: it may be reused in subsequent calls.
+ //
+ // NOTE: When developing a text sink, keep in mind the surface in which the
+ // logs will be displayed, and whether it's important that the sink be
+ // resistent to tampering in the style of b/211428300. Standard text sinks
+ // (like `stderrSink`) do not protect against this (e.g. by escaping
+ // characters) because the cases where they would show user-influenced bytes
+ // are vanishingly small.
+ Emit(*Meta, []byte) (n int, err error)
+}
+
+// bufs is a pool of *bytes.Buffer used in formatting log entries.
+var bufs sync.Pool // Pool of *bytes.Buffer.
+
+// textPrintf formats a text log entry and emits it to all specified Text sinks.
+//
+// The returned n is the maximum across all Emit calls.
+// The returned err is the first non-nil error encountered.
+// Sinks that are disabled by configuration should return (0, nil).
+func textPrintf(m *Meta, textSinks []Text, format string, args ...any) (n int, err error) {
+ // We expect at most file, stderr, and perhaps syslog. If there are more,
+ // we'll end up allocating - no big deal.
+ const maxExpectedTextSinks = 3
+ var noAllocSinks [maxExpectedTextSinks]Text
+
+ sinks := noAllocSinks[:0]
+ for _, s := range textSinks {
+ if s.Enabled(m) {
+ sinks = append(sinks, s)
+ }
+ }
+ if len(sinks) == 0 && m.Severity != Fatal {
+ return 0, nil // No TextSinks specified; don't bother formatting.
+ }
+
+ bufi := bufs.Get()
+ var buf *bytes.Buffer
+ if bufi == nil {
+ buf = bytes.NewBuffer(nil)
+ bufi = buf
+ } else {
+ buf = bufi.(*bytes.Buffer)
+ buf.Reset()
+ }
+
+ // Lmmdd hh:mm:ss.uuuuuu PID/GID file:line]
+ //
+ // The "PID" entry arguably ought to be TID for consistency with other
+ // environments, but TID is not meaningful in a Go program due to the
+ // multiplexing of goroutines across threads.
+ //
+ // Avoid Fprintf, for speed. The format is so simple that we can do it quickly by hand.
+ // It's worth about 3X. Fprintf is hard.
+ const severityChar = "IWEF"
+ buf.WriteByte(severityChar[m.Severity])
+
+ _, month, day := m.Time.Date()
+ hour, minute, second := m.Time.Clock()
+ twoDigits(buf, int(month))
+ twoDigits(buf, day)
+ buf.WriteByte(' ')
+ twoDigits(buf, hour)
+ buf.WriteByte(':')
+ twoDigits(buf, minute)
+ buf.WriteByte(':')
+ twoDigits(buf, second)
+ buf.WriteByte('.')
+ nDigits(buf, 6, uint64(m.Time.Nanosecond()/1000), '0')
+ buf.WriteByte(' ')
+
+ nDigits(buf, 7, uint64(m.Thread), ' ')
+ buf.WriteByte(' ')
+
+ {
+ file := m.File
+ if i := strings.LastIndex(file, "/"); i >= 0 {
+ file = file[i+1:]
+ }
+ buf.WriteString(file)
+ }
+
+ buf.WriteByte(':')
+ {
+ var tmp [19]byte
+ buf.Write(strconv.AppendInt(tmp[:0], int64(m.Line), 10))
+ }
+ buf.WriteString("] ")
+
+ msgStart := buf.Len()
+ fmt.Fprintf(buf, format, args...)
+ if buf.Len() > MaxLogMessageLen-1 {
+ buf.Truncate(MaxLogMessageLen - 1)
+ }
+ msgEnd := buf.Len()
+ if b := buf.Bytes(); b[len(b)-1] != '\n' {
+ buf.WriteByte('\n')
+ }
+
+ for _, s := range sinks {
+ sn, sErr := s.Emit(m, buf.Bytes())
+ if sn > n {
+ n = sn
+ }
+ if sErr != nil && err == nil {
+ err = sErr
+ }
+ }
+
+ if m.Severity == Fatal {
+ savedM := *m
+ fatalMessageStore(savedEntry{
+ meta: &savedM,
+ msg: buf.Bytes()[msgStart:msgEnd],
+ })
+ } else {
+ bufs.Put(bufi)
+ }
+ return n, err
+}
+
+const digits = "0123456789"
+
+// twoDigits formats a zero-prefixed two-digit integer to buf.
+func twoDigits(buf *bytes.Buffer, d int) {
+ buf.WriteByte(digits[(d/10)%10])
+ buf.WriteByte(digits[d%10])
+}
+
+// nDigits formats an n-digit integer to buf, padding with pad on the left. It
+// assumes d != 0.
+func nDigits(buf *bytes.Buffer, n int, d uint64, pad byte) {
+ var tmp [20]byte
+
+ cutoff := len(tmp) - n
+ j := len(tmp) - 1
+ for ; d > 0; j-- {
+ tmp[j] = digits[d%10]
+ d /= 10
+ }
+ for ; j >= cutoff; j-- {
+ tmp[j] = pad
+ }
+ j++
+ buf.Write(tmp[j:])
+}
+
+// Printf writes a log entry to all registered TextSinks in this package, then
+// to all registered StructuredSinks.
+//
+// The returned n is the maximum across all Emit and Printf calls.
+// The returned err is the first non-nil error encountered.
+// Sinks that are disabled by configuration should return (0, nil).
+func Printf(m *Meta, format string, args ...any) (n int, err error) {
+ m.Depth++
+ n, err = textPrintf(m, TextSinks, format, args...)
+
+ for _, sink := range StructuredSinks {
+ // TODO: Support TextSinks that implement StackWanter?
+ if sw, ok := sink.(StackWanter); ok && sw.WantStack(m) {
+ if m.Stack == nil {
+ // First, try to find a stacktrace in args, otherwise generate one.
+ for _, arg := range args {
+ if stack, ok := arg.(stackdump.Stack); ok {
+ m.Stack = &stack
+ break
+ }
+ }
+ if m.Stack == nil {
+ stack := stackdump.Caller( /* skipDepth = */ m.Depth)
+ m.Stack = &stack
+ }
+ }
+ }
+ sn, sErr := sink.Printf(m, format, args...)
+ if sn > n {
+ n = sn
+ }
+ if sErr != nil && err == nil {
+ err = sErr
+ }
+ }
+ return n, err
+}
+
+// The sets of sinks to which logs should be written.
+//
+// These must only be modified during package init, and are read-only thereafter.
+var (
+ // StructuredSinks is the set of Structured sink instances to which logs
+ // should be written.
+ StructuredSinks []Structured
+
+ // TextSinks is the set of Text sink instances to which logs should be
+ // written.
+ //
+ // These are registered separately from Structured sink implementations to
+ // avoid the need to repeat the work of formatting a message for each Text
+ // sink that writes it. The package-level Printf function writes to both sets
+ // independenty, so a given log destination should only register a Structured
+ // *or* a Text sink (not both).
+ TextSinks []Text
+)
+
+type savedEntry struct {
+ meta *Meta
+ msg []byte
+}
+
+// StructuredTextWrapper is a Structured sink which forwards logs to a set of Text sinks.
+//
+// The purpose of this sink is to allow applications to intercept logging calls before they are
+// serialized and sent to Text sinks. For example, if one needs to redact PII from logging
+// arguments before they reach STDERR, one solution would be to do the redacting in a Structured
+// sink that forwards logs to a StructuredTextWrapper instance, and make STDERR a child of that
+// StructuredTextWrapper instance. This is how one could set this up in their application:
+//
+// func init() {
+//
+// wrapper := logsink.StructuredTextWrapper{TextSinks: logsink.TextSinks}
+// // sanitizersink will intercept logs and remove PII
+// sanitizer := sanitizersink{Sink: &wrapper}
+// logsink.StructuredSinks = append(logsink.StructuredSinks, &sanitizer)
+// logsink.TextSinks = nil
+//
+// }
+type StructuredTextWrapper struct {
+ // TextSinks is the set of Text sinks that should receive logs from this
+ // StructuredTextWrapper instance.
+ TextSinks []Text
+}
+
+// Printf forwards logs to all Text sinks registered in the StructuredTextWrapper.
+func (w *StructuredTextWrapper) Printf(meta *Meta, format string, args ...any) (n int, err error) {
+ return textPrintf(meta, w.TextSinks, format, args...)
+}
diff --git a/vendor/github.com/golang/glog/internal/logsink/logsink_fatal.go b/vendor/github.com/golang/glog/internal/logsink/logsink_fatal.go
new file mode 100644
index 00000000000..3dc269abc21
--- /dev/null
+++ b/vendor/github.com/golang/glog/internal/logsink/logsink_fatal.go
@@ -0,0 +1,35 @@
+package logsink
+
+import (
+ "sync/atomic"
+ "unsafe"
+)
+
+func fatalMessageStore(e savedEntry) {
+ // Only put a new one in if we haven't assigned before.
+ atomic.CompareAndSwapPointer(&fatalMessage, nil, unsafe.Pointer(&e))
+}
+
+var fatalMessage unsafe.Pointer // savedEntry stored with CompareAndSwapPointer
+
+// FatalMessage returns the Meta and message contents of the first message
+// logged with Fatal severity, or false if none has occurred.
+func FatalMessage() (*Meta, []byte, bool) {
+ e := (*savedEntry)(atomic.LoadPointer(&fatalMessage))
+ if e == nil {
+ return nil, nil, false
+ }
+ return e.meta, e.msg, true
+}
+
+// DoNotUseRacyFatalMessage is FatalMessage, but worse.
+//
+//go:norace
+//go:nosplit
+func DoNotUseRacyFatalMessage() (*Meta, []byte, bool) {
+ e := (*savedEntry)(fatalMessage)
+ if e == nil {
+ return nil, nil, false
+ }
+ return e.meta, e.msg, true
+}
diff --git a/vendor/github.com/golang/glog/internal/stackdump/stackdump.go b/vendor/github.com/golang/glog/internal/stackdump/stackdump.go
new file mode 100644
index 00000000000..3427c9d6bd0
--- /dev/null
+++ b/vendor/github.com/golang/glog/internal/stackdump/stackdump.go
@@ -0,0 +1,127 @@
+// Copyright 2023 Google Inc. All Rights Reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// Package stackdump provides wrappers for runtime.Stack and runtime.Callers
+// with uniform support for skipping caller frames.
+//
+// ⚠ Unlike the functions in the runtime package, these may allocate a
+// non-trivial quantity of memory: use them with care. ⚠
+package stackdump
+
+import (
+ "bytes"
+ "runtime"
+)
+
+// runtimeStackSelfFrames is 1 if runtime.Stack includes the call to
+// runtime.Stack itself or 0 if it does not.
+//
+// As of 2016-04-27, the gccgo compiler includes runtime.Stack but the gc
+// compiler does not.
+var runtimeStackSelfFrames = func() int {
+ for n := 1 << 10; n < 1<<20; n *= 2 {
+ buf := make([]byte, n)
+ n := runtime.Stack(buf, false)
+ if bytes.Contains(buf[:n], []byte("runtime.Stack")) {
+ return 1
+ } else if n < len(buf) || bytes.Count(buf, []byte("\n")) >= 3 {
+ return 0
+ }
+ }
+ return 0
+}()
+
+// Stack is a stack dump for a single goroutine.
+type Stack struct {
+ // Text is a representation of the stack dump in a human-readable format.
+ Text []byte
+
+ // PC is a representation of the stack dump using raw program counter values.
+ PC []uintptr
+}
+
+func (s Stack) String() string { return string(s.Text) }
+
+// Caller returns the Stack dump for the calling goroutine, starting skipDepth
+// frames before the caller of Caller. (Caller(0) provides a dump starting at
+// the caller of this function.)
+func Caller(skipDepth int) Stack {
+ return Stack{
+ Text: CallerText(skipDepth + 1),
+ PC: CallerPC(skipDepth + 1),
+ }
+}
+
+// CallerText returns a textual dump of the stack starting skipDepth frames before
+// the caller. (CallerText(0) provides a dump starting at the caller of this
+// function.)
+func CallerText(skipDepth int) []byte {
+ for n := 1 << 10; ; n *= 2 {
+ buf := make([]byte, n)
+ n := runtime.Stack(buf, false)
+ if n < len(buf) {
+ return pruneFrames(skipDepth+1+runtimeStackSelfFrames, buf[:n])
+ }
+ }
+}
+
+// CallerPC returns a dump of the program counters of the stack starting
+// skipDepth frames before the caller. (CallerPC(0) provides a dump starting at
+// the caller of this function.)
+func CallerPC(skipDepth int) []uintptr {
+ for n := 1 << 8; ; n *= 2 {
+ buf := make([]uintptr, n)
+ n := runtime.Callers(skipDepth+2, buf)
+ if n < len(buf) {
+ return buf[:n]
+ }
+ }
+}
+
+// pruneFrames removes the topmost skipDepth frames of the first goroutine in a
+// textual stack dump. It overwrites the passed-in slice.
+//
+// If there are fewer than skipDepth frames in the first goroutine's stack,
+// pruneFrames prunes it to an empty stack and leaves the remaining contents
+// intact.
+func pruneFrames(skipDepth int, stack []byte) []byte {
+ headerLen := 0
+ for i, c := range stack {
+ if c == '\n' {
+ headerLen = i + 1
+ break
+ }
+ }
+ if headerLen == 0 {
+ return stack // No header line - not a well-formed stack trace.
+ }
+
+ skipLen := headerLen
+ skipNewlines := skipDepth * 2
+ for ; skipLen < len(stack) && skipNewlines > 0; skipLen++ {
+ c := stack[skipLen]
+ if c != '\n' {
+ continue
+ }
+ skipNewlines--
+ skipLen++
+ if skipNewlines == 0 || skipLen == len(stack) || stack[skipLen] == '\n' {
+ break
+ }
+ }
+
+ pruned := stack[skipLen-headerLen:]
+ copy(pruned, stack[:headerLen])
+ return pruned
+}
diff --git a/vendor/github.com/google/pprof/profile/encode.go b/vendor/github.com/google/pprof/profile/encode.go
index c8a1beb8a8c..182c926b908 100644
--- a/vendor/github.com/google/pprof/profile/encode.go
+++ b/vendor/github.com/google/pprof/profile/encode.go
@@ -258,10 +258,10 @@ func (p *Profile) postDecode() error {
// If this a main linux kernel mapping with a relocation symbol suffix
// ("[kernel.kallsyms]_text"), extract said suffix.
// It is fairly hacky to handle at this level, but the alternatives appear even worse.
- if strings.HasPrefix(m.File, "[kernel.kallsyms]") {
- m.KernelRelocationSymbol = strings.ReplaceAll(m.File, "[kernel.kallsyms]", "")
+ const prefix = "[kernel.kallsyms]"
+ if strings.HasPrefix(m.File, prefix) {
+ m.KernelRelocationSymbol = m.File[len(prefix):]
}
-
}
functions := make(map[uint64]*Function, len(p.Function))
diff --git a/vendor/github.com/gophercloud/gophercloud/CHANGELOG.md b/vendor/github.com/gophercloud/gophercloud/CHANGELOG.md
index 9e2567b98b6..e737082d697 100644
--- a/vendor/github.com/gophercloud/gophercloud/CHANGELOG.md
+++ b/vendor/github.com/gophercloud/gophercloud/CHANGELOG.md
@@ -1,3 +1,28 @@
+## v1.4.0 (2023-05-25)
+
+New features and improvements:
+
+* [GH-2465](https://github.com/gophercloud/gophercloud/pull/2465) keystone: add v3 limits update operation
+* [GH-2596](https://github.com/gophercloud/gophercloud/pull/2596) keystone: add v3 limits get operation
+* [GH-2618](https://github.com/gophercloud/gophercloud/pull/2618) keystone: add v3 limits delete operation
+* [GH-2616](https://github.com/gophercloud/gophercloud/pull/2616) Add CRUD support for register limit APIs
+* [GH-2610](https://github.com/gophercloud/gophercloud/pull/2610) Add PUT/HEAD/DELETE for identity/v3/OS-INHERIT
+* [GH-2597](https://github.com/gophercloud/gophercloud/pull/2597) Add validation and optimise objects.BulkDelete
+* [GH-2602](https://github.com/gophercloud/gophercloud/pull/2602) [swift v1]: introduce a TempURLKey argument for objects.CreateTempURLOpts struct
+* [GH-2623](https://github.com/gophercloud/gophercloud/pull/2623) Add the ability to remove ingress/egress policies from fwaas_v2 groups
+* [GH-2625](https://github.com/gophercloud/gophercloud/pull/2625) neutron: Support trunk_details extension
+
+CI changes:
+
+* [GH-2608](https://github.com/gophercloud/gophercloud/pull/2608) Drop train and ussuri jobs
+* [GH-2589](https://github.com/gophercloud/gophercloud/pull/2589) Bump EmilienM/devstack-action from 0.10 to 0.11
+* [GH-2604](https://github.com/gophercloud/gophercloud/pull/2604) Bump mheap/github-action-required-labels from 3 to 4
+* [GH-2620](https://github.com/gophercloud/gophercloud/pull/2620) Pin goimport dep to a version that works with go 1.14
+* [GH-2619](https://github.com/gophercloud/gophercloud/pull/2619) Fix version comparison for acceptance tests
+* [GH-2627](https://github.com/gophercloud/gophercloud/pull/2627) Limits: Fix ToDo to create registered limit and use it
+* [GH-2629](https://github.com/gophercloud/gophercloud/pull/2629) [manila]: Add share from snapshot restore functional test
+
+
## v1.3.0 (2023-03-28)
* [GH-2464](https://github.com/gophercloud/gophercloud/pull/2464) keystone: add v3 limits create operation
diff --git a/vendor/github.com/gophercloud/gophercloud/provider_client.go b/vendor/github.com/gophercloud/gophercloud/provider_client.go
index c603d6dbe32..12273d80491 100644
--- a/vendor/github.com/gophercloud/gophercloud/provider_client.go
+++ b/vendor/github.com/gophercloud/gophercloud/provider_client.go
@@ -14,7 +14,7 @@ import (
// DefaultUserAgent is the default User-Agent string set in the request header.
const (
- DefaultUserAgent = "gophercloud/v1.3.0"
+ DefaultUserAgent = "gophercloud/v1.4.0"
DefaultMaxBackoffRetries = 60
)
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/internal/httprule/parse.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/internal/httprule/parse.go
index 65ffcf5cf87..52a8561f0f9 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/internal/httprule/parse.go
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/internal/httprule/parse.go
@@ -167,7 +167,7 @@ func (p *parser) segment() (segment, error) {
if err != nil {
return nil, fmt.Errorf("segment neither wildcards, literal or variable: %w", err)
}
- return v, nil
+ return v, err
}
func (p *parser) literal() (segment, error) {
@@ -192,7 +192,7 @@ func (p *parser) variable() (segment, error) {
if _, err := p.accept("="); err == nil {
segs, err = p.segments()
if err != nil {
- return nil, fmt.Errorf("invalid segment in variable %q: %w", path, err)
+ return nil, fmt.Errorf("invalid segment in variable %q: %v", path, err)
}
} else {
segs = []segment{wildcard{}}
@@ -219,7 +219,7 @@ func (p *parser) fieldPath() (string, error) {
}
c, err := p.accept(typeIdent)
if err != nil {
- return "", fmt.Errorf("invalid field path component: %w", err)
+ return "", fmt.Errorf("invalid field path component: %v", err)
}
components = append(components, c)
}
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/context.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/context.go
index 31553e7848a..5ab5b3841da 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/context.go
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/context.go
@@ -13,7 +13,6 @@ import (
"time"
"google.golang.org/grpc/codes"
- "google.golang.org/grpc/grpclog"
"google.golang.org/grpc/metadata"
"google.golang.org/grpc/status"
)
@@ -100,38 +99,6 @@ func AnnotateIncomingContext(ctx context.Context, mux *ServeMux, req *http.Reque
return metadata.NewIncomingContext(ctx, md), nil
}
-func isValidGRPCMetadataKey(key string) bool {
- // Must be a valid gRPC "Header-Name" as defined here:
- // https://github.com/grpc/grpc/blob/4b05dc88b724214d0c725c8e7442cbc7a61b1374/doc/PROTOCOL-HTTP2.md
- // This means 0-9 a-z _ - .
- // Only lowercase letters are valid in the wire protocol, but the client library will normalize
- // uppercase ASCII to lowercase, so uppercase ASCII is also acceptable.
- bytes := []byte(key) // gRPC validates strings on the byte level, not Unicode.
- for _, ch := range bytes {
- validLowercaseLetter := ch >= 'a' && ch <= 'z'
- validUppercaseLetter := ch >= 'A' && ch <= 'Z'
- validDigit := ch >= '0' && ch <= '9'
- validOther := ch == '.' || ch == '-' || ch == '_'
- if !validLowercaseLetter && !validUppercaseLetter && !validDigit && !validOther {
- return false
- }
- }
- return true
-}
-
-func isValidGRPCMetadataTextValue(textValue string) bool {
- // Must be a valid gRPC "ASCII-Value" as defined here:
- // https://github.com/grpc/grpc/blob/4b05dc88b724214d0c725c8e7442cbc7a61b1374/doc/PROTOCOL-HTTP2.md
- // This means printable ASCII (including/plus spaces); 0x20 to 0x7E inclusive.
- bytes := []byte(textValue) // gRPC validates strings on the byte level, not Unicode.
- for _, ch := range bytes {
- if ch < 0x20 || ch > 0x7E {
- return false
- }
- }
- return true
-}
-
func annotateContext(ctx context.Context, mux *ServeMux, req *http.Request, rpcMethodName string, options ...AnnotateContextOption) (context.Context, metadata.MD, error) {
ctx = withRPCMethod(ctx, rpcMethodName)
for _, o := range options {
@@ -154,10 +121,6 @@ func annotateContext(ctx context.Context, mux *ServeMux, req *http.Request, rpcM
pairs = append(pairs, "authorization", val)
}
if h, ok := mux.incomingHeaderMatcher(key); ok {
- if !isValidGRPCMetadataKey(h) {
- grpclog.Errorf("HTTP header name %q is not valid as gRPC metadata key; skipping", h)
- continue
- }
// Handles "-bin" metadata in grpc, since grpc will do another base64
// encode before sending to server, we need to decode it first.
if strings.HasSuffix(key, metadataHeaderBinarySuffix) {
@@ -167,9 +130,6 @@ func annotateContext(ctx context.Context, mux *ServeMux, req *http.Request, rpcM
}
val = string(b)
- } else if !isValidGRPCMetadataTextValue(val) {
- grpclog.Errorf("Value of HTTP header %q contains non-ASCII value (not valid as gRPC metadata): skipping", h)
- continue
}
pairs = append(pairs, h, val)
}
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/marshal_jsonpb.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/marshal_jsonpb.go
index 51b8247da2a..524ea057ccb 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/marshal_jsonpb.go
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/marshal_jsonpb.go
@@ -92,20 +92,23 @@ func (j *JSONPb) marshalNonProtoField(v interface{}) ([]byte, error) {
if rv.Type().Elem().Implements(protoMessageType) {
var buf bytes.Buffer
- if err := buf.WriteByte('['); err != nil {
+ err := buf.WriteByte('[')
+ if err != nil {
return nil, err
}
for i := 0; i < rv.Len(); i++ {
if i != 0 {
- if err := buf.WriteByte(','); err != nil {
+ err = buf.WriteByte(',')
+ if err != nil {
return nil, err
}
}
- if err := j.marshalTo(&buf, rv.Index(i).Interface().(proto.Message)); err != nil {
+ if err = j.marshalTo(&buf, rv.Index(i).Interface().(proto.Message)); err != nil {
return nil, err
}
}
- if err := buf.WriteByte(']'); err != nil {
+ err = buf.WriteByte(']')
+ if err != nil {
return nil, err
}
@@ -114,16 +117,17 @@ func (j *JSONPb) marshalNonProtoField(v interface{}) ([]byte, error) {
if rv.Type().Elem().Implements(typeProtoEnum) {
var buf bytes.Buffer
- if err := buf.WriteByte('['); err != nil {
+ err := buf.WriteByte('[')
+ if err != nil {
return nil, err
}
for i := 0; i < rv.Len(); i++ {
if i != 0 {
- if err := buf.WriteByte(','); err != nil {
+ err = buf.WriteByte(',')
+ if err != nil {
return nil, err
}
}
- var err error
if j.UseEnumNumbers {
_, err = buf.WriteString(strconv.FormatInt(rv.Index(i).Int(), 10))
} else {
@@ -133,7 +137,8 @@ func (j *JSONPb) marshalNonProtoField(v interface{}) ([]byte, error) {
return nil, err
}
}
- if err := buf.WriteByte(']'); err != nil {
+ err = buf.WriteByte(']')
+ if err != nil {
return nil, err
}
@@ -214,7 +219,8 @@ func decodeJSONPb(d *json.Decoder, unmarshaler protojson.UnmarshalOptions, v int
// Decode into bytes for marshalling
var b json.RawMessage
- if err := d.Decode(&b); err != nil {
+ err := d.Decode(&b)
+ if err != nil {
return err
}
@@ -233,7 +239,8 @@ func decodeNonProtoField(d *json.Decoder, unmarshaler protojson.UnmarshalOptions
if rv.Type().ConvertibleTo(typeProtoMessage) {
// Decode into bytes for marshalling
var b json.RawMessage
- if err := d.Decode(&b); err != nil {
+ err := d.Decode(&b)
+ if err != nil {
return err
}
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/mux.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/mux.go
index 139bbbad49c..9fb2960d959 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/mux.go
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/mux.go
@@ -80,7 +80,7 @@ func WithForwardResponseOption(forwardResponseOption func(context.Context, http.
}
}
-// WithUnescapingMode sets the escaping type. See the definitions of UnescapingMode
+// WithEscapingType sets the escaping type. See the definitions of UnescapingMode
// for more information.
func WithUnescapingMode(mode UnescapingMode) ServeMuxOption {
return func(serveMux *ServeMux) {
@@ -101,9 +101,8 @@ func SetQueryParameterParser(queryParameterParser QueryParameterParser) ServeMux
type HeaderMatcherFunc func(string) (string, bool)
// DefaultHeaderMatcher is used to pass http request headers to/from gRPC context. This adds permanent HTTP header
-// keys (as specified by the IANA, e.g: Accept, Cookie, Host) to the gRPC metadata with the grpcgateway- prefix. If you want to know which headers are considered permanent, you can view the isPermanentHTTPHeader function.
-// HTTP headers that start with 'Grpc-Metadata-' are mapped to gRPC metadata after removing the prefix 'Grpc-Metadata-'.
-// Other headers are not added to the gRPC metadata.
+// keys (as specified by the IANA) to gRPC context with grpcgateway- prefix. HTTP headers that start with
+// 'Grpc-Metadata-' are mapped to gRPC metadata after removing prefix 'Grpc-Metadata-'.
func DefaultHeaderMatcher(key string) (string, bool) {
switch key = textproto.CanonicalMIMEHeaderKey(key); {
case isPermanentHTTPHeader(key):
@@ -231,6 +230,7 @@ func WithHealthEndpointAt(healthCheckClient grpc_health_v1.HealthClient, endpoin
w.Header().Set("Content-Type", "application/json")
if resp.GetStatus() != grpc_health_v1.HealthCheckResponse_SERVING {
+ var err error
switch resp.GetStatus() {
case grpc_health_v1.HealthCheckResponse_NOT_SERVING, grpc_health_v1.HealthCheckResponse_UNKNOWN:
err = status.Error(codes.Unavailable, resp.String())
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/pattern.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/pattern.go
index 8f90d15a562..df7cb81426a 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/pattern.go
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/pattern.go
@@ -15,6 +15,8 @@ var (
ErrNotMatch = errors.New("not match to the path pattern")
// ErrInvalidPattern indicates that the given definition of Pattern is not valid.
ErrInvalidPattern = errors.New("invalid pattern")
+ // ErrMalformedSequence indicates that an escape sequence was malformed.
+ ErrMalformedSequence = errors.New("malformed escape sequence")
)
type MalformedSequenceError string
diff --git a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/query.go b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/query.go
index 31ce33a7621..56b796e6f4d 100644
--- a/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/query.go
+++ b/vendor/github.com/grpc-ecosystem/grpc-gateway/v2/runtime/query.go
@@ -47,7 +47,8 @@ type DefaultQueryParser struct{}
// A value is ignored if its key starts with one of the elements in "filter".
func (*DefaultQueryParser) Parse(msg proto.Message, values url.Values, filter *utilities.DoubleArray) error {
for key, values := range values {
- if match := valuesKeyRegexp.FindStringSubmatch(key); len(match) == 3 {
+ match := valuesKeyRegexp.FindStringSubmatch(key)
+ if len(match) == 3 {
key = match[1]
values = append([]string{match[2]}, values...)
}
@@ -320,13 +321,15 @@ func parseMessage(msgDescriptor protoreflect.MessageDescriptor, value string) (p
msg = fm
case "google.protobuf.Value":
var v structpb.Value
- if err := protojson.Unmarshal([]byte(value), &v); err != nil {
+ err := protojson.Unmarshal([]byte(value), &v)
+ if err != nil {
return protoreflect.Value{}, err
}
msg = &v
case "google.protobuf.Struct":
var v structpb.Struct
- if err := protojson.Unmarshal([]byte(value), &v); err != nil {
+ err := protojson.Unmarshal([]byte(value), &v)
+ if err != nil {
return protoreflect.Value{}, err
}
msg = &v
diff --git a/vendor/github.com/hashicorp/consul/api/config_entry.go b/vendor/github.com/hashicorp/consul/api/config_entry.go
index 4e9682ee6f8..7160d7d228b 100644
--- a/vendor/github.com/hashicorp/consul/api/config_entry.go
+++ b/vendor/github.com/hashicorp/consul/api/config_entry.go
@@ -35,6 +35,10 @@ const (
const (
BuiltinAWSLambdaExtension string = "builtin/aws/lambda"
BuiltinLuaExtension string = "builtin/lua"
+ // BuiltinValidateExtension should not be exposed directly or accepted as a valid configured
+ // extension type, as it is only used indirectly via troubleshooting tools. It is included here
+ // for common reference alongside other builtin extensions.
+ BuiltinValidateExtension string = "builtin/proxy/validate"
)
type ConfigEntry interface {
@@ -254,6 +258,15 @@ type PassiveHealthCheck struct {
// when an outlier status is detected through consecutive 5xx.
// This setting can be used to disable ejection or to ramp it up slowly.
EnforcingConsecutive5xx *uint32 `json:",omitempty" alias:"enforcing_consecutive_5xx"`
+
+ // The maximum % of an upstream cluster that can be ejected due to outlier detection.
+ // Defaults to 10% but will eject at least one host regardless of the value.
+ MaxEjectionPercent *uint32 `json:",omitempty" alias:"max_ejection_percent"`
+
+ // The base time that a host is ejected for. The real time is equal to the base time
+ // multiplied by the number of times the host has been ejected and is capped by
+ // max_ejection_time (Default 300s). Defaults to 30000ms or 30s.
+ BaseEjectionTime *time.Duration `json:",omitempty" alias:"base_ejection_time"`
}
// UpstreamLimits describes the limits that are associated with a specific
diff --git a/vendor/github.com/hashicorp/consul/api/connect.go b/vendor/github.com/hashicorp/consul/api/connect.go
index a40d1e2321a..1c1da9a3798 100644
--- a/vendor/github.com/hashicorp/consul/api/connect.go
+++ b/vendor/github.com/hashicorp/consul/api/connect.go
@@ -1,5 +1,8 @@
package api
+// TelemetryCollectorName is the service name for the Consul Telemetry Collector
+const TelemetryCollectorName string = "consul-telemetry-collector"
+
// Connect can be used to work with endpoints related to Connect, the
// feature for securely connecting services within Consul.
type Connect struct {
diff --git a/vendor/github.com/hashicorp/nomad/api/allocations.go b/vendor/github.com/hashicorp/nomad/api/allocations.go
index 0159a9e12e7..87f7d9b1160 100644
--- a/vendor/github.com/hashicorp/nomad/api/allocations.go
+++ b/vendor/github.com/hashicorp/nomad/api/allocations.go
@@ -326,6 +326,7 @@ func (a *Allocation) Stub() *AllocationListStub {
TaskStates: a.TaskStates,
DeploymentStatus: a.DeploymentStatus,
FollowupEvalID: a.FollowupEvalID,
+ NextAllocation: a.NextAllocation,
RescheduleTracker: a.RescheduleTracker,
PreemptedAllocations: a.PreemptedAllocations,
PreemptedByAllocation: a.PreemptedByAllocation,
@@ -379,6 +380,7 @@ type AllocationListStub struct {
TaskStates map[string]*TaskState
DeploymentStatus *AllocDeploymentStatus
FollowupEvalID string
+ NextAllocation string
RescheduleTracker *RescheduleTracker
PreemptedAllocations []string
PreemptedByAllocation string
diff --git a/vendor/github.com/hashicorp/nomad/api/api.go b/vendor/github.com/hashicorp/nomad/api/api.go
index 1bf97f05f95..ac755e254f7 100644
--- a/vendor/github.com/hashicorp/nomad/api/api.go
+++ b/vendor/github.com/hashicorp/nomad/api/api.go
@@ -895,13 +895,16 @@ func (c *Client) websocket(endpoint string, q *QueryOptions) (*websocket.Conn, *
conn, resp, err := dialer.Dial(rhttp.URL.String(), rhttp.Header)
// check resp status code, as it's more informative than handshake error we get from ws library
- if resp != nil && resp.StatusCode != 101 {
+ if resp != nil && resp.StatusCode != http.StatusSwitchingProtocols {
var buf bytes.Buffer
if resp.Header.Get("Content-Encoding") == "gzip" {
greader, err := gzip.NewReader(resp.Body)
if err != nil {
- return nil, nil, fmt.Errorf("Unexpected response code: %d", resp.StatusCode)
+ return nil, nil, newUnexpectedResponseError(
+ fromStatusCode(resp.StatusCode),
+ withExpectedStatuses([]int{http.StatusSwitchingProtocols}),
+ withError(err))
}
io.Copy(&buf, greader)
} else {
@@ -909,7 +912,11 @@ func (c *Client) websocket(endpoint string, q *QueryOptions) (*websocket.Conn, *
}
resp.Body.Close()
- return nil, nil, fmt.Errorf("Unexpected response code: %d (%s)", resp.StatusCode, buf.Bytes())
+ return nil, nil, newUnexpectedResponseError(
+ fromStatusCode(resp.StatusCode),
+ withExpectedStatuses([]int{http.StatusSwitchingProtocols}),
+ withBody(fmt.Sprint(buf.Bytes())),
+ )
}
return conn, resp, err
@@ -1129,24 +1136,6 @@ func encodeBody(obj interface{}) (io.Reader, error) {
return buf, nil
}
-// requireOK is used to wrap doRequest and check for a 200
-func requireOK(d time.Duration, resp *http.Response, e error) (time.Duration, *http.Response, error) {
- if e != nil {
- if resp != nil {
- resp.Body.Close()
- }
- return d, nil, e
- }
- if resp.StatusCode != 200 {
- var buf bytes.Buffer
- _, _ = io.Copy(&buf, resp.Body)
- _ = resp.Body.Close()
- body := strings.TrimSpace(buf.String())
- return d, nil, fmt.Errorf("Unexpected response code: %d (%s)", resp.StatusCode, body)
- }
- return d, resp, nil
-}
-
// Context returns the context used for canceling HTTP requests related to this query
func (o *QueryOptions) Context() context.Context {
if o != nil && o.ctx != nil {
diff --git a/vendor/github.com/hashicorp/nomad/api/contexts/contexts.go b/vendor/github.com/hashicorp/nomad/api/contexts/contexts.go
index 2ce523a72dc..5176f5b8290 100644
--- a/vendor/github.com/hashicorp/nomad/api/contexts/contexts.go
+++ b/vendor/github.com/hashicorp/nomad/api/contexts/contexts.go
@@ -15,6 +15,7 @@ const (
Evals Context = "evals"
Jobs Context = "jobs"
Nodes Context = "nodes"
+ NodePools Context = "node_pools"
Namespaces Context = "namespaces"
Quotas Context = "quotas"
Recommendations Context = "recommendations"
diff --git a/vendor/github.com/hashicorp/nomad/api/error_unexpected_response.go b/vendor/github.com/hashicorp/nomad/api/error_unexpected_response.go
new file mode 100644
index 00000000000..b843fc7ab9e
--- /dev/null
+++ b/vendor/github.com/hashicorp/nomad/api/error_unexpected_response.go
@@ -0,0 +1,178 @@
+// Copyright (c) HashiCorp, Inc.
+// SPDX-License-Identifier: MPL-2.0
+
+package api
+
+import (
+ "bytes"
+ "fmt"
+ "io"
+ "net/http"
+ "strings"
+ "time"
+
+ "golang.org/x/exp/slices"
+)
+
+// UnexpectedResponseError tracks the components for API errors encountered when
+// requireOK and requireStatusIn's conditions are not met.
+type UnexpectedResponseError struct {
+ expected []int
+ statusCode int
+ statusText string
+ body string
+ err error
+ additional error
+}
+
+func (e UnexpectedResponseError) HasExpectedStatuses() bool { return len(e.expected) > 0 }
+func (e UnexpectedResponseError) ExpectedStatuses() []int { return e.expected }
+func (e UnexpectedResponseError) HasStatusCode() bool { return e.statusCode != 0 }
+func (e UnexpectedResponseError) StatusCode() int { return e.statusCode }
+func (e UnexpectedResponseError) HasStatusText() bool { return e.statusText != "" }
+func (e UnexpectedResponseError) StatusText() string { return e.statusText }
+func (e UnexpectedResponseError) HasBody() bool { return e.body != "" }
+func (e UnexpectedResponseError) Body() string { return e.body }
+func (e UnexpectedResponseError) HasError() bool { return e.err != nil }
+func (e UnexpectedResponseError) Unwrap() error { return e.err }
+func (e UnexpectedResponseError) HasAdditional() bool { return e.additional != nil }
+func (e UnexpectedResponseError) Additional() error { return e.additional }
+func newUnexpectedResponseError(src unexpectedResponseErrorSource, opts ...unexpectedResponseErrorOption) UnexpectedResponseError {
+ nErr := src()
+ for _, opt := range opts {
+ opt(nErr)
+ }
+ if nErr.statusText == "" {
+ // the stdlib's http.StatusText function is a good place to start
+ nErr.statusFromCode(http.StatusText)
+ }
+
+ return *nErr
+}
+
+// Use textual representation of the given integer code. Called when status text
+// is not set using the WithStatusText option.
+func (e UnexpectedResponseError) statusFromCode(f func(int) string) {
+ e.statusText = f(e.statusCode)
+ if !e.HasStatusText() {
+ e.statusText = "unknown status code"
+ }
+}
+
+func (e UnexpectedResponseError) Error() string {
+ var eTxt strings.Builder
+ eTxt.WriteString("Unexpected response code")
+ if e.HasBody() || e.HasStatusCode() {
+ eTxt.WriteString(": ")
+ }
+ if e.HasStatusCode() {
+ eTxt.WriteString(fmt.Sprint(e.statusCode))
+ if e.HasBody() {
+ eTxt.WriteRune(' ')
+ }
+ }
+ if e.HasBody() {
+ eTxt.WriteString(fmt.Sprintf("(%s)", e.body))
+ }
+
+ if e.HasAdditional() {
+ eTxt.WriteString(fmt.Sprintf(". Additionally, an error occurred while constructing this error (%s); the body might be truncated or missing.", e.additional.Error()))
+ }
+
+ return eTxt.String()
+}
+
+// UnexpectedResponseErrorOptions are functions passed to NewUnexpectedResponseError
+// to customize the created error.
+type unexpectedResponseErrorOption func(*UnexpectedResponseError)
+
+// withError allows the addition of a Go error that may have been encountered
+// while processing the response. For example, if there is an error constructing
+// the gzip reader to process a gzip-encoded response body.
+func withError(e error) unexpectedResponseErrorOption {
+ return func(u *UnexpectedResponseError) { u.err = e }
+}
+
+// withBody overwrites the Body value with the provided custom value
+func withBody(b string) unexpectedResponseErrorOption {
+ return func(u *UnexpectedResponseError) { u.body = b }
+}
+
+// withStatusText overwrites the StatusText value the provided custom value
+func withStatusText(st string) unexpectedResponseErrorOption {
+ return func(u *UnexpectedResponseError) { u.statusText = st }
+}
+
+// withExpectedStatuses provides a list of statuses that the receiving function
+// expected to receive. This can be used by API callers to provide more feedback
+// to end-users.
+func withExpectedStatuses(s []int) unexpectedResponseErrorOption {
+ return func(u *UnexpectedResponseError) { u.expected = slices.Clone(s) }
+}
+
+// unexpectedResponseErrorSource provides the basis for a NewUnexpectedResponseError.
+type unexpectedResponseErrorSource func() *UnexpectedResponseError
+
+// fromHTTPResponse read an open HTTP response, drains and closes its body as
+// the data for the UnexpectedResponseError.
+func fromHTTPResponse(resp *http.Response) unexpectedResponseErrorSource {
+ return func() *UnexpectedResponseError {
+ u := new(UnexpectedResponseError)
+
+ if resp != nil {
+ // collect and close the body
+ var buf bytes.Buffer
+ if _, e := io.Copy(&buf, resp.Body); e != nil {
+ u.additional = e
+ }
+
+ // Body has been tested as safe to close more than once
+ _ = resp.Body.Close()
+ body := strings.TrimSpace(buf.String())
+
+ // make and return the error
+ u.statusCode = resp.StatusCode
+ u.statusText = strings.TrimSpace(strings.TrimPrefix(resp.Status, fmt.Sprint(resp.StatusCode)))
+ u.body = body
+ }
+ return u
+ }
+}
+
+// fromStatusCode attempts to resolve the status code to status text using
+// the resolving function provided inside of the NewUnexpectedResponseError
+// implementation.
+func fromStatusCode(sc int) unexpectedResponseErrorSource {
+ return func() *UnexpectedResponseError { return &UnexpectedResponseError{statusCode: sc} }
+}
+
+// doRequestWrapper is a function that wraps the client's doRequest method
+// and can be used to provide error and response handling
+type doRequestWrapper = func(time.Duration, *http.Response, error) (time.Duration, *http.Response, error)
+
+// requireOK is used to wrap doRequest and check for a 200
+func requireOK(d time.Duration, resp *http.Response, e error) (time.Duration, *http.Response, error) {
+ f := requireStatusIn(http.StatusOK)
+ return f(d, resp, e)
+}
+
+// requireStatusIn is a doRequestWrapper generator that takes expected HTTP
+// response codes and validates that the received response code is among them
+func requireStatusIn(statuses ...int) doRequestWrapper {
+ return func(d time.Duration, resp *http.Response, e error) (time.Duration, *http.Response, error) {
+ if e != nil {
+ if resp != nil {
+ _ = resp.Body.Close()
+ }
+ return d, nil, e
+ }
+
+ for _, status := range statuses {
+ if resp.StatusCode == status {
+ return d, resp, nil
+ }
+ }
+
+ return d, nil, newUnexpectedResponseError(fromHTTPResponse(resp), withExpectedStatuses(statuses))
+ }
+}
diff --git a/vendor/github.com/hashicorp/nomad/api/jobs.go b/vendor/github.com/hashicorp/nomad/api/jobs.go
index 64b25c7108f..f768b351044 100644
--- a/vendor/github.com/hashicorp/nomad/api/jobs.go
+++ b/vendor/github.com/hashicorp/nomad/api/jobs.go
@@ -29,6 +29,9 @@ const (
// on all clients.
JobTypeSysbatch = "sysbatch"
+ // JobDefaultPriority is the default priority if not specified.
+ JobDefaultPriority = 50
+
// PeriodicSpecCron is used for a cron spec.
PeriodicSpecCron = "cron"
@@ -790,9 +793,11 @@ func (m *Multiregion) Copy() *Multiregion {
copyRegion.Name = region.Name
copyRegion.Count = pointerOf(*region.Count)
copyRegion.Datacenters = append(copyRegion.Datacenters, region.Datacenters...)
+ copyRegion.NodePool = region.NodePool
for k, v := range region.Meta {
copyRegion.Meta[k] = v
}
+
copy.Regions = append(copy.Regions, copyRegion)
}
return copy
@@ -807,6 +812,7 @@ type MultiregionRegion struct {
Name string `hcl:",label"`
Count *int `hcl:"count,optional"`
Datacenters []string `hcl:"datacenters,optional"`
+ NodePool string `hcl:"node_pool,optional"`
Meta map[string]string `hcl:"meta,block"`
}
@@ -940,6 +946,7 @@ type Job struct {
Priority *int `hcl:"priority,optional"`
AllAtOnce *bool `mapstructure:"all_at_once" hcl:"all_at_once,optional"`
Datacenters []string `hcl:"datacenters,optional"`
+ NodePool *string `hcl:"node_pool,optional"`
Constraints []*Constraint `hcl:"constraint,block"`
Affinities []*Affinity `hcl:"affinity,block"`
TaskGroups []*TaskGroup `hcl:"group,block"`
@@ -1003,7 +1010,7 @@ func (j *Job) Canonicalize() {
j.Namespace = pointerOf(DefaultNamespace)
}
if j.Priority == nil {
- j.Priority = pointerOf(0)
+ j.Priority = pointerOf(JobDefaultPriority)
}
if j.Stop == nil {
j.Stop = pointerOf(false)
@@ -1011,8 +1018,8 @@ func (j *Job) Canonicalize() {
if j.Region == nil {
j.Region = pointerOf(GlobalRegion)
}
- if j.Namespace == nil {
- j.Namespace = pointerOf("default")
+ if j.NodePool == nil {
+ j.NodePool = pointerOf(NodePoolDefault)
}
if j.Type == nil {
j.Type = pointerOf("service")
diff --git a/vendor/github.com/hashicorp/nomad/api/node_pools.go b/vendor/github.com/hashicorp/nomad/api/node_pools.go
new file mode 100644
index 00000000000..37ecf155523
--- /dev/null
+++ b/vendor/github.com/hashicorp/nomad/api/node_pools.go
@@ -0,0 +1,105 @@
+// Copyright (c) HashiCorp, Inc.
+// SPDX-License-Identifier: MPL-2.0
+
+package api
+
+import (
+ "errors"
+ "net/url"
+)
+
+const (
+ // NodePoolAll is the node pool that always includes all nodes.
+ NodePoolAll = "all"
+
+ // NodePoolDefault is the default node pool.
+ NodePoolDefault = "default"
+)
+
+// NodePools is used to access node pools endpoints.
+type NodePools struct {
+ client *Client
+}
+
+// NodePools returns a handle on the node pools endpoints.
+func (c *Client) NodePools() *NodePools {
+ return &NodePools{client: c}
+}
+
+// List is used to list all node pools.
+func (n *NodePools) List(q *QueryOptions) ([]*NodePool, *QueryMeta, error) {
+ var resp []*NodePool
+ qm, err := n.client.query("/v1/node/pools", &resp, q)
+ if err != nil {
+ return nil, nil, err
+ }
+ return resp, qm, nil
+}
+
+// PrefixList is used to list node pools that match a given prefix.
+func (n *NodePools) PrefixList(prefix string, q *QueryOptions) ([]*NodePool, *QueryMeta, error) {
+ if q == nil {
+ q = &QueryOptions{}
+ }
+ q.Prefix = prefix
+ return n.List(q)
+}
+
+// Info is used to fetch details of a specific node pool.
+func (n *NodePools) Info(name string, q *QueryOptions) (*NodePool, *QueryMeta, error) {
+ if name == "" {
+ return nil, nil, errors.New("missing node pool name")
+ }
+
+ var resp NodePool
+ qm, err := n.client.query("/v1/node/pool/"+url.PathEscape(name), &resp, q)
+ if err != nil {
+ return nil, nil, err
+ }
+ return &resp, qm, nil
+}
+
+// Register is used to create or update a node pool.
+func (n *NodePools) Register(pool *NodePool, w *WriteOptions) (*WriteMeta, error) {
+ if pool == nil {
+ return nil, errors.New("missing node pool")
+ }
+ if pool.Name == "" {
+ return nil, errors.New("missing node pool name")
+ }
+
+ wm, err := n.client.put("/v1/node/pools", pool, nil, w)
+ if err != nil {
+ return nil, err
+ }
+ return wm, nil
+}
+
+// Delete is used to delete a node pool.
+func (n *NodePools) Delete(name string, w *WriteOptions) (*WriteMeta, error) {
+ if name == "" {
+ return nil, errors.New("missing node pool name")
+ }
+
+ wm, err := n.client.delete("/v1/node/pool/"+url.PathEscape(name), nil, nil, w)
+ if err != nil {
+ return nil, err
+ }
+ return wm, nil
+}
+
+// NodePool is used to serialize a node pool.
+type NodePool struct {
+ Name string `hcl:"name,label"`
+ Description string `hcl:"description,optional"`
+ Meta map[string]string `hcl:"meta,block"`
+ SchedulerConfiguration *NodePoolSchedulerConfiguration `hcl:"scheduler_configuration,block"`
+ CreateIndex uint64
+ ModifyIndex uint64
+}
+
+// NodePoolSchedulerConfiguration is used to serialize the scheduler
+// configuration of a node pool.
+type NodePoolSchedulerConfiguration struct {
+ SchedulerAlgorithm SchedulerAlgorithm `hcl:"scheduler_algorithm,optional"`
+}
diff --git a/vendor/github.com/hashicorp/nomad/api/nodes.go b/vendor/github.com/hashicorp/nomad/api/nodes.go
index dfc5646be09..697c7d731d3 100644
--- a/vendor/github.com/hashicorp/nomad/api/nodes.go
+++ b/vendor/github.com/hashicorp/nomad/api/nodes.go
@@ -553,6 +553,7 @@ type Node struct {
Links map[string]string
Meta map[string]string
NodeClass string
+ NodePool string
CgroupParent string
Drain bool
DrainStrategy *DrainStrategy
@@ -914,6 +915,7 @@ type NodeListStub struct {
Datacenter string
Name string
NodeClass string
+ NodePool string
Version string
Drain bool
SchedulingEligibility string
diff --git a/vendor/github.com/hashicorp/nomad/api/operator.go b/vendor/github.com/hashicorp/nomad/api/operator.go
index ba8d41cecd4..32faf354661 100644
--- a/vendor/github.com/hashicorp/nomad/api/operator.go
+++ b/vendor/github.com/hashicorp/nomad/api/operator.go
@@ -6,8 +6,8 @@ package api
import (
"encoding/json"
"errors"
- "fmt"
"io"
+ "net/http"
"strconv"
"strings"
"time"
@@ -341,13 +341,15 @@ func (op *Operator) LicenseGet(q *QueryOptions) (*LicenseReply, *QueryMeta, erro
}
defer resp.Body.Close()
- if resp.StatusCode == 204 {
+ if resp.StatusCode == http.StatusNoContent {
return nil, nil, errors.New("Nomad Enterprise only endpoint")
}
- if resp.StatusCode != 200 {
- body, _ := io.ReadAll(resp.Body)
- return nil, nil, fmt.Errorf("Unexpected response code: %d (%s)", resp.StatusCode, body)
+ if resp.StatusCode != http.StatusOK {
+ return nil, nil, newUnexpectedResponseError(
+ fromHTTPResponse(resp),
+ withExpectedStatuses([]int{http.StatusOK, http.StatusNoContent}),
+ )
}
err = json.NewDecoder(resp.Body).Decode(&reply)
diff --git a/vendor/github.com/hashicorp/nomad/api/services.go b/vendor/github.com/hashicorp/nomad/api/services.go
index 450236547b5..95f02781006 100644
--- a/vendor/github.com/hashicorp/nomad/api/services.go
+++ b/vendor/github.com/hashicorp/nomad/api/services.go
@@ -212,6 +212,7 @@ type ServiceCheck struct {
Interval time.Duration `hcl:"interval,optional"`
Timeout time.Duration `hcl:"timeout,optional"`
InitialStatus string `mapstructure:"initial_status" hcl:"initial_status,optional"`
+ TLSServerName string `mapstructure:"tls_server_name" hcl:"tls_server_name,optional"`
TLSSkipVerify bool `mapstructure:"tls_skip_verify" hcl:"tls_skip_verify,optional"`
Header map[string][]string `hcl:"header,block"`
Method string `hcl:"method,optional"`
diff --git a/vendor/github.com/hashicorp/nomad/api/tasks.go b/vendor/github.com/hashicorp/nomad/api/tasks.go
index e928b3a0418..65344290510 100644
--- a/vendor/github.com/hashicorp/nomad/api/tasks.go
+++ b/vendor/github.com/hashicorp/nomad/api/tasks.go
@@ -641,12 +641,19 @@ func (g *TaskGroup) AddSpread(s *Spread) *TaskGroup {
type LogConfig struct {
MaxFiles *int `mapstructure:"max_files" hcl:"max_files,optional"`
MaxFileSizeMB *int `mapstructure:"max_file_size" hcl:"max_file_size,optional"`
+
+ // COMPAT(1.6.0): Enabled had to be swapped for Disabled to fix a backwards
+ // compatibility bug when restoring pre-1.5.4 jobs. Remove in 1.6.0
+ Enabled *bool `mapstructure:"enabled" hcl:"enabled,optional"`
+
+ Disabled *bool `mapstructure:"disabled" hcl:"disabled,optional"`
}
func DefaultLogConfig() *LogConfig {
return &LogConfig{
MaxFiles: pointerOf(10),
MaxFileSizeMB: pointerOf(10),
+ Disabled: pointerOf(false),
}
}
@@ -657,6 +664,9 @@ func (l *LogConfig) Canonicalize() {
if l.MaxFileSizeMB == nil {
l.MaxFileSizeMB = pointerOf(10)
}
+ if l.Disabled == nil {
+ l.Disabled = pointerOf(false)
+ }
}
// DispatchPayloadConfig configures how a task gets its input from a job dispatch
diff --git a/vendor/github.com/hashicorp/nomad/api/variables.go b/vendor/github.com/hashicorp/nomad/api/variables.go
index 91dc13cf460..86458c13ae1 100644
--- a/vendor/github.com/hashicorp/nomad/api/variables.go
+++ b/vendor/github.com/hashicorp/nomad/api/variables.go
@@ -4,14 +4,11 @@
package api
import (
- "bytes"
"encoding/json"
"errors"
"fmt"
- "io"
"net/http"
"strings"
- "time"
)
const (
@@ -457,39 +454,3 @@ type ErrCASConflict struct {
func (e ErrCASConflict) Error() string {
return fmt.Sprintf("cas conflict: expected ModifyIndex %v; found %v", e.CheckIndex, e.Conflict.ModifyIndex)
}
-
-// doRequestWrapper is a function that wraps the client's doRequest method
-// and can be used to provide error and response handling
-type doRequestWrapper = func(time.Duration, *http.Response, error) (time.Duration, *http.Response, error)
-
-// requireStatusIn is a doRequestWrapper generator that takes expected HTTP
-// response codes and validates that the received response code is among them
-func requireStatusIn(statuses ...int) doRequestWrapper {
- fn := func(d time.Duration, resp *http.Response, e error) (time.Duration, *http.Response, error) {
- if e != nil {
- if resp != nil {
- _ = resp.Body.Close()
- }
- return d, nil, e
- }
-
- for _, status := range statuses {
- if resp.StatusCode == status {
- return d, resp, nil
- }
- }
-
- return d, nil, generateUnexpectedResponseCodeError(resp)
- }
- return fn
-}
-
-// generateUnexpectedResponseCodeError creates a standardized error
-// when the the API client's newRequest method receives an unexpected
-// HTTP response code when accessing the variable's HTTP API
-func generateUnexpectedResponseCodeError(resp *http.Response) error {
- var buf bytes.Buffer
- _, _ = io.Copy(&buf, resp.Body)
- _ = resp.Body.Close()
- return fmt.Errorf("Unexpected response code: %d (%s)", resp.StatusCode, buf.Bytes())
-}
diff --git a/vendor/github.com/hetznercloud/hcloud-go/hcloud/certificate.go b/vendor/github.com/hetznercloud/hcloud-go/hcloud/certificate.go
index 62785523170..e56e141558c 100644
--- a/vendor/github.com/hetznercloud/hcloud-go/hcloud/certificate.go
+++ b/vendor/github.com/hetznercloud/hcloud-go/hcloud/certificate.go
@@ -260,7 +260,7 @@ func (o CertificateCreateOpts) validateUploaded() error {
return nil
}
-// Create creates a new certificate uploaded certificate.
+// Create creates a new uploaded certificate.
//
// Create returns an error for certificates of any other type. Use
// CreateCertificate to create such certificates.
diff --git a/vendor/github.com/hetznercloud/hcloud-go/hcloud/hcloud.go b/vendor/github.com/hetznercloud/hcloud-go/hcloud/hcloud.go
index 7adc8745afe..55f7bf9f2ac 100644
--- a/vendor/github.com/hetznercloud/hcloud-go/hcloud/hcloud.go
+++ b/vendor/github.com/hetznercloud/hcloud-go/hcloud/hcloud.go
@@ -2,4 +2,4 @@
package hcloud
// Version is the library's version following Semantic Versioning.
-const Version = "1.42.0" // x-release-please-version
+const Version = "1.45.1" // x-release-please-version
diff --git a/vendor/github.com/hetznercloud/hcloud-go/hcloud/iso.go b/vendor/github.com/hetznercloud/hcloud-go/hcloud/iso.go
index d5814cb8023..d0a2a137f5a 100644
--- a/vendor/github.com/hetznercloud/hcloud-go/hcloud/iso.go
+++ b/vendor/github.com/hetznercloud/hcloud-go/hcloud/iso.go
@@ -134,10 +134,12 @@ func (c *ISOClient) List(ctx context.Context, opts ISOListOpts) ([]*ISO, *Respon
// All returns all ISOs.
func (c *ISOClient) All(ctx context.Context) ([]*ISO, error) {
- allISOs := []*ISO{}
+ return c.AllWithOpts(ctx, ISOListOpts{ListOpts: ListOpts{PerPage: 50}})
+}
- opts := ISOListOpts{}
- opts.PerPage = 50
+// AllWithOpts returns all ISOs for the given options.
+func (c *ISOClient) AllWithOpts(ctx context.Context, opts ISOListOpts) ([]*ISO, error) {
+ allISOs := make([]*ISO, 0)
err := c.client.all(func(page int) (*Response, error) {
opts.Page = page
diff --git a/vendor/github.com/hetznercloud/hcloud-go/hcloud/primary_ip.go b/vendor/github.com/hetznercloud/hcloud-go/hcloud/primary_ip.go
index e328b9b36ad..c478241d120 100644
--- a/vendor/github.com/hetznercloud/hcloud-go/hcloud/primary_ip.go
+++ b/vendor/github.com/hetznercloud/hcloud-go/hcloud/primary_ip.go
@@ -43,6 +43,32 @@ type PrimaryIPDNSPTR struct {
IP string
}
+// changeDNSPtr changes or resets the reverse DNS pointer for a IP address.
+// Pass a nil ptr to reset the reverse DNS pointer to its default value.
+func (p *PrimaryIP) changeDNSPtr(ctx context.Context, client *Client, ip net.IP, ptr *string) (*Action, *Response, error) {
+ reqBody := schema.PrimaryIPActionChangeDNSPtrRequest{
+ IP: ip.String(),
+ DNSPtr: ptr,
+ }
+ reqBodyData, err := json.Marshal(reqBody)
+ if err != nil {
+ return nil, nil, err
+ }
+
+ path := fmt.Sprintf("/primary_ips/%d/actions/change_dns_ptr", p.ID)
+ req, err := client.NewRequest(ctx, "POST", path, bytes.NewReader(reqBodyData))
+ if err != nil {
+ return nil, nil, err
+ }
+
+ var respBody PrimaryIPChangeDNSPtrResult
+ resp, err := client.Do(req, &respBody)
+ if err != nil {
+ return nil, resp, err
+ }
+ return ActionFromSchema(respBody.Action), resp, nil
+}
+
// GetDNSPtrForIP searches for the dns assigned to the given IP address.
// It returns an error if there is no dns set for the given IP address.
func (p *PrimaryIP) GetDNSPtrForIP(ip net.IP) (string, error) {
diff --git a/vendor/github.com/hetznercloud/hcloud-go/hcloud/schema.go b/vendor/github.com/hetznercloud/hcloud-go/hcloud/schema.go
index b72db88d2f0..fb2079faf26 100644
--- a/vendor/github.com/hetznercloud/hcloud-go/hcloud/schema.go
+++ b/vendor/github.com/hetznercloud/hcloud-go/hcloud/schema.go
@@ -278,15 +278,16 @@ func ServerPrivateNetFromSchema(s schema.ServerPrivateNet) ServerPrivateNet {
// ServerTypeFromSchema converts a schema.ServerType to a ServerType.
func ServerTypeFromSchema(s schema.ServerType) *ServerType {
st := &ServerType{
- ID: s.ID,
- Name: s.Name,
- Description: s.Description,
- Cores: s.Cores,
- Memory: s.Memory,
- Disk: s.Disk,
- StorageType: StorageType(s.StorageType),
- CPUType: CPUType(s.CPUType),
- Architecture: Architecture(s.Architecture),
+ ID: s.ID,
+ Name: s.Name,
+ Description: s.Description,
+ Cores: s.Cores,
+ Memory: s.Memory,
+ Disk: s.Disk,
+ StorageType: StorageType(s.StorageType),
+ CPUType: CPUType(s.CPUType),
+ Architecture: Architecture(s.Architecture),
+ IncludedTraffic: s.IncludedTraffic,
}
for _, price := range s.Prices {
st.Pricings = append(st.Pricings, ServerTypeLocationPricing{
diff --git a/vendor/github.com/hetznercloud/hcloud-go/hcloud/schema/primary_ip.go b/vendor/github.com/hetznercloud/hcloud-go/hcloud/schema/primary_ip.go
index d232a732d19..f6c7229a2b4 100644
--- a/vendor/github.com/hetznercloud/hcloud-go/hcloud/schema/primary_ip.go
+++ b/vendor/github.com/hetznercloud/hcloud-go/hcloud/schema/primary_ip.go
@@ -53,3 +53,10 @@ type PrimaryIPListResult struct {
type PrimaryIPUpdateResult struct {
PrimaryIP PrimaryIP `json:"primary_ip"`
}
+
+// PrimaryIPActionChangeDNSPtrRequest defines the schema for the request to
+// change a Primary IP's reverse DNS pointer.
+type PrimaryIPActionChangeDNSPtrRequest struct {
+ IP string `json:"ip"`
+ DNSPtr *string `json:"dns_ptr"`
+}
diff --git a/vendor/github.com/hetznercloud/hcloud-go/hcloud/schema/server_type.go b/vendor/github.com/hetznercloud/hcloud-go/hcloud/schema/server_type.go
index e2fe2f72615..1294a00517f 100644
--- a/vendor/github.com/hetznercloud/hcloud-go/hcloud/schema/server_type.go
+++ b/vendor/github.com/hetznercloud/hcloud-go/hcloud/schema/server_type.go
@@ -2,16 +2,17 @@ package schema
// ServerType defines the schema of a server type.
type ServerType struct {
- ID int `json:"id"`
- Name string `json:"name"`
- Description string `json:"description"`
- Cores int `json:"cores"`
- Memory float32 `json:"memory"`
- Disk int `json:"disk"`
- StorageType string `json:"storage_type"`
- CPUType string `json:"cpu_type"`
- Architecture string `json:"architecture"`
- Prices []PricingServerTypePrice `json:"prices"`
+ ID int `json:"id"`
+ Name string `json:"name"`
+ Description string `json:"description"`
+ Cores int `json:"cores"`
+ Memory float32 `json:"memory"`
+ Disk int `json:"disk"`
+ StorageType string `json:"storage_type"`
+ CPUType string `json:"cpu_type"`
+ Architecture string `json:"architecture"`
+ IncludedTraffic int64 `json:"included_traffic"`
+ Prices []PricingServerTypePrice `json:"prices"`
}
// ServerTypeListResponse defines the schema of the response when
diff --git a/vendor/github.com/hetznercloud/hcloud-go/hcloud/server_type.go b/vendor/github.com/hetznercloud/hcloud-go/hcloud/server_type.go
index 37ebb7f0903..2a5c90a5ce1 100644
--- a/vendor/github.com/hetznercloud/hcloud-go/hcloud/server_type.go
+++ b/vendor/github.com/hetznercloud/hcloud-go/hcloud/server_type.go
@@ -20,7 +20,9 @@ type ServerType struct {
StorageType StorageType
CPUType CPUType
Architecture Architecture
- Pricings []ServerTypeLocationPricing
+ // IncludedTraffic is the free traffic per month in bytes
+ IncludedTraffic int64
+ Pricings []ServerTypeLocationPricing
}
// StorageType specifies the type of storage.
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/README.md b/vendor/github.com/ionos-cloud/sdk-go/v6/README.md
index f020bdf4333..48ab1f3881f 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/README.md
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/README.md
@@ -352,7 +352,6 @@ KubernetesApi | [**K8sPut**](docs/api/KubernetesApi.md#k8sput) | **Put** /k8s/{k
KubernetesApi | [**K8sVersionsDefaultGet**](docs/api/KubernetesApi.md#k8sversionsdefaultget) | **Get** /k8s/versions/default | Get Default Kubernetes Version
KubernetesApi | [**K8sVersionsGet**](docs/api/KubernetesApi.md#k8sversionsget) | **Get** /k8s/versions | Get Kubernetes Versions
LANsApi | [**DatacentersLansDelete**](docs/api/LANsApi.md#datacenterslansdelete) | **Delete** /datacenters/{datacenterId}/lans/{lanId} | Delete LANs
-LANsApi | [**DatacentersLansEnableIpv6**](docs/api/LANsApi.md#datacenterslansenableipv6) | **Post** /datacenters/{datacenterId}/lans/enable-ipv6 | Enable IPv6 in the current Virtual Datacenter
LANsApi | [**DatacentersLansFindById**](docs/api/LANsApi.md#datacenterslansfindbyid) | **Get** /datacenters/{datacenterId}/lans/{lanId} | Retrieve LANs
LANsApi | [**DatacentersLansGet**](docs/api/LANsApi.md#datacenterslansget) | **Get** /datacenters/{datacenterId}/lans | List LANs
LANsApi | [**DatacentersLansNicsFindById**](docs/api/LANsApi.md#datacenterslansnicsfindbyid) | **Get** /datacenters/{datacenterId}/lans/{lanId}/nics/{nicId} | Retrieve attached NICs
@@ -620,7 +619,9 @@ All URIs are relative to *https://api.ionos.com/cloudapi/v6*
- [Lan](docs/models/Lan)
- [LanEntities](docs/models/LanEntities)
- [LanNics](docs/models/LanNics)
+ - [LanPost](docs/models/LanPost)
- [LanProperties](docs/models/LanProperties)
+ - [LanPropertiesPost](docs/models/LanPropertiesPost)
- [Lans](docs/models/Lans)
- [Loadbalancer](docs/models/Loadbalancer)
- [LoadbalancerEntities](docs/models/LoadbalancerEntities)
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/api_lans.go b/vendor/github.com/ionos-cloud/sdk-go/v6/api_lans.go
index 07560c52865..75e864a530f 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/api_lans.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/api_lans.go
@@ -192,167 +192,6 @@ func (a *LANsApiService) DatacentersLansDeleteExecute(r ApiDatacentersLansDelete
return localVarAPIResponse, nil
}
-type ApiDatacentersLansEnableIpv6Request struct {
- ctx _context.Context
- ApiService *LANsApiService
- datacenterId string
- pretty *bool
- depth *int32
- xContractNumber *int32
-}
-
-func (r ApiDatacentersLansEnableIpv6Request) Pretty(pretty bool) ApiDatacentersLansEnableIpv6Request {
- r.pretty = &pretty
- return r
-}
-func (r ApiDatacentersLansEnableIpv6Request) Depth(depth int32) ApiDatacentersLansEnableIpv6Request {
- r.depth = &depth
- return r
-}
-func (r ApiDatacentersLansEnableIpv6Request) XContractNumber(xContractNumber int32) ApiDatacentersLansEnableIpv6Request {
- r.xContractNumber = &xContractNumber
- return r
-}
-
-func (r ApiDatacentersLansEnableIpv6Request) Execute() (*APIResponse, error) {
- return r.ApiService.DatacentersLansEnableIpv6Execute(r)
-}
-
-/*
- * DatacentersLansEnableIpv6 Enable IPv6 in the current Virtual Datacenter
- * Enable IPv6 for all NICs in the current Virtual Datacenter.
- * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
- * @param datacenterId The unique ID of the data center.
- * @return ApiDatacentersLansEnableIpv6Request
- */
-func (a *LANsApiService) DatacentersLansEnableIpv6(ctx _context.Context, datacenterId string) ApiDatacentersLansEnableIpv6Request {
- return ApiDatacentersLansEnableIpv6Request{
- ApiService: a,
- ctx: ctx,
- datacenterId: datacenterId,
- }
-}
-
-/*
- * Execute executes the request
- */
-func (a *LANsApiService) DatacentersLansEnableIpv6Execute(r ApiDatacentersLansEnableIpv6Request) (*APIResponse, error) {
- var (
- localVarHTTPMethod = _nethttp.MethodPost
- localVarPostBody interface{}
- localVarFormFileName string
- localVarFileName string
- localVarFileBytes []byte
- )
-
- localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LANsApiService.DatacentersLansEnableIpv6")
- if err != nil {
- return nil, GenericOpenAPIError{error: err.Error()}
- }
-
- localVarPath := localBasePath + "/datacenters/{datacenterId}/lans/enable-ipv6"
- localVarPath = strings.Replace(localVarPath, "{"+"datacenterId"+"}", _neturl.PathEscape(parameterToString(r.datacenterId, "")), -1)
-
- localVarHeaderParams := make(map[string]string)
- localVarQueryParams := _neturl.Values{}
- localVarFormParams := _neturl.Values{}
-
- if r.pretty != nil {
- localVarQueryParams.Add("pretty", parameterToString(*r.pretty, ""))
- } else {
- defaultQueryParam := a.client.cfg.DefaultQueryParams.Get("pretty")
- if defaultQueryParam == "" {
- localVarQueryParams.Add("pretty", parameterToString(true, ""))
- }
- }
- if r.depth != nil {
- localVarQueryParams.Add("depth", parameterToString(*r.depth, ""))
- } else {
- defaultQueryParam := a.client.cfg.DefaultQueryParams.Get("depth")
- if defaultQueryParam == "" {
- localVarQueryParams.Add("depth", parameterToString(0, ""))
- }
- }
-
- // to determine the Content-Type header
- localVarHTTPContentTypes := []string{}
-
- // set Content-Type header
- localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes)
- if localVarHTTPContentType != "" {
- localVarHeaderParams["Content-Type"] = localVarHTTPContentType
- }
-
- // to determine the Accept header
- localVarHTTPHeaderAccepts := []string{"*/*"}
-
- // set Accept header
- localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts)
- if localVarHTTPHeaderAccept != "" {
- localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept
- }
- if r.xContractNumber != nil {
- localVarHeaderParams["X-Contract-Number"] = parameterToString(*r.xContractNumber, "")
- }
- if r.ctx != nil {
- // API Key Authentication
- if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok {
- if apiKey, ok := auth["Token Authentication"]; ok {
- var key string
- if apiKey.Prefix != "" {
- key = apiKey.Prefix + " " + apiKey.Key
- } else {
- key = apiKey.Key
- }
- localVarHeaderParams["Authorization"] = key
- }
- }
- }
- req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes)
- if err != nil {
- return nil, err
- }
-
- localVarHTTPResponse, httpRequestTime, err := a.client.callAPI(req)
-
- localVarAPIResponse := &APIResponse{
- Response: localVarHTTPResponse,
- Method: localVarHTTPMethod,
- RequestURL: localVarPath,
- RequestTime: httpRequestTime,
- Operation: "DatacentersLansEnableIpv6",
- }
-
- if err != nil || localVarHTTPResponse == nil {
- return localVarAPIResponse, err
- }
-
- localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body)
- localVarHTTPResponse.Body.Close()
- localVarAPIResponse.Payload = localVarBody
- if err != nil {
- return localVarAPIResponse, err
- }
-
- if localVarHTTPResponse.StatusCode >= 300 {
- newErr := GenericOpenAPIError{
- statusCode: localVarHTTPResponse.StatusCode,
- body: localVarBody,
- error: fmt.Sprintf(FormatStringErr, localVarHTTPResponse.Status, string(localVarBody)),
- }
- var v Error
- err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type"))
- if err != nil {
- newErr.error = fmt.Sprintf(FormatStringErr, localVarHTTPResponse.Status, err.Error())
- return localVarAPIResponse, newErr
- }
- newErr.model = v
- return localVarAPIResponse, newErr
- }
-
- return localVarAPIResponse, nil
-}
-
type ApiDatacentersLansFindByIdRequest struct {
ctx _context.Context
ApiService *LANsApiService
@@ -1563,13 +1402,13 @@ type ApiDatacentersLansPostRequest struct {
ctx _context.Context
ApiService *LANsApiService
datacenterId string
- lan *Lan
+ lan *LanPost
pretty *bool
depth *int32
xContractNumber *int32
}
-func (r ApiDatacentersLansPostRequest) Lan(lan Lan) ApiDatacentersLansPostRequest {
+func (r ApiDatacentersLansPostRequest) Lan(lan LanPost) ApiDatacentersLansPostRequest {
r.lan = &lan
return r
}
@@ -1586,7 +1425,7 @@ func (r ApiDatacentersLansPostRequest) XContractNumber(xContractNumber int32) Ap
return r
}
-func (r ApiDatacentersLansPostRequest) Execute() (Lan, *APIResponse, error) {
+func (r ApiDatacentersLansPostRequest) Execute() (LanPost, *APIResponse, error) {
return r.ApiService.DatacentersLansPostExecute(r)
}
@@ -1607,16 +1446,16 @@ func (a *LANsApiService) DatacentersLansPost(ctx _context.Context, datacenterId
/*
* Execute executes the request
- * @return Lan
+ * @return LanPost
*/
-func (a *LANsApiService) DatacentersLansPostExecute(r ApiDatacentersLansPostRequest) (Lan, *APIResponse, error) {
+func (a *LANsApiService) DatacentersLansPostExecute(r ApiDatacentersLansPostRequest) (LanPost, *APIResponse, error) {
var (
localVarHTTPMethod = _nethttp.MethodPost
localVarPostBody interface{}
localVarFormFileName string
localVarFileName string
localVarFileBytes []byte
- localVarReturnValue Lan
+ localVarReturnValue LanPost
)
localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LANsApiService.DatacentersLansPost")
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/client.go b/vendor/github.com/ionos-cloud/sdk-go/v6/client.go
index 0bbdf2a6db7..09747ffdddf 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/client.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/client.go
@@ -53,7 +53,7 @@ const (
RequestStatusFailed = "FAILED"
RequestStatusDone = "DONE"
- Version = "6.1.6"
+ Version = "6.1.7"
)
// Constants for APIs
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/configuration.go b/vendor/github.com/ionos-cloud/sdk-go/v6/configuration.go
index d6ef150c2bf..0da20bd00db 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/configuration.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/configuration.go
@@ -130,7 +130,7 @@ func NewConfiguration(username, password, token, hostUrl string) *Configuration
cfg := &Configuration{
DefaultHeader: make(map[string]string),
DefaultQueryParams: url.Values{},
- UserAgent: "ionos-cloud-sdk-go/v6.1.6",
+ UserAgent: "ionos-cloud-sdk-go/v6.1.7",
Debug: false,
Username: username,
Password: password,
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer.go
index a63fe3431db..61cf511883f 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer.go
@@ -16,15 +16,15 @@ import (
// ApplicationLoadBalancer struct for ApplicationLoadBalancer
type ApplicationLoadBalancer struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Entities *ApplicationLoadBalancerEntities `json:"entities,omitempty"`
// The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *ApplicationLoadBalancerProperties `json:"properties"`
- Entities *ApplicationLoadBalancerEntities `json:"entities,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewApplicationLoadBalancer instantiates a new ApplicationLoadBalancer object
@@ -47,114 +47,114 @@ func NewApplicationLoadBalancerWithDefaults() *ApplicationLoadBalancer {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancer) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancer) GetEntities() *ApplicationLoadBalancerEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancer) GetIdOk() (*string, bool) {
+func (o *ApplicationLoadBalancer) GetEntitiesOk() (*ApplicationLoadBalancerEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *ApplicationLoadBalancer) SetId(v string) {
+// SetEntities sets field value
+func (o *ApplicationLoadBalancer) SetEntities(v ApplicationLoadBalancerEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancer) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancer) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *ApplicationLoadBalancer) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancer) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancer) GetTypeOk() (*Type, bool) {
+func (o *ApplicationLoadBalancer) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *ApplicationLoadBalancer) SetType(v Type) {
+// SetHref sets field value
+func (o *ApplicationLoadBalancer) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancer) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancer) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancer) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancer) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancer) GetHrefOk() (*string, bool) {
+func (o *ApplicationLoadBalancer) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *ApplicationLoadBalancer) SetHref(v string) {
+// SetId sets field value
+func (o *ApplicationLoadBalancer) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancer) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancer) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -162,7 +162,7 @@ func (o *ApplicationLoadBalancer) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancer) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
@@ -200,7 +200,7 @@ func (o *ApplicationLoadBalancer) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for ApplicationLoadBalancerProperties will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancer) GetProperties() *ApplicationLoadBalancerProperties {
if o == nil {
return nil
@@ -237,38 +237,38 @@ func (o *ApplicationLoadBalancer) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for ApplicationLoadBalancerEntities will be returned
-func (o *ApplicationLoadBalancer) GetEntities() *ApplicationLoadBalancerEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancer) GetType() *Type {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancer) GetEntitiesOk() (*ApplicationLoadBalancerEntities, bool) {
+func (o *ApplicationLoadBalancer) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *ApplicationLoadBalancer) SetEntities(v ApplicationLoadBalancerEntities) {
+// SetType sets field value
+func (o *ApplicationLoadBalancer) SetType(v Type) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancer) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancer) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -277,24 +277,30 @@ func (o *ApplicationLoadBalancer) HasEntities() bool {
func (o ApplicationLoadBalancer) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_entities.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_entities.go
index d8cd1a1528c..425fceaa1ed 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_entities.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_entities.go
@@ -38,7 +38,7 @@ func NewApplicationLoadBalancerEntitiesWithDefaults() *ApplicationLoadBalancerEn
}
// GetForwardingrules returns the Forwardingrules field value
-// If the value is explicit nil, the zero value for ApplicationLoadBalancerForwardingRules will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancerEntities) GetForwardingrules() *ApplicationLoadBalancerForwardingRules {
if o == nil {
return nil
@@ -80,6 +80,7 @@ func (o ApplicationLoadBalancerEntities) MarshalJSON() ([]byte, error) {
if o.Forwardingrules != nil {
toSerialize["forwardingrules"] = o.Forwardingrules
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rule.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rule.go
index 34c30dfc600..e9e1bd5c917 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rule.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rule.go
@@ -16,14 +16,14 @@ import (
// ApplicationLoadBalancerForwardingRule struct for ApplicationLoadBalancerForwardingRule
type ApplicationLoadBalancerForwardingRule struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *ApplicationLoadBalancerForwardingRuleProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewApplicationLoadBalancerForwardingRule instantiates a new ApplicationLoadBalancerForwardingRule object
@@ -46,190 +46,190 @@ func NewApplicationLoadBalancerForwardingRuleWithDefaults() *ApplicationLoadBala
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerForwardingRule) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRule) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRule) GetIdOk() (*string, bool) {
+func (o *ApplicationLoadBalancerForwardingRule) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *ApplicationLoadBalancerForwardingRule) SetId(v string) {
+// SetHref sets field value
+func (o *ApplicationLoadBalancerForwardingRule) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRule) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRule) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *ApplicationLoadBalancerForwardingRule) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRule) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRule) GetTypeOk() (*Type, bool) {
+func (o *ApplicationLoadBalancerForwardingRule) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *ApplicationLoadBalancerForwardingRule) SetType(v Type) {
+// SetId sets field value
+func (o *ApplicationLoadBalancerForwardingRule) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRule) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRule) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerForwardingRule) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRule) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRule) GetHrefOk() (*string, bool) {
+func (o *ApplicationLoadBalancerForwardingRule) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *ApplicationLoadBalancerForwardingRule) SetHref(v string) {
+// SetMetadata sets field value
+func (o *ApplicationLoadBalancerForwardingRule) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRule) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRule) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *ApplicationLoadBalancerForwardingRule) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRule) GetProperties() *ApplicationLoadBalancerForwardingRuleProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRule) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *ApplicationLoadBalancerForwardingRule) GetPropertiesOk() (*ApplicationLoadBalancerForwardingRuleProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *ApplicationLoadBalancerForwardingRule) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *ApplicationLoadBalancerForwardingRule) SetProperties(v ApplicationLoadBalancerForwardingRuleProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRule) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRule) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for ApplicationLoadBalancerForwardingRuleProperties will be returned
-func (o *ApplicationLoadBalancerForwardingRule) GetProperties() *ApplicationLoadBalancerForwardingRuleProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRule) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRule) GetPropertiesOk() (*ApplicationLoadBalancerForwardingRuleProperties, bool) {
+func (o *ApplicationLoadBalancerForwardingRule) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *ApplicationLoadBalancerForwardingRule) SetProperties(v ApplicationLoadBalancerForwardingRuleProperties) {
+// SetType sets field value
+func (o *ApplicationLoadBalancerForwardingRule) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRule) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRule) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *ApplicationLoadBalancerForwardingRule) HasProperties() bool {
func (o ApplicationLoadBalancerForwardingRule) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rule_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rule_properties.go
index f73da694f06..b5adc750a9a 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rule_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rule_properties.go
@@ -16,33 +16,33 @@ import (
// ApplicationLoadBalancerForwardingRuleProperties struct for ApplicationLoadBalancerForwardingRuleProperties
type ApplicationLoadBalancerForwardingRuleProperties struct {
- // The name of the Application Load Balancer forwarding rule.
- Name *string `json:"name"`
- // The balancing protocol.
- Protocol *string `json:"protocol"`
+ // The maximum time in milliseconds to wait for the client to acknowledge or send data; default is 50,000 (50 seconds).
+ ClientTimeout *int32 `json:"clientTimeout,omitempty"`
+ // An array of items in the collection. The original order of rules is preserved during processing, except that rules of the 'FORWARD' type are processed after the rules with other defined actions. The relative order of the 'FORWARD' type rules is also preserved during the processing.
+ HttpRules *[]ApplicationLoadBalancerHttpRule `json:"httpRules,omitempty"`
// The listening (inbound) IP.
ListenerIp *string `json:"listenerIp"`
// The listening (inbound) port number; the valid range is 1 to 65535.
ListenerPort *int32 `json:"listenerPort"`
- // The maximum time in milliseconds to wait for the client to acknowledge or send data; default is 50,000 (50 seconds).
- ClientTimeout *int32 `json:"clientTimeout,omitempty"`
+ // The name of the Application Load Balancer forwarding rule.
+ Name *string `json:"name"`
+ // The balancing protocol.
+ Protocol *string `json:"protocol"`
// Array of items in the collection.
ServerCertificates *[]string `json:"serverCertificates,omitempty"`
- // An array of items in the collection. The original order of rules is preserved during processing, except that rules of the 'FORWARD' type are processed after the rules with other defined actions. The relative order of the 'FORWARD' type rules is also preserved during the processing.
- HttpRules *[]ApplicationLoadBalancerHttpRule `json:"httpRules,omitempty"`
}
// NewApplicationLoadBalancerForwardingRuleProperties instantiates a new ApplicationLoadBalancerForwardingRuleProperties object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewApplicationLoadBalancerForwardingRuleProperties(name string, protocol string, listenerIp string, listenerPort int32) *ApplicationLoadBalancerForwardingRuleProperties {
+func NewApplicationLoadBalancerForwardingRuleProperties(listenerIp string, listenerPort int32, name string, protocol string) *ApplicationLoadBalancerForwardingRuleProperties {
this := ApplicationLoadBalancerForwardingRuleProperties{}
- this.Name = &name
- this.Protocol = &protocol
this.ListenerIp = &listenerIp
this.ListenerPort = &listenerPort
+ this.Name = &name
+ this.Protocol = &protocol
return &this
}
@@ -55,76 +55,76 @@ func NewApplicationLoadBalancerForwardingRulePropertiesWithDefaults() *Applicati
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerForwardingRuleProperties) GetName() *string {
+// GetClientTimeout returns the ClientTimeout field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRuleProperties) GetClientTimeout() *int32 {
if o == nil {
return nil
}
- return o.Name
+ return o.ClientTimeout
}
-// GetNameOk returns a tuple with the Name field value
+// GetClientTimeoutOk returns a tuple with the ClientTimeout field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRuleProperties) GetNameOk() (*string, bool) {
+func (o *ApplicationLoadBalancerForwardingRuleProperties) GetClientTimeoutOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.ClientTimeout, true
}
-// SetName sets field value
-func (o *ApplicationLoadBalancerForwardingRuleProperties) SetName(v string) {
+// SetClientTimeout sets field value
+func (o *ApplicationLoadBalancerForwardingRuleProperties) SetClientTimeout(v int32) {
- o.Name = &v
+ o.ClientTimeout = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRuleProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasClientTimeout returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRuleProperties) HasClientTimeout() bool {
+ if o != nil && o.ClientTimeout != nil {
return true
}
return false
}
-// GetProtocol returns the Protocol field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerForwardingRuleProperties) GetProtocol() *string {
+// GetHttpRules returns the HttpRules field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRuleProperties) GetHttpRules() *[]ApplicationLoadBalancerHttpRule {
if o == nil {
return nil
}
- return o.Protocol
+ return o.HttpRules
}
-// GetProtocolOk returns a tuple with the Protocol field value
+// GetHttpRulesOk returns a tuple with the HttpRules field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRuleProperties) GetProtocolOk() (*string, bool) {
+func (o *ApplicationLoadBalancerForwardingRuleProperties) GetHttpRulesOk() (*[]ApplicationLoadBalancerHttpRule, bool) {
if o == nil {
return nil, false
}
- return o.Protocol, true
+ return o.HttpRules, true
}
-// SetProtocol sets field value
-func (o *ApplicationLoadBalancerForwardingRuleProperties) SetProtocol(v string) {
+// SetHttpRules sets field value
+func (o *ApplicationLoadBalancerForwardingRuleProperties) SetHttpRules(v []ApplicationLoadBalancerHttpRule) {
- o.Protocol = &v
+ o.HttpRules = &v
}
-// HasProtocol returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRuleProperties) HasProtocol() bool {
- if o != nil && o.Protocol != nil {
+// HasHttpRules returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRuleProperties) HasHttpRules() bool {
+ if o != nil && o.HttpRules != nil {
return true
}
@@ -132,7 +132,7 @@ func (o *ApplicationLoadBalancerForwardingRuleProperties) HasProtocol() bool {
}
// GetListenerIp returns the ListenerIp field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancerForwardingRuleProperties) GetListenerIp() *string {
if o == nil {
return nil
@@ -170,7 +170,7 @@ func (o *ApplicationLoadBalancerForwardingRuleProperties) HasListenerIp() bool {
}
// GetListenerPort returns the ListenerPort field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancerForwardingRuleProperties) GetListenerPort() *int32 {
if o == nil {
return nil
@@ -207,114 +207,114 @@ func (o *ApplicationLoadBalancerForwardingRuleProperties) HasListenerPort() bool
return false
}
-// GetClientTimeout returns the ClientTimeout field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ApplicationLoadBalancerForwardingRuleProperties) GetClientTimeout() *int32 {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRuleProperties) GetName() *string {
if o == nil {
return nil
}
- return o.ClientTimeout
+ return o.Name
}
-// GetClientTimeoutOk returns a tuple with the ClientTimeout field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRuleProperties) GetClientTimeoutOk() (*int32, bool) {
+func (o *ApplicationLoadBalancerForwardingRuleProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.ClientTimeout, true
+ return o.Name, true
}
-// SetClientTimeout sets field value
-func (o *ApplicationLoadBalancerForwardingRuleProperties) SetClientTimeout(v int32) {
+// SetName sets field value
+func (o *ApplicationLoadBalancerForwardingRuleProperties) SetName(v string) {
- o.ClientTimeout = &v
+ o.Name = &v
}
-// HasClientTimeout returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRuleProperties) HasClientTimeout() bool {
- if o != nil && o.ClientTimeout != nil {
+// HasName returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRuleProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetServerCertificates returns the ServerCertificates field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *ApplicationLoadBalancerForwardingRuleProperties) GetServerCertificates() *[]string {
+// GetProtocol returns the Protocol field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRuleProperties) GetProtocol() *string {
if o == nil {
return nil
}
- return o.ServerCertificates
+ return o.Protocol
}
-// GetServerCertificatesOk returns a tuple with the ServerCertificates field value
+// GetProtocolOk returns a tuple with the Protocol field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRuleProperties) GetServerCertificatesOk() (*[]string, bool) {
+func (o *ApplicationLoadBalancerForwardingRuleProperties) GetProtocolOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.ServerCertificates, true
+ return o.Protocol, true
}
-// SetServerCertificates sets field value
-func (o *ApplicationLoadBalancerForwardingRuleProperties) SetServerCertificates(v []string) {
+// SetProtocol sets field value
+func (o *ApplicationLoadBalancerForwardingRuleProperties) SetProtocol(v string) {
- o.ServerCertificates = &v
+ o.Protocol = &v
}
-// HasServerCertificates returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRuleProperties) HasServerCertificates() bool {
- if o != nil && o.ServerCertificates != nil {
+// HasProtocol returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRuleProperties) HasProtocol() bool {
+ if o != nil && o.Protocol != nil {
return true
}
return false
}
-// GetHttpRules returns the HttpRules field value
-// If the value is explicit nil, the zero value for []ApplicationLoadBalancerHttpRule will be returned
-func (o *ApplicationLoadBalancerForwardingRuleProperties) GetHttpRules() *[]ApplicationLoadBalancerHttpRule {
+// GetServerCertificates returns the ServerCertificates field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRuleProperties) GetServerCertificates() *[]string {
if o == nil {
return nil
}
- return o.HttpRules
+ return o.ServerCertificates
}
-// GetHttpRulesOk returns a tuple with the HttpRules field value
+// GetServerCertificatesOk returns a tuple with the ServerCertificates field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRuleProperties) GetHttpRulesOk() (*[]ApplicationLoadBalancerHttpRule, bool) {
+func (o *ApplicationLoadBalancerForwardingRuleProperties) GetServerCertificatesOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.HttpRules, true
+ return o.ServerCertificates, true
}
-// SetHttpRules sets field value
-func (o *ApplicationLoadBalancerForwardingRuleProperties) SetHttpRules(v []ApplicationLoadBalancerHttpRule) {
+// SetServerCertificates sets field value
+func (o *ApplicationLoadBalancerForwardingRuleProperties) SetServerCertificates(v []string) {
- o.HttpRules = &v
+ o.ServerCertificates = &v
}
-// HasHttpRules returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRuleProperties) HasHttpRules() bool {
- if o != nil && o.HttpRules != nil {
+// HasServerCertificates returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRuleProperties) HasServerCertificates() bool {
+ if o != nil && o.ServerCertificates != nil {
return true
}
@@ -323,27 +323,34 @@ func (o *ApplicationLoadBalancerForwardingRuleProperties) HasHttpRules() bool {
func (o ApplicationLoadBalancerForwardingRuleProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
+ if o.ClientTimeout != nil {
+ toSerialize["clientTimeout"] = o.ClientTimeout
}
- if o.Protocol != nil {
- toSerialize["protocol"] = o.Protocol
+
+ if o.HttpRules != nil {
+ toSerialize["httpRules"] = o.HttpRules
}
+
if o.ListenerIp != nil {
toSerialize["listenerIp"] = o.ListenerIp
}
+
if o.ListenerPort != nil {
toSerialize["listenerPort"] = o.ListenerPort
}
- if o.ClientTimeout != nil {
- toSerialize["clientTimeout"] = o.ClientTimeout
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
+ if o.Protocol != nil {
+ toSerialize["protocol"] = o.Protocol
}
+
if o.ServerCertificates != nil {
toSerialize["serverCertificates"] = o.ServerCertificates
}
- if o.HttpRules != nil {
- toSerialize["httpRules"] = o.HttpRules
- }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rule_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rule_put.go
index 0328b229cc1..d5e6f649a8e 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rule_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rule_put.go
@@ -16,13 +16,13 @@ import (
// ApplicationLoadBalancerForwardingRulePut struct for ApplicationLoadBalancerForwardingRulePut
type ApplicationLoadBalancerForwardingRulePut struct {
+ // The URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
- Id *string `json:"id,omitempty"`
+ Id *string `json:"id,omitempty"`
+ Properties *ApplicationLoadBalancerForwardingRuleProperties `json:"properties"`
// The type of object that has been created.
Type *Type `json:"type,omitempty"`
- // The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
- Properties *ApplicationLoadBalancerForwardingRuleProperties `json:"properties"`
}
// NewApplicationLoadBalancerForwardingRulePut instantiates a new ApplicationLoadBalancerForwardingRulePut object
@@ -45,152 +45,152 @@ func NewApplicationLoadBalancerForwardingRulePutWithDefaults() *ApplicationLoadB
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerForwardingRulePut) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRulePut) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRulePut) GetIdOk() (*string, bool) {
+func (o *ApplicationLoadBalancerForwardingRulePut) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *ApplicationLoadBalancerForwardingRulePut) SetId(v string) {
+// SetHref sets field value
+func (o *ApplicationLoadBalancerForwardingRulePut) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRulePut) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRulePut) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *ApplicationLoadBalancerForwardingRulePut) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRulePut) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRulePut) GetTypeOk() (*Type, bool) {
+func (o *ApplicationLoadBalancerForwardingRulePut) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *ApplicationLoadBalancerForwardingRulePut) SetType(v Type) {
+// SetId sets field value
+func (o *ApplicationLoadBalancerForwardingRulePut) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRulePut) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRulePut) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerForwardingRulePut) GetHref() *string {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRulePut) GetProperties() *ApplicationLoadBalancerForwardingRuleProperties {
if o == nil {
return nil
}
- return o.Href
+ return o.Properties
}
-// GetHrefOk returns a tuple with the Href field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRulePut) GetHrefOk() (*string, bool) {
+func (o *ApplicationLoadBalancerForwardingRulePut) GetPropertiesOk() (*ApplicationLoadBalancerForwardingRuleProperties, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Properties, true
}
-// SetHref sets field value
-func (o *ApplicationLoadBalancerForwardingRulePut) SetHref(v string) {
+// SetProperties sets field value
+func (o *ApplicationLoadBalancerForwardingRulePut) SetProperties(v ApplicationLoadBalancerForwardingRuleProperties) {
- o.Href = &v
+ o.Properties = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRulePut) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRulePut) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for ApplicationLoadBalancerForwardingRuleProperties will be returned
-func (o *ApplicationLoadBalancerForwardingRulePut) GetProperties() *ApplicationLoadBalancerForwardingRuleProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRulePut) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRulePut) GetPropertiesOk() (*ApplicationLoadBalancerForwardingRuleProperties, bool) {
+func (o *ApplicationLoadBalancerForwardingRulePut) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *ApplicationLoadBalancerForwardingRulePut) SetProperties(v ApplicationLoadBalancerForwardingRuleProperties) {
+// SetType sets field value
+func (o *ApplicationLoadBalancerForwardingRulePut) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRulePut) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRulePut) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -199,18 +199,22 @@ func (o *ApplicationLoadBalancerForwardingRulePut) HasProperties() bool {
func (o ApplicationLoadBalancerForwardingRulePut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rules.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rules.go
index 14b1f86e574..aae71997f3c 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rules.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_forwarding_rules.go
@@ -16,19 +16,19 @@ import (
// ApplicationLoadBalancerForwardingRules struct for ApplicationLoadBalancerForwardingRules
type ApplicationLoadBalancerForwardingRules struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// The URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]ApplicationLoadBalancerForwardingRule `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewApplicationLoadBalancerForwardingRules instantiates a new ApplicationLoadBalancerForwardingRules object
@@ -49,114 +49,114 @@ func NewApplicationLoadBalancerForwardingRulesWithDefaults() *ApplicationLoadBal
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerForwardingRules) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRules) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRules) GetIdOk() (*string, bool) {
+func (o *ApplicationLoadBalancerForwardingRules) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *ApplicationLoadBalancerForwardingRules) SetId(v string) {
+// SetLinks sets field value
+func (o *ApplicationLoadBalancerForwardingRules) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRules) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRules) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *ApplicationLoadBalancerForwardingRules) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRules) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRules) GetTypeOk() (*Type, bool) {
+func (o *ApplicationLoadBalancerForwardingRules) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *ApplicationLoadBalancerForwardingRules) SetType(v Type) {
+// SetHref sets field value
+func (o *ApplicationLoadBalancerForwardingRules) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRules) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRules) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerForwardingRules) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRules) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRules) GetHrefOk() (*string, bool) {
+func (o *ApplicationLoadBalancerForwardingRules) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *ApplicationLoadBalancerForwardingRules) SetHref(v string) {
+// SetId sets field value
+func (o *ApplicationLoadBalancerForwardingRules) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRules) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRules) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *ApplicationLoadBalancerForwardingRules) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []ApplicationLoadBalancerForwardingRule will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancerForwardingRules) GetItems() *[]ApplicationLoadBalancerForwardingRule {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *ApplicationLoadBalancerForwardingRules) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *ApplicationLoadBalancerForwardingRules) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRules) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRules) GetOffsetOk() (*float32, bool) {
+func (o *ApplicationLoadBalancerForwardingRules) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *ApplicationLoadBalancerForwardingRules) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *ApplicationLoadBalancerForwardingRules) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRules) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRules) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *ApplicationLoadBalancerForwardingRules) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRules) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRules) GetLimitOk() (*float32, bool) {
+func (o *ApplicationLoadBalancerForwardingRules) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *ApplicationLoadBalancerForwardingRules) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *ApplicationLoadBalancerForwardingRules) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRules) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRules) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *ApplicationLoadBalancerForwardingRules) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerForwardingRules) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerForwardingRules) GetLinksOk() (*PaginationLinks, bool) {
+func (o *ApplicationLoadBalancerForwardingRules) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *ApplicationLoadBalancerForwardingRules) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *ApplicationLoadBalancerForwardingRules) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerForwardingRules) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerForwardingRules) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *ApplicationLoadBalancerForwardingRules) HasLinks() bool {
func (o ApplicationLoadBalancerForwardingRules) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_http_rule.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_http_rule.go
index 9c117202ee0..1d52893f52e 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_http_rule.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_http_rule.go
@@ -16,24 +16,24 @@ import (
// ApplicationLoadBalancerHttpRule struct for ApplicationLoadBalancerHttpRule
type ApplicationLoadBalancerHttpRule struct {
- // The unique name of the Application Load Balancer HTTP rule.
- Name *string `json:"name"`
- // The HTTP rule type.
- Type *string `json:"type"`
- // The ID of the target group; this parameter is mandatory and is valid only for 'FORWARD' actions.
- TargetGroup *string `json:"targetGroup,omitempty"`
+ // An array of items in the collection. The action will be executed only if each condition is met; the rule will always be applied if no conditions are set.
+ Conditions *[]ApplicationLoadBalancerHttpRuleCondition `json:"conditions,omitempty"`
+ // Specifies the content type and is valid only for 'STATIC' actions.
+ ContentType *string `json:"contentType,omitempty"`
// Indicates whether the query part of the URI should be dropped and is valid only for 'REDIRECT' actions. Default value is 'FALSE', the redirect URI does not contain any query parameters.
DropQuery *bool `json:"dropQuery,omitempty"`
// The location for the redirection; this parameter is mandatory and valid only for 'REDIRECT' actions.
Location *string `json:"location,omitempty"`
- // The status code is for 'REDIRECT' and 'STATIC' actions only. If the HTTP rule is 'REDIRECT' the valid values are: 301, 302, 303, 307, 308; default value is '301'. If the HTTP rule is 'STATIC' the valid values are from the range 200-599; default value is '503'.
- StatusCode *int32 `json:"statusCode,omitempty"`
+ // The unique name of the Application Load Balancer HTTP rule.
+ Name *string `json:"name"`
// The response message of the request; this parameter is mandatory for 'STATIC' actions.
ResponseMessage *string `json:"responseMessage,omitempty"`
- // Specifies the content type and is valid only for 'STATIC' actions.
- ContentType *string `json:"contentType,omitempty"`
- // An array of items in the collection. The action will be executed only if each condition is met; the rule will always be applied if no conditions are set.
- Conditions *[]ApplicationLoadBalancerHttpRuleCondition `json:"conditions,omitempty"`
+ // The status code is for 'REDIRECT' and 'STATIC' actions only. If the HTTP rule is 'REDIRECT' the valid values are: 301, 302, 303, 307, 308; default value is '301'. If the HTTP rule is 'STATIC' the valid values are from the range 200-599; default value is '503'.
+ StatusCode *int32 `json:"statusCode,omitempty"`
+ // The ID of the target group; this parameter is mandatory and is valid only for 'FORWARD' actions.
+ TargetGroup *string `json:"targetGroup,omitempty"`
+ // The HTTP rule type.
+ Type *string `json:"type"`
}
// NewApplicationLoadBalancerHttpRule instantiates a new ApplicationLoadBalancerHttpRule object
@@ -57,114 +57,76 @@ func NewApplicationLoadBalancerHttpRuleWithDefaults() *ApplicationLoadBalancerHt
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerHttpRule) GetName() *string {
- if o == nil {
- return nil
- }
-
- return o.Name
-
-}
-
-// GetNameOk returns a tuple with the Name field value
-// and a boolean to check if the value has been set.
-// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerHttpRule) GetNameOk() (*string, bool) {
- if o == nil {
- return nil, false
- }
-
- return o.Name, true
-}
-
-// SetName sets field value
-func (o *ApplicationLoadBalancerHttpRule) SetName(v string) {
-
- o.Name = &v
-
-}
-
-// HasName returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerHttpRule) HasName() bool {
- if o != nil && o.Name != nil {
- return true
- }
-
- return false
-}
-
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerHttpRule) GetType() *string {
+// GetConditions returns the Conditions field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerHttpRule) GetConditions() *[]ApplicationLoadBalancerHttpRuleCondition {
if o == nil {
return nil
}
- return o.Type
+ return o.Conditions
}
-// GetTypeOk returns a tuple with the Type field value
+// GetConditionsOk returns a tuple with the Conditions field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerHttpRule) GetTypeOk() (*string, bool) {
+func (o *ApplicationLoadBalancerHttpRule) GetConditionsOk() (*[]ApplicationLoadBalancerHttpRuleCondition, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Conditions, true
}
-// SetType sets field value
-func (o *ApplicationLoadBalancerHttpRule) SetType(v string) {
+// SetConditions sets field value
+func (o *ApplicationLoadBalancerHttpRule) SetConditions(v []ApplicationLoadBalancerHttpRuleCondition) {
- o.Type = &v
+ o.Conditions = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerHttpRule) HasType() bool {
- if o != nil && o.Type != nil {
+// HasConditions returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerHttpRule) HasConditions() bool {
+ if o != nil && o.Conditions != nil {
return true
}
return false
}
-// GetTargetGroup returns the TargetGroup field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerHttpRule) GetTargetGroup() *string {
+// GetContentType returns the ContentType field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerHttpRule) GetContentType() *string {
if o == nil {
return nil
}
- return o.TargetGroup
+ return o.ContentType
}
-// GetTargetGroupOk returns a tuple with the TargetGroup field value
+// GetContentTypeOk returns a tuple with the ContentType field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerHttpRule) GetTargetGroupOk() (*string, bool) {
+func (o *ApplicationLoadBalancerHttpRule) GetContentTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.TargetGroup, true
+ return o.ContentType, true
}
-// SetTargetGroup sets field value
-func (o *ApplicationLoadBalancerHttpRule) SetTargetGroup(v string) {
+// SetContentType sets field value
+func (o *ApplicationLoadBalancerHttpRule) SetContentType(v string) {
- o.TargetGroup = &v
+ o.ContentType = &v
}
-// HasTargetGroup returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerHttpRule) HasTargetGroup() bool {
- if o != nil && o.TargetGroup != nil {
+// HasContentType returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerHttpRule) HasContentType() bool {
+ if o != nil && o.ContentType != nil {
return true
}
@@ -172,7 +134,7 @@ func (o *ApplicationLoadBalancerHttpRule) HasTargetGroup() bool {
}
// GetDropQuery returns the DropQuery field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancerHttpRule) GetDropQuery() *bool {
if o == nil {
return nil
@@ -210,7 +172,7 @@ func (o *ApplicationLoadBalancerHttpRule) HasDropQuery() bool {
}
// GetLocation returns the Location field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancerHttpRule) GetLocation() *string {
if o == nil {
return nil
@@ -247,38 +209,38 @@ func (o *ApplicationLoadBalancerHttpRule) HasLocation() bool {
return false
}
-// GetStatusCode returns the StatusCode field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ApplicationLoadBalancerHttpRule) GetStatusCode() *int32 {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerHttpRule) GetName() *string {
if o == nil {
return nil
}
- return o.StatusCode
+ return o.Name
}
-// GetStatusCodeOk returns a tuple with the StatusCode field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerHttpRule) GetStatusCodeOk() (*int32, bool) {
+func (o *ApplicationLoadBalancerHttpRule) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.StatusCode, true
+ return o.Name, true
}
-// SetStatusCode sets field value
-func (o *ApplicationLoadBalancerHttpRule) SetStatusCode(v int32) {
+// SetName sets field value
+func (o *ApplicationLoadBalancerHttpRule) SetName(v string) {
- o.StatusCode = &v
+ o.Name = &v
}
-// HasStatusCode returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerHttpRule) HasStatusCode() bool {
- if o != nil && o.StatusCode != nil {
+// HasName returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerHttpRule) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -286,7 +248,7 @@ func (o *ApplicationLoadBalancerHttpRule) HasStatusCode() bool {
}
// GetResponseMessage returns the ResponseMessage field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancerHttpRule) GetResponseMessage() *string {
if o == nil {
return nil
@@ -323,76 +285,114 @@ func (o *ApplicationLoadBalancerHttpRule) HasResponseMessage() bool {
return false
}
-// GetContentType returns the ContentType field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerHttpRule) GetContentType() *string {
+// GetStatusCode returns the StatusCode field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerHttpRule) GetStatusCode() *int32 {
if o == nil {
return nil
}
- return o.ContentType
+ return o.StatusCode
}
-// GetContentTypeOk returns a tuple with the ContentType field value
+// GetStatusCodeOk returns a tuple with the StatusCode field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerHttpRule) GetContentTypeOk() (*string, bool) {
+func (o *ApplicationLoadBalancerHttpRule) GetStatusCodeOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.ContentType, true
+ return o.StatusCode, true
}
-// SetContentType sets field value
-func (o *ApplicationLoadBalancerHttpRule) SetContentType(v string) {
+// SetStatusCode sets field value
+func (o *ApplicationLoadBalancerHttpRule) SetStatusCode(v int32) {
- o.ContentType = &v
+ o.StatusCode = &v
}
-// HasContentType returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerHttpRule) HasContentType() bool {
- if o != nil && o.ContentType != nil {
+// HasStatusCode returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerHttpRule) HasStatusCode() bool {
+ if o != nil && o.StatusCode != nil {
return true
}
return false
}
-// GetConditions returns the Conditions field value
-// If the value is explicit nil, the zero value for []ApplicationLoadBalancerHttpRuleCondition will be returned
-func (o *ApplicationLoadBalancerHttpRule) GetConditions() *[]ApplicationLoadBalancerHttpRuleCondition {
+// GetTargetGroup returns the TargetGroup field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerHttpRule) GetTargetGroup() *string {
if o == nil {
return nil
}
- return o.Conditions
+ return o.TargetGroup
}
-// GetConditionsOk returns a tuple with the Conditions field value
+// GetTargetGroupOk returns a tuple with the TargetGroup field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerHttpRule) GetConditionsOk() (*[]ApplicationLoadBalancerHttpRuleCondition, bool) {
+func (o *ApplicationLoadBalancerHttpRule) GetTargetGroupOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Conditions, true
+ return o.TargetGroup, true
}
-// SetConditions sets field value
-func (o *ApplicationLoadBalancerHttpRule) SetConditions(v []ApplicationLoadBalancerHttpRuleCondition) {
+// SetTargetGroup sets field value
+func (o *ApplicationLoadBalancerHttpRule) SetTargetGroup(v string) {
- o.Conditions = &v
+ o.TargetGroup = &v
}
-// HasConditions returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerHttpRule) HasConditions() bool {
- if o != nil && o.Conditions != nil {
+// HasTargetGroup returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerHttpRule) HasTargetGroup() bool {
+ if o != nil && o.TargetGroup != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerHttpRule) GetType() *string {
+ if o == nil {
+ return nil
+ }
+
+ return o.Type
+
+}
+
+// GetTypeOk returns a tuple with the Type field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *ApplicationLoadBalancerHttpRule) GetTypeOk() (*string, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Type, true
+}
+
+// SetType sets field value
+func (o *ApplicationLoadBalancerHttpRule) SetType(v string) {
+
+ o.Type = &v
+
+}
+
+// HasType returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerHttpRule) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -401,33 +401,42 @@ func (o *ApplicationLoadBalancerHttpRule) HasConditions() bool {
func (o ApplicationLoadBalancerHttpRule) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Conditions != nil {
+ toSerialize["conditions"] = o.Conditions
}
- if o.TargetGroup != nil {
- toSerialize["targetGroup"] = o.TargetGroup
+
+ if o.ContentType != nil {
+ toSerialize["contentType"] = o.ContentType
}
+
if o.DropQuery != nil {
toSerialize["dropQuery"] = o.DropQuery
}
+
if o.Location != nil {
toSerialize["location"] = o.Location
}
- if o.StatusCode != nil {
- toSerialize["statusCode"] = o.StatusCode
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
}
+
if o.ResponseMessage != nil {
toSerialize["responseMessage"] = o.ResponseMessage
}
- if o.ContentType != nil {
- toSerialize["contentType"] = o.ContentType
+
+ if o.StatusCode != nil {
+ toSerialize["statusCode"] = o.StatusCode
}
- if o.Conditions != nil {
- toSerialize["conditions"] = o.Conditions
+
+ if o.TargetGroup != nil {
+ toSerialize["targetGroup"] = o.TargetGroup
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_http_rule_condition.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_http_rule_condition.go
index a61e46532ff..a2b12adfd33 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_http_rule_condition.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_http_rule_condition.go
@@ -16,14 +16,14 @@ import (
// ApplicationLoadBalancerHttpRuleCondition struct for ApplicationLoadBalancerHttpRuleCondition
type ApplicationLoadBalancerHttpRuleCondition struct {
- // The HTTP rule condition type.
- Type *string `json:"type"`
// The matching rule for the HTTP rule condition attribute; this parameter is mandatory for 'HEADER', 'PATH', 'QUERY', 'METHOD', 'HOST', and 'COOKIE' types. It must be 'null' if the type is 'SOURCE_IP'.
Condition *string `json:"condition"`
- // Specifies whether the condition should be negated; the default value is 'FALSE'.
- Negate *bool `json:"negate,omitempty"`
// The key can only be set when the HTTP rule condition type is 'COOKIES', 'HEADER', or 'QUERY'. For the type 'PATH', 'METHOD', 'HOST', or 'SOURCE_IP' the value must be 'null'.
Key *string `json:"key,omitempty"`
+ // Specifies whether the condition should be negated; the default value is 'FALSE'.
+ Negate *bool `json:"negate,omitempty"`
+ // The HTTP rule condition type.
+ Type *string `json:"type"`
// This parameter is mandatory for the conditions 'CONTAINS', 'EQUALS', 'MATCHES', 'STARTS_WITH', 'ENDS_WITH', or if the type is 'SOURCE_IP'. Specify a valid CIDR. If the condition is 'EXISTS', the value must be 'null'.
Value *string `json:"value,omitempty"`
}
@@ -32,11 +32,11 @@ type ApplicationLoadBalancerHttpRuleCondition struct {
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewApplicationLoadBalancerHttpRuleCondition(type_ string, condition string) *ApplicationLoadBalancerHttpRuleCondition {
+func NewApplicationLoadBalancerHttpRuleCondition(condition string, type_ string) *ApplicationLoadBalancerHttpRuleCondition {
this := ApplicationLoadBalancerHttpRuleCondition{}
- this.Type = &type_
this.Condition = &condition
+ this.Type = &type_
return &this
}
@@ -49,76 +49,76 @@ func NewApplicationLoadBalancerHttpRuleConditionWithDefaults() *ApplicationLoadB
return &this
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerHttpRuleCondition) GetType() *string {
+// GetCondition returns the Condition field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerHttpRuleCondition) GetCondition() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Condition
}
-// GetTypeOk returns a tuple with the Type field value
+// GetConditionOk returns a tuple with the Condition field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerHttpRuleCondition) GetTypeOk() (*string, bool) {
+func (o *ApplicationLoadBalancerHttpRuleCondition) GetConditionOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Condition, true
}
-// SetType sets field value
-func (o *ApplicationLoadBalancerHttpRuleCondition) SetType(v string) {
+// SetCondition sets field value
+func (o *ApplicationLoadBalancerHttpRuleCondition) SetCondition(v string) {
- o.Type = &v
+ o.Condition = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerHttpRuleCondition) HasType() bool {
- if o != nil && o.Type != nil {
+// HasCondition returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerHttpRuleCondition) HasCondition() bool {
+ if o != nil && o.Condition != nil {
return true
}
return false
}
-// GetCondition returns the Condition field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerHttpRuleCondition) GetCondition() *string {
+// GetKey returns the Key field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerHttpRuleCondition) GetKey() *string {
if o == nil {
return nil
}
- return o.Condition
+ return o.Key
}
-// GetConditionOk returns a tuple with the Condition field value
+// GetKeyOk returns a tuple with the Key field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerHttpRuleCondition) GetConditionOk() (*string, bool) {
+func (o *ApplicationLoadBalancerHttpRuleCondition) GetKeyOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Condition, true
+ return o.Key, true
}
-// SetCondition sets field value
-func (o *ApplicationLoadBalancerHttpRuleCondition) SetCondition(v string) {
+// SetKey sets field value
+func (o *ApplicationLoadBalancerHttpRuleCondition) SetKey(v string) {
- o.Condition = &v
+ o.Key = &v
}
-// HasCondition returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerHttpRuleCondition) HasCondition() bool {
- if o != nil && o.Condition != nil {
+// HasKey returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerHttpRuleCondition) HasKey() bool {
+ if o != nil && o.Key != nil {
return true
}
@@ -126,7 +126,7 @@ func (o *ApplicationLoadBalancerHttpRuleCondition) HasCondition() bool {
}
// GetNegate returns the Negate field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancerHttpRuleCondition) GetNegate() *bool {
if o == nil {
return nil
@@ -163,38 +163,38 @@ func (o *ApplicationLoadBalancerHttpRuleCondition) HasNegate() bool {
return false
}
-// GetKey returns the Key field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerHttpRuleCondition) GetKey() *string {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerHttpRuleCondition) GetType() *string {
if o == nil {
return nil
}
- return o.Key
+ return o.Type
}
-// GetKeyOk returns a tuple with the Key field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerHttpRuleCondition) GetKeyOk() (*string, bool) {
+func (o *ApplicationLoadBalancerHttpRuleCondition) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Key, true
+ return o.Type, true
}
-// SetKey sets field value
-func (o *ApplicationLoadBalancerHttpRuleCondition) SetKey(v string) {
+// SetType sets field value
+func (o *ApplicationLoadBalancerHttpRuleCondition) SetType(v string) {
- o.Key = &v
+ o.Type = &v
}
-// HasKey returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerHttpRuleCondition) HasKey() bool {
- if o != nil && o.Key != nil {
+// HasType returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerHttpRuleCondition) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -202,7 +202,7 @@ func (o *ApplicationLoadBalancerHttpRuleCondition) HasKey() bool {
}
// GetValue returns the Value field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancerHttpRuleCondition) GetValue() *string {
if o == nil {
return nil
@@ -241,21 +241,26 @@ func (o *ApplicationLoadBalancerHttpRuleCondition) HasValue() bool {
func (o ApplicationLoadBalancerHttpRuleCondition) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Condition != nil {
toSerialize["condition"] = o.Condition
}
+
+ if o.Key != nil {
+ toSerialize["key"] = o.Key
+ }
+
if o.Negate != nil {
toSerialize["negate"] = o.Negate
}
- if o.Key != nil {
- toSerialize["key"] = o.Key
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
if o.Value != nil {
toSerialize["value"] = o.Value
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_properties.go
index 5055570bd07..8c62ecc1031 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_properties.go
@@ -16,27 +16,27 @@ import (
// ApplicationLoadBalancerProperties struct for ApplicationLoadBalancerProperties
type ApplicationLoadBalancerProperties struct {
- // The Application Load Balancer name.
- Name *string `json:"name"`
- // The ID of the listening (inbound) LAN.
- ListenerLan *int32 `json:"listenerLan"`
// Collection of the Application Load Balancer IP addresses. (Inbound and outbound) IPs of the 'listenerLan' are customer-reserved public IPs for the public load balancers, and private IPs for the private load balancers.
Ips *[]string `json:"ips,omitempty"`
- // The ID of the balanced private target LAN (outbound).
- TargetLan *int32 `json:"targetLan"`
// Collection of private IP addresses with the subnet mask of the Application Load Balancer. IPs must contain valid a subnet mask. If no IP is provided, the system will generate an IP with /24 subnet.
LbPrivateIps *[]string `json:"lbPrivateIps,omitempty"`
+ // The ID of the listening (inbound) LAN.
+ ListenerLan *int32 `json:"listenerLan"`
+ // The Application Load Balancer name.
+ Name *string `json:"name"`
+ // The ID of the balanced private target LAN (outbound).
+ TargetLan *int32 `json:"targetLan"`
}
// NewApplicationLoadBalancerProperties instantiates a new ApplicationLoadBalancerProperties object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewApplicationLoadBalancerProperties(name string, listenerLan int32, targetLan int32) *ApplicationLoadBalancerProperties {
+func NewApplicationLoadBalancerProperties(listenerLan int32, name string, targetLan int32) *ApplicationLoadBalancerProperties {
this := ApplicationLoadBalancerProperties{}
- this.Name = &name
this.ListenerLan = &listenerLan
+ this.Name = &name
this.TargetLan = &targetLan
return &this
@@ -50,38 +50,76 @@ func NewApplicationLoadBalancerPropertiesWithDefaults() *ApplicationLoadBalancer
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerProperties) GetName() *string {
+// GetIps returns the Ips field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerProperties) GetIps() *[]string {
if o == nil {
return nil
}
- return o.Name
+ return o.Ips
}
-// GetNameOk returns a tuple with the Name field value
+// GetIpsOk returns a tuple with the Ips field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerProperties) GetNameOk() (*string, bool) {
+func (o *ApplicationLoadBalancerProperties) GetIpsOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.Ips, true
}
-// SetName sets field value
-func (o *ApplicationLoadBalancerProperties) SetName(v string) {
+// SetIps sets field value
+func (o *ApplicationLoadBalancerProperties) SetIps(v []string) {
- o.Name = &v
+ o.Ips = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasIps returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerProperties) HasIps() bool {
+ if o != nil && o.Ips != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetLbPrivateIps returns the LbPrivateIps field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerProperties) GetLbPrivateIps() *[]string {
+ if o == nil {
+ return nil
+ }
+
+ return o.LbPrivateIps
+
+}
+
+// GetLbPrivateIpsOk returns a tuple with the LbPrivateIps field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *ApplicationLoadBalancerProperties) GetLbPrivateIpsOk() (*[]string, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.LbPrivateIps, true
+}
+
+// SetLbPrivateIps sets field value
+func (o *ApplicationLoadBalancerProperties) SetLbPrivateIps(v []string) {
+
+ o.LbPrivateIps = &v
+
+}
+
+// HasLbPrivateIps returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerProperties) HasLbPrivateIps() bool {
+ if o != nil && o.LbPrivateIps != nil {
return true
}
@@ -89,7 +127,7 @@ func (o *ApplicationLoadBalancerProperties) HasName() bool {
}
// GetListenerLan returns the ListenerLan field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancerProperties) GetListenerLan() *int32 {
if o == nil {
return nil
@@ -126,38 +164,38 @@ func (o *ApplicationLoadBalancerProperties) HasListenerLan() bool {
return false
}
-// GetIps returns the Ips field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *ApplicationLoadBalancerProperties) GetIps() *[]string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerProperties) GetName() *string {
if o == nil {
return nil
}
- return o.Ips
+ return o.Name
}
-// GetIpsOk returns a tuple with the Ips field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerProperties) GetIpsOk() (*[]string, bool) {
+func (o *ApplicationLoadBalancerProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Ips, true
+ return o.Name, true
}
-// SetIps sets field value
-func (o *ApplicationLoadBalancerProperties) SetIps(v []string) {
+// SetName sets field value
+func (o *ApplicationLoadBalancerProperties) SetName(v string) {
- o.Ips = &v
+ o.Name = &v
}
-// HasIps returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerProperties) HasIps() bool {
- if o != nil && o.Ips != nil {
+// HasName returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -165,7 +203,7 @@ func (o *ApplicationLoadBalancerProperties) HasIps() bool {
}
// GetTargetLan returns the TargetLan field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancerProperties) GetTargetLan() *int32 {
if o == nil {
return nil
@@ -202,61 +240,28 @@ func (o *ApplicationLoadBalancerProperties) HasTargetLan() bool {
return false
}
-// GetLbPrivateIps returns the LbPrivateIps field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *ApplicationLoadBalancerProperties) GetLbPrivateIps() *[]string {
- if o == nil {
- return nil
+func (o ApplicationLoadBalancerProperties) MarshalJSON() ([]byte, error) {
+ toSerialize := map[string]interface{}{}
+ if o.Ips != nil {
+ toSerialize["ips"] = o.Ips
}
- return o.LbPrivateIps
-
-}
-
-// GetLbPrivateIpsOk returns a tuple with the LbPrivateIps field value
-// and a boolean to check if the value has been set.
-// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerProperties) GetLbPrivateIpsOk() (*[]string, bool) {
- if o == nil {
- return nil, false
+ if o.LbPrivateIps != nil {
+ toSerialize["lbPrivateIps"] = o.LbPrivateIps
}
- return o.LbPrivateIps, true
-}
-
-// SetLbPrivateIps sets field value
-func (o *ApplicationLoadBalancerProperties) SetLbPrivateIps(v []string) {
-
- o.LbPrivateIps = &v
-
-}
-
-// HasLbPrivateIps returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerProperties) HasLbPrivateIps() bool {
- if o != nil && o.LbPrivateIps != nil {
- return true
+ if o.ListenerLan != nil {
+ toSerialize["listenerLan"] = o.ListenerLan
}
- return false
-}
-
-func (o ApplicationLoadBalancerProperties) MarshalJSON() ([]byte, error) {
- toSerialize := map[string]interface{}{}
if o.Name != nil {
toSerialize["name"] = o.Name
}
- if o.ListenerLan != nil {
- toSerialize["listenerLan"] = o.ListenerLan
- }
- if o.Ips != nil {
- toSerialize["ips"] = o.Ips
- }
+
if o.TargetLan != nil {
toSerialize["targetLan"] = o.TargetLan
}
- if o.LbPrivateIps != nil {
- toSerialize["lbPrivateIps"] = o.LbPrivateIps
- }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_put.go
index ce188b2d816..79a5fa1c708 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancer_put.go
@@ -16,13 +16,13 @@ import (
// ApplicationLoadBalancerPut struct for ApplicationLoadBalancerPut
type ApplicationLoadBalancerPut struct {
+ // The URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
- Id *string `json:"id,omitempty"`
+ Id *string `json:"id,omitempty"`
+ Properties *ApplicationLoadBalancerProperties `json:"properties"`
// The type of object that has been created.
Type *Type `json:"type,omitempty"`
- // The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
- Properties *ApplicationLoadBalancerProperties `json:"properties"`
}
// NewApplicationLoadBalancerPut instantiates a new ApplicationLoadBalancerPut object
@@ -45,152 +45,152 @@ func NewApplicationLoadBalancerPutWithDefaults() *ApplicationLoadBalancerPut {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerPut) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerPut) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerPut) GetIdOk() (*string, bool) {
+func (o *ApplicationLoadBalancerPut) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *ApplicationLoadBalancerPut) SetId(v string) {
+// SetHref sets field value
+func (o *ApplicationLoadBalancerPut) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerPut) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerPut) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *ApplicationLoadBalancerPut) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerPut) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerPut) GetTypeOk() (*Type, bool) {
+func (o *ApplicationLoadBalancerPut) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *ApplicationLoadBalancerPut) SetType(v Type) {
+// SetId sets field value
+func (o *ApplicationLoadBalancerPut) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerPut) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerPut) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancerPut) GetHref() *string {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerPut) GetProperties() *ApplicationLoadBalancerProperties {
if o == nil {
return nil
}
- return o.Href
+ return o.Properties
}
-// GetHrefOk returns a tuple with the Href field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerPut) GetHrefOk() (*string, bool) {
+func (o *ApplicationLoadBalancerPut) GetPropertiesOk() (*ApplicationLoadBalancerProperties, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Properties, true
}
-// SetHref sets field value
-func (o *ApplicationLoadBalancerPut) SetHref(v string) {
+// SetProperties sets field value
+func (o *ApplicationLoadBalancerPut) SetProperties(v ApplicationLoadBalancerProperties) {
- o.Href = &v
+ o.Properties = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerPut) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerPut) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for ApplicationLoadBalancerProperties will be returned
-func (o *ApplicationLoadBalancerPut) GetProperties() *ApplicationLoadBalancerProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancerPut) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancerPut) GetPropertiesOk() (*ApplicationLoadBalancerProperties, bool) {
+func (o *ApplicationLoadBalancerPut) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *ApplicationLoadBalancerPut) SetProperties(v ApplicationLoadBalancerProperties) {
+// SetType sets field value
+func (o *ApplicationLoadBalancerPut) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancerPut) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancerPut) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -199,18 +199,22 @@ func (o *ApplicationLoadBalancerPut) HasProperties() bool {
func (o ApplicationLoadBalancerPut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancers.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancers.go
index a3eff3d6ae9..a2f3a9e04c1 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancers.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_application_load_balancers.go
@@ -16,19 +16,19 @@ import (
// ApplicationLoadBalancers struct for ApplicationLoadBalancers
type ApplicationLoadBalancers struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// The URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]ApplicationLoadBalancer `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewApplicationLoadBalancers instantiates a new ApplicationLoadBalancers object
@@ -49,114 +49,114 @@ func NewApplicationLoadBalancersWithDefaults() *ApplicationLoadBalancers {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancers) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancers) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancers) GetIdOk() (*string, bool) {
+func (o *ApplicationLoadBalancers) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *ApplicationLoadBalancers) SetId(v string) {
+// SetLinks sets field value
+func (o *ApplicationLoadBalancers) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancers) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancers) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *ApplicationLoadBalancers) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancers) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancers) GetTypeOk() (*Type, bool) {
+func (o *ApplicationLoadBalancers) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *ApplicationLoadBalancers) SetType(v Type) {
+// SetHref sets field value
+func (o *ApplicationLoadBalancers) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancers) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancers) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ApplicationLoadBalancers) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancers) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancers) GetHrefOk() (*string, bool) {
+func (o *ApplicationLoadBalancers) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *ApplicationLoadBalancers) SetHref(v string) {
+// SetId sets field value
+func (o *ApplicationLoadBalancers) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancers) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancers) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *ApplicationLoadBalancers) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []ApplicationLoadBalancer will be returned
+// If the value is explicit nil, nil is returned
func (o *ApplicationLoadBalancers) GetItems() *[]ApplicationLoadBalancer {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *ApplicationLoadBalancers) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *ApplicationLoadBalancers) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancers) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancers) GetOffsetOk() (*float32, bool) {
+func (o *ApplicationLoadBalancers) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *ApplicationLoadBalancers) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *ApplicationLoadBalancers) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancers) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancers) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *ApplicationLoadBalancers) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancers) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancers) GetLimitOk() (*float32, bool) {
+func (o *ApplicationLoadBalancers) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *ApplicationLoadBalancers) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *ApplicationLoadBalancers) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancers) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancers) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *ApplicationLoadBalancers) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *ApplicationLoadBalancers) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ApplicationLoadBalancers) GetLinksOk() (*PaginationLinks, bool) {
+func (o *ApplicationLoadBalancers) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *ApplicationLoadBalancers) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *ApplicationLoadBalancers) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *ApplicationLoadBalancers) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *ApplicationLoadBalancers) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *ApplicationLoadBalancers) HasLinks() bool {
func (o ApplicationLoadBalancers) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_attached_volumes.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_attached_volumes.go
index 3791f488e5f..fdd81e42551 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_attached_volumes.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_attached_volumes.go
@@ -16,19 +16,19 @@ import (
// AttachedVolumes struct for AttachedVolumes
type AttachedVolumes struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// The URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Volume `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewAttachedVolumes instantiates a new AttachedVolumes object
@@ -49,114 +49,114 @@ func NewAttachedVolumesWithDefaults() *AttachedVolumes {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *AttachedVolumes) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *AttachedVolumes) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *AttachedVolumes) GetIdOk() (*string, bool) {
+func (o *AttachedVolumes) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *AttachedVolumes) SetId(v string) {
+// SetLinks sets field value
+func (o *AttachedVolumes) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *AttachedVolumes) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *AttachedVolumes) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *AttachedVolumes) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *AttachedVolumes) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *AttachedVolumes) GetTypeOk() (*Type, bool) {
+func (o *AttachedVolumes) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *AttachedVolumes) SetType(v Type) {
+// SetHref sets field value
+func (o *AttachedVolumes) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *AttachedVolumes) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *AttachedVolumes) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *AttachedVolumes) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *AttachedVolumes) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *AttachedVolumes) GetHrefOk() (*string, bool) {
+func (o *AttachedVolumes) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *AttachedVolumes) SetHref(v string) {
+// SetId sets field value
+func (o *AttachedVolumes) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *AttachedVolumes) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *AttachedVolumes) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *AttachedVolumes) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Volume will be returned
+// If the value is explicit nil, nil is returned
func (o *AttachedVolumes) GetItems() *[]Volume {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *AttachedVolumes) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *AttachedVolumes) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *AttachedVolumes) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *AttachedVolumes) GetOffsetOk() (*float32, bool) {
+func (o *AttachedVolumes) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *AttachedVolumes) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *AttachedVolumes) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *AttachedVolumes) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *AttachedVolumes) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *AttachedVolumes) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *AttachedVolumes) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *AttachedVolumes) GetLimitOk() (*float32, bool) {
+func (o *AttachedVolumes) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *AttachedVolumes) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *AttachedVolumes) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *AttachedVolumes) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *AttachedVolumes) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *AttachedVolumes) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *AttachedVolumes) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *AttachedVolumes) GetLinksOk() (*PaginationLinks, bool) {
+func (o *AttachedVolumes) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *AttachedVolumes) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *AttachedVolumes) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *AttachedVolumes) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *AttachedVolumes) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *AttachedVolumes) HasLinks() bool {
func (o AttachedVolumes) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_unit.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_unit.go
index bc9197db953..6f1ff7c4746 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_unit.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_unit.go
@@ -16,14 +16,14 @@ import (
// BackupUnit struct for BackupUnit
type BackupUnit struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *string `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *BackupUnitProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *string `json:"type,omitempty"`
}
// NewBackupUnit instantiates a new BackupUnit object
@@ -46,190 +46,190 @@ func NewBackupUnitWithDefaults() *BackupUnit {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *BackupUnit) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *BackupUnit) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BackupUnit) GetIdOk() (*string, bool) {
+func (o *BackupUnit) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *BackupUnit) SetId(v string) {
+// SetHref sets field value
+func (o *BackupUnit) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *BackupUnit) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *BackupUnit) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *BackupUnit) GetType() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *BackupUnit) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BackupUnit) GetTypeOk() (*string, bool) {
+func (o *BackupUnit) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *BackupUnit) SetType(v string) {
+// SetId sets field value
+func (o *BackupUnit) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *BackupUnit) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *BackupUnit) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *BackupUnit) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *BackupUnit) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BackupUnit) GetHrefOk() (*string, bool) {
+func (o *BackupUnit) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *BackupUnit) SetHref(v string) {
+// SetMetadata sets field value
+func (o *BackupUnit) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *BackupUnit) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *BackupUnit) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *BackupUnit) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *BackupUnit) GetProperties() *BackupUnitProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BackupUnit) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *BackupUnit) GetPropertiesOk() (*BackupUnitProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *BackupUnit) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *BackupUnit) SetProperties(v BackupUnitProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *BackupUnit) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *BackupUnit) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for BackupUnitProperties will be returned
-func (o *BackupUnit) GetProperties() *BackupUnitProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *BackupUnit) GetType() *string {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BackupUnit) GetPropertiesOk() (*BackupUnitProperties, bool) {
+func (o *BackupUnit) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *BackupUnit) SetProperties(v BackupUnitProperties) {
+// SetType sets field value
+func (o *BackupUnit) SetType(v string) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *BackupUnit) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *BackupUnit) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *BackupUnit) HasProperties() bool {
func (o BackupUnit) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_unit_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_unit_properties.go
index 45b5584e28b..64698d35608 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_unit_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_unit_properties.go
@@ -16,12 +16,12 @@ import (
// BackupUnitProperties struct for BackupUnitProperties
type BackupUnitProperties struct {
+ // The email associated with the backup unit. Bear in mind that this email does not be the same email as of the user.
+ Email *string `json:"email,omitempty"`
// The name of the resource (alphanumeric characters only).
Name *string `json:"name"`
// The password associated with that resource.
Password *string `json:"password,omitempty"`
- // The email associated with the backup unit. Bear in mind that this email does not be the same email as of the user.
- Email *string `json:"email,omitempty"`
}
// NewBackupUnitProperties instantiates a new BackupUnitProperties object
@@ -44,114 +44,114 @@ func NewBackupUnitPropertiesWithDefaults() *BackupUnitProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *BackupUnitProperties) GetName() *string {
+// GetEmail returns the Email field value
+// If the value is explicit nil, nil is returned
+func (o *BackupUnitProperties) GetEmail() *string {
if o == nil {
return nil
}
- return o.Name
+ return o.Email
}
-// GetNameOk returns a tuple with the Name field value
+// GetEmailOk returns a tuple with the Email field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BackupUnitProperties) GetNameOk() (*string, bool) {
+func (o *BackupUnitProperties) GetEmailOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.Email, true
}
-// SetName sets field value
-func (o *BackupUnitProperties) SetName(v string) {
+// SetEmail sets field value
+func (o *BackupUnitProperties) SetEmail(v string) {
- o.Name = &v
+ o.Email = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *BackupUnitProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasEmail returns a boolean if a field has been set.
+func (o *BackupUnitProperties) HasEmail() bool {
+ if o != nil && o.Email != nil {
return true
}
return false
}
-// GetPassword returns the Password field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *BackupUnitProperties) GetPassword() *string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *BackupUnitProperties) GetName() *string {
if o == nil {
return nil
}
- return o.Password
+ return o.Name
}
-// GetPasswordOk returns a tuple with the Password field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BackupUnitProperties) GetPasswordOk() (*string, bool) {
+func (o *BackupUnitProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Password, true
+ return o.Name, true
}
-// SetPassword sets field value
-func (o *BackupUnitProperties) SetPassword(v string) {
+// SetName sets field value
+func (o *BackupUnitProperties) SetName(v string) {
- o.Password = &v
+ o.Name = &v
}
-// HasPassword returns a boolean if a field has been set.
-func (o *BackupUnitProperties) HasPassword() bool {
- if o != nil && o.Password != nil {
+// HasName returns a boolean if a field has been set.
+func (o *BackupUnitProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetEmail returns the Email field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *BackupUnitProperties) GetEmail() *string {
+// GetPassword returns the Password field value
+// If the value is explicit nil, nil is returned
+func (o *BackupUnitProperties) GetPassword() *string {
if o == nil {
return nil
}
- return o.Email
+ return o.Password
}
-// GetEmailOk returns a tuple with the Email field value
+// GetPasswordOk returns a tuple with the Password field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BackupUnitProperties) GetEmailOk() (*string, bool) {
+func (o *BackupUnitProperties) GetPasswordOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Email, true
+ return o.Password, true
}
-// SetEmail sets field value
-func (o *BackupUnitProperties) SetEmail(v string) {
+// SetPassword sets field value
+func (o *BackupUnitProperties) SetPassword(v string) {
- o.Email = &v
+ o.Password = &v
}
-// HasEmail returns a boolean if a field has been set.
-func (o *BackupUnitProperties) HasEmail() bool {
- if o != nil && o.Email != nil {
+// HasPassword returns a boolean if a field has been set.
+func (o *BackupUnitProperties) HasPassword() bool {
+ if o != nil && o.Password != nil {
return true
}
@@ -160,15 +160,18 @@ func (o *BackupUnitProperties) HasEmail() bool {
func (o BackupUnitProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
+ if o.Email != nil {
+ toSerialize["email"] = o.Email
+ }
+
if o.Name != nil {
toSerialize["name"] = o.Name
}
+
if o.Password != nil {
toSerialize["password"] = o.Password
}
- if o.Email != nil {
- toSerialize["email"] = o.Email
- }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_unit_sso.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_unit_sso.go
index f493bf950c8..ea6ba4159b5 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_unit_sso.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_unit_sso.go
@@ -39,7 +39,7 @@ func NewBackupUnitSSOWithDefaults() *BackupUnitSSO {
}
// GetSsoUrl returns the SsoUrl field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *BackupUnitSSO) GetSsoUrl() *string {
if o == nil {
return nil
@@ -81,6 +81,7 @@ func (o BackupUnitSSO) MarshalJSON() ([]byte, error) {
if o.SsoUrl != nil {
toSerialize["ssoUrl"] = o.SsoUrl
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_units.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_units.go
index 6023f94e15a..280d50c6110 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_units.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_backup_units.go
@@ -16,14 +16,14 @@ import (
// BackupUnits struct for BackupUnits
type BackupUnits struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *string `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]BackupUnit `json:"items,omitempty"`
+ // The type of object that has been created.
+ Type *string `json:"type,omitempty"`
}
// NewBackupUnits instantiates a new BackupUnits object
@@ -44,152 +44,152 @@ func NewBackupUnitsWithDefaults() *BackupUnits {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *BackupUnits) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *BackupUnits) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BackupUnits) GetIdOk() (*string, bool) {
+func (o *BackupUnits) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *BackupUnits) SetId(v string) {
+// SetHref sets field value
+func (o *BackupUnits) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *BackupUnits) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *BackupUnits) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *BackupUnits) GetType() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *BackupUnits) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BackupUnits) GetTypeOk() (*string, bool) {
+func (o *BackupUnits) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *BackupUnits) SetType(v string) {
+// SetId sets field value
+func (o *BackupUnits) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *BackupUnits) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *BackupUnits) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *BackupUnits) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *BackupUnits) GetItems() *[]BackupUnit {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BackupUnits) GetHrefOk() (*string, bool) {
+func (o *BackupUnits) GetItemsOk() (*[]BackupUnit, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *BackupUnits) SetHref(v string) {
+// SetItems sets field value
+func (o *BackupUnits) SetItems(v []BackupUnit) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *BackupUnits) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *BackupUnits) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []BackupUnit will be returned
-func (o *BackupUnits) GetItems() *[]BackupUnit {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *BackupUnits) GetType() *string {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BackupUnits) GetItemsOk() (*[]BackupUnit, bool) {
+func (o *BackupUnits) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *BackupUnits) SetItems(v []BackupUnit) {
+// SetType sets field value
+func (o *BackupUnits) SetType(v string) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *BackupUnits) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *BackupUnits) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *BackupUnits) HasItems() bool {
func (o BackupUnits) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_balanced_nics.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_balanced_nics.go
index feef17f6267..f9338b5784a 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_balanced_nics.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_balanced_nics.go
@@ -16,19 +16,19 @@ import (
// BalancedNics struct for BalancedNics
type BalancedNics struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Nic `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewBalancedNics instantiates a new BalancedNics object
@@ -49,114 +49,114 @@ func NewBalancedNicsWithDefaults() *BalancedNics {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *BalancedNics) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *BalancedNics) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BalancedNics) GetIdOk() (*string, bool) {
+func (o *BalancedNics) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *BalancedNics) SetId(v string) {
+// SetLinks sets field value
+func (o *BalancedNics) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *BalancedNics) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *BalancedNics) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *BalancedNics) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *BalancedNics) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BalancedNics) GetTypeOk() (*Type, bool) {
+func (o *BalancedNics) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *BalancedNics) SetType(v Type) {
+// SetHref sets field value
+func (o *BalancedNics) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *BalancedNics) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *BalancedNics) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *BalancedNics) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *BalancedNics) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BalancedNics) GetHrefOk() (*string, bool) {
+func (o *BalancedNics) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *BalancedNics) SetHref(v string) {
+// SetId sets field value
+func (o *BalancedNics) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *BalancedNics) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *BalancedNics) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *BalancedNics) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Nic will be returned
+// If the value is explicit nil, nil is returned
func (o *BalancedNics) GetItems() *[]Nic {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *BalancedNics) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *BalancedNics) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *BalancedNics) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BalancedNics) GetOffsetOk() (*float32, bool) {
+func (o *BalancedNics) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *BalancedNics) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *BalancedNics) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *BalancedNics) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *BalancedNics) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *BalancedNics) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *BalancedNics) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BalancedNics) GetLimitOk() (*float32, bool) {
+func (o *BalancedNics) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *BalancedNics) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *BalancedNics) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *BalancedNics) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *BalancedNics) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *BalancedNics) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *BalancedNics) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *BalancedNics) GetLinksOk() (*PaginationLinks, bool) {
+func (o *BalancedNics) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *BalancedNics) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *BalancedNics) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *BalancedNics) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *BalancedNics) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *BalancedNics) HasLinks() bool {
func (o BalancedNics) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_cdroms.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_cdroms.go
index 4d2bb9a8536..86289fa1deb 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_cdroms.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_cdroms.go
@@ -16,19 +16,19 @@ import (
// Cdroms struct for Cdroms
type Cdroms struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Image `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewCdroms instantiates a new Cdroms object
@@ -49,114 +49,114 @@ func NewCdromsWithDefaults() *Cdroms {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Cdroms) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *Cdroms) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Cdroms) GetIdOk() (*string, bool) {
+func (o *Cdroms) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *Cdroms) SetId(v string) {
+// SetLinks sets field value
+func (o *Cdroms) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Cdroms) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *Cdroms) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Cdroms) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Cdroms) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Cdroms) GetTypeOk() (*Type, bool) {
+func (o *Cdroms) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Cdroms) SetType(v Type) {
+// SetHref sets field value
+func (o *Cdroms) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Cdroms) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Cdroms) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Cdroms) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Cdroms) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Cdroms) GetHrefOk() (*string, bool) {
+func (o *Cdroms) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Cdroms) SetHref(v string) {
+// SetId sets field value
+func (o *Cdroms) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Cdroms) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Cdroms) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *Cdroms) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Image will be returned
+// If the value is explicit nil, nil is returned
func (o *Cdroms) GetItems() *[]Image {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *Cdroms) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Cdroms) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *Cdroms) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Cdroms) GetOffsetOk() (*float32, bool) {
+func (o *Cdroms) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *Cdroms) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *Cdroms) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *Cdroms) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *Cdroms) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Cdroms) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *Cdroms) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Cdroms) GetLimitOk() (*float32, bool) {
+func (o *Cdroms) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *Cdroms) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *Cdroms) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *Cdroms) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *Cdroms) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *Cdroms) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Cdroms) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Cdroms) GetLinksOk() (*PaginationLinks, bool) {
+func (o *Cdroms) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *Cdroms) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *Cdroms) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *Cdroms) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Cdroms) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *Cdroms) HasLinks() bool {
func (o Cdroms) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_connectable_datacenter.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_connectable_datacenter.go
index 6b8a5f4cd81..778a5bdd097 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_connectable_datacenter.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_connectable_datacenter.go
@@ -17,8 +17,8 @@ import (
// ConnectableDatacenter struct for ConnectableDatacenter
type ConnectableDatacenter struct {
Id *string `json:"id,omitempty"`
- Name *string `json:"name,omitempty"`
Location *string `json:"location,omitempty"`
+ Name *string `json:"name,omitempty"`
}
// NewConnectableDatacenter instantiates a new ConnectableDatacenter object
@@ -40,7 +40,7 @@ func NewConnectableDatacenterWithDefaults() *ConnectableDatacenter {
}
// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *ConnectableDatacenter) GetId() *string {
if o == nil {
return nil
@@ -77,76 +77,76 @@ func (o *ConnectableDatacenter) HasId() bool {
return false
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ConnectableDatacenter) GetName() *string {
+// GetLocation returns the Location field value
+// If the value is explicit nil, nil is returned
+func (o *ConnectableDatacenter) GetLocation() *string {
if o == nil {
return nil
}
- return o.Name
+ return o.Location
}
-// GetNameOk returns a tuple with the Name field value
+// GetLocationOk returns a tuple with the Location field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ConnectableDatacenter) GetNameOk() (*string, bool) {
+func (o *ConnectableDatacenter) GetLocationOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.Location, true
}
-// SetName sets field value
-func (o *ConnectableDatacenter) SetName(v string) {
+// SetLocation sets field value
+func (o *ConnectableDatacenter) SetLocation(v string) {
- o.Name = &v
+ o.Location = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *ConnectableDatacenter) HasName() bool {
- if o != nil && o.Name != nil {
+// HasLocation returns a boolean if a field has been set.
+func (o *ConnectableDatacenter) HasLocation() bool {
+ if o != nil && o.Location != nil {
return true
}
return false
}
-// GetLocation returns the Location field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ConnectableDatacenter) GetLocation() *string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *ConnectableDatacenter) GetName() *string {
if o == nil {
return nil
}
- return o.Location
+ return o.Name
}
-// GetLocationOk returns a tuple with the Location field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ConnectableDatacenter) GetLocationOk() (*string, bool) {
+func (o *ConnectableDatacenter) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Location, true
+ return o.Name, true
}
-// SetLocation sets field value
-func (o *ConnectableDatacenter) SetLocation(v string) {
+// SetName sets field value
+func (o *ConnectableDatacenter) SetName(v string) {
- o.Location = &v
+ o.Name = &v
}
-// HasLocation returns a boolean if a field has been set.
-func (o *ConnectableDatacenter) HasLocation() bool {
- if o != nil && o.Location != nil {
+// HasName returns a boolean if a field has been set.
+func (o *ConnectableDatacenter) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -158,12 +158,15 @@ func (o ConnectableDatacenter) MarshalJSON() ([]byte, error) {
if o.Id != nil {
toSerialize["id"] = o.Id
}
- if o.Name != nil {
- toSerialize["name"] = o.Name
- }
+
if o.Location != nil {
toSerialize["location"] = o.Location
}
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_contract.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_contract.go
index e1e05792e97..d3ce413e191 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_contract.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_contract.go
@@ -16,9 +16,9 @@ import (
// Contract struct for Contract
type Contract struct {
- // The type of the resource.
- Type *Type `json:"type,omitempty"`
Properties *ContractProperties `json:"properties"`
+ // The type of the resource.
+ Type *Type `json:"type,omitempty"`
}
// NewContract instantiates a new Contract object
@@ -41,76 +41,76 @@ func NewContractWithDefaults() *Contract {
return &this
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Contract) GetType() *Type {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *Contract) GetProperties() *ContractProperties {
if o == nil {
return nil
}
- return o.Type
+ return o.Properties
}
-// GetTypeOk returns a tuple with the Type field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Contract) GetTypeOk() (*Type, bool) {
+func (o *Contract) GetPropertiesOk() (*ContractProperties, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Properties, true
}
-// SetType sets field value
-func (o *Contract) SetType(v Type) {
+// SetProperties sets field value
+func (o *Contract) SetProperties(v ContractProperties) {
- o.Type = &v
+ o.Properties = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Contract) HasType() bool {
- if o != nil && o.Type != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *Contract) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for ContractProperties will be returned
-func (o *Contract) GetProperties() *ContractProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Contract) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Contract) GetPropertiesOk() (*ContractProperties, bool) {
+func (o *Contract) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *Contract) SetProperties(v ContractProperties) {
+// SetType sets field value
+func (o *Contract) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *Contract) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Contract) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -119,12 +119,14 @@ func (o *Contract) HasProperties() bool {
func (o Contract) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_contract_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_contract_properties.go
index 522f6182974..a579ea3b789 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_contract_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_contract_properties.go
@@ -20,11 +20,11 @@ type ContractProperties struct {
ContractNumber *int64 `json:"contractNumber,omitempty"`
// The contract owner's user name.
Owner *string `json:"owner,omitempty"`
- // The contract status.
- Status *string `json:"status,omitempty"`
// The registration domain of the contract.
RegDomain *string `json:"regDomain,omitempty"`
ResourceLimits *ResourceLimits `json:"resourceLimits,omitempty"`
+ // The contract status.
+ Status *string `json:"status,omitempty"`
}
// NewContractProperties instantiates a new ContractProperties object
@@ -46,7 +46,7 @@ func NewContractPropertiesWithDefaults() *ContractProperties {
}
// GetContractNumber returns the ContractNumber field value
-// If the value is explicit nil, the zero value for int64 will be returned
+// If the value is explicit nil, nil is returned
func (o *ContractProperties) GetContractNumber() *int64 {
if o == nil {
return nil
@@ -84,7 +84,7 @@ func (o *ContractProperties) HasContractNumber() bool {
}
// GetOwner returns the Owner field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *ContractProperties) GetOwner() *string {
if o == nil {
return nil
@@ -121,114 +121,114 @@ func (o *ContractProperties) HasOwner() bool {
return false
}
-// GetStatus returns the Status field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ContractProperties) GetStatus() *string {
+// GetRegDomain returns the RegDomain field value
+// If the value is explicit nil, nil is returned
+func (o *ContractProperties) GetRegDomain() *string {
if o == nil {
return nil
}
- return o.Status
+ return o.RegDomain
}
-// GetStatusOk returns a tuple with the Status field value
+// GetRegDomainOk returns a tuple with the RegDomain field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ContractProperties) GetStatusOk() (*string, bool) {
+func (o *ContractProperties) GetRegDomainOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Status, true
+ return o.RegDomain, true
}
-// SetStatus sets field value
-func (o *ContractProperties) SetStatus(v string) {
+// SetRegDomain sets field value
+func (o *ContractProperties) SetRegDomain(v string) {
- o.Status = &v
+ o.RegDomain = &v
}
-// HasStatus returns a boolean if a field has been set.
-func (o *ContractProperties) HasStatus() bool {
- if o != nil && o.Status != nil {
+// HasRegDomain returns a boolean if a field has been set.
+func (o *ContractProperties) HasRegDomain() bool {
+ if o != nil && o.RegDomain != nil {
return true
}
return false
}
-// GetRegDomain returns the RegDomain field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ContractProperties) GetRegDomain() *string {
+// GetResourceLimits returns the ResourceLimits field value
+// If the value is explicit nil, nil is returned
+func (o *ContractProperties) GetResourceLimits() *ResourceLimits {
if o == nil {
return nil
}
- return o.RegDomain
+ return o.ResourceLimits
}
-// GetRegDomainOk returns a tuple with the RegDomain field value
+// GetResourceLimitsOk returns a tuple with the ResourceLimits field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ContractProperties) GetRegDomainOk() (*string, bool) {
+func (o *ContractProperties) GetResourceLimitsOk() (*ResourceLimits, bool) {
if o == nil {
return nil, false
}
- return o.RegDomain, true
+ return o.ResourceLimits, true
}
-// SetRegDomain sets field value
-func (o *ContractProperties) SetRegDomain(v string) {
+// SetResourceLimits sets field value
+func (o *ContractProperties) SetResourceLimits(v ResourceLimits) {
- o.RegDomain = &v
+ o.ResourceLimits = &v
}
-// HasRegDomain returns a boolean if a field has been set.
-func (o *ContractProperties) HasRegDomain() bool {
- if o != nil && o.RegDomain != nil {
+// HasResourceLimits returns a boolean if a field has been set.
+func (o *ContractProperties) HasResourceLimits() bool {
+ if o != nil && o.ResourceLimits != nil {
return true
}
return false
}
-// GetResourceLimits returns the ResourceLimits field value
-// If the value is explicit nil, the zero value for ResourceLimits will be returned
-func (o *ContractProperties) GetResourceLimits() *ResourceLimits {
+// GetStatus returns the Status field value
+// If the value is explicit nil, nil is returned
+func (o *ContractProperties) GetStatus() *string {
if o == nil {
return nil
}
- return o.ResourceLimits
+ return o.Status
}
-// GetResourceLimitsOk returns a tuple with the ResourceLimits field value
+// GetStatusOk returns a tuple with the Status field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ContractProperties) GetResourceLimitsOk() (*ResourceLimits, bool) {
+func (o *ContractProperties) GetStatusOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.ResourceLimits, true
+ return o.Status, true
}
-// SetResourceLimits sets field value
-func (o *ContractProperties) SetResourceLimits(v ResourceLimits) {
+// SetStatus sets field value
+func (o *ContractProperties) SetStatus(v string) {
- o.ResourceLimits = &v
+ o.Status = &v
}
-// HasResourceLimits returns a boolean if a field has been set.
-func (o *ContractProperties) HasResourceLimits() bool {
- if o != nil && o.ResourceLimits != nil {
+// HasStatus returns a boolean if a field has been set.
+func (o *ContractProperties) HasStatus() bool {
+ if o != nil && o.Status != nil {
return true
}
@@ -240,18 +240,23 @@ func (o ContractProperties) MarshalJSON() ([]byte, error) {
if o.ContractNumber != nil {
toSerialize["contractNumber"] = o.ContractNumber
}
+
if o.Owner != nil {
toSerialize["owner"] = o.Owner
}
- if o.Status != nil {
- toSerialize["status"] = o.Status
- }
+
if o.RegDomain != nil {
toSerialize["regDomain"] = o.RegDomain
}
+
if o.ResourceLimits != nil {
toSerialize["resourceLimits"] = o.ResourceLimits
}
+
+ if o.Status != nil {
+ toSerialize["status"] = o.Status
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_contracts.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_contracts.go
index c6fc46e310e..61e2f9aa961 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_contracts.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_contracts.go
@@ -16,14 +16,14 @@ import (
// Contracts struct for Contracts
type Contracts struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// The URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Contract `json:"items,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewContracts instantiates a new Contracts object
@@ -44,152 +44,152 @@ func NewContractsWithDefaults() *Contracts {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Contracts) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Contracts) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Contracts) GetIdOk() (*string, bool) {
+func (o *Contracts) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Contracts) SetId(v string) {
+// SetHref sets field value
+func (o *Contracts) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Contracts) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Contracts) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Contracts) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Contracts) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Contracts) GetTypeOk() (*Type, bool) {
+func (o *Contracts) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Contracts) SetType(v Type) {
+// SetId sets field value
+func (o *Contracts) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Contracts) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Contracts) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Contracts) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *Contracts) GetItems() *[]Contract {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Contracts) GetHrefOk() (*string, bool) {
+func (o *Contracts) GetItemsOk() (*[]Contract, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *Contracts) SetHref(v string) {
+// SetItems sets field value
+func (o *Contracts) SetItems(v []Contract) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Contracts) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *Contracts) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Contract will be returned
-func (o *Contracts) GetItems() *[]Contract {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Contracts) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Contracts) GetItemsOk() (*[]Contract, bool) {
+func (o *Contracts) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *Contracts) SetItems(v []Contract) {
+// SetType sets field value
+func (o *Contracts) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *Contracts) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Contracts) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *Contracts) HasItems() bool {
func (o Contracts) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_cpu_architecture_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_cpu_architecture_properties.go
index 80c6b6c2411..c86a3899dea 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_cpu_architecture_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_cpu_architecture_properties.go
@@ -45,7 +45,7 @@ func NewCpuArchitecturePropertiesWithDefaults() *CpuArchitectureProperties {
}
// GetCpuFamily returns the CpuFamily field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *CpuArchitectureProperties) GetCpuFamily() *string {
if o == nil {
return nil
@@ -83,7 +83,7 @@ func (o *CpuArchitectureProperties) HasCpuFamily() bool {
}
// GetMaxCores returns the MaxCores field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *CpuArchitectureProperties) GetMaxCores() *int32 {
if o == nil {
return nil
@@ -121,7 +121,7 @@ func (o *CpuArchitectureProperties) HasMaxCores() bool {
}
// GetMaxRam returns the MaxRam field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *CpuArchitectureProperties) GetMaxRam() *int32 {
if o == nil {
return nil
@@ -159,7 +159,7 @@ func (o *CpuArchitectureProperties) HasMaxRam() bool {
}
// GetVendor returns the Vendor field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *CpuArchitectureProperties) GetVendor() *string {
if o == nil {
return nil
@@ -201,15 +201,19 @@ func (o CpuArchitectureProperties) MarshalJSON() ([]byte, error) {
if o.CpuFamily != nil {
toSerialize["cpuFamily"] = o.CpuFamily
}
+
if o.MaxCores != nil {
toSerialize["maxCores"] = o.MaxCores
}
+
if o.MaxRam != nil {
toSerialize["maxRam"] = o.MaxRam
}
+
if o.Vendor != nil {
toSerialize["vendor"] = o.Vendor
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_data_center_entities.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_data_center_entities.go
index 65fa3ee3d1d..2ac821f85da 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_data_center_entities.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_data_center_entities.go
@@ -16,12 +16,12 @@ import (
// DataCenterEntities struct for DataCenterEntities
type DataCenterEntities struct {
- Servers *Servers `json:"servers,omitempty"`
- Volumes *Volumes `json:"volumes,omitempty"`
- Loadbalancers *Loadbalancers `json:"loadbalancers,omitempty"`
Lans *Lans `json:"lans,omitempty"`
- Networkloadbalancers *NetworkLoadBalancers `json:"networkloadbalancers,omitempty"`
+ Loadbalancers *Loadbalancers `json:"loadbalancers,omitempty"`
Natgateways *NatGateways `json:"natgateways,omitempty"`
+ Networkloadbalancers *NetworkLoadBalancers `json:"networkloadbalancers,omitempty"`
+ Servers *Servers `json:"servers,omitempty"`
+ Volumes *Volumes `json:"volumes,omitempty"`
}
// NewDataCenterEntities instantiates a new DataCenterEntities object
@@ -42,228 +42,228 @@ func NewDataCenterEntitiesWithDefaults() *DataCenterEntities {
return &this
}
-// GetServers returns the Servers field value
-// If the value is explicit nil, the zero value for Servers will be returned
-func (o *DataCenterEntities) GetServers() *Servers {
+// GetLans returns the Lans field value
+// If the value is explicit nil, nil is returned
+func (o *DataCenterEntities) GetLans() *Lans {
if o == nil {
return nil
}
- return o.Servers
+ return o.Lans
}
-// GetServersOk returns a tuple with the Servers field value
+// GetLansOk returns a tuple with the Lans field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DataCenterEntities) GetServersOk() (*Servers, bool) {
+func (o *DataCenterEntities) GetLansOk() (*Lans, bool) {
if o == nil {
return nil, false
}
- return o.Servers, true
+ return o.Lans, true
}
-// SetServers sets field value
-func (o *DataCenterEntities) SetServers(v Servers) {
+// SetLans sets field value
+func (o *DataCenterEntities) SetLans(v Lans) {
- o.Servers = &v
+ o.Lans = &v
}
-// HasServers returns a boolean if a field has been set.
-func (o *DataCenterEntities) HasServers() bool {
- if o != nil && o.Servers != nil {
+// HasLans returns a boolean if a field has been set.
+func (o *DataCenterEntities) HasLans() bool {
+ if o != nil && o.Lans != nil {
return true
}
return false
}
-// GetVolumes returns the Volumes field value
-// If the value is explicit nil, the zero value for Volumes will be returned
-func (o *DataCenterEntities) GetVolumes() *Volumes {
+// GetLoadbalancers returns the Loadbalancers field value
+// If the value is explicit nil, nil is returned
+func (o *DataCenterEntities) GetLoadbalancers() *Loadbalancers {
if o == nil {
return nil
}
- return o.Volumes
+ return o.Loadbalancers
}
-// GetVolumesOk returns a tuple with the Volumes field value
+// GetLoadbalancersOk returns a tuple with the Loadbalancers field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DataCenterEntities) GetVolumesOk() (*Volumes, bool) {
+func (o *DataCenterEntities) GetLoadbalancersOk() (*Loadbalancers, bool) {
if o == nil {
return nil, false
}
- return o.Volumes, true
+ return o.Loadbalancers, true
}
-// SetVolumes sets field value
-func (o *DataCenterEntities) SetVolumes(v Volumes) {
+// SetLoadbalancers sets field value
+func (o *DataCenterEntities) SetLoadbalancers(v Loadbalancers) {
- o.Volumes = &v
+ o.Loadbalancers = &v
}
-// HasVolumes returns a boolean if a field has been set.
-func (o *DataCenterEntities) HasVolumes() bool {
- if o != nil && o.Volumes != nil {
+// HasLoadbalancers returns a boolean if a field has been set.
+func (o *DataCenterEntities) HasLoadbalancers() bool {
+ if o != nil && o.Loadbalancers != nil {
return true
}
return false
}
-// GetLoadbalancers returns the Loadbalancers field value
-// If the value is explicit nil, the zero value for Loadbalancers will be returned
-func (o *DataCenterEntities) GetLoadbalancers() *Loadbalancers {
+// GetNatgateways returns the Natgateways field value
+// If the value is explicit nil, nil is returned
+func (o *DataCenterEntities) GetNatgateways() *NatGateways {
if o == nil {
return nil
}
- return o.Loadbalancers
+ return o.Natgateways
}
-// GetLoadbalancersOk returns a tuple with the Loadbalancers field value
+// GetNatgatewaysOk returns a tuple with the Natgateways field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DataCenterEntities) GetLoadbalancersOk() (*Loadbalancers, bool) {
+func (o *DataCenterEntities) GetNatgatewaysOk() (*NatGateways, bool) {
if o == nil {
return nil, false
}
- return o.Loadbalancers, true
+ return o.Natgateways, true
}
-// SetLoadbalancers sets field value
-func (o *DataCenterEntities) SetLoadbalancers(v Loadbalancers) {
+// SetNatgateways sets field value
+func (o *DataCenterEntities) SetNatgateways(v NatGateways) {
- o.Loadbalancers = &v
+ o.Natgateways = &v
}
-// HasLoadbalancers returns a boolean if a field has been set.
-func (o *DataCenterEntities) HasLoadbalancers() bool {
- if o != nil && o.Loadbalancers != nil {
+// HasNatgateways returns a boolean if a field has been set.
+func (o *DataCenterEntities) HasNatgateways() bool {
+ if o != nil && o.Natgateways != nil {
return true
}
return false
}
-// GetLans returns the Lans field value
-// If the value is explicit nil, the zero value for Lans will be returned
-func (o *DataCenterEntities) GetLans() *Lans {
+// GetNetworkloadbalancers returns the Networkloadbalancers field value
+// If the value is explicit nil, nil is returned
+func (o *DataCenterEntities) GetNetworkloadbalancers() *NetworkLoadBalancers {
if o == nil {
return nil
}
- return o.Lans
+ return o.Networkloadbalancers
}
-// GetLansOk returns a tuple with the Lans field value
+// GetNetworkloadbalancersOk returns a tuple with the Networkloadbalancers field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DataCenterEntities) GetLansOk() (*Lans, bool) {
+func (o *DataCenterEntities) GetNetworkloadbalancersOk() (*NetworkLoadBalancers, bool) {
if o == nil {
return nil, false
}
- return o.Lans, true
+ return o.Networkloadbalancers, true
}
-// SetLans sets field value
-func (o *DataCenterEntities) SetLans(v Lans) {
+// SetNetworkloadbalancers sets field value
+func (o *DataCenterEntities) SetNetworkloadbalancers(v NetworkLoadBalancers) {
- o.Lans = &v
+ o.Networkloadbalancers = &v
}
-// HasLans returns a boolean if a field has been set.
-func (o *DataCenterEntities) HasLans() bool {
- if o != nil && o.Lans != nil {
+// HasNetworkloadbalancers returns a boolean if a field has been set.
+func (o *DataCenterEntities) HasNetworkloadbalancers() bool {
+ if o != nil && o.Networkloadbalancers != nil {
return true
}
return false
}
-// GetNetworkloadbalancers returns the Networkloadbalancers field value
-// If the value is explicit nil, the zero value for NetworkLoadBalancers will be returned
-func (o *DataCenterEntities) GetNetworkloadbalancers() *NetworkLoadBalancers {
+// GetServers returns the Servers field value
+// If the value is explicit nil, nil is returned
+func (o *DataCenterEntities) GetServers() *Servers {
if o == nil {
return nil
}
- return o.Networkloadbalancers
+ return o.Servers
}
-// GetNetworkloadbalancersOk returns a tuple with the Networkloadbalancers field value
+// GetServersOk returns a tuple with the Servers field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DataCenterEntities) GetNetworkloadbalancersOk() (*NetworkLoadBalancers, bool) {
+func (o *DataCenterEntities) GetServersOk() (*Servers, bool) {
if o == nil {
return nil, false
}
- return o.Networkloadbalancers, true
+ return o.Servers, true
}
-// SetNetworkloadbalancers sets field value
-func (o *DataCenterEntities) SetNetworkloadbalancers(v NetworkLoadBalancers) {
+// SetServers sets field value
+func (o *DataCenterEntities) SetServers(v Servers) {
- o.Networkloadbalancers = &v
+ o.Servers = &v
}
-// HasNetworkloadbalancers returns a boolean if a field has been set.
-func (o *DataCenterEntities) HasNetworkloadbalancers() bool {
- if o != nil && o.Networkloadbalancers != nil {
+// HasServers returns a boolean if a field has been set.
+func (o *DataCenterEntities) HasServers() bool {
+ if o != nil && o.Servers != nil {
return true
}
return false
}
-// GetNatgateways returns the Natgateways field value
-// If the value is explicit nil, the zero value for NatGateways will be returned
-func (o *DataCenterEntities) GetNatgateways() *NatGateways {
+// GetVolumes returns the Volumes field value
+// If the value is explicit nil, nil is returned
+func (o *DataCenterEntities) GetVolumes() *Volumes {
if o == nil {
return nil
}
- return o.Natgateways
+ return o.Volumes
}
-// GetNatgatewaysOk returns a tuple with the Natgateways field value
+// GetVolumesOk returns a tuple with the Volumes field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DataCenterEntities) GetNatgatewaysOk() (*NatGateways, bool) {
+func (o *DataCenterEntities) GetVolumesOk() (*Volumes, bool) {
if o == nil {
return nil, false
}
- return o.Natgateways, true
+ return o.Volumes, true
}
-// SetNatgateways sets field value
-func (o *DataCenterEntities) SetNatgateways(v NatGateways) {
+// SetVolumes sets field value
+func (o *DataCenterEntities) SetVolumes(v Volumes) {
- o.Natgateways = &v
+ o.Volumes = &v
}
-// HasNatgateways returns a boolean if a field has been set.
-func (o *DataCenterEntities) HasNatgateways() bool {
- if o != nil && o.Natgateways != nil {
+// HasVolumes returns a boolean if a field has been set.
+func (o *DataCenterEntities) HasVolumes() bool {
+ if o != nil && o.Volumes != nil {
return true
}
@@ -272,24 +272,30 @@ func (o *DataCenterEntities) HasNatgateways() bool {
func (o DataCenterEntities) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Servers != nil {
- toSerialize["servers"] = o.Servers
- }
- if o.Volumes != nil {
- toSerialize["volumes"] = o.Volumes
+ if o.Lans != nil {
+ toSerialize["lans"] = o.Lans
}
+
if o.Loadbalancers != nil {
toSerialize["loadbalancers"] = o.Loadbalancers
}
- if o.Lans != nil {
- toSerialize["lans"] = o.Lans
+
+ if o.Natgateways != nil {
+ toSerialize["natgateways"] = o.Natgateways
}
+
if o.Networkloadbalancers != nil {
toSerialize["networkloadbalancers"] = o.Networkloadbalancers
}
- if o.Natgateways != nil {
- toSerialize["natgateways"] = o.Natgateways
+
+ if o.Servers != nil {
+ toSerialize["servers"] = o.Servers
}
+
+ if o.Volumes != nil {
+ toSerialize["volumes"] = o.Volumes
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenter.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenter.go
index 45a4e9d7dac..9b53f656c72 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenter.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenter.go
@@ -16,15 +16,15 @@ import (
// Datacenter struct for Datacenter
type Datacenter struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Entities *DataCenterEntities `json:"entities,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *DatacenterProperties `json:"properties"`
- Entities *DataCenterEntities `json:"entities,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewDatacenter instantiates a new Datacenter object
@@ -47,114 +47,114 @@ func NewDatacenterWithDefaults() *Datacenter {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Datacenter) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *Datacenter) GetEntities() *DataCenterEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Datacenter) GetIdOk() (*string, bool) {
+func (o *Datacenter) GetEntitiesOk() (*DataCenterEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *Datacenter) SetId(v string) {
+// SetEntities sets field value
+func (o *Datacenter) SetEntities(v DataCenterEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Datacenter) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *Datacenter) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Datacenter) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Datacenter) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Datacenter) GetTypeOk() (*Type, bool) {
+func (o *Datacenter) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Datacenter) SetType(v Type) {
+// SetHref sets field value
+func (o *Datacenter) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Datacenter) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Datacenter) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Datacenter) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Datacenter) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Datacenter) GetHrefOk() (*string, bool) {
+func (o *Datacenter) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Datacenter) SetHref(v string) {
+// SetId sets field value
+func (o *Datacenter) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Datacenter) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Datacenter) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -162,7 +162,7 @@ func (o *Datacenter) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *Datacenter) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
@@ -200,7 +200,7 @@ func (o *Datacenter) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for DatacenterProperties will be returned
+// If the value is explicit nil, nil is returned
func (o *Datacenter) GetProperties() *DatacenterProperties {
if o == nil {
return nil
@@ -237,38 +237,38 @@ func (o *Datacenter) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for DataCenterEntities will be returned
-func (o *Datacenter) GetEntities() *DataCenterEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Datacenter) GetType() *Type {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Datacenter) GetEntitiesOk() (*DataCenterEntities, bool) {
+func (o *Datacenter) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *Datacenter) SetEntities(v DataCenterEntities) {
+// SetType sets field value
+func (o *Datacenter) SetType(v Type) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *Datacenter) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Datacenter) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -277,24 +277,30 @@ func (o *Datacenter) HasEntities() bool {
func (o Datacenter) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenter_element_metadata.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenter_element_metadata.go
index 3034ac67d30..d0d262ff511 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenter_element_metadata.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenter_element_metadata.go
@@ -17,20 +17,20 @@ import (
// DatacenterElementMetadata struct for DatacenterElementMetadata
type DatacenterElementMetadata struct {
- // Resource's Entity Tag as defined in http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.11 Entity Tag is also added as an 'ETag response header to requests which don't use 'depth' parameter.
- Etag *string `json:"etag,omitempty"`
- // The last time the resource was created.
- CreatedDate *IonosTime
// The user who created the resource.
CreatedBy *string `json:"createdBy,omitempty"`
// The unique ID of the user who created the resource.
CreatedByUserId *string `json:"createdByUserId,omitempty"`
- // The last time the resource was modified.
- LastModifiedDate *IonosTime
+ // The last time the resource was created.
+ CreatedDate *IonosTime
+ // Resource's Entity Tag as defined in http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.11 Entity Tag is also added as an 'ETag response header to requests which don't use 'depth' parameter.
+ Etag *string `json:"etag,omitempty"`
// The user who last modified the resource.
LastModifiedBy *string `json:"lastModifiedBy,omitempty"`
// The unique ID of the user who last modified the resource.
LastModifiedByUserId *string `json:"lastModifiedByUserId,omitempty"`
+ // The last time the resource was modified.
+ LastModifiedDate *IonosTime
// State of the resource. *AVAILABLE* There are no pending modification requests for this item; *BUSY* There is at least one modification request pending and all following requests will be queued; *INACTIVE* Resource has been de-provisioned; *DEPLOYING* Resource state DEPLOYING - relevant for Kubernetes cluster/nodepool; *ACTIVE* Resource state ACTIVE - relevant for Kubernetes cluster/nodepool; *FAILED* Resource state FAILED - relevant for Kubernetes cluster/nodepool; *SUSPENDED* Resource state SUSPENDED - relevant for Kubernetes cluster/nodepool; *FAILED_SUSPENDED* Resource state FAILED_SUSPENDED - relevant for Kubernetes cluster; *UPDATING* Resource state UPDATING - relevant for Kubernetes cluster/nodepool; *FAILED_UPDATING* Resource state FAILED_UPDATING - relevant for Kubernetes cluster/nodepool; *DESTROYING* Resource state DESTROYING - relevant for Kubernetes cluster; *FAILED_DESTROYING* Resource state FAILED_DESTROYING - relevant for Kubernetes cluster/nodepool; *TERMINATED* Resource state TERMINATED - relevant for Kubernetes cluster/nodepool; *HIBERNATING* Resource state HIBERNATING - relevant for Kubernetes cluster/nodepool; *FAILED_HIBERNATING* Resource state FAILED_HIBERNATING - relevant for Kubernetes cluster/nodepool; *MAINTENANCE* Resource state MAINTENANCE - relevant for Kubernetes cluster/nodepool; *FAILED_HIBERNATING* Resource state FAILED_HIBERNATING - relevant for Kubernetes cluster/nodepool.
State *string `json:"state,omitempty"`
}
@@ -53,91 +53,8 @@ func NewDatacenterElementMetadataWithDefaults() *DatacenterElementMetadata {
return &this
}
-// GetEtag returns the Etag field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *DatacenterElementMetadata) GetEtag() *string {
- if o == nil {
- return nil
- }
-
- return o.Etag
-
-}
-
-// GetEtagOk returns a tuple with the Etag field value
-// and a boolean to check if the value has been set.
-// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DatacenterElementMetadata) GetEtagOk() (*string, bool) {
- if o == nil {
- return nil, false
- }
-
- return o.Etag, true
-}
-
-// SetEtag sets field value
-func (o *DatacenterElementMetadata) SetEtag(v string) {
-
- o.Etag = &v
-
-}
-
-// HasEtag returns a boolean if a field has been set.
-func (o *DatacenterElementMetadata) HasEtag() bool {
- if o != nil && o.Etag != nil {
- return true
- }
-
- return false
-}
-
-// GetCreatedDate returns the CreatedDate field value
-// If the value is explicit nil, the zero value for time.Time will be returned
-func (o *DatacenterElementMetadata) GetCreatedDate() *time.Time {
- if o == nil {
- return nil
- }
-
- if o.CreatedDate == nil {
- return nil
- }
- return &o.CreatedDate.Time
-
-}
-
-// GetCreatedDateOk returns a tuple with the CreatedDate field value
-// and a boolean to check if the value has been set.
-// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DatacenterElementMetadata) GetCreatedDateOk() (*time.Time, bool) {
- if o == nil {
- return nil, false
- }
-
- if o.CreatedDate == nil {
- return nil, false
- }
- return &o.CreatedDate.Time, true
-
-}
-
-// SetCreatedDate sets field value
-func (o *DatacenterElementMetadata) SetCreatedDate(v time.Time) {
-
- o.CreatedDate = &IonosTime{v}
-
-}
-
-// HasCreatedDate returns a boolean if a field has been set.
-func (o *DatacenterElementMetadata) HasCreatedDate() bool {
- if o != nil && o.CreatedDate != nil {
- return true
- }
-
- return false
-}
-
// GetCreatedBy returns the CreatedBy field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *DatacenterElementMetadata) GetCreatedBy() *string {
if o == nil {
return nil
@@ -175,7 +92,7 @@ func (o *DatacenterElementMetadata) HasCreatedBy() bool {
}
// GetCreatedByUserId returns the CreatedByUserId field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *DatacenterElementMetadata) GetCreatedByUserId() *string {
if o == nil {
return nil
@@ -212,45 +129,83 @@ func (o *DatacenterElementMetadata) HasCreatedByUserId() bool {
return false
}
-// GetLastModifiedDate returns the LastModifiedDate field value
-// If the value is explicit nil, the zero value for time.Time will be returned
-func (o *DatacenterElementMetadata) GetLastModifiedDate() *time.Time {
+// GetCreatedDate returns the CreatedDate field value
+// If the value is explicit nil, nil is returned
+func (o *DatacenterElementMetadata) GetCreatedDate() *time.Time {
if o == nil {
return nil
}
- if o.LastModifiedDate == nil {
+ if o.CreatedDate == nil {
return nil
}
- return &o.LastModifiedDate.Time
+ return &o.CreatedDate.Time
}
-// GetLastModifiedDateOk returns a tuple with the LastModifiedDate field value
+// GetCreatedDateOk returns a tuple with the CreatedDate field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DatacenterElementMetadata) GetLastModifiedDateOk() (*time.Time, bool) {
+func (o *DatacenterElementMetadata) GetCreatedDateOk() (*time.Time, bool) {
if o == nil {
return nil, false
}
- if o.LastModifiedDate == nil {
+ if o.CreatedDate == nil {
return nil, false
}
- return &o.LastModifiedDate.Time, true
+ return &o.CreatedDate.Time, true
}
-// SetLastModifiedDate sets field value
-func (o *DatacenterElementMetadata) SetLastModifiedDate(v time.Time) {
+// SetCreatedDate sets field value
+func (o *DatacenterElementMetadata) SetCreatedDate(v time.Time) {
- o.LastModifiedDate = &IonosTime{v}
+ o.CreatedDate = &IonosTime{v}
}
-// HasLastModifiedDate returns a boolean if a field has been set.
-func (o *DatacenterElementMetadata) HasLastModifiedDate() bool {
- if o != nil && o.LastModifiedDate != nil {
+// HasCreatedDate returns a boolean if a field has been set.
+func (o *DatacenterElementMetadata) HasCreatedDate() bool {
+ if o != nil && o.CreatedDate != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetEtag returns the Etag field value
+// If the value is explicit nil, nil is returned
+func (o *DatacenterElementMetadata) GetEtag() *string {
+ if o == nil {
+ return nil
+ }
+
+ return o.Etag
+
+}
+
+// GetEtagOk returns a tuple with the Etag field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *DatacenterElementMetadata) GetEtagOk() (*string, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Etag, true
+}
+
+// SetEtag sets field value
+func (o *DatacenterElementMetadata) SetEtag(v string) {
+
+ o.Etag = &v
+
+}
+
+// HasEtag returns a boolean if a field has been set.
+func (o *DatacenterElementMetadata) HasEtag() bool {
+ if o != nil && o.Etag != nil {
return true
}
@@ -258,7 +213,7 @@ func (o *DatacenterElementMetadata) HasLastModifiedDate() bool {
}
// GetLastModifiedBy returns the LastModifiedBy field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *DatacenterElementMetadata) GetLastModifiedBy() *string {
if o == nil {
return nil
@@ -296,7 +251,7 @@ func (o *DatacenterElementMetadata) HasLastModifiedBy() bool {
}
// GetLastModifiedByUserId returns the LastModifiedByUserId field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *DatacenterElementMetadata) GetLastModifiedByUserId() *string {
if o == nil {
return nil
@@ -333,8 +288,53 @@ func (o *DatacenterElementMetadata) HasLastModifiedByUserId() bool {
return false
}
+// GetLastModifiedDate returns the LastModifiedDate field value
+// If the value is explicit nil, nil is returned
+func (o *DatacenterElementMetadata) GetLastModifiedDate() *time.Time {
+ if o == nil {
+ return nil
+ }
+
+ if o.LastModifiedDate == nil {
+ return nil
+ }
+ return &o.LastModifiedDate.Time
+
+}
+
+// GetLastModifiedDateOk returns a tuple with the LastModifiedDate field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *DatacenterElementMetadata) GetLastModifiedDateOk() (*time.Time, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ if o.LastModifiedDate == nil {
+ return nil, false
+ }
+ return &o.LastModifiedDate.Time, true
+
+}
+
+// SetLastModifiedDate sets field value
+func (o *DatacenterElementMetadata) SetLastModifiedDate(v time.Time) {
+
+ o.LastModifiedDate = &IonosTime{v}
+
+}
+
+// HasLastModifiedDate returns a boolean if a field has been set.
+func (o *DatacenterElementMetadata) HasLastModifiedDate() bool {
+ if o != nil && o.LastModifiedDate != nil {
+ return true
+ }
+
+ return false
+}
+
// GetState returns the State field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *DatacenterElementMetadata) GetState() *string {
if o == nil {
return nil
@@ -373,30 +373,38 @@ func (o *DatacenterElementMetadata) HasState() bool {
func (o DatacenterElementMetadata) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Etag != nil {
- toSerialize["etag"] = o.Etag
- }
- if o.CreatedDate != nil {
- toSerialize["createdDate"] = o.CreatedDate
- }
if o.CreatedBy != nil {
toSerialize["createdBy"] = o.CreatedBy
}
+
if o.CreatedByUserId != nil {
toSerialize["createdByUserId"] = o.CreatedByUserId
}
- if o.LastModifiedDate != nil {
- toSerialize["lastModifiedDate"] = o.LastModifiedDate
+
+ if o.CreatedDate != nil {
+ toSerialize["createdDate"] = o.CreatedDate
}
+
+ if o.Etag != nil {
+ toSerialize["etag"] = o.Etag
+ }
+
if o.LastModifiedBy != nil {
toSerialize["lastModifiedBy"] = o.LastModifiedBy
}
+
if o.LastModifiedByUserId != nil {
toSerialize["lastModifiedByUserId"] = o.LastModifiedByUserId
}
+
+ if o.LastModifiedDate != nil {
+ toSerialize["lastModifiedDate"] = o.LastModifiedDate
+ }
+
if o.State != nil {
toSerialize["state"] = o.State
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenter_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenter_properties.go
index 7ea45724220..18e81f828e9 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenter_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenter_properties.go
@@ -16,20 +16,20 @@ import (
// DatacenterProperties struct for DatacenterProperties
type DatacenterProperties struct {
- // The name of the resource.
- Name *string `json:"name,omitempty"`
+ // Array of features and CPU families available in a location
+ CpuArchitecture *[]CpuArchitectureProperties `json:"cpuArchitecture,omitempty"`
// A description for the datacenter, such as staging, production.
Description *string `json:"description,omitempty"`
- // The physical location where the datacenter will be created. This will be where all of your servers live. Property cannot be modified after datacenter creation (disallowed in update requests).
- Location *string `json:"location"`
- // The version of the data center; incremented with every change.
- Version *int32 `json:"version,omitempty"`
// List of features supported by the location where this data center is provisioned.
Features *[]string `json:"features,omitempty"`
+ // The physical location where the datacenter will be created. This will be where all of your servers live. Property cannot be modified after datacenter creation (disallowed in update requests).
+ Location *string `json:"location"`
+ // The name of the resource.
+ Name *string `json:"name,omitempty"`
// Boolean value representing if the data center requires extra protection, such as two-step verification.
SecAuthProtection *bool `json:"secAuthProtection,omitempty"`
- // Array of features and CPU families available in a location
- CpuArchitecture *[]CpuArchitectureProperties `json:"cpuArchitecture,omitempty"`
+ // The version of the data center; incremented with every change.
+ Version *int32 `json:"version,omitempty"`
}
// NewDatacenterProperties instantiates a new DatacenterProperties object
@@ -52,38 +52,38 @@ func NewDatacenterPropertiesWithDefaults() *DatacenterProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *DatacenterProperties) GetName() *string {
+// GetCpuArchitecture returns the CpuArchitecture field value
+// If the value is explicit nil, nil is returned
+func (o *DatacenterProperties) GetCpuArchitecture() *[]CpuArchitectureProperties {
if o == nil {
return nil
}
- return o.Name
+ return o.CpuArchitecture
}
-// GetNameOk returns a tuple with the Name field value
+// GetCpuArchitectureOk returns a tuple with the CpuArchitecture field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DatacenterProperties) GetNameOk() (*string, bool) {
+func (o *DatacenterProperties) GetCpuArchitectureOk() (*[]CpuArchitectureProperties, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.CpuArchitecture, true
}
-// SetName sets field value
-func (o *DatacenterProperties) SetName(v string) {
+// SetCpuArchitecture sets field value
+func (o *DatacenterProperties) SetCpuArchitecture(v []CpuArchitectureProperties) {
- o.Name = &v
+ o.CpuArchitecture = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *DatacenterProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasCpuArchitecture returns a boolean if a field has been set.
+func (o *DatacenterProperties) HasCpuArchitecture() bool {
+ if o != nil && o.CpuArchitecture != nil {
return true
}
@@ -91,7 +91,7 @@ func (o *DatacenterProperties) HasName() bool {
}
// GetDescription returns the Description field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *DatacenterProperties) GetDescription() *string {
if o == nil {
return nil
@@ -128,114 +128,114 @@ func (o *DatacenterProperties) HasDescription() bool {
return false
}
-// GetLocation returns the Location field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *DatacenterProperties) GetLocation() *string {
+// GetFeatures returns the Features field value
+// If the value is explicit nil, nil is returned
+func (o *DatacenterProperties) GetFeatures() *[]string {
if o == nil {
return nil
}
- return o.Location
+ return o.Features
}
-// GetLocationOk returns a tuple with the Location field value
+// GetFeaturesOk returns a tuple with the Features field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DatacenterProperties) GetLocationOk() (*string, bool) {
+func (o *DatacenterProperties) GetFeaturesOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.Location, true
+ return o.Features, true
}
-// SetLocation sets field value
-func (o *DatacenterProperties) SetLocation(v string) {
+// SetFeatures sets field value
+func (o *DatacenterProperties) SetFeatures(v []string) {
- o.Location = &v
+ o.Features = &v
}
-// HasLocation returns a boolean if a field has been set.
-func (o *DatacenterProperties) HasLocation() bool {
- if o != nil && o.Location != nil {
+// HasFeatures returns a boolean if a field has been set.
+func (o *DatacenterProperties) HasFeatures() bool {
+ if o != nil && o.Features != nil {
return true
}
return false
}
-// GetVersion returns the Version field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *DatacenterProperties) GetVersion() *int32 {
+// GetLocation returns the Location field value
+// If the value is explicit nil, nil is returned
+func (o *DatacenterProperties) GetLocation() *string {
if o == nil {
return nil
}
- return o.Version
+ return o.Location
}
-// GetVersionOk returns a tuple with the Version field value
+// GetLocationOk returns a tuple with the Location field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DatacenterProperties) GetVersionOk() (*int32, bool) {
+func (o *DatacenterProperties) GetLocationOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Version, true
+ return o.Location, true
}
-// SetVersion sets field value
-func (o *DatacenterProperties) SetVersion(v int32) {
+// SetLocation sets field value
+func (o *DatacenterProperties) SetLocation(v string) {
- o.Version = &v
+ o.Location = &v
}
-// HasVersion returns a boolean if a field has been set.
-func (o *DatacenterProperties) HasVersion() bool {
- if o != nil && o.Version != nil {
+// HasLocation returns a boolean if a field has been set.
+func (o *DatacenterProperties) HasLocation() bool {
+ if o != nil && o.Location != nil {
return true
}
return false
}
-// GetFeatures returns the Features field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *DatacenterProperties) GetFeatures() *[]string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *DatacenterProperties) GetName() *string {
if o == nil {
return nil
}
- return o.Features
+ return o.Name
}
-// GetFeaturesOk returns a tuple with the Features field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DatacenterProperties) GetFeaturesOk() (*[]string, bool) {
+func (o *DatacenterProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Features, true
+ return o.Name, true
}
-// SetFeatures sets field value
-func (o *DatacenterProperties) SetFeatures(v []string) {
+// SetName sets field value
+func (o *DatacenterProperties) SetName(v string) {
- o.Features = &v
+ o.Name = &v
}
-// HasFeatures returns a boolean if a field has been set.
-func (o *DatacenterProperties) HasFeatures() bool {
- if o != nil && o.Features != nil {
+// HasName returns a boolean if a field has been set.
+func (o *DatacenterProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -243,7 +243,7 @@ func (o *DatacenterProperties) HasFeatures() bool {
}
// GetSecAuthProtection returns the SecAuthProtection field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *DatacenterProperties) GetSecAuthProtection() *bool {
if o == nil {
return nil
@@ -280,38 +280,38 @@ func (o *DatacenterProperties) HasSecAuthProtection() bool {
return false
}
-// GetCpuArchitecture returns the CpuArchitecture field value
-// If the value is explicit nil, the zero value for []CpuArchitectureProperties will be returned
-func (o *DatacenterProperties) GetCpuArchitecture() *[]CpuArchitectureProperties {
+// GetVersion returns the Version field value
+// If the value is explicit nil, nil is returned
+func (o *DatacenterProperties) GetVersion() *int32 {
if o == nil {
return nil
}
- return o.CpuArchitecture
+ return o.Version
}
-// GetCpuArchitectureOk returns a tuple with the CpuArchitecture field value
+// GetVersionOk returns a tuple with the Version field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *DatacenterProperties) GetCpuArchitectureOk() (*[]CpuArchitectureProperties, bool) {
+func (o *DatacenterProperties) GetVersionOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.CpuArchitecture, true
+ return o.Version, true
}
-// SetCpuArchitecture sets field value
-func (o *DatacenterProperties) SetCpuArchitecture(v []CpuArchitectureProperties) {
+// SetVersion sets field value
+func (o *DatacenterProperties) SetVersion(v int32) {
- o.CpuArchitecture = &v
+ o.Version = &v
}
-// HasCpuArchitecture returns a boolean if a field has been set.
-func (o *DatacenterProperties) HasCpuArchitecture() bool {
- if o != nil && o.CpuArchitecture != nil {
+// HasVersion returns a boolean if a field has been set.
+func (o *DatacenterProperties) HasVersion() bool {
+ if o != nil && o.Version != nil {
return true
}
@@ -320,27 +320,34 @@ func (o *DatacenterProperties) HasCpuArchitecture() bool {
func (o DatacenterProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
+ if o.CpuArchitecture != nil {
+ toSerialize["cpuArchitecture"] = o.CpuArchitecture
}
+
if o.Description != nil {
toSerialize["description"] = o.Description
}
+
+ if o.Features != nil {
+ toSerialize["features"] = o.Features
+ }
+
if o.Location != nil {
toSerialize["location"] = o.Location
}
- if o.Version != nil {
- toSerialize["version"] = o.Version
- }
- if o.Features != nil {
- toSerialize["features"] = o.Features
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
}
+
if o.SecAuthProtection != nil {
toSerialize["secAuthProtection"] = o.SecAuthProtection
}
- if o.CpuArchitecture != nil {
- toSerialize["cpuArchitecture"] = o.CpuArchitecture
+
+ if o.Version != nil {
+ toSerialize["version"] = o.Version
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenters.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenters.go
index 28911601f0c..43c00c3c7da 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenters.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_datacenters.go
@@ -16,19 +16,19 @@ import (
// Datacenters struct for Datacenters
type Datacenters struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Datacenter `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewDatacenters instantiates a new Datacenters object
@@ -49,114 +49,114 @@ func NewDatacentersWithDefaults() *Datacenters {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Datacenters) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *Datacenters) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Datacenters) GetIdOk() (*string, bool) {
+func (o *Datacenters) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *Datacenters) SetId(v string) {
+// SetLinks sets field value
+func (o *Datacenters) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Datacenters) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *Datacenters) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Datacenters) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Datacenters) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Datacenters) GetTypeOk() (*Type, bool) {
+func (o *Datacenters) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Datacenters) SetType(v Type) {
+// SetHref sets field value
+func (o *Datacenters) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Datacenters) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Datacenters) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Datacenters) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Datacenters) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Datacenters) GetHrefOk() (*string, bool) {
+func (o *Datacenters) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Datacenters) SetHref(v string) {
+// SetId sets field value
+func (o *Datacenters) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Datacenters) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Datacenters) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *Datacenters) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Datacenter will be returned
+// If the value is explicit nil, nil is returned
func (o *Datacenters) GetItems() *[]Datacenter {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *Datacenters) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Datacenters) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *Datacenters) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Datacenters) GetOffsetOk() (*float32, bool) {
+func (o *Datacenters) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *Datacenters) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *Datacenters) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *Datacenters) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *Datacenters) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Datacenters) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *Datacenters) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Datacenters) GetLimitOk() (*float32, bool) {
+func (o *Datacenters) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *Datacenters) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *Datacenters) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *Datacenters) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *Datacenters) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *Datacenters) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Datacenters) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Datacenters) GetLinksOk() (*PaginationLinks, bool) {
+func (o *Datacenters) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *Datacenters) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *Datacenters) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *Datacenters) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Datacenters) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *Datacenters) HasLinks() bool {
func (o Datacenters) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_error.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_error.go
index a383952b792..d5e52dd39b0 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_error.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_error.go
@@ -40,7 +40,7 @@ func NewErrorWithDefaults() *Error {
}
// GetHttpStatus returns the HttpStatus field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *Error) GetHttpStatus() *int32 {
if o == nil {
return nil
@@ -78,7 +78,7 @@ func (o *Error) HasHttpStatus() bool {
}
// GetMessages returns the Messages field value
-// If the value is explicit nil, the zero value for []ErrorMessage will be returned
+// If the value is explicit nil, nil is returned
func (o *Error) GetMessages() *[]ErrorMessage {
if o == nil {
return nil
@@ -120,9 +120,11 @@ func (o Error) MarshalJSON() ([]byte, error) {
if o.HttpStatus != nil {
toSerialize["httpStatus"] = o.HttpStatus
}
+
if o.Messages != nil {
toSerialize["messages"] = o.Messages
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_error_message.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_error_message.go
index f3044d977df..d567be376c3 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_error_message.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_error_message.go
@@ -41,7 +41,7 @@ func NewErrorMessageWithDefaults() *ErrorMessage {
}
// GetErrorCode returns the ErrorCode field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *ErrorMessage) GetErrorCode() *string {
if o == nil {
return nil
@@ -79,7 +79,7 @@ func (o *ErrorMessage) HasErrorCode() bool {
}
// GetMessage returns the Message field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *ErrorMessage) GetMessage() *string {
if o == nil {
return nil
@@ -121,9 +121,11 @@ func (o ErrorMessage) MarshalJSON() ([]byte, error) {
if o.ErrorCode != nil {
toSerialize["errorCode"] = o.ErrorCode
}
+
if o.Message != nil {
toSerialize["message"] = o.Message
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_firewall_rule.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_firewall_rule.go
index 6b472e4e913..88f0f5ead32 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_firewall_rule.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_firewall_rule.go
@@ -16,14 +16,14 @@ import (
// FirewallRule struct for FirewallRule
type FirewallRule struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *FirewallruleProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewFirewallRule instantiates a new FirewallRule object
@@ -46,190 +46,190 @@ func NewFirewallRuleWithDefaults() *FirewallRule {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FirewallRule) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallRule) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallRule) GetIdOk() (*string, bool) {
+func (o *FirewallRule) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *FirewallRule) SetId(v string) {
+// SetHref sets field value
+func (o *FirewallRule) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *FirewallRule) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *FirewallRule) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *FirewallRule) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallRule) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallRule) GetTypeOk() (*Type, bool) {
+func (o *FirewallRule) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *FirewallRule) SetType(v Type) {
+// SetId sets field value
+func (o *FirewallRule) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *FirewallRule) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *FirewallRule) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FirewallRule) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallRule) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallRule) GetHrefOk() (*string, bool) {
+func (o *FirewallRule) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *FirewallRule) SetHref(v string) {
+// SetMetadata sets field value
+func (o *FirewallRule) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *FirewallRule) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *FirewallRule) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *FirewallRule) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallRule) GetProperties() *FirewallruleProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallRule) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *FirewallRule) GetPropertiesOk() (*FirewallruleProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *FirewallRule) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *FirewallRule) SetProperties(v FirewallruleProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *FirewallRule) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *FirewallRule) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for FirewallruleProperties will be returned
-func (o *FirewallRule) GetProperties() *FirewallruleProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallRule) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallRule) GetPropertiesOk() (*FirewallruleProperties, bool) {
+func (o *FirewallRule) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *FirewallRule) SetProperties(v FirewallruleProperties) {
+// SetType sets field value
+func (o *FirewallRule) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *FirewallRule) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *FirewallRule) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *FirewallRule) HasProperties() bool {
func (o FirewallRule) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_firewall_rules.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_firewall_rules.go
index f3b572931ca..5701dda1200 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_firewall_rules.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_firewall_rules.go
@@ -16,19 +16,19 @@ import (
// FirewallRules struct for FirewallRules
type FirewallRules struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]FirewallRule `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewFirewallRules instantiates a new FirewallRules object
@@ -49,114 +49,114 @@ func NewFirewallRulesWithDefaults() *FirewallRules {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FirewallRules) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallRules) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallRules) GetIdOk() (*string, bool) {
+func (o *FirewallRules) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *FirewallRules) SetId(v string) {
+// SetLinks sets field value
+func (o *FirewallRules) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *FirewallRules) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *FirewallRules) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *FirewallRules) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallRules) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallRules) GetTypeOk() (*Type, bool) {
+func (o *FirewallRules) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *FirewallRules) SetType(v Type) {
+// SetHref sets field value
+func (o *FirewallRules) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *FirewallRules) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *FirewallRules) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FirewallRules) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallRules) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallRules) GetHrefOk() (*string, bool) {
+func (o *FirewallRules) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *FirewallRules) SetHref(v string) {
+// SetId sets field value
+func (o *FirewallRules) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *FirewallRules) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *FirewallRules) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *FirewallRules) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []FirewallRule will be returned
+// If the value is explicit nil, nil is returned
func (o *FirewallRules) GetItems() *[]FirewallRule {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *FirewallRules) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *FirewallRules) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallRules) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallRules) GetOffsetOk() (*float32, bool) {
+func (o *FirewallRules) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *FirewallRules) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *FirewallRules) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *FirewallRules) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *FirewallRules) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *FirewallRules) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallRules) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallRules) GetLimitOk() (*float32, bool) {
+func (o *FirewallRules) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *FirewallRules) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *FirewallRules) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *FirewallRules) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *FirewallRules) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *FirewallRules) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallRules) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallRules) GetLinksOk() (*PaginationLinks, bool) {
+func (o *FirewallRules) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *FirewallRules) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *FirewallRules) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *FirewallRules) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *FirewallRules) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *FirewallRules) HasLinks() bool {
func (o FirewallRules) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_firewallrule_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_firewallrule_properties.go
index 640cd23fb58..0e5de49b3b3 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_firewallrule_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_firewallrule_properties.go
@@ -16,26 +16,32 @@ import (
// FirewallruleProperties struct for FirewallruleProperties
type FirewallruleProperties struct {
+ // Defines the allowed code (from 0 to 254) if protocol ICMP or ICMPv6 is chosen. Value null allows all codes.
+ // to set this field to `nil` in order to be marshalled, the explicit nil address `Nilint32` can be used, or the setter `SetIcmpCodeNil`
+ IcmpCode *int32 `json:"icmpCode,omitempty"`
+ // Defines the allowed type (from 0 to 254) if the protocol ICMP or ICMPv6 is chosen. Value null allows all types.
+ // to set this field to `nil` in order to be marshalled, the explicit nil address `Nilint32` can be used, or the setter `SetIcmpTypeNil`
+ IcmpType *int32 `json:"icmpType,omitempty"`
+ // The IP version for this rule. If sourceIp or targetIp are specified, you can omit this value - the IP version will then be deduced from the IP address(es) used; if you specify it anyway, it must match the specified IP address(es). If neither sourceIp nor targetIp are specified, this rule allows traffic only for the specified IP version. If neither sourceIp, targetIp nor ipVersion are specified, this rule will only allow IPv4 traffic.
+ // to set this field to `nil` in order to be marshalled, the explicit nil address `Nilstring` can be used, or the setter `SetIpVersionNil`
+ IpVersion *string `json:"ipVersion,omitempty"`
// The name of the resource.
Name *string `json:"name,omitempty"`
+ // Defines the end range of the allowed port (from 1 to 65534) if the protocol TCP or UDP is chosen. Leave portRangeStart and portRangeEnd null to allow all ports.
+ PortRangeEnd *int32 `json:"portRangeEnd,omitempty"`
+ // Defines the start range of the allowed port (from 1 to 65534) if protocol TCP or UDP is chosen. Leave portRangeStart and portRangeEnd value null to allow all ports.
+ PortRangeStart *int32 `json:"portRangeStart,omitempty"`
// The protocol for the rule. Property cannot be modified after it is created (disallowed in update requests).
Protocol *string `json:"protocol"`
- // Only traffic originating from the respective MAC address is allowed. Valid format: aa:bb:cc:dd:ee:ff. Value null allows traffic from any MAC address.
- SourceMac *string `json:"sourceMac,omitempty"`
- // The IP version for this rule. If sourceIp or targetIp are specified, you can omit this value - the IP version will then be deduced from the IP address(es) used; if you specify it anyway, it must match the specified IP address(es). If neither sourceIp nor targetIp are specified, this rule allows traffic only for the specified IP version. If neither sourceIp, targetIp nor ipVersion are specified, this rule will only allow IPv4 traffic.
- IpVersion *string `json:"ipVersion,omitempty"`
// Only traffic originating from the respective IP address (or CIDR block) is allowed. Value null allows traffic from any IP address (according to the selected ipVersion).
+ // to set this field to `nil` in order to be marshalled, the explicit nil address `Nilstring` can be used, or the setter `SetSourceIpNil`
SourceIp *string `json:"sourceIp,omitempty"`
+ // Only traffic originating from the respective MAC address is allowed. Valid format: aa:bb:cc:dd:ee:ff. Value null allows traffic from any MAC address.
+ // to set this field to `nil` in order to be marshalled, the explicit nil address `Nilstring` can be used, or the setter `SetSourceMacNil`
+ SourceMac *string `json:"sourceMac,omitempty"`
// If the target NIC has multiple IP addresses, only the traffic directed to the respective IP address (or CIDR block) of the NIC is allowed. Value null allows traffic to any target IP address (according to the selected ipVersion).
+ // to set this field to `nil` in order to be marshalled, the explicit nil address `Nilstring` can be used, or the setter `SetTargetIpNil`
TargetIp *string `json:"targetIp,omitempty"`
- // Defines the allowed code (from 0 to 254) if protocol ICMP or ICMPv6 is chosen. Value null allows all codes.
- IcmpCode *int32 `json:"icmpCode,omitempty"`
- // Defines the allowed type (from 0 to 254) if the protocol ICMP or ICMPv6 is chosen. Value null allows all types.
- IcmpType *int32 `json:"icmpType,omitempty"`
- // Defines the start range of the allowed port (from 1 to 65534) if protocol TCP or UDP is chosen. Leave portRangeStart and portRangeEnd value null to allow all ports.
- PortRangeStart *int32 `json:"portRangeStart,omitempty"`
- // Defines the end range of the allowed port (from 1 to 65534) if the protocol TCP or UDP is chosen. Leave portRangeStart and portRangeEnd null to allow all ports.
- PortRangeEnd *int32 `json:"portRangeEnd,omitempty"`
// The type of the firewall rule. If not specified, the default INGRESS value is used.
Type *string `json:"type,omitempty"`
}
@@ -60,380 +66,410 @@ func NewFirewallrulePropertiesWithDefaults() *FirewallruleProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FirewallruleProperties) GetName() *string {
+// GetIcmpCode returns the IcmpCode field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallruleProperties) GetIcmpCode() *int32 {
if o == nil {
return nil
}
- return o.Name
+ return o.IcmpCode
}
-// GetNameOk returns a tuple with the Name field value
+// GetIcmpCodeOk returns a tuple with the IcmpCode field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallruleProperties) GetNameOk() (*string, bool) {
+func (o *FirewallruleProperties) GetIcmpCodeOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.IcmpCode, true
}
-// SetName sets field value
-func (o *FirewallruleProperties) SetName(v string) {
+// SetIcmpCode sets field value
+func (o *FirewallruleProperties) SetIcmpCode(v int32) {
- o.Name = &v
+ o.IcmpCode = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *FirewallruleProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// sets IcmpCode to the explicit address that will be encoded as nil when marshaled
+func (o *FirewallruleProperties) SetIcmpCodeNil() {
+ o.IcmpCode = &Nilint32
+}
+
+// HasIcmpCode returns a boolean if a field has been set.
+func (o *FirewallruleProperties) HasIcmpCode() bool {
+ if o != nil && o.IcmpCode != nil {
return true
}
return false
}
-// GetProtocol returns the Protocol field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FirewallruleProperties) GetProtocol() *string {
+// GetIcmpType returns the IcmpType field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallruleProperties) GetIcmpType() *int32 {
if o == nil {
return nil
}
- return o.Protocol
+ return o.IcmpType
}
-// GetProtocolOk returns a tuple with the Protocol field value
+// GetIcmpTypeOk returns a tuple with the IcmpType field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallruleProperties) GetProtocolOk() (*string, bool) {
+func (o *FirewallruleProperties) GetIcmpTypeOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Protocol, true
+ return o.IcmpType, true
}
-// SetProtocol sets field value
-func (o *FirewallruleProperties) SetProtocol(v string) {
+// SetIcmpType sets field value
+func (o *FirewallruleProperties) SetIcmpType(v int32) {
- o.Protocol = &v
+ o.IcmpType = &v
}
-// HasProtocol returns a boolean if a field has been set.
-func (o *FirewallruleProperties) HasProtocol() bool {
- if o != nil && o.Protocol != nil {
+// sets IcmpType to the explicit address that will be encoded as nil when marshaled
+func (o *FirewallruleProperties) SetIcmpTypeNil() {
+ o.IcmpType = &Nilint32
+}
+
+// HasIcmpType returns a boolean if a field has been set.
+func (o *FirewallruleProperties) HasIcmpType() bool {
+ if o != nil && o.IcmpType != nil {
return true
}
return false
}
-// GetSourceMac returns the SourceMac field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FirewallruleProperties) GetSourceMac() *string {
+// GetIpVersion returns the IpVersion field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallruleProperties) GetIpVersion() *string {
if o == nil {
return nil
}
- return o.SourceMac
+ return o.IpVersion
}
-// GetSourceMacOk returns a tuple with the SourceMac field value
+// GetIpVersionOk returns a tuple with the IpVersion field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallruleProperties) GetSourceMacOk() (*string, bool) {
+func (o *FirewallruleProperties) GetIpVersionOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.SourceMac, true
+ return o.IpVersion, true
}
-// SetSourceMac sets field value
-func (o *FirewallruleProperties) SetSourceMac(v string) {
+// SetIpVersion sets field value
+func (o *FirewallruleProperties) SetIpVersion(v string) {
- o.SourceMac = &v
+ o.IpVersion = &v
}
-// HasSourceMac returns a boolean if a field has been set.
-func (o *FirewallruleProperties) HasSourceMac() bool {
- if o != nil && o.SourceMac != nil {
+// sets IpVersion to the explicit address that will be encoded as nil when marshaled
+func (o *FirewallruleProperties) SetIpVersionNil() {
+ o.IpVersion = &Nilstring
+}
+
+// HasIpVersion returns a boolean if a field has been set.
+func (o *FirewallruleProperties) HasIpVersion() bool {
+ if o != nil && o.IpVersion != nil {
return true
}
return false
}
-// GetIpVersion returns the IpVersion field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FirewallruleProperties) GetIpVersion() *string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallruleProperties) GetName() *string {
if o == nil {
return nil
}
- return o.IpVersion
+ return o.Name
}
-// GetIpVersionOk returns a tuple with the IpVersion field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallruleProperties) GetIpVersionOk() (*string, bool) {
+func (o *FirewallruleProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.IpVersion, true
+ return o.Name, true
}
-// SetIpVersion sets field value
-func (o *FirewallruleProperties) SetIpVersion(v string) {
+// SetName sets field value
+func (o *FirewallruleProperties) SetName(v string) {
- o.IpVersion = &v
+ o.Name = &v
}
-// HasIpVersion returns a boolean if a field has been set.
-func (o *FirewallruleProperties) HasIpVersion() bool {
- if o != nil && o.IpVersion != nil {
+// HasName returns a boolean if a field has been set.
+func (o *FirewallruleProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetSourceIp returns the SourceIp field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FirewallruleProperties) GetSourceIp() *string {
+// GetPortRangeEnd returns the PortRangeEnd field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallruleProperties) GetPortRangeEnd() *int32 {
if o == nil {
return nil
}
- return o.SourceIp
+ return o.PortRangeEnd
}
-// GetSourceIpOk returns a tuple with the SourceIp field value
+// GetPortRangeEndOk returns a tuple with the PortRangeEnd field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallruleProperties) GetSourceIpOk() (*string, bool) {
+func (o *FirewallruleProperties) GetPortRangeEndOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.SourceIp, true
+ return o.PortRangeEnd, true
}
-// SetSourceIp sets field value
-func (o *FirewallruleProperties) SetSourceIp(v string) {
+// SetPortRangeEnd sets field value
+func (o *FirewallruleProperties) SetPortRangeEnd(v int32) {
- o.SourceIp = &v
+ o.PortRangeEnd = &v
}
-// HasSourceIp returns a boolean if a field has been set.
-func (o *FirewallruleProperties) HasSourceIp() bool {
- if o != nil && o.SourceIp != nil {
+// HasPortRangeEnd returns a boolean if a field has been set.
+func (o *FirewallruleProperties) HasPortRangeEnd() bool {
+ if o != nil && o.PortRangeEnd != nil {
return true
}
return false
}
-// GetTargetIp returns the TargetIp field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FirewallruleProperties) GetTargetIp() *string {
+// GetPortRangeStart returns the PortRangeStart field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallruleProperties) GetPortRangeStart() *int32 {
if o == nil {
return nil
}
- return o.TargetIp
+ return o.PortRangeStart
}
-// GetTargetIpOk returns a tuple with the TargetIp field value
+// GetPortRangeStartOk returns a tuple with the PortRangeStart field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallruleProperties) GetTargetIpOk() (*string, bool) {
+func (o *FirewallruleProperties) GetPortRangeStartOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.TargetIp, true
+ return o.PortRangeStart, true
}
-// SetTargetIp sets field value
-func (o *FirewallruleProperties) SetTargetIp(v string) {
+// SetPortRangeStart sets field value
+func (o *FirewallruleProperties) SetPortRangeStart(v int32) {
- o.TargetIp = &v
+ o.PortRangeStart = &v
}
-// HasTargetIp returns a boolean if a field has been set.
-func (o *FirewallruleProperties) HasTargetIp() bool {
- if o != nil && o.TargetIp != nil {
+// HasPortRangeStart returns a boolean if a field has been set.
+func (o *FirewallruleProperties) HasPortRangeStart() bool {
+ if o != nil && o.PortRangeStart != nil {
return true
}
return false
}
-// GetIcmpCode returns the IcmpCode field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *FirewallruleProperties) GetIcmpCode() *int32 {
+// GetProtocol returns the Protocol field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallruleProperties) GetProtocol() *string {
if o == nil {
return nil
}
- return o.IcmpCode
+ return o.Protocol
}
-// GetIcmpCodeOk returns a tuple with the IcmpCode field value
+// GetProtocolOk returns a tuple with the Protocol field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallruleProperties) GetIcmpCodeOk() (*int32, bool) {
+func (o *FirewallruleProperties) GetProtocolOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.IcmpCode, true
+ return o.Protocol, true
}
-// SetIcmpCode sets field value
-func (o *FirewallruleProperties) SetIcmpCode(v int32) {
+// SetProtocol sets field value
+func (o *FirewallruleProperties) SetProtocol(v string) {
- o.IcmpCode = &v
+ o.Protocol = &v
}
-// HasIcmpCode returns a boolean if a field has been set.
-func (o *FirewallruleProperties) HasIcmpCode() bool {
- if o != nil && o.IcmpCode != nil {
+// HasProtocol returns a boolean if a field has been set.
+func (o *FirewallruleProperties) HasProtocol() bool {
+ if o != nil && o.Protocol != nil {
return true
}
return false
}
-// GetIcmpType returns the IcmpType field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *FirewallruleProperties) GetIcmpType() *int32 {
+// GetSourceIp returns the SourceIp field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallruleProperties) GetSourceIp() *string {
if o == nil {
return nil
}
- return o.IcmpType
+ return o.SourceIp
}
-// GetIcmpTypeOk returns a tuple with the IcmpType field value
+// GetSourceIpOk returns a tuple with the SourceIp field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallruleProperties) GetIcmpTypeOk() (*int32, bool) {
+func (o *FirewallruleProperties) GetSourceIpOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.IcmpType, true
+ return o.SourceIp, true
}
-// SetIcmpType sets field value
-func (o *FirewallruleProperties) SetIcmpType(v int32) {
+// SetSourceIp sets field value
+func (o *FirewallruleProperties) SetSourceIp(v string) {
- o.IcmpType = &v
+ o.SourceIp = &v
}
-// HasIcmpType returns a boolean if a field has been set.
-func (o *FirewallruleProperties) HasIcmpType() bool {
- if o != nil && o.IcmpType != nil {
+// sets SourceIp to the explicit address that will be encoded as nil when marshaled
+func (o *FirewallruleProperties) SetSourceIpNil() {
+ o.SourceIp = &Nilstring
+}
+
+// HasSourceIp returns a boolean if a field has been set.
+func (o *FirewallruleProperties) HasSourceIp() bool {
+ if o != nil && o.SourceIp != nil {
return true
}
return false
}
-// GetPortRangeStart returns the PortRangeStart field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *FirewallruleProperties) GetPortRangeStart() *int32 {
+// GetSourceMac returns the SourceMac field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallruleProperties) GetSourceMac() *string {
if o == nil {
return nil
}
- return o.PortRangeStart
+ return o.SourceMac
}
-// GetPortRangeStartOk returns a tuple with the PortRangeStart field value
+// GetSourceMacOk returns a tuple with the SourceMac field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallruleProperties) GetPortRangeStartOk() (*int32, bool) {
+func (o *FirewallruleProperties) GetSourceMacOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.PortRangeStart, true
+ return o.SourceMac, true
}
-// SetPortRangeStart sets field value
-func (o *FirewallruleProperties) SetPortRangeStart(v int32) {
+// SetSourceMac sets field value
+func (o *FirewallruleProperties) SetSourceMac(v string) {
- o.PortRangeStart = &v
+ o.SourceMac = &v
}
-// HasPortRangeStart returns a boolean if a field has been set.
-func (o *FirewallruleProperties) HasPortRangeStart() bool {
- if o != nil && o.PortRangeStart != nil {
+// sets SourceMac to the explicit address that will be encoded as nil when marshaled
+func (o *FirewallruleProperties) SetSourceMacNil() {
+ o.SourceMac = &Nilstring
+}
+
+// HasSourceMac returns a boolean if a field has been set.
+func (o *FirewallruleProperties) HasSourceMac() bool {
+ if o != nil && o.SourceMac != nil {
return true
}
return false
}
-// GetPortRangeEnd returns the PortRangeEnd field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *FirewallruleProperties) GetPortRangeEnd() *int32 {
+// GetTargetIp returns the TargetIp field value
+// If the value is explicit nil, nil is returned
+func (o *FirewallruleProperties) GetTargetIp() *string {
if o == nil {
return nil
}
- return o.PortRangeEnd
+ return o.TargetIp
}
-// GetPortRangeEndOk returns a tuple with the PortRangeEnd field value
+// GetTargetIpOk returns a tuple with the TargetIp field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FirewallruleProperties) GetPortRangeEndOk() (*int32, bool) {
+func (o *FirewallruleProperties) GetTargetIpOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.PortRangeEnd, true
+ return o.TargetIp, true
}
-// SetPortRangeEnd sets field value
-func (o *FirewallruleProperties) SetPortRangeEnd(v int32) {
+// SetTargetIp sets field value
+func (o *FirewallruleProperties) SetTargetIp(v string) {
- o.PortRangeEnd = &v
+ o.TargetIp = &v
}
-// HasPortRangeEnd returns a boolean if a field has been set.
-func (o *FirewallruleProperties) HasPortRangeEnd() bool {
- if o != nil && o.PortRangeEnd != nil {
+// sets TargetIp to the explicit address that will be encoded as nil when marshaled
+func (o *FirewallruleProperties) SetTargetIpNil() {
+ o.TargetIp = &Nilstring
+}
+
+// HasTargetIp returns a boolean if a field has been set.
+func (o *FirewallruleProperties) HasTargetIp() bool {
+ if o != nil && o.TargetIp != nil {
return true
}
@@ -441,7 +477,7 @@ func (o *FirewallruleProperties) HasPortRangeEnd() bool {
}
// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *FirewallruleProperties) GetType() *string {
if o == nil {
return nil
@@ -480,29 +516,61 @@ func (o *FirewallruleProperties) HasType() bool {
func (o FirewallruleProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
+
+ if o.IcmpCode == &Nilint32 {
+ toSerialize["icmpCode"] = nil
+ } else if o.IcmpCode != nil {
+ toSerialize["icmpCode"] = o.IcmpCode
+ }
+
+ if o.IcmpType == &Nilint32 {
+ toSerialize["icmpType"] = nil
+ } else if o.IcmpType != nil {
+ toSerialize["icmpType"] = o.IcmpType
+ }
+
+ if o.IpVersion == &Nilstring {
+ toSerialize["ipVersion"] = nil
+ } else if o.IpVersion != nil {
+ toSerialize["ipVersion"] = o.IpVersion
+ }
if o.Name != nil {
toSerialize["name"] = o.Name
}
+
+ if o.PortRangeEnd != nil {
+ toSerialize["portRangeEnd"] = o.PortRangeEnd
+ }
+
+ if o.PortRangeStart != nil {
+ toSerialize["portRangeStart"] = o.PortRangeStart
+ }
+
if o.Protocol != nil {
toSerialize["protocol"] = o.Protocol
}
- toSerialize["sourceMac"] = o.SourceMac
- if o.IpVersion != nil {
- toSerialize["ipVersion"] = o.IpVersion
+
+ if o.SourceIp == &Nilstring {
+ toSerialize["sourceIp"] = nil
+ } else if o.SourceIp != nil {
+ toSerialize["sourceIp"] = o.SourceIp
}
- toSerialize["sourceIp"] = o.SourceIp
- toSerialize["targetIp"] = o.TargetIp
- toSerialize["icmpCode"] = o.IcmpCode
- toSerialize["icmpType"] = o.IcmpType
- if o.PortRangeStart != nil {
- toSerialize["portRangeStart"] = o.PortRangeStart
+
+ if o.SourceMac == &Nilstring {
+ toSerialize["sourceMac"] = nil
+ } else if o.SourceMac != nil {
+ toSerialize["sourceMac"] = o.SourceMac
}
- if o.PortRangeEnd != nil {
- toSerialize["portRangeEnd"] = o.PortRangeEnd
+
+ if o.TargetIp == &Nilstring {
+ toSerialize["targetIp"] = nil
+ } else if o.TargetIp != nil {
+ toSerialize["targetIp"] = o.TargetIp
}
if o.Type != nil {
toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_log.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_log.go
index e8d74517f14..6e441240889 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_log.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_log.go
@@ -16,14 +16,14 @@ import (
// FlowLog struct for FlowLog
type FlowLog struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *FlowLogProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewFlowLog instantiates a new FlowLog object
@@ -46,190 +46,190 @@ func NewFlowLogWithDefaults() *FlowLog {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FlowLog) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLog) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLog) GetIdOk() (*string, bool) {
+func (o *FlowLog) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *FlowLog) SetId(v string) {
+// SetHref sets field value
+func (o *FlowLog) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *FlowLog) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *FlowLog) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *FlowLog) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLog) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLog) GetTypeOk() (*Type, bool) {
+func (o *FlowLog) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *FlowLog) SetType(v Type) {
+// SetId sets field value
+func (o *FlowLog) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *FlowLog) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *FlowLog) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FlowLog) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLog) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLog) GetHrefOk() (*string, bool) {
+func (o *FlowLog) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *FlowLog) SetHref(v string) {
+// SetMetadata sets field value
+func (o *FlowLog) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *FlowLog) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *FlowLog) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *FlowLog) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLog) GetProperties() *FlowLogProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLog) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *FlowLog) GetPropertiesOk() (*FlowLogProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *FlowLog) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *FlowLog) SetProperties(v FlowLogProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *FlowLog) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *FlowLog) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for FlowLogProperties will be returned
-func (o *FlowLog) GetProperties() *FlowLogProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLog) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLog) GetPropertiesOk() (*FlowLogProperties, bool) {
+func (o *FlowLog) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *FlowLog) SetProperties(v FlowLogProperties) {
+// SetType sets field value
+func (o *FlowLog) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *FlowLog) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *FlowLog) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *FlowLog) HasProperties() bool {
func (o FlowLog) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_log_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_log_properties.go
index dca17c21480..0f2a3b202c5 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_log_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_log_properties.go
@@ -16,27 +16,27 @@ import (
// FlowLogProperties struct for FlowLogProperties
type FlowLogProperties struct {
- // The resource name.
- Name *string `json:"name"`
// Specifies the traffic action pattern.
Action *string `json:"action"`
- // Specifies the traffic direction pattern.
- Direction *string `json:"direction"`
// The S3 bucket name of an existing IONOS Cloud S3 bucket.
Bucket *string `json:"bucket"`
+ // Specifies the traffic direction pattern.
+ Direction *string `json:"direction"`
+ // The resource name.
+ Name *string `json:"name"`
}
// NewFlowLogProperties instantiates a new FlowLogProperties object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewFlowLogProperties(name string, action string, direction string, bucket string) *FlowLogProperties {
+func NewFlowLogProperties(action string, bucket string, direction string, name string) *FlowLogProperties {
this := FlowLogProperties{}
- this.Name = &name
this.Action = &action
- this.Direction = &direction
this.Bucket = &bucket
+ this.Direction = &direction
+ this.Name = &name
return &this
}
@@ -49,76 +49,76 @@ func NewFlowLogPropertiesWithDefaults() *FlowLogProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FlowLogProperties) GetName() *string {
+// GetAction returns the Action field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogProperties) GetAction() *string {
if o == nil {
return nil
}
- return o.Name
+ return o.Action
}
-// GetNameOk returns a tuple with the Name field value
+// GetActionOk returns a tuple with the Action field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogProperties) GetNameOk() (*string, bool) {
+func (o *FlowLogProperties) GetActionOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.Action, true
}
-// SetName sets field value
-func (o *FlowLogProperties) SetName(v string) {
+// SetAction sets field value
+func (o *FlowLogProperties) SetAction(v string) {
- o.Name = &v
+ o.Action = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *FlowLogProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasAction returns a boolean if a field has been set.
+func (o *FlowLogProperties) HasAction() bool {
+ if o != nil && o.Action != nil {
return true
}
return false
}
-// GetAction returns the Action field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FlowLogProperties) GetAction() *string {
+// GetBucket returns the Bucket field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogProperties) GetBucket() *string {
if o == nil {
return nil
}
- return o.Action
+ return o.Bucket
}
-// GetActionOk returns a tuple with the Action field value
+// GetBucketOk returns a tuple with the Bucket field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogProperties) GetActionOk() (*string, bool) {
+func (o *FlowLogProperties) GetBucketOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Action, true
+ return o.Bucket, true
}
-// SetAction sets field value
-func (o *FlowLogProperties) SetAction(v string) {
+// SetBucket sets field value
+func (o *FlowLogProperties) SetBucket(v string) {
- o.Action = &v
+ o.Bucket = &v
}
-// HasAction returns a boolean if a field has been set.
-func (o *FlowLogProperties) HasAction() bool {
- if o != nil && o.Action != nil {
+// HasBucket returns a boolean if a field has been set.
+func (o *FlowLogProperties) HasBucket() bool {
+ if o != nil && o.Bucket != nil {
return true
}
@@ -126,7 +126,7 @@ func (o *FlowLogProperties) HasAction() bool {
}
// GetDirection returns the Direction field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *FlowLogProperties) GetDirection() *string {
if o == nil {
return nil
@@ -163,38 +163,38 @@ func (o *FlowLogProperties) HasDirection() bool {
return false
}
-// GetBucket returns the Bucket field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FlowLogProperties) GetBucket() *string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogProperties) GetName() *string {
if o == nil {
return nil
}
- return o.Bucket
+ return o.Name
}
-// GetBucketOk returns a tuple with the Bucket field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogProperties) GetBucketOk() (*string, bool) {
+func (o *FlowLogProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Bucket, true
+ return o.Name, true
}
-// SetBucket sets field value
-func (o *FlowLogProperties) SetBucket(v string) {
+// SetName sets field value
+func (o *FlowLogProperties) SetName(v string) {
- o.Bucket = &v
+ o.Name = &v
}
-// HasBucket returns a boolean if a field has been set.
-func (o *FlowLogProperties) HasBucket() bool {
- if o != nil && o.Bucket != nil {
+// HasName returns a boolean if a field has been set.
+func (o *FlowLogProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -203,18 +203,22 @@ func (o *FlowLogProperties) HasBucket() bool {
func (o FlowLogProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
- }
if o.Action != nil {
toSerialize["action"] = o.Action
}
+
+ if o.Bucket != nil {
+ toSerialize["bucket"] = o.Bucket
+ }
+
if o.Direction != nil {
toSerialize["direction"] = o.Direction
}
- if o.Bucket != nil {
- toSerialize["bucket"] = o.Bucket
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_log_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_log_put.go
index 8f9b7f77781..7fe84d71f66 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_log_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_log_put.go
@@ -16,13 +16,13 @@ import (
// FlowLogPut struct for FlowLogPut
type FlowLogPut struct {
+ // URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
- Id *string `json:"id,omitempty"`
+ Id *string `json:"id,omitempty"`
+ Properties *FlowLogProperties `json:"properties"`
// The type of object that has been created.
Type *Type `json:"type,omitempty"`
- // URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
- Properties *FlowLogProperties `json:"properties"`
}
// NewFlowLogPut instantiates a new FlowLogPut object
@@ -45,152 +45,152 @@ func NewFlowLogPutWithDefaults() *FlowLogPut {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FlowLogPut) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogPut) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogPut) GetIdOk() (*string, bool) {
+func (o *FlowLogPut) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *FlowLogPut) SetId(v string) {
+// SetHref sets field value
+func (o *FlowLogPut) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *FlowLogPut) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *FlowLogPut) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *FlowLogPut) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogPut) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogPut) GetTypeOk() (*Type, bool) {
+func (o *FlowLogPut) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *FlowLogPut) SetType(v Type) {
+// SetId sets field value
+func (o *FlowLogPut) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *FlowLogPut) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *FlowLogPut) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FlowLogPut) GetHref() *string {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogPut) GetProperties() *FlowLogProperties {
if o == nil {
return nil
}
- return o.Href
+ return o.Properties
}
-// GetHrefOk returns a tuple with the Href field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogPut) GetHrefOk() (*string, bool) {
+func (o *FlowLogPut) GetPropertiesOk() (*FlowLogProperties, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Properties, true
}
-// SetHref sets field value
-func (o *FlowLogPut) SetHref(v string) {
+// SetProperties sets field value
+func (o *FlowLogPut) SetProperties(v FlowLogProperties) {
- o.Href = &v
+ o.Properties = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *FlowLogPut) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *FlowLogPut) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for FlowLogProperties will be returned
-func (o *FlowLogPut) GetProperties() *FlowLogProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogPut) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogPut) GetPropertiesOk() (*FlowLogProperties, bool) {
+func (o *FlowLogPut) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *FlowLogPut) SetProperties(v FlowLogProperties) {
+// SetType sets field value
+func (o *FlowLogPut) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *FlowLogPut) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *FlowLogPut) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -199,18 +199,22 @@ func (o *FlowLogPut) HasProperties() bool {
func (o FlowLogPut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_logs.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_logs.go
index 48f070e31ce..653d925ab21 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_logs.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_flow_logs.go
@@ -16,19 +16,19 @@ import (
// FlowLogs struct for FlowLogs
type FlowLogs struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// The URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]FlowLog `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewFlowLogs instantiates a new FlowLogs object
@@ -49,114 +49,114 @@ func NewFlowLogsWithDefaults() *FlowLogs {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FlowLogs) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogs) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogs) GetIdOk() (*string, bool) {
+func (o *FlowLogs) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *FlowLogs) SetId(v string) {
+// SetLinks sets field value
+func (o *FlowLogs) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *FlowLogs) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *FlowLogs) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *FlowLogs) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogs) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogs) GetTypeOk() (*Type, bool) {
+func (o *FlowLogs) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *FlowLogs) SetType(v Type) {
+// SetHref sets field value
+func (o *FlowLogs) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *FlowLogs) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *FlowLogs) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *FlowLogs) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogs) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogs) GetHrefOk() (*string, bool) {
+func (o *FlowLogs) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *FlowLogs) SetHref(v string) {
+// SetId sets field value
+func (o *FlowLogs) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *FlowLogs) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *FlowLogs) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *FlowLogs) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []FlowLog will be returned
+// If the value is explicit nil, nil is returned
func (o *FlowLogs) GetItems() *[]FlowLog {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *FlowLogs) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *FlowLogs) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogs) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogs) GetOffsetOk() (*float32, bool) {
+func (o *FlowLogs) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *FlowLogs) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *FlowLogs) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *FlowLogs) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *FlowLogs) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *FlowLogs) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogs) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogs) GetLimitOk() (*float32, bool) {
+func (o *FlowLogs) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *FlowLogs) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *FlowLogs) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *FlowLogs) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *FlowLogs) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *FlowLogs) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *FlowLogs) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *FlowLogs) GetLinksOk() (*PaginationLinks, bool) {
+func (o *FlowLogs) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *FlowLogs) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *FlowLogs) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *FlowLogs) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *FlowLogs) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *FlowLogs) HasLinks() bool {
func (o FlowLogs) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group.go
index a1e9b6781a9..1509dd460de 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group.go
@@ -16,14 +16,14 @@ import (
// Group struct for Group
type Group struct {
+ Entities *GroupEntities `json:"entities,omitempty"`
+ // URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
- Id *string `json:"id,omitempty"`
+ Id *string `json:"id,omitempty"`
+ Properties *GroupProperties `json:"properties"`
// The type of the resource.
Type *Type `json:"type,omitempty"`
- // URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
- Properties *GroupProperties `json:"properties"`
- Entities *GroupEntities `json:"entities,omitempty"`
}
// NewGroup instantiates a new Group object
@@ -46,114 +46,114 @@ func NewGroupWithDefaults() *Group {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Group) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *Group) GetEntities() *GroupEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Group) GetIdOk() (*string, bool) {
+func (o *Group) GetEntitiesOk() (*GroupEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *Group) SetId(v string) {
+// SetEntities sets field value
+func (o *Group) SetEntities(v GroupEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Group) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *Group) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Group) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Group) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Group) GetTypeOk() (*Type, bool) {
+func (o *Group) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Group) SetType(v Type) {
+// SetHref sets field value
+func (o *Group) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Group) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Group) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Group) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Group) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Group) GetHrefOk() (*string, bool) {
+func (o *Group) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Group) SetHref(v string) {
+// SetId sets field value
+func (o *Group) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Group) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Group) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -161,7 +161,7 @@ func (o *Group) HasHref() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for GroupProperties will be returned
+// If the value is explicit nil, nil is returned
func (o *Group) GetProperties() *GroupProperties {
if o == nil {
return nil
@@ -198,38 +198,38 @@ func (o *Group) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for GroupEntities will be returned
-func (o *Group) GetEntities() *GroupEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Group) GetType() *Type {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Group) GetEntitiesOk() (*GroupEntities, bool) {
+func (o *Group) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *Group) SetEntities(v GroupEntities) {
+// SetType sets field value
+func (o *Group) SetType(v Type) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *Group) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Group) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *Group) HasEntities() bool {
func (o Group) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_entities.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_entities.go
index 067e84cac6d..f9e91462267 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_entities.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_entities.go
@@ -16,8 +16,8 @@ import (
// GroupEntities struct for GroupEntities
type GroupEntities struct {
- Users *GroupMembers `json:"users,omitempty"`
Resources *ResourceGroups `json:"resources,omitempty"`
+ Users *GroupMembers `json:"users,omitempty"`
}
// NewGroupEntities instantiates a new GroupEntities object
@@ -38,76 +38,76 @@ func NewGroupEntitiesWithDefaults() *GroupEntities {
return &this
}
-// GetUsers returns the Users field value
-// If the value is explicit nil, the zero value for GroupMembers will be returned
-func (o *GroupEntities) GetUsers() *GroupMembers {
+// GetResources returns the Resources field value
+// If the value is explicit nil, nil is returned
+func (o *GroupEntities) GetResources() *ResourceGroups {
if o == nil {
return nil
}
- return o.Users
+ return o.Resources
}
-// GetUsersOk returns a tuple with the Users field value
+// GetResourcesOk returns a tuple with the Resources field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupEntities) GetUsersOk() (*GroupMembers, bool) {
+func (o *GroupEntities) GetResourcesOk() (*ResourceGroups, bool) {
if o == nil {
return nil, false
}
- return o.Users, true
+ return o.Resources, true
}
-// SetUsers sets field value
-func (o *GroupEntities) SetUsers(v GroupMembers) {
+// SetResources sets field value
+func (o *GroupEntities) SetResources(v ResourceGroups) {
- o.Users = &v
+ o.Resources = &v
}
-// HasUsers returns a boolean if a field has been set.
-func (o *GroupEntities) HasUsers() bool {
- if o != nil && o.Users != nil {
+// HasResources returns a boolean if a field has been set.
+func (o *GroupEntities) HasResources() bool {
+ if o != nil && o.Resources != nil {
return true
}
return false
}
-// GetResources returns the Resources field value
-// If the value is explicit nil, the zero value for ResourceGroups will be returned
-func (o *GroupEntities) GetResources() *ResourceGroups {
+// GetUsers returns the Users field value
+// If the value is explicit nil, nil is returned
+func (o *GroupEntities) GetUsers() *GroupMembers {
if o == nil {
return nil
}
- return o.Resources
+ return o.Users
}
-// GetResourcesOk returns a tuple with the Resources field value
+// GetUsersOk returns a tuple with the Users field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupEntities) GetResourcesOk() (*ResourceGroups, bool) {
+func (o *GroupEntities) GetUsersOk() (*GroupMembers, bool) {
if o == nil {
return nil, false
}
- return o.Resources, true
+ return o.Users, true
}
-// SetResources sets field value
-func (o *GroupEntities) SetResources(v ResourceGroups) {
+// SetUsers sets field value
+func (o *GroupEntities) SetUsers(v GroupMembers) {
- o.Resources = &v
+ o.Users = &v
}
-// HasResources returns a boolean if a field has been set.
-func (o *GroupEntities) HasResources() bool {
- if o != nil && o.Resources != nil {
+// HasUsers returns a boolean if a field has been set.
+func (o *GroupEntities) HasUsers() bool {
+ if o != nil && o.Users != nil {
return true
}
@@ -116,12 +116,14 @@ func (o *GroupEntities) HasResources() bool {
func (o GroupEntities) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Users != nil {
- toSerialize["users"] = o.Users
- }
if o.Resources != nil {
toSerialize["resources"] = o.Resources
}
+
+ if o.Users != nil {
+ toSerialize["users"] = o.Users
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_members.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_members.go
index c38d7c018f7..a4a750e784e 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_members.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_members.go
@@ -16,14 +16,14 @@ import (
// GroupMembers struct for GroupMembers
type GroupMembers struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]User `json:"items,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewGroupMembers instantiates a new GroupMembers object
@@ -44,152 +44,152 @@ func NewGroupMembersWithDefaults() *GroupMembers {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *GroupMembers) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *GroupMembers) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupMembers) GetIdOk() (*string, bool) {
+func (o *GroupMembers) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *GroupMembers) SetId(v string) {
+// SetHref sets field value
+func (o *GroupMembers) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *GroupMembers) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *GroupMembers) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *GroupMembers) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *GroupMembers) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupMembers) GetTypeOk() (*Type, bool) {
+func (o *GroupMembers) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *GroupMembers) SetType(v Type) {
+// SetId sets field value
+func (o *GroupMembers) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *GroupMembers) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *GroupMembers) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *GroupMembers) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *GroupMembers) GetItems() *[]User {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupMembers) GetHrefOk() (*string, bool) {
+func (o *GroupMembers) GetItemsOk() (*[]User, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *GroupMembers) SetHref(v string) {
+// SetItems sets field value
+func (o *GroupMembers) SetItems(v []User) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *GroupMembers) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *GroupMembers) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []User will be returned
-func (o *GroupMembers) GetItems() *[]User {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *GroupMembers) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupMembers) GetItemsOk() (*[]User, bool) {
+func (o *GroupMembers) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *GroupMembers) SetItems(v []User) {
+// SetType sets field value
+func (o *GroupMembers) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *GroupMembers) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *GroupMembers) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *GroupMembers) HasItems() bool {
func (o GroupMembers) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_properties.go
index c4c55d9b17a..d73cb668b84 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_properties.go
@@ -16,40 +16,40 @@ import (
// GroupProperties struct for GroupProperties
type GroupProperties struct {
- // The name of the resource.
- Name *string `json:"name,omitempty"`
- // Create data center privilege.
- CreateDataCenter *bool `json:"createDataCenter,omitempty"`
- // Create snapshot privilege.
- CreateSnapshot *bool `json:"createSnapshot,omitempty"`
- // Reserve IP block privilege.
- ReserveIp *bool `json:"reserveIp,omitempty"`
// Activity log access privilege.
AccessActivityLog *bool `json:"accessActivityLog,omitempty"`
- // Create pcc privilege.
- CreatePcc *bool `json:"createPcc,omitempty"`
- // S3 privilege.
- S3Privilege *bool `json:"s3Privilege,omitempty"`
+ // Privilege for a group to access and manage certificates.
+ AccessAndManageCertificates *bool `json:"accessAndManageCertificates,omitempty"`
+ // Privilege for a group to access and manage dns records.
+ AccessAndManageDns *bool `json:"accessAndManageDns,omitempty"`
+ // Privilege for a group to access and manage monitoring related functionality (access metrics, CRUD on alarms, alarm-actions etc) using Monotoring-as-a-Service (MaaS).
+ AccessAndManageMonitoring *bool `json:"accessAndManageMonitoring,omitempty"`
// Create backup unit privilege.
CreateBackupUnit *bool `json:"createBackupUnit,omitempty"`
+ // Create data center privilege.
+ CreateDataCenter *bool `json:"createDataCenter,omitempty"`
+ // Create Flow Logs privilege.
+ CreateFlowLog *bool `json:"createFlowLog,omitempty"`
// Create internet access privilege.
CreateInternetAccess *bool `json:"createInternetAccess,omitempty"`
// Create Kubernetes cluster privilege.
CreateK8sCluster *bool `json:"createK8sCluster,omitempty"`
- // Create Flow Logs privilege.
- CreateFlowLog *bool `json:"createFlowLog,omitempty"`
- // Privilege for a group to access and manage monitoring related functionality (access metrics, CRUD on alarms, alarm-actions etc) using Monotoring-as-a-Service (MaaS).
- AccessAndManageMonitoring *bool `json:"accessAndManageMonitoring,omitempty"`
- // Privilege for a group to access and manage certificates.
- AccessAndManageCertificates *bool `json:"accessAndManageCertificates,omitempty"`
+ // Create pcc privilege.
+ CreatePcc *bool `json:"createPcc,omitempty"`
+ // Create snapshot privilege.
+ CreateSnapshot *bool `json:"createSnapshot,omitempty"`
// Privilege for a group to manage DBaaS related functionality.
ManageDBaaS *bool `json:"manageDBaaS,omitempty"`
- // Privilege for a group to access and manage dns records.
- AccessAndManageDns *bool `json:"accessAndManageDns,omitempty"`
+ // Privilege for a group to access and manage the Data Platform.
+ ManageDataplatform *bool `json:"manageDataplatform,omitempty"`
// Privilege for group accessing container registry related functionality.
ManageRegistry *bool `json:"manageRegistry,omitempty"`
- // Privilege for a group to access and manage Data Platform.
- ManageDataplatform *bool `json:"manageDataplatform,omitempty"`
+ // The name of the resource.
+ Name *string `json:"name,omitempty"`
+ // Reserve IP block privilege.
+ ReserveIp *bool `json:"reserveIp,omitempty"`
+ // S3 privilege.
+ S3Privilege *bool `json:"s3Privilege,omitempty"`
}
// NewGroupProperties instantiates a new GroupProperties object
@@ -70,304 +70,266 @@ func NewGroupPropertiesWithDefaults() *GroupProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *GroupProperties) GetName() *string {
- if o == nil {
- return nil
- }
-
- return o.Name
-
-}
-
-// GetNameOk returns a tuple with the Name field value
-// and a boolean to check if the value has been set.
-// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetNameOk() (*string, bool) {
- if o == nil {
- return nil, false
- }
-
- return o.Name, true
-}
-
-// SetName sets field value
-func (o *GroupProperties) SetName(v string) {
-
- o.Name = &v
-
-}
-
-// HasName returns a boolean if a field has been set.
-func (o *GroupProperties) HasName() bool {
- if o != nil && o.Name != nil {
- return true
- }
-
- return false
-}
-
-// GetCreateDataCenter returns the CreateDataCenter field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *GroupProperties) GetCreateDataCenter() *bool {
+// GetAccessActivityLog returns the AccessActivityLog field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetAccessActivityLog() *bool {
if o == nil {
return nil
}
- return o.CreateDataCenter
+ return o.AccessActivityLog
}
-// GetCreateDataCenterOk returns a tuple with the CreateDataCenter field value
+// GetAccessActivityLogOk returns a tuple with the AccessActivityLog field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetCreateDataCenterOk() (*bool, bool) {
+func (o *GroupProperties) GetAccessActivityLogOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.CreateDataCenter, true
+ return o.AccessActivityLog, true
}
-// SetCreateDataCenter sets field value
-func (o *GroupProperties) SetCreateDataCenter(v bool) {
+// SetAccessActivityLog sets field value
+func (o *GroupProperties) SetAccessActivityLog(v bool) {
- o.CreateDataCenter = &v
+ o.AccessActivityLog = &v
}
-// HasCreateDataCenter returns a boolean if a field has been set.
-func (o *GroupProperties) HasCreateDataCenter() bool {
- if o != nil && o.CreateDataCenter != nil {
+// HasAccessActivityLog returns a boolean if a field has been set.
+func (o *GroupProperties) HasAccessActivityLog() bool {
+ if o != nil && o.AccessActivityLog != nil {
return true
}
return false
}
-// GetCreateSnapshot returns the CreateSnapshot field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *GroupProperties) GetCreateSnapshot() *bool {
+// GetAccessAndManageCertificates returns the AccessAndManageCertificates field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetAccessAndManageCertificates() *bool {
if o == nil {
return nil
}
- return o.CreateSnapshot
+ return o.AccessAndManageCertificates
}
-// GetCreateSnapshotOk returns a tuple with the CreateSnapshot field value
+// GetAccessAndManageCertificatesOk returns a tuple with the AccessAndManageCertificates field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetCreateSnapshotOk() (*bool, bool) {
+func (o *GroupProperties) GetAccessAndManageCertificatesOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.CreateSnapshot, true
+ return o.AccessAndManageCertificates, true
}
-// SetCreateSnapshot sets field value
-func (o *GroupProperties) SetCreateSnapshot(v bool) {
+// SetAccessAndManageCertificates sets field value
+func (o *GroupProperties) SetAccessAndManageCertificates(v bool) {
- o.CreateSnapshot = &v
+ o.AccessAndManageCertificates = &v
}
-// HasCreateSnapshot returns a boolean if a field has been set.
-func (o *GroupProperties) HasCreateSnapshot() bool {
- if o != nil && o.CreateSnapshot != nil {
+// HasAccessAndManageCertificates returns a boolean if a field has been set.
+func (o *GroupProperties) HasAccessAndManageCertificates() bool {
+ if o != nil && o.AccessAndManageCertificates != nil {
return true
}
return false
}
-// GetReserveIp returns the ReserveIp field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *GroupProperties) GetReserveIp() *bool {
+// GetAccessAndManageDns returns the AccessAndManageDns field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetAccessAndManageDns() *bool {
if o == nil {
return nil
}
- return o.ReserveIp
+ return o.AccessAndManageDns
}
-// GetReserveIpOk returns a tuple with the ReserveIp field value
+// GetAccessAndManageDnsOk returns a tuple with the AccessAndManageDns field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetReserveIpOk() (*bool, bool) {
+func (o *GroupProperties) GetAccessAndManageDnsOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.ReserveIp, true
+ return o.AccessAndManageDns, true
}
-// SetReserveIp sets field value
-func (o *GroupProperties) SetReserveIp(v bool) {
+// SetAccessAndManageDns sets field value
+func (o *GroupProperties) SetAccessAndManageDns(v bool) {
- o.ReserveIp = &v
+ o.AccessAndManageDns = &v
}
-// HasReserveIp returns a boolean if a field has been set.
-func (o *GroupProperties) HasReserveIp() bool {
- if o != nil && o.ReserveIp != nil {
+// HasAccessAndManageDns returns a boolean if a field has been set.
+func (o *GroupProperties) HasAccessAndManageDns() bool {
+ if o != nil && o.AccessAndManageDns != nil {
return true
}
return false
}
-// GetAccessActivityLog returns the AccessActivityLog field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *GroupProperties) GetAccessActivityLog() *bool {
+// GetAccessAndManageMonitoring returns the AccessAndManageMonitoring field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetAccessAndManageMonitoring() *bool {
if o == nil {
return nil
}
- return o.AccessActivityLog
+ return o.AccessAndManageMonitoring
}
-// GetAccessActivityLogOk returns a tuple with the AccessActivityLog field value
+// GetAccessAndManageMonitoringOk returns a tuple with the AccessAndManageMonitoring field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetAccessActivityLogOk() (*bool, bool) {
+func (o *GroupProperties) GetAccessAndManageMonitoringOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.AccessActivityLog, true
+ return o.AccessAndManageMonitoring, true
}
-// SetAccessActivityLog sets field value
-func (o *GroupProperties) SetAccessActivityLog(v bool) {
+// SetAccessAndManageMonitoring sets field value
+func (o *GroupProperties) SetAccessAndManageMonitoring(v bool) {
- o.AccessActivityLog = &v
+ o.AccessAndManageMonitoring = &v
}
-// HasAccessActivityLog returns a boolean if a field has been set.
-func (o *GroupProperties) HasAccessActivityLog() bool {
- if o != nil && o.AccessActivityLog != nil {
+// HasAccessAndManageMonitoring returns a boolean if a field has been set.
+func (o *GroupProperties) HasAccessAndManageMonitoring() bool {
+ if o != nil && o.AccessAndManageMonitoring != nil {
return true
}
return false
}
-// GetCreatePcc returns the CreatePcc field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *GroupProperties) GetCreatePcc() *bool {
+// GetCreateBackupUnit returns the CreateBackupUnit field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetCreateBackupUnit() *bool {
if o == nil {
return nil
}
- return o.CreatePcc
+ return o.CreateBackupUnit
}
-// GetCreatePccOk returns a tuple with the CreatePcc field value
+// GetCreateBackupUnitOk returns a tuple with the CreateBackupUnit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetCreatePccOk() (*bool, bool) {
+func (o *GroupProperties) GetCreateBackupUnitOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.CreatePcc, true
+ return o.CreateBackupUnit, true
}
-// SetCreatePcc sets field value
-func (o *GroupProperties) SetCreatePcc(v bool) {
+// SetCreateBackupUnit sets field value
+func (o *GroupProperties) SetCreateBackupUnit(v bool) {
- o.CreatePcc = &v
+ o.CreateBackupUnit = &v
}
-// HasCreatePcc returns a boolean if a field has been set.
-func (o *GroupProperties) HasCreatePcc() bool {
- if o != nil && o.CreatePcc != nil {
+// HasCreateBackupUnit returns a boolean if a field has been set.
+func (o *GroupProperties) HasCreateBackupUnit() bool {
+ if o != nil && o.CreateBackupUnit != nil {
return true
}
return false
}
-// GetS3Privilege returns the S3Privilege field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *GroupProperties) GetS3Privilege() *bool {
+// GetCreateDataCenter returns the CreateDataCenter field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetCreateDataCenter() *bool {
if o == nil {
return nil
}
- return o.S3Privilege
+ return o.CreateDataCenter
}
-// GetS3PrivilegeOk returns a tuple with the S3Privilege field value
+// GetCreateDataCenterOk returns a tuple with the CreateDataCenter field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetS3PrivilegeOk() (*bool, bool) {
+func (o *GroupProperties) GetCreateDataCenterOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.S3Privilege, true
+ return o.CreateDataCenter, true
}
-// SetS3Privilege sets field value
-func (o *GroupProperties) SetS3Privilege(v bool) {
+// SetCreateDataCenter sets field value
+func (o *GroupProperties) SetCreateDataCenter(v bool) {
- o.S3Privilege = &v
+ o.CreateDataCenter = &v
}
-// HasS3Privilege returns a boolean if a field has been set.
-func (o *GroupProperties) HasS3Privilege() bool {
- if o != nil && o.S3Privilege != nil {
+// HasCreateDataCenter returns a boolean if a field has been set.
+func (o *GroupProperties) HasCreateDataCenter() bool {
+ if o != nil && o.CreateDataCenter != nil {
return true
}
return false
}
-// GetCreateBackupUnit returns the CreateBackupUnit field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *GroupProperties) GetCreateBackupUnit() *bool {
+// GetCreateFlowLog returns the CreateFlowLog field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetCreateFlowLog() *bool {
if o == nil {
return nil
}
- return o.CreateBackupUnit
+ return o.CreateFlowLog
}
-// GetCreateBackupUnitOk returns a tuple with the CreateBackupUnit field value
+// GetCreateFlowLogOk returns a tuple with the CreateFlowLog field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetCreateBackupUnitOk() (*bool, bool) {
+func (o *GroupProperties) GetCreateFlowLogOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.CreateBackupUnit, true
+ return o.CreateFlowLog, true
}
-// SetCreateBackupUnit sets field value
-func (o *GroupProperties) SetCreateBackupUnit(v bool) {
+// SetCreateFlowLog sets field value
+func (o *GroupProperties) SetCreateFlowLog(v bool) {
- o.CreateBackupUnit = &v
+ o.CreateFlowLog = &v
}
-// HasCreateBackupUnit returns a boolean if a field has been set.
-func (o *GroupProperties) HasCreateBackupUnit() bool {
- if o != nil && o.CreateBackupUnit != nil {
+// HasCreateFlowLog returns a boolean if a field has been set.
+func (o *GroupProperties) HasCreateFlowLog() bool {
+ if o != nil && o.CreateFlowLog != nil {
return true
}
@@ -375,7 +337,7 @@ func (o *GroupProperties) HasCreateBackupUnit() bool {
}
// GetCreateInternetAccess returns the CreateInternetAccess field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *GroupProperties) GetCreateInternetAccess() *bool {
if o == nil {
return nil
@@ -413,7 +375,7 @@ func (o *GroupProperties) HasCreateInternetAccess() bool {
}
// GetCreateK8sCluster returns the CreateK8sCluster field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *GroupProperties) GetCreateK8sCluster() *bool {
if o == nil {
return nil
@@ -450,114 +412,76 @@ func (o *GroupProperties) HasCreateK8sCluster() bool {
return false
}
-// GetCreateFlowLog returns the CreateFlowLog field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *GroupProperties) GetCreateFlowLog() *bool {
+// GetCreatePcc returns the CreatePcc field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetCreatePcc() *bool {
if o == nil {
return nil
}
- return o.CreateFlowLog
+ return o.CreatePcc
}
-// GetCreateFlowLogOk returns a tuple with the CreateFlowLog field value
+// GetCreatePccOk returns a tuple with the CreatePcc field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetCreateFlowLogOk() (*bool, bool) {
- if o == nil {
- return nil, false
- }
-
- return o.CreateFlowLog, true
-}
-
-// SetCreateFlowLog sets field value
-func (o *GroupProperties) SetCreateFlowLog(v bool) {
-
- o.CreateFlowLog = &v
-
-}
-
-// HasCreateFlowLog returns a boolean if a field has been set.
-func (o *GroupProperties) HasCreateFlowLog() bool {
- if o != nil && o.CreateFlowLog != nil {
- return true
- }
-
- return false
-}
-
-// GetAccessAndManageMonitoring returns the AccessAndManageMonitoring field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *GroupProperties) GetAccessAndManageMonitoring() *bool {
- if o == nil {
- return nil
- }
-
- return o.AccessAndManageMonitoring
-
-}
-
-// GetAccessAndManageMonitoringOk returns a tuple with the AccessAndManageMonitoring field value
-// and a boolean to check if the value has been set.
-// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetAccessAndManageMonitoringOk() (*bool, bool) {
+func (o *GroupProperties) GetCreatePccOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.AccessAndManageMonitoring, true
+ return o.CreatePcc, true
}
-// SetAccessAndManageMonitoring sets field value
-func (o *GroupProperties) SetAccessAndManageMonitoring(v bool) {
+// SetCreatePcc sets field value
+func (o *GroupProperties) SetCreatePcc(v bool) {
- o.AccessAndManageMonitoring = &v
+ o.CreatePcc = &v
}
-// HasAccessAndManageMonitoring returns a boolean if a field has been set.
-func (o *GroupProperties) HasAccessAndManageMonitoring() bool {
- if o != nil && o.AccessAndManageMonitoring != nil {
+// HasCreatePcc returns a boolean if a field has been set.
+func (o *GroupProperties) HasCreatePcc() bool {
+ if o != nil && o.CreatePcc != nil {
return true
}
return false
}
-// GetAccessAndManageCertificates returns the AccessAndManageCertificates field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *GroupProperties) GetAccessAndManageCertificates() *bool {
+// GetCreateSnapshot returns the CreateSnapshot field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetCreateSnapshot() *bool {
if o == nil {
return nil
}
- return o.AccessAndManageCertificates
+ return o.CreateSnapshot
}
-// GetAccessAndManageCertificatesOk returns a tuple with the AccessAndManageCertificates field value
+// GetCreateSnapshotOk returns a tuple with the CreateSnapshot field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetAccessAndManageCertificatesOk() (*bool, bool) {
+func (o *GroupProperties) GetCreateSnapshotOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.AccessAndManageCertificates, true
+ return o.CreateSnapshot, true
}
-// SetAccessAndManageCertificates sets field value
-func (o *GroupProperties) SetAccessAndManageCertificates(v bool) {
+// SetCreateSnapshot sets field value
+func (o *GroupProperties) SetCreateSnapshot(v bool) {
- o.AccessAndManageCertificates = &v
+ o.CreateSnapshot = &v
}
-// HasAccessAndManageCertificates returns a boolean if a field has been set.
-func (o *GroupProperties) HasAccessAndManageCertificates() bool {
- if o != nil && o.AccessAndManageCertificates != nil {
+// HasCreateSnapshot returns a boolean if a field has been set.
+func (o *GroupProperties) HasCreateSnapshot() bool {
+ if o != nil && o.CreateSnapshot != nil {
return true
}
@@ -565,7 +489,7 @@ func (o *GroupProperties) HasAccessAndManageCertificates() bool {
}
// GetManageDBaaS returns the ManageDBaaS field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *GroupProperties) GetManageDBaaS() *bool {
if o == nil {
return nil
@@ -602,38 +526,38 @@ func (o *GroupProperties) HasManageDBaaS() bool {
return false
}
-// GetAccessAndManageDns returns the AccessAndManageDns field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *GroupProperties) GetAccessAndManageDns() *bool {
+// GetManageDataplatform returns the ManageDataplatform field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetManageDataplatform() *bool {
if o == nil {
return nil
}
- return o.AccessAndManageDns
+ return o.ManageDataplatform
}
-// GetAccessAndManageDnsOk returns a tuple with the AccessAndManageDns field value
+// GetManageDataplatformOk returns a tuple with the ManageDataplatform field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetAccessAndManageDnsOk() (*bool, bool) {
+func (o *GroupProperties) GetManageDataplatformOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.AccessAndManageDns, true
+ return o.ManageDataplatform, true
}
-// SetAccessAndManageDns sets field value
-func (o *GroupProperties) SetAccessAndManageDns(v bool) {
+// SetManageDataplatform sets field value
+func (o *GroupProperties) SetManageDataplatform(v bool) {
- o.AccessAndManageDns = &v
+ o.ManageDataplatform = &v
}
-// HasAccessAndManageDns returns a boolean if a field has been set.
-func (o *GroupProperties) HasAccessAndManageDns() bool {
- if o != nil && o.AccessAndManageDns != nil {
+// HasManageDataplatform returns a boolean if a field has been set.
+func (o *GroupProperties) HasManageDataplatform() bool {
+ if o != nil && o.ManageDataplatform != nil {
return true
}
@@ -641,7 +565,7 @@ func (o *GroupProperties) HasAccessAndManageDns() bool {
}
// GetManageRegistry returns the ManageRegistry field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *GroupProperties) GetManageRegistry() *bool {
if o == nil {
return nil
@@ -678,97 +602,190 @@ func (o *GroupProperties) HasManageRegistry() bool {
return false
}
-// GetManageDataplatform returns the ManageDataplatform field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *GroupProperties) GetManageDataplatform() *bool {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetName() *string {
if o == nil {
return nil
}
- return o.ManageDataplatform
+ return o.Name
}
-// GetManageDataplatformOk returns a tuple with the ManageDataplatform field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupProperties) GetManageDataplatformOk() (*bool, bool) {
+func (o *GroupProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.ManageDataplatform, true
+ return o.Name, true
}
-// SetManageDataplatform sets field value
-func (o *GroupProperties) SetManageDataplatform(v bool) {
+// SetName sets field value
+func (o *GroupProperties) SetName(v string) {
- o.ManageDataplatform = &v
+ o.Name = &v
}
-// HasManageDataplatform returns a boolean if a field has been set.
-func (o *GroupProperties) HasManageDataplatform() bool {
- if o != nil && o.ManageDataplatform != nil {
+// HasName returns a boolean if a field has been set.
+func (o *GroupProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-func (o GroupProperties) MarshalJSON() ([]byte, error) {
- toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
+// GetReserveIp returns the ReserveIp field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetReserveIp() *bool {
+ if o == nil {
+ return nil
}
- if o.CreateDataCenter != nil {
- toSerialize["createDataCenter"] = o.CreateDataCenter
+
+ return o.ReserveIp
+
+}
+
+// GetReserveIpOk returns a tuple with the ReserveIp field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *GroupProperties) GetReserveIpOk() (*bool, bool) {
+ if o == nil {
+ return nil, false
}
- if o.CreateSnapshot != nil {
- toSerialize["createSnapshot"] = o.CreateSnapshot
+
+ return o.ReserveIp, true
+}
+
+// SetReserveIp sets field value
+func (o *GroupProperties) SetReserveIp(v bool) {
+
+ o.ReserveIp = &v
+
+}
+
+// HasReserveIp returns a boolean if a field has been set.
+func (o *GroupProperties) HasReserveIp() bool {
+ if o != nil && o.ReserveIp != nil {
+ return true
}
- if o.ReserveIp != nil {
- toSerialize["reserveIp"] = o.ReserveIp
+
+ return false
+}
+
+// GetS3Privilege returns the S3Privilege field value
+// If the value is explicit nil, nil is returned
+func (o *GroupProperties) GetS3Privilege() *bool {
+ if o == nil {
+ return nil
+ }
+
+ return o.S3Privilege
+
+}
+
+// GetS3PrivilegeOk returns a tuple with the S3Privilege field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *GroupProperties) GetS3PrivilegeOk() (*bool, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.S3Privilege, true
+}
+
+// SetS3Privilege sets field value
+func (o *GroupProperties) SetS3Privilege(v bool) {
+
+ o.S3Privilege = &v
+
+}
+
+// HasS3Privilege returns a boolean if a field has been set.
+func (o *GroupProperties) HasS3Privilege() bool {
+ if o != nil && o.S3Privilege != nil {
+ return true
}
+
+ return false
+}
+
+func (o GroupProperties) MarshalJSON() ([]byte, error) {
+ toSerialize := map[string]interface{}{}
if o.AccessActivityLog != nil {
toSerialize["accessActivityLog"] = o.AccessActivityLog
}
- if o.CreatePcc != nil {
- toSerialize["createPcc"] = o.CreatePcc
+
+ if o.AccessAndManageCertificates != nil {
+ toSerialize["accessAndManageCertificates"] = o.AccessAndManageCertificates
}
- if o.S3Privilege != nil {
- toSerialize["s3Privilege"] = o.S3Privilege
+
+ if o.AccessAndManageDns != nil {
+ toSerialize["accessAndManageDns"] = o.AccessAndManageDns
}
+
+ if o.AccessAndManageMonitoring != nil {
+ toSerialize["accessAndManageMonitoring"] = o.AccessAndManageMonitoring
+ }
+
if o.CreateBackupUnit != nil {
toSerialize["createBackupUnit"] = o.CreateBackupUnit
}
+
+ if o.CreateDataCenter != nil {
+ toSerialize["createDataCenter"] = o.CreateDataCenter
+ }
+
+ if o.CreateFlowLog != nil {
+ toSerialize["createFlowLog"] = o.CreateFlowLog
+ }
+
if o.CreateInternetAccess != nil {
toSerialize["createInternetAccess"] = o.CreateInternetAccess
}
+
if o.CreateK8sCluster != nil {
toSerialize["createK8sCluster"] = o.CreateK8sCluster
}
- if o.CreateFlowLog != nil {
- toSerialize["createFlowLog"] = o.CreateFlowLog
- }
- if o.AccessAndManageMonitoring != nil {
- toSerialize["accessAndManageMonitoring"] = o.AccessAndManageMonitoring
+
+ if o.CreatePcc != nil {
+ toSerialize["createPcc"] = o.CreatePcc
}
- if o.AccessAndManageCertificates != nil {
- toSerialize["accessAndManageCertificates"] = o.AccessAndManageCertificates
+
+ if o.CreateSnapshot != nil {
+ toSerialize["createSnapshot"] = o.CreateSnapshot
}
+
if o.ManageDBaaS != nil {
toSerialize["manageDBaaS"] = o.ManageDBaaS
}
- if o.AccessAndManageDns != nil {
- toSerialize["accessAndManageDns"] = o.AccessAndManageDns
+
+ if o.ManageDataplatform != nil {
+ toSerialize["manageDataplatform"] = o.ManageDataplatform
}
+
if o.ManageRegistry != nil {
toSerialize["manageRegistry"] = o.ManageRegistry
}
- if o.ManageDataplatform != nil {
- toSerialize["manageDataplatform"] = o.ManageDataplatform
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
+ if o.ReserveIp != nil {
+ toSerialize["reserveIp"] = o.ReserveIp
+ }
+
+ if o.S3Privilege != nil {
+ toSerialize["s3Privilege"] = o.S3Privilege
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_share.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_share.go
index a25a874a379..ae84478aa82 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_share.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_share.go
@@ -16,13 +16,13 @@ import (
// GroupShare struct for GroupShare
type GroupShare struct {
+ // URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
- Id *string `json:"id,omitempty"`
+ Id *string `json:"id,omitempty"`
+ Properties *GroupShareProperties `json:"properties"`
// resource as generic type
Type *Type `json:"type,omitempty"`
- // URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
- Properties *GroupShareProperties `json:"properties"`
}
// NewGroupShare instantiates a new GroupShare object
@@ -45,152 +45,152 @@ func NewGroupShareWithDefaults() *GroupShare {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *GroupShare) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *GroupShare) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupShare) GetIdOk() (*string, bool) {
+func (o *GroupShare) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *GroupShare) SetId(v string) {
+// SetHref sets field value
+func (o *GroupShare) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *GroupShare) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *GroupShare) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *GroupShare) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *GroupShare) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupShare) GetTypeOk() (*Type, bool) {
+func (o *GroupShare) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *GroupShare) SetType(v Type) {
+// SetId sets field value
+func (o *GroupShare) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *GroupShare) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *GroupShare) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *GroupShare) GetHref() *string {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *GroupShare) GetProperties() *GroupShareProperties {
if o == nil {
return nil
}
- return o.Href
+ return o.Properties
}
-// GetHrefOk returns a tuple with the Href field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupShare) GetHrefOk() (*string, bool) {
+func (o *GroupShare) GetPropertiesOk() (*GroupShareProperties, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Properties, true
}
-// SetHref sets field value
-func (o *GroupShare) SetHref(v string) {
+// SetProperties sets field value
+func (o *GroupShare) SetProperties(v GroupShareProperties) {
- o.Href = &v
+ o.Properties = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *GroupShare) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *GroupShare) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for GroupShareProperties will be returned
-func (o *GroupShare) GetProperties() *GroupShareProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *GroupShare) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupShare) GetPropertiesOk() (*GroupShareProperties, bool) {
+func (o *GroupShare) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *GroupShare) SetProperties(v GroupShareProperties) {
+// SetType sets field value
+func (o *GroupShare) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *GroupShare) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *GroupShare) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -199,18 +199,22 @@ func (o *GroupShare) HasProperties() bool {
func (o GroupShare) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_share_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_share_properties.go
index 5e356c127b1..1ca06267f7c 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_share_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_share_properties.go
@@ -41,7 +41,7 @@ func NewGroupSharePropertiesWithDefaults() *GroupShareProperties {
}
// GetEditPrivilege returns the EditPrivilege field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *GroupShareProperties) GetEditPrivilege() *bool {
if o == nil {
return nil
@@ -79,7 +79,7 @@ func (o *GroupShareProperties) HasEditPrivilege() bool {
}
// GetSharePrivilege returns the SharePrivilege field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *GroupShareProperties) GetSharePrivilege() *bool {
if o == nil {
return nil
@@ -121,9 +121,11 @@ func (o GroupShareProperties) MarshalJSON() ([]byte, error) {
if o.EditPrivilege != nil {
toSerialize["editPrivilege"] = o.EditPrivilege
}
+
if o.SharePrivilege != nil {
toSerialize["sharePrivilege"] = o.SharePrivilege
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_shares.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_shares.go
index 6735473c872..091da39c5f2 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_shares.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_shares.go
@@ -16,14 +16,14 @@ import (
// GroupShares struct for GroupShares
type GroupShares struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // Share representing groups and resource relationship
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]GroupShare `json:"items,omitempty"`
+ // Share representing groups and resource relationship
+ Type *Type `json:"type,omitempty"`
}
// NewGroupShares instantiates a new GroupShares object
@@ -44,152 +44,152 @@ func NewGroupSharesWithDefaults() *GroupShares {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *GroupShares) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *GroupShares) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupShares) GetIdOk() (*string, bool) {
+func (o *GroupShares) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *GroupShares) SetId(v string) {
+// SetHref sets field value
+func (o *GroupShares) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *GroupShares) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *GroupShares) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *GroupShares) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *GroupShares) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupShares) GetTypeOk() (*Type, bool) {
+func (o *GroupShares) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *GroupShares) SetType(v Type) {
+// SetId sets field value
+func (o *GroupShares) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *GroupShares) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *GroupShares) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *GroupShares) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *GroupShares) GetItems() *[]GroupShare {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupShares) GetHrefOk() (*string, bool) {
+func (o *GroupShares) GetItemsOk() (*[]GroupShare, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *GroupShares) SetHref(v string) {
+// SetItems sets field value
+func (o *GroupShares) SetItems(v []GroupShare) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *GroupShares) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *GroupShares) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []GroupShare will be returned
-func (o *GroupShares) GetItems() *[]GroupShare {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *GroupShares) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupShares) GetItemsOk() (*[]GroupShare, bool) {
+func (o *GroupShares) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *GroupShares) SetItems(v []GroupShare) {
+// SetType sets field value
+func (o *GroupShares) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *GroupShares) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *GroupShares) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *GroupShares) HasItems() bool {
func (o GroupShares) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_users.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_users.go
index a2fb51bc2bb..4a4f075c1ea 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_users.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_group_users.go
@@ -16,14 +16,14 @@ import (
// GroupUsers Collection of the groups the user is a member of.
type GroupUsers struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of the resource.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Group `json:"items,omitempty"`
+ // The type of the resource.
+ Type *Type `json:"type,omitempty"`
}
// NewGroupUsers instantiates a new GroupUsers object
@@ -44,152 +44,152 @@ func NewGroupUsersWithDefaults() *GroupUsers {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *GroupUsers) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *GroupUsers) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupUsers) GetIdOk() (*string, bool) {
+func (o *GroupUsers) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *GroupUsers) SetId(v string) {
+// SetHref sets field value
+func (o *GroupUsers) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *GroupUsers) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *GroupUsers) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *GroupUsers) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *GroupUsers) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupUsers) GetTypeOk() (*Type, bool) {
+func (o *GroupUsers) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *GroupUsers) SetType(v Type) {
+// SetId sets field value
+func (o *GroupUsers) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *GroupUsers) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *GroupUsers) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *GroupUsers) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *GroupUsers) GetItems() *[]Group {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupUsers) GetHrefOk() (*string, bool) {
+func (o *GroupUsers) GetItemsOk() (*[]Group, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *GroupUsers) SetHref(v string) {
+// SetItems sets field value
+func (o *GroupUsers) SetItems(v []Group) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *GroupUsers) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *GroupUsers) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Group will be returned
-func (o *GroupUsers) GetItems() *[]Group {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *GroupUsers) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *GroupUsers) GetItemsOk() (*[]Group, bool) {
+func (o *GroupUsers) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *GroupUsers) SetItems(v []Group) {
+// SetType sets field value
+func (o *GroupUsers) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *GroupUsers) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *GroupUsers) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *GroupUsers) HasItems() bool {
func (o GroupUsers) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_groups.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_groups.go
index 85df0a37de4..578d27c1c90 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_groups.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_groups.go
@@ -16,14 +16,14 @@ import (
// Groups struct for Groups
type Groups struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of the resource.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Group `json:"items,omitempty"`
+ // The type of the resource.
+ Type *Type `json:"type,omitempty"`
}
// NewGroups instantiates a new Groups object
@@ -44,152 +44,152 @@ func NewGroupsWithDefaults() *Groups {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Groups) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Groups) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Groups) GetIdOk() (*string, bool) {
+func (o *Groups) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Groups) SetId(v string) {
+// SetHref sets field value
+func (o *Groups) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Groups) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Groups) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Groups) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Groups) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Groups) GetTypeOk() (*Type, bool) {
+func (o *Groups) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Groups) SetType(v Type) {
+// SetId sets field value
+func (o *Groups) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Groups) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Groups) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Groups) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *Groups) GetItems() *[]Group {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Groups) GetHrefOk() (*string, bool) {
+func (o *Groups) GetItemsOk() (*[]Group, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *Groups) SetHref(v string) {
+// SetItems sets field value
+func (o *Groups) SetItems(v []Group) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Groups) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *Groups) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Group will be returned
-func (o *Groups) GetItems() *[]Group {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Groups) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Groups) GetItemsOk() (*[]Group, bool) {
+func (o *Groups) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *Groups) SetItems(v []Group) {
+// SetType sets field value
+func (o *Groups) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *Groups) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Groups) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *Groups) HasItems() bool {
func (o Groups) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_image.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_image.go
index 747a0e9493c..962c8e2e85c 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_image.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_image.go
@@ -16,14 +16,14 @@ import (
// Image struct for Image
type Image struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *ImageProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewImage instantiates a new Image object
@@ -46,190 +46,190 @@ func NewImageWithDefaults() *Image {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Image) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Image) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Image) GetIdOk() (*string, bool) {
+func (o *Image) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Image) SetId(v string) {
+// SetHref sets field value
+func (o *Image) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Image) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Image) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Image) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Image) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Image) GetTypeOk() (*Type, bool) {
+func (o *Image) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Image) SetType(v Type) {
+// SetId sets field value
+func (o *Image) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Image) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Image) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Image) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *Image) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Image) GetHrefOk() (*string, bool) {
+func (o *Image) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *Image) SetHref(v string) {
+// SetMetadata sets field value
+func (o *Image) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Image) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *Image) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *Image) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *Image) GetProperties() *ImageProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Image) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *Image) GetPropertiesOk() (*ImageProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *Image) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *Image) SetProperties(v ImageProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *Image) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *Image) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for ImageProperties will be returned
-func (o *Image) GetProperties() *ImageProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Image) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Image) GetPropertiesOk() (*ImageProperties, bool) {
+func (o *Image) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *Image) SetProperties(v ImageProperties) {
+// SetType sets field value
+func (o *Image) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *Image) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Image) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *Image) HasProperties() bool {
func (o Image) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_image_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_image_properties.go
index 2ab0f5a65ce..f6059779e40 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_image_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_image_properties.go
@@ -16,44 +16,44 @@ import (
// ImageProperties struct for ImageProperties
type ImageProperties struct {
- // The resource name.
- Name *string `json:"name,omitempty"`
- // Human-readable description.
- Description *string `json:"description,omitempty"`
- // The location of this image/snapshot.
- Location *string `json:"location,omitempty"`
- // The image size in GB.
- Size *float32 `json:"size,omitempty"`
+ // Cloud init compatibility.
+ CloudInit *string `json:"cloudInit,omitempty"`
// Hot-plug capable CPU (no reboot required).
CpuHotPlug *bool `json:"cpuHotPlug,omitempty"`
// Hot-unplug capable CPU (no reboot required).
CpuHotUnplug *bool `json:"cpuHotUnplug,omitempty"`
- // Hot-plug capable RAM (no reboot required).
- RamHotPlug *bool `json:"ramHotPlug,omitempty"`
- // Hot-unplug capable RAM (no reboot required).
- RamHotUnplug *bool `json:"ramHotUnplug,omitempty"`
- // Hot-plug capable NIC (no reboot required).
- NicHotPlug *bool `json:"nicHotPlug,omitempty"`
- // Hot-unplug capable NIC (no reboot required).
- NicHotUnplug *bool `json:"nicHotUnplug,omitempty"`
- // Hot-plug capable Virt-IO drive (no reboot required).
- DiscVirtioHotPlug *bool `json:"discVirtioHotPlug,omitempty"`
- // Hot-unplug capable Virt-IO drive (no reboot required). Not supported with Windows VMs.
- DiscVirtioHotUnplug *bool `json:"discVirtioHotUnplug,omitempty"`
+ // Human-readable description.
+ Description *string `json:"description,omitempty"`
// Hot-plug capable SCSI drive (no reboot required).
DiscScsiHotPlug *bool `json:"discScsiHotPlug,omitempty"`
// Hot-unplug capable SCSI drive (no reboot required). Not supported with Windows VMs.
DiscScsiHotUnplug *bool `json:"discScsiHotUnplug,omitempty"`
- // The OS type of this image.
- LicenceType *string `json:"licenceType"`
+ // Hot-plug capable Virt-IO drive (no reboot required).
+ DiscVirtioHotPlug *bool `json:"discVirtioHotPlug,omitempty"`
+ // Hot-unplug capable Virt-IO drive (no reboot required). Not supported with Windows VMs.
+ DiscVirtioHotUnplug *bool `json:"discVirtioHotUnplug,omitempty"`
+ // List of image aliases mapped for this image
+ ImageAliases *[]string `json:"imageAliases,omitempty"`
// The image type.
ImageType *string `json:"imageType,omitempty"`
+ // The OS type of this image.
+ LicenceType *string `json:"licenceType"`
+ // The location of this image/snapshot.
+ Location *string `json:"location,omitempty"`
+ // The resource name.
+ Name *string `json:"name,omitempty"`
+ // Hot-plug capable NIC (no reboot required).
+ NicHotPlug *bool `json:"nicHotPlug,omitempty"`
+ // Hot-unplug capable NIC (no reboot required).
+ NicHotUnplug *bool `json:"nicHotUnplug,omitempty"`
// Indicates whether the image is part of a public repository.
Public *bool `json:"public,omitempty"`
- // List of image aliases mapped for this image
- ImageAliases *[]string `json:"imageAliases,omitempty"`
- // Cloud init compatibility.
- CloudInit *string `json:"cloudInit,omitempty"`
+ // Hot-plug capable RAM (no reboot required).
+ RamHotPlug *bool `json:"ramHotPlug,omitempty"`
+ // Hot-unplug capable RAM (no reboot required).
+ RamHotUnplug *bool `json:"ramHotUnplug,omitempty"`
+ // The image size in GB.
+ Size *float32 `json:"size,omitempty"`
}
// NewImageProperties instantiates a new ImageProperties object
@@ -76,722 +76,722 @@ func NewImagePropertiesWithDefaults() *ImageProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ImageProperties) GetName() *string {
+// GetCloudInit returns the CloudInit field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetCloudInit() *string {
if o == nil {
return nil
}
- return o.Name
+ return o.CloudInit
}
-// GetNameOk returns a tuple with the Name field value
+// GetCloudInitOk returns a tuple with the CloudInit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetNameOk() (*string, bool) {
+func (o *ImageProperties) GetCloudInitOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.CloudInit, true
}
-// SetName sets field value
-func (o *ImageProperties) SetName(v string) {
+// SetCloudInit sets field value
+func (o *ImageProperties) SetCloudInit(v string) {
- o.Name = &v
+ o.CloudInit = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *ImageProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasCloudInit returns a boolean if a field has been set.
+func (o *ImageProperties) HasCloudInit() bool {
+ if o != nil && o.CloudInit != nil {
return true
}
return false
}
-// GetDescription returns the Description field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ImageProperties) GetDescription() *string {
+// GetCpuHotPlug returns the CpuHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetCpuHotPlug() *bool {
if o == nil {
return nil
}
- return o.Description
+ return o.CpuHotPlug
}
-// GetDescriptionOk returns a tuple with the Description field value
+// GetCpuHotPlugOk returns a tuple with the CpuHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetDescriptionOk() (*string, bool) {
+func (o *ImageProperties) GetCpuHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Description, true
+ return o.CpuHotPlug, true
}
-// SetDescription sets field value
-func (o *ImageProperties) SetDescription(v string) {
+// SetCpuHotPlug sets field value
+func (o *ImageProperties) SetCpuHotPlug(v bool) {
- o.Description = &v
+ o.CpuHotPlug = &v
}
-// HasDescription returns a boolean if a field has been set.
-func (o *ImageProperties) HasDescription() bool {
- if o != nil && o.Description != nil {
+// HasCpuHotPlug returns a boolean if a field has been set.
+func (o *ImageProperties) HasCpuHotPlug() bool {
+ if o != nil && o.CpuHotPlug != nil {
return true
}
return false
}
-// GetLocation returns the Location field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ImageProperties) GetLocation() *string {
+// GetCpuHotUnplug returns the CpuHotUnplug field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetCpuHotUnplug() *bool {
if o == nil {
return nil
}
- return o.Location
+ return o.CpuHotUnplug
}
-// GetLocationOk returns a tuple with the Location field value
+// GetCpuHotUnplugOk returns a tuple with the CpuHotUnplug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetLocationOk() (*string, bool) {
+func (o *ImageProperties) GetCpuHotUnplugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Location, true
+ return o.CpuHotUnplug, true
}
-// SetLocation sets field value
-func (o *ImageProperties) SetLocation(v string) {
+// SetCpuHotUnplug sets field value
+func (o *ImageProperties) SetCpuHotUnplug(v bool) {
- o.Location = &v
+ o.CpuHotUnplug = &v
}
-// HasLocation returns a boolean if a field has been set.
-func (o *ImageProperties) HasLocation() bool {
- if o != nil && o.Location != nil {
+// HasCpuHotUnplug returns a boolean if a field has been set.
+func (o *ImageProperties) HasCpuHotUnplug() bool {
+ if o != nil && o.CpuHotUnplug != nil {
return true
}
return false
}
-// GetSize returns the Size field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *ImageProperties) GetSize() *float32 {
+// GetDescription returns the Description field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetDescription() *string {
if o == nil {
return nil
}
- return o.Size
+ return o.Description
}
-// GetSizeOk returns a tuple with the Size field value
+// GetDescriptionOk returns a tuple with the Description field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetSizeOk() (*float32, bool) {
+func (o *ImageProperties) GetDescriptionOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Size, true
+ return o.Description, true
}
-// SetSize sets field value
-func (o *ImageProperties) SetSize(v float32) {
+// SetDescription sets field value
+func (o *ImageProperties) SetDescription(v string) {
- o.Size = &v
+ o.Description = &v
}
-// HasSize returns a boolean if a field has been set.
-func (o *ImageProperties) HasSize() bool {
- if o != nil && o.Size != nil {
+// HasDescription returns a boolean if a field has been set.
+func (o *ImageProperties) HasDescription() bool {
+ if o != nil && o.Description != nil {
return true
}
return false
}
-// GetCpuHotPlug returns the CpuHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *ImageProperties) GetCpuHotPlug() *bool {
+// GetDiscScsiHotPlug returns the DiscScsiHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetDiscScsiHotPlug() *bool {
if o == nil {
return nil
}
- return o.CpuHotPlug
+ return o.DiscScsiHotPlug
}
-// GetCpuHotPlugOk returns a tuple with the CpuHotPlug field value
+// GetDiscScsiHotPlugOk returns a tuple with the DiscScsiHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetCpuHotPlugOk() (*bool, bool) {
+func (o *ImageProperties) GetDiscScsiHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.CpuHotPlug, true
+ return o.DiscScsiHotPlug, true
}
-// SetCpuHotPlug sets field value
-func (o *ImageProperties) SetCpuHotPlug(v bool) {
+// SetDiscScsiHotPlug sets field value
+func (o *ImageProperties) SetDiscScsiHotPlug(v bool) {
- o.CpuHotPlug = &v
+ o.DiscScsiHotPlug = &v
}
-// HasCpuHotPlug returns a boolean if a field has been set.
-func (o *ImageProperties) HasCpuHotPlug() bool {
- if o != nil && o.CpuHotPlug != nil {
+// HasDiscScsiHotPlug returns a boolean if a field has been set.
+func (o *ImageProperties) HasDiscScsiHotPlug() bool {
+ if o != nil && o.DiscScsiHotPlug != nil {
return true
}
return false
}
-// GetCpuHotUnplug returns the CpuHotUnplug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *ImageProperties) GetCpuHotUnplug() *bool {
+// GetDiscScsiHotUnplug returns the DiscScsiHotUnplug field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetDiscScsiHotUnplug() *bool {
if o == nil {
return nil
}
- return o.CpuHotUnplug
+ return o.DiscScsiHotUnplug
}
-// GetCpuHotUnplugOk returns a tuple with the CpuHotUnplug field value
+// GetDiscScsiHotUnplugOk returns a tuple with the DiscScsiHotUnplug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetCpuHotUnplugOk() (*bool, bool) {
+func (o *ImageProperties) GetDiscScsiHotUnplugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.CpuHotUnplug, true
+ return o.DiscScsiHotUnplug, true
}
-// SetCpuHotUnplug sets field value
-func (o *ImageProperties) SetCpuHotUnplug(v bool) {
+// SetDiscScsiHotUnplug sets field value
+func (o *ImageProperties) SetDiscScsiHotUnplug(v bool) {
- o.CpuHotUnplug = &v
+ o.DiscScsiHotUnplug = &v
}
-// HasCpuHotUnplug returns a boolean if a field has been set.
-func (o *ImageProperties) HasCpuHotUnplug() bool {
- if o != nil && o.CpuHotUnplug != nil {
+// HasDiscScsiHotUnplug returns a boolean if a field has been set.
+func (o *ImageProperties) HasDiscScsiHotUnplug() bool {
+ if o != nil && o.DiscScsiHotUnplug != nil {
return true
}
return false
}
-// GetRamHotPlug returns the RamHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *ImageProperties) GetRamHotPlug() *bool {
+// GetDiscVirtioHotPlug returns the DiscVirtioHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetDiscVirtioHotPlug() *bool {
if o == nil {
return nil
}
- return o.RamHotPlug
+ return o.DiscVirtioHotPlug
}
-// GetRamHotPlugOk returns a tuple with the RamHotPlug field value
+// GetDiscVirtioHotPlugOk returns a tuple with the DiscVirtioHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetRamHotPlugOk() (*bool, bool) {
+func (o *ImageProperties) GetDiscVirtioHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.RamHotPlug, true
+ return o.DiscVirtioHotPlug, true
}
-// SetRamHotPlug sets field value
-func (o *ImageProperties) SetRamHotPlug(v bool) {
+// SetDiscVirtioHotPlug sets field value
+func (o *ImageProperties) SetDiscVirtioHotPlug(v bool) {
- o.RamHotPlug = &v
+ o.DiscVirtioHotPlug = &v
}
-// HasRamHotPlug returns a boolean if a field has been set.
-func (o *ImageProperties) HasRamHotPlug() bool {
- if o != nil && o.RamHotPlug != nil {
+// HasDiscVirtioHotPlug returns a boolean if a field has been set.
+func (o *ImageProperties) HasDiscVirtioHotPlug() bool {
+ if o != nil && o.DiscVirtioHotPlug != nil {
return true
}
return false
}
-// GetRamHotUnplug returns the RamHotUnplug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *ImageProperties) GetRamHotUnplug() *bool {
+// GetDiscVirtioHotUnplug returns the DiscVirtioHotUnplug field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetDiscVirtioHotUnplug() *bool {
if o == nil {
return nil
}
- return o.RamHotUnplug
+ return o.DiscVirtioHotUnplug
}
-// GetRamHotUnplugOk returns a tuple with the RamHotUnplug field value
+// GetDiscVirtioHotUnplugOk returns a tuple with the DiscVirtioHotUnplug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetRamHotUnplugOk() (*bool, bool) {
+func (o *ImageProperties) GetDiscVirtioHotUnplugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.RamHotUnplug, true
+ return o.DiscVirtioHotUnplug, true
}
-// SetRamHotUnplug sets field value
-func (o *ImageProperties) SetRamHotUnplug(v bool) {
+// SetDiscVirtioHotUnplug sets field value
+func (o *ImageProperties) SetDiscVirtioHotUnplug(v bool) {
- o.RamHotUnplug = &v
+ o.DiscVirtioHotUnplug = &v
}
-// HasRamHotUnplug returns a boolean if a field has been set.
-func (o *ImageProperties) HasRamHotUnplug() bool {
- if o != nil && o.RamHotUnplug != nil {
+// HasDiscVirtioHotUnplug returns a boolean if a field has been set.
+func (o *ImageProperties) HasDiscVirtioHotUnplug() bool {
+ if o != nil && o.DiscVirtioHotUnplug != nil {
return true
}
return false
}
-// GetNicHotPlug returns the NicHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *ImageProperties) GetNicHotPlug() *bool {
+// GetImageAliases returns the ImageAliases field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetImageAliases() *[]string {
if o == nil {
return nil
}
- return o.NicHotPlug
+ return o.ImageAliases
}
-// GetNicHotPlugOk returns a tuple with the NicHotPlug field value
+// GetImageAliasesOk returns a tuple with the ImageAliases field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetNicHotPlugOk() (*bool, bool) {
+func (o *ImageProperties) GetImageAliasesOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.NicHotPlug, true
+ return o.ImageAliases, true
}
-// SetNicHotPlug sets field value
-func (o *ImageProperties) SetNicHotPlug(v bool) {
+// SetImageAliases sets field value
+func (o *ImageProperties) SetImageAliases(v []string) {
- o.NicHotPlug = &v
+ o.ImageAliases = &v
}
-// HasNicHotPlug returns a boolean if a field has been set.
-func (o *ImageProperties) HasNicHotPlug() bool {
- if o != nil && o.NicHotPlug != nil {
+// HasImageAliases returns a boolean if a field has been set.
+func (o *ImageProperties) HasImageAliases() bool {
+ if o != nil && o.ImageAliases != nil {
return true
}
return false
}
-// GetNicHotUnplug returns the NicHotUnplug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *ImageProperties) GetNicHotUnplug() *bool {
+// GetImageType returns the ImageType field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetImageType() *string {
if o == nil {
return nil
}
- return o.NicHotUnplug
+ return o.ImageType
}
-// GetNicHotUnplugOk returns a tuple with the NicHotUnplug field value
+// GetImageTypeOk returns a tuple with the ImageType field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetNicHotUnplugOk() (*bool, bool) {
+func (o *ImageProperties) GetImageTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.NicHotUnplug, true
+ return o.ImageType, true
}
-// SetNicHotUnplug sets field value
-func (o *ImageProperties) SetNicHotUnplug(v bool) {
+// SetImageType sets field value
+func (o *ImageProperties) SetImageType(v string) {
- o.NicHotUnplug = &v
+ o.ImageType = &v
}
-// HasNicHotUnplug returns a boolean if a field has been set.
-func (o *ImageProperties) HasNicHotUnplug() bool {
- if o != nil && o.NicHotUnplug != nil {
+// HasImageType returns a boolean if a field has been set.
+func (o *ImageProperties) HasImageType() bool {
+ if o != nil && o.ImageType != nil {
return true
}
return false
}
-// GetDiscVirtioHotPlug returns the DiscVirtioHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *ImageProperties) GetDiscVirtioHotPlug() *bool {
+// GetLicenceType returns the LicenceType field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetLicenceType() *string {
if o == nil {
return nil
}
- return o.DiscVirtioHotPlug
+ return o.LicenceType
}
-// GetDiscVirtioHotPlugOk returns a tuple with the DiscVirtioHotPlug field value
+// GetLicenceTypeOk returns a tuple with the LicenceType field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetDiscVirtioHotPlugOk() (*bool, bool) {
+func (o *ImageProperties) GetLicenceTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.DiscVirtioHotPlug, true
+ return o.LicenceType, true
}
-// SetDiscVirtioHotPlug sets field value
-func (o *ImageProperties) SetDiscVirtioHotPlug(v bool) {
+// SetLicenceType sets field value
+func (o *ImageProperties) SetLicenceType(v string) {
- o.DiscVirtioHotPlug = &v
+ o.LicenceType = &v
}
-// HasDiscVirtioHotPlug returns a boolean if a field has been set.
-func (o *ImageProperties) HasDiscVirtioHotPlug() bool {
- if o != nil && o.DiscVirtioHotPlug != nil {
+// HasLicenceType returns a boolean if a field has been set.
+func (o *ImageProperties) HasLicenceType() bool {
+ if o != nil && o.LicenceType != nil {
return true
}
return false
}
-// GetDiscVirtioHotUnplug returns the DiscVirtioHotUnplug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *ImageProperties) GetDiscVirtioHotUnplug() *bool {
+// GetLocation returns the Location field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetLocation() *string {
if o == nil {
return nil
}
- return o.DiscVirtioHotUnplug
+ return o.Location
}
-// GetDiscVirtioHotUnplugOk returns a tuple with the DiscVirtioHotUnplug field value
+// GetLocationOk returns a tuple with the Location field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetDiscVirtioHotUnplugOk() (*bool, bool) {
+func (o *ImageProperties) GetLocationOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.DiscVirtioHotUnplug, true
+ return o.Location, true
}
-// SetDiscVirtioHotUnplug sets field value
-func (o *ImageProperties) SetDiscVirtioHotUnplug(v bool) {
+// SetLocation sets field value
+func (o *ImageProperties) SetLocation(v string) {
- o.DiscVirtioHotUnplug = &v
+ o.Location = &v
}
-// HasDiscVirtioHotUnplug returns a boolean if a field has been set.
-func (o *ImageProperties) HasDiscVirtioHotUnplug() bool {
- if o != nil && o.DiscVirtioHotUnplug != nil {
+// HasLocation returns a boolean if a field has been set.
+func (o *ImageProperties) HasLocation() bool {
+ if o != nil && o.Location != nil {
return true
}
return false
}
-// GetDiscScsiHotPlug returns the DiscScsiHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *ImageProperties) GetDiscScsiHotPlug() *bool {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetName() *string {
if o == nil {
return nil
}
- return o.DiscScsiHotPlug
+ return o.Name
}
-// GetDiscScsiHotPlugOk returns a tuple with the DiscScsiHotPlug field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetDiscScsiHotPlugOk() (*bool, bool) {
+func (o *ImageProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.DiscScsiHotPlug, true
+ return o.Name, true
}
-// SetDiscScsiHotPlug sets field value
-func (o *ImageProperties) SetDiscScsiHotPlug(v bool) {
+// SetName sets field value
+func (o *ImageProperties) SetName(v string) {
- o.DiscScsiHotPlug = &v
+ o.Name = &v
}
-// HasDiscScsiHotPlug returns a boolean if a field has been set.
-func (o *ImageProperties) HasDiscScsiHotPlug() bool {
- if o != nil && o.DiscScsiHotPlug != nil {
+// HasName returns a boolean if a field has been set.
+func (o *ImageProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetDiscScsiHotUnplug returns the DiscScsiHotUnplug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *ImageProperties) GetDiscScsiHotUnplug() *bool {
+// GetNicHotPlug returns the NicHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetNicHotPlug() *bool {
if o == nil {
return nil
}
- return o.DiscScsiHotUnplug
+ return o.NicHotPlug
}
-// GetDiscScsiHotUnplugOk returns a tuple with the DiscScsiHotUnplug field value
+// GetNicHotPlugOk returns a tuple with the NicHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetDiscScsiHotUnplugOk() (*bool, bool) {
+func (o *ImageProperties) GetNicHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.DiscScsiHotUnplug, true
+ return o.NicHotPlug, true
}
-// SetDiscScsiHotUnplug sets field value
-func (o *ImageProperties) SetDiscScsiHotUnplug(v bool) {
+// SetNicHotPlug sets field value
+func (o *ImageProperties) SetNicHotPlug(v bool) {
- o.DiscScsiHotUnplug = &v
+ o.NicHotPlug = &v
}
-// HasDiscScsiHotUnplug returns a boolean if a field has been set.
-func (o *ImageProperties) HasDiscScsiHotUnplug() bool {
- if o != nil && o.DiscScsiHotUnplug != nil {
+// HasNicHotPlug returns a boolean if a field has been set.
+func (o *ImageProperties) HasNicHotPlug() bool {
+ if o != nil && o.NicHotPlug != nil {
return true
}
return false
}
-// GetLicenceType returns the LicenceType field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ImageProperties) GetLicenceType() *string {
+// GetNicHotUnplug returns the NicHotUnplug field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetNicHotUnplug() *bool {
if o == nil {
return nil
}
- return o.LicenceType
+ return o.NicHotUnplug
}
-// GetLicenceTypeOk returns a tuple with the LicenceType field value
+// GetNicHotUnplugOk returns a tuple with the NicHotUnplug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetLicenceTypeOk() (*string, bool) {
+func (o *ImageProperties) GetNicHotUnplugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.LicenceType, true
+ return o.NicHotUnplug, true
}
-// SetLicenceType sets field value
-func (o *ImageProperties) SetLicenceType(v string) {
+// SetNicHotUnplug sets field value
+func (o *ImageProperties) SetNicHotUnplug(v bool) {
- o.LicenceType = &v
+ o.NicHotUnplug = &v
}
-// HasLicenceType returns a boolean if a field has been set.
-func (o *ImageProperties) HasLicenceType() bool {
- if o != nil && o.LicenceType != nil {
+// HasNicHotUnplug returns a boolean if a field has been set.
+func (o *ImageProperties) HasNicHotUnplug() bool {
+ if o != nil && o.NicHotUnplug != nil {
return true
}
return false
}
-// GetImageType returns the ImageType field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ImageProperties) GetImageType() *string {
+// GetPublic returns the Public field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetPublic() *bool {
if o == nil {
return nil
}
- return o.ImageType
+ return o.Public
}
-// GetImageTypeOk returns a tuple with the ImageType field value
+// GetPublicOk returns a tuple with the Public field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetImageTypeOk() (*string, bool) {
+func (o *ImageProperties) GetPublicOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.ImageType, true
+ return o.Public, true
}
-// SetImageType sets field value
-func (o *ImageProperties) SetImageType(v string) {
+// SetPublic sets field value
+func (o *ImageProperties) SetPublic(v bool) {
- o.ImageType = &v
+ o.Public = &v
}
-// HasImageType returns a boolean if a field has been set.
-func (o *ImageProperties) HasImageType() bool {
- if o != nil && o.ImageType != nil {
+// HasPublic returns a boolean if a field has been set.
+func (o *ImageProperties) HasPublic() bool {
+ if o != nil && o.Public != nil {
return true
}
return false
}
-// GetPublic returns the Public field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *ImageProperties) GetPublic() *bool {
+// GetRamHotPlug returns the RamHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetRamHotPlug() *bool {
if o == nil {
return nil
}
- return o.Public
+ return o.RamHotPlug
}
-// GetPublicOk returns a tuple with the Public field value
+// GetRamHotPlugOk returns a tuple with the RamHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetPublicOk() (*bool, bool) {
+func (o *ImageProperties) GetRamHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Public, true
+ return o.RamHotPlug, true
}
-// SetPublic sets field value
-func (o *ImageProperties) SetPublic(v bool) {
+// SetRamHotPlug sets field value
+func (o *ImageProperties) SetRamHotPlug(v bool) {
- o.Public = &v
+ o.RamHotPlug = &v
}
-// HasPublic returns a boolean if a field has been set.
-func (o *ImageProperties) HasPublic() bool {
- if o != nil && o.Public != nil {
+// HasRamHotPlug returns a boolean if a field has been set.
+func (o *ImageProperties) HasRamHotPlug() bool {
+ if o != nil && o.RamHotPlug != nil {
return true
}
return false
}
-// GetImageAliases returns the ImageAliases field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *ImageProperties) GetImageAliases() *[]string {
+// GetRamHotUnplug returns the RamHotUnplug field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetRamHotUnplug() *bool {
if o == nil {
return nil
}
- return o.ImageAliases
+ return o.RamHotUnplug
}
-// GetImageAliasesOk returns a tuple with the ImageAliases field value
+// GetRamHotUnplugOk returns a tuple with the RamHotUnplug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetImageAliasesOk() (*[]string, bool) {
+func (o *ImageProperties) GetRamHotUnplugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.ImageAliases, true
+ return o.RamHotUnplug, true
}
-// SetImageAliases sets field value
-func (o *ImageProperties) SetImageAliases(v []string) {
+// SetRamHotUnplug sets field value
+func (o *ImageProperties) SetRamHotUnplug(v bool) {
- o.ImageAliases = &v
+ o.RamHotUnplug = &v
}
-// HasImageAliases returns a boolean if a field has been set.
-func (o *ImageProperties) HasImageAliases() bool {
- if o != nil && o.ImageAliases != nil {
+// HasRamHotUnplug returns a boolean if a field has been set.
+func (o *ImageProperties) HasRamHotUnplug() bool {
+ if o != nil && o.RamHotUnplug != nil {
return true
}
return false
}
-// GetCloudInit returns the CloudInit field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ImageProperties) GetCloudInit() *string {
+// GetSize returns the Size field value
+// If the value is explicit nil, nil is returned
+func (o *ImageProperties) GetSize() *float32 {
if o == nil {
return nil
}
- return o.CloudInit
+ return o.Size
}
-// GetCloudInitOk returns a tuple with the CloudInit field value
+// GetSizeOk returns a tuple with the Size field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ImageProperties) GetCloudInitOk() (*string, bool) {
+func (o *ImageProperties) GetSizeOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.CloudInit, true
+ return o.Size, true
}
-// SetCloudInit sets field value
-func (o *ImageProperties) SetCloudInit(v string) {
+// SetSize sets field value
+func (o *ImageProperties) SetSize(v float32) {
- o.CloudInit = &v
+ o.Size = &v
}
-// HasCloudInit returns a boolean if a field has been set.
-func (o *ImageProperties) HasCloudInit() bool {
- if o != nil && o.CloudInit != nil {
+// HasSize returns a boolean if a field has been set.
+func (o *ImageProperties) HasSize() bool {
+ if o != nil && o.Size != nil {
return true
}
@@ -800,63 +800,82 @@ func (o *ImageProperties) HasCloudInit() bool {
func (o ImageProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
- }
- if o.Description != nil {
- toSerialize["description"] = o.Description
- }
- if o.Location != nil {
- toSerialize["location"] = o.Location
- }
- if o.Size != nil {
- toSerialize["size"] = o.Size
+ if o.CloudInit != nil {
+ toSerialize["cloudInit"] = o.CloudInit
}
+
if o.CpuHotPlug != nil {
toSerialize["cpuHotPlug"] = o.CpuHotPlug
}
+
if o.CpuHotUnplug != nil {
toSerialize["cpuHotUnplug"] = o.CpuHotUnplug
}
- if o.RamHotPlug != nil {
- toSerialize["ramHotPlug"] = o.RamHotPlug
- }
- if o.RamHotUnplug != nil {
- toSerialize["ramHotUnplug"] = o.RamHotUnplug
+
+ if o.Description != nil {
+ toSerialize["description"] = o.Description
}
- if o.NicHotPlug != nil {
- toSerialize["nicHotPlug"] = o.NicHotPlug
+
+ if o.DiscScsiHotPlug != nil {
+ toSerialize["discScsiHotPlug"] = o.DiscScsiHotPlug
}
- if o.NicHotUnplug != nil {
- toSerialize["nicHotUnplug"] = o.NicHotUnplug
+
+ if o.DiscScsiHotUnplug != nil {
+ toSerialize["discScsiHotUnplug"] = o.DiscScsiHotUnplug
}
+
if o.DiscVirtioHotPlug != nil {
toSerialize["discVirtioHotPlug"] = o.DiscVirtioHotPlug
}
+
if o.DiscVirtioHotUnplug != nil {
toSerialize["discVirtioHotUnplug"] = o.DiscVirtioHotUnplug
}
- if o.DiscScsiHotPlug != nil {
- toSerialize["discScsiHotPlug"] = o.DiscScsiHotPlug
+
+ if o.ImageAliases != nil {
+ toSerialize["imageAliases"] = o.ImageAliases
}
- if o.DiscScsiHotUnplug != nil {
- toSerialize["discScsiHotUnplug"] = o.DiscScsiHotUnplug
+
+ if o.ImageType != nil {
+ toSerialize["imageType"] = o.ImageType
}
+
if o.LicenceType != nil {
toSerialize["licenceType"] = o.LicenceType
}
- if o.ImageType != nil {
- toSerialize["imageType"] = o.ImageType
+
+ if o.Location != nil {
+ toSerialize["location"] = o.Location
+ }
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
+ if o.NicHotPlug != nil {
+ toSerialize["nicHotPlug"] = o.NicHotPlug
}
+
+ if o.NicHotUnplug != nil {
+ toSerialize["nicHotUnplug"] = o.NicHotUnplug
+ }
+
if o.Public != nil {
toSerialize["public"] = o.Public
}
- if o.ImageAliases != nil {
- toSerialize["imageAliases"] = o.ImageAliases
+
+ if o.RamHotPlug != nil {
+ toSerialize["ramHotPlug"] = o.RamHotPlug
}
- if o.CloudInit != nil {
- toSerialize["cloudInit"] = o.CloudInit
+
+ if o.RamHotUnplug != nil {
+ toSerialize["ramHotUnplug"] = o.RamHotUnplug
}
+
+ if o.Size != nil {
+ toSerialize["size"] = o.Size
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_images.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_images.go
index ff496fb196f..1cec4020e6e 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_images.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_images.go
@@ -16,14 +16,14 @@ import (
// Images struct for Images
type Images struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// The URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Image `json:"items,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewImages instantiates a new Images object
@@ -44,152 +44,152 @@ func NewImagesWithDefaults() *Images {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Images) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Images) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Images) GetIdOk() (*string, bool) {
+func (o *Images) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Images) SetId(v string) {
+// SetHref sets field value
+func (o *Images) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Images) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Images) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Images) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Images) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Images) GetTypeOk() (*Type, bool) {
+func (o *Images) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Images) SetType(v Type) {
+// SetId sets field value
+func (o *Images) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Images) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Images) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Images) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *Images) GetItems() *[]Image {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Images) GetHrefOk() (*string, bool) {
+func (o *Images) GetItemsOk() (*[]Image, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *Images) SetHref(v string) {
+// SetItems sets field value
+func (o *Images) SetItems(v []Image) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Images) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *Images) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Image will be returned
-func (o *Images) GetItems() *[]Image {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Images) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Images) GetItemsOk() (*[]Image, bool) {
+func (o *Images) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *Images) SetItems(v []Image) {
+// SetType sets field value
+func (o *Images) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *Images) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Images) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *Images) HasItems() bool {
func (o Images) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_info.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_info.go
index 19f4a146768..2ada276b579 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_info.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_info.go
@@ -43,7 +43,7 @@ func NewInfoWithDefaults() *Info {
}
// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *Info) GetHref() *string {
if o == nil {
return nil
@@ -81,7 +81,7 @@ func (o *Info) HasHref() bool {
}
// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *Info) GetName() *string {
if o == nil {
return nil
@@ -119,7 +119,7 @@ func (o *Info) HasName() bool {
}
// GetVersion returns the Version field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *Info) GetVersion() *string {
if o == nil {
return nil
@@ -161,12 +161,15 @@ func (o Info) MarshalJSON() ([]byte, error) {
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
if o.Name != nil {
toSerialize["name"] = o.Name
}
+
if o.Version != nil {
toSerialize["version"] = o.Version
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_block.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_block.go
index af07f6fb18f..c7e16a0f215 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_block.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_block.go
@@ -16,14 +16,14 @@ import (
// IpBlock struct for IpBlock
type IpBlock struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *IpBlockProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewIpBlock instantiates a new IpBlock object
@@ -46,190 +46,190 @@ func NewIpBlockWithDefaults() *IpBlock {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpBlock) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlock) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlock) GetIdOk() (*string, bool) {
+func (o *IpBlock) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *IpBlock) SetId(v string) {
+// SetHref sets field value
+func (o *IpBlock) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *IpBlock) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *IpBlock) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *IpBlock) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlock) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlock) GetTypeOk() (*Type, bool) {
+func (o *IpBlock) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *IpBlock) SetType(v Type) {
+// SetId sets field value
+func (o *IpBlock) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *IpBlock) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *IpBlock) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpBlock) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlock) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlock) GetHrefOk() (*string, bool) {
+func (o *IpBlock) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *IpBlock) SetHref(v string) {
+// SetMetadata sets field value
+func (o *IpBlock) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *IpBlock) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *IpBlock) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *IpBlock) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlock) GetProperties() *IpBlockProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlock) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *IpBlock) GetPropertiesOk() (*IpBlockProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *IpBlock) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *IpBlock) SetProperties(v IpBlockProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *IpBlock) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *IpBlock) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for IpBlockProperties will be returned
-func (o *IpBlock) GetProperties() *IpBlockProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlock) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlock) GetPropertiesOk() (*IpBlockProperties, bool) {
+func (o *IpBlock) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *IpBlock) SetProperties(v IpBlockProperties) {
+// SetType sets field value
+func (o *IpBlock) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *IpBlock) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *IpBlock) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *IpBlock) HasProperties() bool {
func (o IpBlock) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_block_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_block_properties.go
index 4f732b53b2a..19c3ed75734 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_block_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_block_properties.go
@@ -16,16 +16,16 @@ import (
// IpBlockProperties struct for IpBlockProperties
type IpBlockProperties struct {
+ // Read-Only attribute. Lists consumption detail for an individual IP
+ IpConsumers *[]IpConsumer `json:"ipConsumers,omitempty"`
// Collection of IPs, associated with the IP Block.
Ips *[]string `json:"ips,omitempty"`
// Location of that IP block. Property cannot be modified after it is created (disallowed in update requests).
Location *string `json:"location"`
- // The size of the IP block.
- Size *int32 `json:"size"`
// The name of the resource.
Name *string `json:"name,omitempty"`
- // Read-Only attribute. Lists consumption detail for an individual IP
- IpConsumers *[]IpConsumer `json:"ipConsumers,omitempty"`
+ // The size of the IP block.
+ Size *int32 `json:"size"`
}
// NewIpBlockProperties instantiates a new IpBlockProperties object
@@ -49,114 +49,114 @@ func NewIpBlockPropertiesWithDefaults() *IpBlockProperties {
return &this
}
-// GetIps returns the Ips field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *IpBlockProperties) GetIps() *[]string {
+// GetIpConsumers returns the IpConsumers field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlockProperties) GetIpConsumers() *[]IpConsumer {
if o == nil {
return nil
}
- return o.Ips
+ return o.IpConsumers
}
-// GetIpsOk returns a tuple with the Ips field value
+// GetIpConsumersOk returns a tuple with the IpConsumers field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlockProperties) GetIpsOk() (*[]string, bool) {
+func (o *IpBlockProperties) GetIpConsumersOk() (*[]IpConsumer, bool) {
if o == nil {
return nil, false
}
- return o.Ips, true
+ return o.IpConsumers, true
}
-// SetIps sets field value
-func (o *IpBlockProperties) SetIps(v []string) {
+// SetIpConsumers sets field value
+func (o *IpBlockProperties) SetIpConsumers(v []IpConsumer) {
- o.Ips = &v
+ o.IpConsumers = &v
}
-// HasIps returns a boolean if a field has been set.
-func (o *IpBlockProperties) HasIps() bool {
- if o != nil && o.Ips != nil {
+// HasIpConsumers returns a boolean if a field has been set.
+func (o *IpBlockProperties) HasIpConsumers() bool {
+ if o != nil && o.IpConsumers != nil {
return true
}
return false
}
-// GetLocation returns the Location field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpBlockProperties) GetLocation() *string {
+// GetIps returns the Ips field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlockProperties) GetIps() *[]string {
if o == nil {
return nil
}
- return o.Location
+ return o.Ips
}
-// GetLocationOk returns a tuple with the Location field value
+// GetIpsOk returns a tuple with the Ips field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlockProperties) GetLocationOk() (*string, bool) {
+func (o *IpBlockProperties) GetIpsOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.Location, true
+ return o.Ips, true
}
-// SetLocation sets field value
-func (o *IpBlockProperties) SetLocation(v string) {
+// SetIps sets field value
+func (o *IpBlockProperties) SetIps(v []string) {
- o.Location = &v
+ o.Ips = &v
}
-// HasLocation returns a boolean if a field has been set.
-func (o *IpBlockProperties) HasLocation() bool {
- if o != nil && o.Location != nil {
+// HasIps returns a boolean if a field has been set.
+func (o *IpBlockProperties) HasIps() bool {
+ if o != nil && o.Ips != nil {
return true
}
return false
}
-// GetSize returns the Size field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *IpBlockProperties) GetSize() *int32 {
+// GetLocation returns the Location field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlockProperties) GetLocation() *string {
if o == nil {
return nil
}
- return o.Size
+ return o.Location
}
-// GetSizeOk returns a tuple with the Size field value
+// GetLocationOk returns a tuple with the Location field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlockProperties) GetSizeOk() (*int32, bool) {
+func (o *IpBlockProperties) GetLocationOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Size, true
+ return o.Location, true
}
-// SetSize sets field value
-func (o *IpBlockProperties) SetSize(v int32) {
+// SetLocation sets field value
+func (o *IpBlockProperties) SetLocation(v string) {
- o.Size = &v
+ o.Location = &v
}
-// HasSize returns a boolean if a field has been set.
-func (o *IpBlockProperties) HasSize() bool {
- if o != nil && o.Size != nil {
+// HasLocation returns a boolean if a field has been set.
+func (o *IpBlockProperties) HasLocation() bool {
+ if o != nil && o.Location != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *IpBlockProperties) HasSize() bool {
}
// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *IpBlockProperties) GetName() *string {
if o == nil {
return nil
@@ -201,38 +201,38 @@ func (o *IpBlockProperties) HasName() bool {
return false
}
-// GetIpConsumers returns the IpConsumers field value
-// If the value is explicit nil, the zero value for []IpConsumer will be returned
-func (o *IpBlockProperties) GetIpConsumers() *[]IpConsumer {
+// GetSize returns the Size field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlockProperties) GetSize() *int32 {
if o == nil {
return nil
}
- return o.IpConsumers
+ return o.Size
}
-// GetIpConsumersOk returns a tuple with the IpConsumers field value
+// GetSizeOk returns a tuple with the Size field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlockProperties) GetIpConsumersOk() (*[]IpConsumer, bool) {
+func (o *IpBlockProperties) GetSizeOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.IpConsumers, true
+ return o.Size, true
}
-// SetIpConsumers sets field value
-func (o *IpBlockProperties) SetIpConsumers(v []IpConsumer) {
+// SetSize sets field value
+func (o *IpBlockProperties) SetSize(v int32) {
- o.IpConsumers = &v
+ o.Size = &v
}
-// HasIpConsumers returns a boolean if a field has been set.
-func (o *IpBlockProperties) HasIpConsumers() bool {
- if o != nil && o.IpConsumers != nil {
+// HasSize returns a boolean if a field has been set.
+func (o *IpBlockProperties) HasSize() bool {
+ if o != nil && o.Size != nil {
return true
}
@@ -241,21 +241,26 @@ func (o *IpBlockProperties) HasIpConsumers() bool {
func (o IpBlockProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
+ if o.IpConsumers != nil {
+ toSerialize["ipConsumers"] = o.IpConsumers
+ }
+
if o.Ips != nil {
toSerialize["ips"] = o.Ips
}
+
if o.Location != nil {
toSerialize["location"] = o.Location
}
- if o.Size != nil {
- toSerialize["size"] = o.Size
- }
+
if o.Name != nil {
toSerialize["name"] = o.Name
}
- if o.IpConsumers != nil {
- toSerialize["ipConsumers"] = o.IpConsumers
+
+ if o.Size != nil {
+ toSerialize["size"] = o.Size
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_blocks.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_blocks.go
index 010dc17fea0..117235c82c8 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_blocks.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_blocks.go
@@ -16,19 +16,19 @@ import (
// IpBlocks struct for IpBlocks
type IpBlocks struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]IpBlock `json:"items,omitempty"`
+ // The limit, specified in the request (if not specified, the endpoint's default pagination limit is used).
+ Limit *float32 `json:"limit,omitempty"`
// The offset, specified in the request (if not is specified, 0 is used by default).
Offset *float32 `json:"offset,omitempty"`
- // The limit, specified in the request (if not specified, the endpoint's default pagination limit is used).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewIpBlocks instantiates a new IpBlocks object
@@ -49,114 +49,114 @@ func NewIpBlocksWithDefaults() *IpBlocks {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpBlocks) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlocks) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlocks) GetIdOk() (*string, bool) {
+func (o *IpBlocks) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *IpBlocks) SetId(v string) {
+// SetLinks sets field value
+func (o *IpBlocks) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *IpBlocks) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *IpBlocks) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *IpBlocks) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlocks) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlocks) GetTypeOk() (*Type, bool) {
+func (o *IpBlocks) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *IpBlocks) SetType(v Type) {
+// SetHref sets field value
+func (o *IpBlocks) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *IpBlocks) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *IpBlocks) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpBlocks) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlocks) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlocks) GetHrefOk() (*string, bool) {
+func (o *IpBlocks) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *IpBlocks) SetHref(v string) {
+// SetId sets field value
+func (o *IpBlocks) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *IpBlocks) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *IpBlocks) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *IpBlocks) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []IpBlock will be returned
+// If the value is explicit nil, nil is returned
func (o *IpBlocks) GetItems() *[]IpBlock {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *IpBlocks) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *IpBlocks) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlocks) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlocks) GetOffsetOk() (*float32, bool) {
+func (o *IpBlocks) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *IpBlocks) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *IpBlocks) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *IpBlocks) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *IpBlocks) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *IpBlocks) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlocks) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlocks) GetLimitOk() (*float32, bool) {
+func (o *IpBlocks) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *IpBlocks) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *IpBlocks) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *IpBlocks) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *IpBlocks) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *IpBlocks) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *IpBlocks) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpBlocks) GetLinksOk() (*PaginationLinks, bool) {
+func (o *IpBlocks) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *IpBlocks) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *IpBlocks) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *IpBlocks) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *IpBlocks) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *IpBlocks) HasLinks() bool {
func (o IpBlocks) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_consumer.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_consumer.go
index a0e9e55c6d7..e405979fe2b 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_consumer.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_consumer.go
@@ -16,15 +16,15 @@ import (
// IpConsumer struct for IpConsumer
type IpConsumer struct {
+ DatacenterId *string `json:"datacenterId,omitempty"`
+ DatacenterName *string `json:"datacenterName,omitempty"`
Ip *string `json:"ip,omitempty"`
+ K8sClusterUuid *string `json:"k8sClusterUuid,omitempty"`
+ K8sNodePoolUuid *string `json:"k8sNodePoolUuid,omitempty"`
Mac *string `json:"mac,omitempty"`
NicId *string `json:"nicId,omitempty"`
ServerId *string `json:"serverId,omitempty"`
ServerName *string `json:"serverName,omitempty"`
- DatacenterId *string `json:"datacenterId,omitempty"`
- DatacenterName *string `json:"datacenterName,omitempty"`
- K8sNodePoolUuid *string `json:"k8sNodePoolUuid,omitempty"`
- K8sClusterUuid *string `json:"k8sClusterUuid,omitempty"`
}
// NewIpConsumer instantiates a new IpConsumer object
@@ -45,342 +45,342 @@ func NewIpConsumerWithDefaults() *IpConsumer {
return &this
}
-// GetIp returns the Ip field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpConsumer) GetIp() *string {
+// GetDatacenterId returns the DatacenterId field value
+// If the value is explicit nil, nil is returned
+func (o *IpConsumer) GetDatacenterId() *string {
if o == nil {
return nil
}
- return o.Ip
+ return o.DatacenterId
}
-// GetIpOk returns a tuple with the Ip field value
+// GetDatacenterIdOk returns a tuple with the DatacenterId field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpConsumer) GetIpOk() (*string, bool) {
+func (o *IpConsumer) GetDatacenterIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Ip, true
+ return o.DatacenterId, true
}
-// SetIp sets field value
-func (o *IpConsumer) SetIp(v string) {
+// SetDatacenterId sets field value
+func (o *IpConsumer) SetDatacenterId(v string) {
- o.Ip = &v
+ o.DatacenterId = &v
}
-// HasIp returns a boolean if a field has been set.
-func (o *IpConsumer) HasIp() bool {
- if o != nil && o.Ip != nil {
+// HasDatacenterId returns a boolean if a field has been set.
+func (o *IpConsumer) HasDatacenterId() bool {
+ if o != nil && o.DatacenterId != nil {
return true
}
return false
}
-// GetMac returns the Mac field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpConsumer) GetMac() *string {
+// GetDatacenterName returns the DatacenterName field value
+// If the value is explicit nil, nil is returned
+func (o *IpConsumer) GetDatacenterName() *string {
if o == nil {
return nil
}
- return o.Mac
+ return o.DatacenterName
}
-// GetMacOk returns a tuple with the Mac field value
+// GetDatacenterNameOk returns a tuple with the DatacenterName field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpConsumer) GetMacOk() (*string, bool) {
+func (o *IpConsumer) GetDatacenterNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Mac, true
+ return o.DatacenterName, true
}
-// SetMac sets field value
-func (o *IpConsumer) SetMac(v string) {
+// SetDatacenterName sets field value
+func (o *IpConsumer) SetDatacenterName(v string) {
- o.Mac = &v
+ o.DatacenterName = &v
}
-// HasMac returns a boolean if a field has been set.
-func (o *IpConsumer) HasMac() bool {
- if o != nil && o.Mac != nil {
+// HasDatacenterName returns a boolean if a field has been set.
+func (o *IpConsumer) HasDatacenterName() bool {
+ if o != nil && o.DatacenterName != nil {
return true
}
return false
}
-// GetNicId returns the NicId field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpConsumer) GetNicId() *string {
+// GetIp returns the Ip field value
+// If the value is explicit nil, nil is returned
+func (o *IpConsumer) GetIp() *string {
if o == nil {
return nil
}
- return o.NicId
+ return o.Ip
}
-// GetNicIdOk returns a tuple with the NicId field value
+// GetIpOk returns a tuple with the Ip field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpConsumer) GetNicIdOk() (*string, bool) {
+func (o *IpConsumer) GetIpOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.NicId, true
+ return o.Ip, true
}
-// SetNicId sets field value
-func (o *IpConsumer) SetNicId(v string) {
+// SetIp sets field value
+func (o *IpConsumer) SetIp(v string) {
- o.NicId = &v
+ o.Ip = &v
}
-// HasNicId returns a boolean if a field has been set.
-func (o *IpConsumer) HasNicId() bool {
- if o != nil && o.NicId != nil {
+// HasIp returns a boolean if a field has been set.
+func (o *IpConsumer) HasIp() bool {
+ if o != nil && o.Ip != nil {
return true
}
return false
}
-// GetServerId returns the ServerId field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpConsumer) GetServerId() *string {
+// GetK8sClusterUuid returns the K8sClusterUuid field value
+// If the value is explicit nil, nil is returned
+func (o *IpConsumer) GetK8sClusterUuid() *string {
if o == nil {
return nil
}
- return o.ServerId
+ return o.K8sClusterUuid
}
-// GetServerIdOk returns a tuple with the ServerId field value
+// GetK8sClusterUuidOk returns a tuple with the K8sClusterUuid field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpConsumer) GetServerIdOk() (*string, bool) {
+func (o *IpConsumer) GetK8sClusterUuidOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.ServerId, true
+ return o.K8sClusterUuid, true
}
-// SetServerId sets field value
-func (o *IpConsumer) SetServerId(v string) {
+// SetK8sClusterUuid sets field value
+func (o *IpConsumer) SetK8sClusterUuid(v string) {
- o.ServerId = &v
+ o.K8sClusterUuid = &v
}
-// HasServerId returns a boolean if a field has been set.
-func (o *IpConsumer) HasServerId() bool {
- if o != nil && o.ServerId != nil {
+// HasK8sClusterUuid returns a boolean if a field has been set.
+func (o *IpConsumer) HasK8sClusterUuid() bool {
+ if o != nil && o.K8sClusterUuid != nil {
return true
}
return false
}
-// GetServerName returns the ServerName field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpConsumer) GetServerName() *string {
+// GetK8sNodePoolUuid returns the K8sNodePoolUuid field value
+// If the value is explicit nil, nil is returned
+func (o *IpConsumer) GetK8sNodePoolUuid() *string {
if o == nil {
return nil
}
- return o.ServerName
+ return o.K8sNodePoolUuid
}
-// GetServerNameOk returns a tuple with the ServerName field value
+// GetK8sNodePoolUuidOk returns a tuple with the K8sNodePoolUuid field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpConsumer) GetServerNameOk() (*string, bool) {
+func (o *IpConsumer) GetK8sNodePoolUuidOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.ServerName, true
+ return o.K8sNodePoolUuid, true
}
-// SetServerName sets field value
-func (o *IpConsumer) SetServerName(v string) {
+// SetK8sNodePoolUuid sets field value
+func (o *IpConsumer) SetK8sNodePoolUuid(v string) {
- o.ServerName = &v
+ o.K8sNodePoolUuid = &v
}
-// HasServerName returns a boolean if a field has been set.
-func (o *IpConsumer) HasServerName() bool {
- if o != nil && o.ServerName != nil {
+// HasK8sNodePoolUuid returns a boolean if a field has been set.
+func (o *IpConsumer) HasK8sNodePoolUuid() bool {
+ if o != nil && o.K8sNodePoolUuid != nil {
return true
}
return false
}
-// GetDatacenterId returns the DatacenterId field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpConsumer) GetDatacenterId() *string {
+// GetMac returns the Mac field value
+// If the value is explicit nil, nil is returned
+func (o *IpConsumer) GetMac() *string {
if o == nil {
return nil
}
- return o.DatacenterId
+ return o.Mac
}
-// GetDatacenterIdOk returns a tuple with the DatacenterId field value
+// GetMacOk returns a tuple with the Mac field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpConsumer) GetDatacenterIdOk() (*string, bool) {
+func (o *IpConsumer) GetMacOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.DatacenterId, true
+ return o.Mac, true
}
-// SetDatacenterId sets field value
-func (o *IpConsumer) SetDatacenterId(v string) {
+// SetMac sets field value
+func (o *IpConsumer) SetMac(v string) {
- o.DatacenterId = &v
+ o.Mac = &v
}
-// HasDatacenterId returns a boolean if a field has been set.
-func (o *IpConsumer) HasDatacenterId() bool {
- if o != nil && o.DatacenterId != nil {
+// HasMac returns a boolean if a field has been set.
+func (o *IpConsumer) HasMac() bool {
+ if o != nil && o.Mac != nil {
return true
}
return false
}
-// GetDatacenterName returns the DatacenterName field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpConsumer) GetDatacenterName() *string {
+// GetNicId returns the NicId field value
+// If the value is explicit nil, nil is returned
+func (o *IpConsumer) GetNicId() *string {
if o == nil {
return nil
}
- return o.DatacenterName
+ return o.NicId
}
-// GetDatacenterNameOk returns a tuple with the DatacenterName field value
+// GetNicIdOk returns a tuple with the NicId field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpConsumer) GetDatacenterNameOk() (*string, bool) {
+func (o *IpConsumer) GetNicIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.DatacenterName, true
+ return o.NicId, true
}
-// SetDatacenterName sets field value
-func (o *IpConsumer) SetDatacenterName(v string) {
+// SetNicId sets field value
+func (o *IpConsumer) SetNicId(v string) {
- o.DatacenterName = &v
+ o.NicId = &v
}
-// HasDatacenterName returns a boolean if a field has been set.
-func (o *IpConsumer) HasDatacenterName() bool {
- if o != nil && o.DatacenterName != nil {
+// HasNicId returns a boolean if a field has been set.
+func (o *IpConsumer) HasNicId() bool {
+ if o != nil && o.NicId != nil {
return true
}
return false
}
-// GetK8sNodePoolUuid returns the K8sNodePoolUuid field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpConsumer) GetK8sNodePoolUuid() *string {
+// GetServerId returns the ServerId field value
+// If the value is explicit nil, nil is returned
+func (o *IpConsumer) GetServerId() *string {
if o == nil {
return nil
}
- return o.K8sNodePoolUuid
+ return o.ServerId
}
-// GetK8sNodePoolUuidOk returns a tuple with the K8sNodePoolUuid field value
+// GetServerIdOk returns a tuple with the ServerId field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpConsumer) GetK8sNodePoolUuidOk() (*string, bool) {
+func (o *IpConsumer) GetServerIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.K8sNodePoolUuid, true
+ return o.ServerId, true
}
-// SetK8sNodePoolUuid sets field value
-func (o *IpConsumer) SetK8sNodePoolUuid(v string) {
+// SetServerId sets field value
+func (o *IpConsumer) SetServerId(v string) {
- o.K8sNodePoolUuid = &v
+ o.ServerId = &v
}
-// HasK8sNodePoolUuid returns a boolean if a field has been set.
-func (o *IpConsumer) HasK8sNodePoolUuid() bool {
- if o != nil && o.K8sNodePoolUuid != nil {
+// HasServerId returns a boolean if a field has been set.
+func (o *IpConsumer) HasServerId() bool {
+ if o != nil && o.ServerId != nil {
return true
}
return false
}
-// GetK8sClusterUuid returns the K8sClusterUuid field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *IpConsumer) GetK8sClusterUuid() *string {
+// GetServerName returns the ServerName field value
+// If the value is explicit nil, nil is returned
+func (o *IpConsumer) GetServerName() *string {
if o == nil {
return nil
}
- return o.K8sClusterUuid
+ return o.ServerName
}
-// GetK8sClusterUuidOk returns a tuple with the K8sClusterUuid field value
+// GetServerNameOk returns a tuple with the ServerName field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *IpConsumer) GetK8sClusterUuidOk() (*string, bool) {
+func (o *IpConsumer) GetServerNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.K8sClusterUuid, true
+ return o.ServerName, true
}
-// SetK8sClusterUuid sets field value
-func (o *IpConsumer) SetK8sClusterUuid(v string) {
+// SetServerName sets field value
+func (o *IpConsumer) SetServerName(v string) {
- o.K8sClusterUuid = &v
+ o.ServerName = &v
}
-// HasK8sClusterUuid returns a boolean if a field has been set.
-func (o *IpConsumer) HasK8sClusterUuid() bool {
- if o != nil && o.K8sClusterUuid != nil {
+// HasServerName returns a boolean if a field has been set.
+func (o *IpConsumer) HasServerName() bool {
+ if o != nil && o.ServerName != nil {
return true
}
@@ -389,33 +389,42 @@ func (o *IpConsumer) HasK8sClusterUuid() bool {
func (o IpConsumer) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
+ if o.DatacenterId != nil {
+ toSerialize["datacenterId"] = o.DatacenterId
+ }
+
+ if o.DatacenterName != nil {
+ toSerialize["datacenterName"] = o.DatacenterName
+ }
+
if o.Ip != nil {
toSerialize["ip"] = o.Ip
}
+
+ if o.K8sClusterUuid != nil {
+ toSerialize["k8sClusterUuid"] = o.K8sClusterUuid
+ }
+
+ if o.K8sNodePoolUuid != nil {
+ toSerialize["k8sNodePoolUuid"] = o.K8sNodePoolUuid
+ }
+
if o.Mac != nil {
toSerialize["mac"] = o.Mac
}
+
if o.NicId != nil {
toSerialize["nicId"] = o.NicId
}
+
if o.ServerId != nil {
toSerialize["serverId"] = o.ServerId
}
+
if o.ServerName != nil {
toSerialize["serverName"] = o.ServerName
}
- if o.DatacenterId != nil {
- toSerialize["datacenterId"] = o.DatacenterId
- }
- if o.DatacenterName != nil {
- toSerialize["datacenterName"] = o.DatacenterName
- }
- if o.K8sNodePoolUuid != nil {
- toSerialize["k8sNodePoolUuid"] = o.K8sNodePoolUuid
- }
- if o.K8sClusterUuid != nil {
- toSerialize["k8sClusterUuid"] = o.K8sClusterUuid
- }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_failover.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_failover.go
index 16677e73e1a..60c902a97dc 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_failover.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_ip_failover.go
@@ -39,7 +39,7 @@ func NewIPFailoverWithDefaults() *IPFailover {
}
// GetIp returns the Ip field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *IPFailover) GetIp() *string {
if o == nil {
return nil
@@ -77,7 +77,7 @@ func (o *IPFailover) HasIp() bool {
}
// GetNicUuid returns the NicUuid field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *IPFailover) GetNicUuid() *string {
if o == nil {
return nil
@@ -119,9 +119,11 @@ func (o IPFailover) MarshalJSON() ([]byte, error) {
if o.Ip != nil {
toSerialize["ip"] = o.Ip
}
+
if o.NicUuid != nil {
toSerialize["nicUuid"] = o.NicUuid
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_auto_scaling.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_auto_scaling.go
index 24f95d7b3f8..49d9b3e8642 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_auto_scaling.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_auto_scaling.go
@@ -16,21 +16,21 @@ import (
// KubernetesAutoScaling struct for KubernetesAutoScaling
type KubernetesAutoScaling struct {
- // The minimum number of working nodes that the managed node pool can scale must be >= 1 and >= nodeCount. Required if autoScaling is specified.
- MinNodeCount *int32 `json:"minNodeCount"`
// The maximum number of worker nodes that the managed node pool can scale in. Must be >= minNodeCount and must be >= nodeCount. Required if autoScaling is specified.
MaxNodeCount *int32 `json:"maxNodeCount"`
+ // The minimum number of working nodes that the managed node pool can scale must be >= 1 and >= nodeCount. Required if autoScaling is specified.
+ MinNodeCount *int32 `json:"minNodeCount"`
}
// NewKubernetesAutoScaling instantiates a new KubernetesAutoScaling object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewKubernetesAutoScaling(minNodeCount int32, maxNodeCount int32) *KubernetesAutoScaling {
+func NewKubernetesAutoScaling(maxNodeCount int32, minNodeCount int32) *KubernetesAutoScaling {
this := KubernetesAutoScaling{}
- this.MinNodeCount = &minNodeCount
this.MaxNodeCount = &maxNodeCount
+ this.MinNodeCount = &minNodeCount
return &this
}
@@ -43,76 +43,76 @@ func NewKubernetesAutoScalingWithDefaults() *KubernetesAutoScaling {
return &this
}
-// GetMinNodeCount returns the MinNodeCount field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *KubernetesAutoScaling) GetMinNodeCount() *int32 {
+// GetMaxNodeCount returns the MaxNodeCount field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesAutoScaling) GetMaxNodeCount() *int32 {
if o == nil {
return nil
}
- return o.MinNodeCount
+ return o.MaxNodeCount
}
-// GetMinNodeCountOk returns a tuple with the MinNodeCount field value
+// GetMaxNodeCountOk returns a tuple with the MaxNodeCount field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesAutoScaling) GetMinNodeCountOk() (*int32, bool) {
+func (o *KubernetesAutoScaling) GetMaxNodeCountOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.MinNodeCount, true
+ return o.MaxNodeCount, true
}
-// SetMinNodeCount sets field value
-func (o *KubernetesAutoScaling) SetMinNodeCount(v int32) {
+// SetMaxNodeCount sets field value
+func (o *KubernetesAutoScaling) SetMaxNodeCount(v int32) {
- o.MinNodeCount = &v
+ o.MaxNodeCount = &v
}
-// HasMinNodeCount returns a boolean if a field has been set.
-func (o *KubernetesAutoScaling) HasMinNodeCount() bool {
- if o != nil && o.MinNodeCount != nil {
+// HasMaxNodeCount returns a boolean if a field has been set.
+func (o *KubernetesAutoScaling) HasMaxNodeCount() bool {
+ if o != nil && o.MaxNodeCount != nil {
return true
}
return false
}
-// GetMaxNodeCount returns the MaxNodeCount field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *KubernetesAutoScaling) GetMaxNodeCount() *int32 {
+// GetMinNodeCount returns the MinNodeCount field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesAutoScaling) GetMinNodeCount() *int32 {
if o == nil {
return nil
}
- return o.MaxNodeCount
+ return o.MinNodeCount
}
-// GetMaxNodeCountOk returns a tuple with the MaxNodeCount field value
+// GetMinNodeCountOk returns a tuple with the MinNodeCount field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesAutoScaling) GetMaxNodeCountOk() (*int32, bool) {
+func (o *KubernetesAutoScaling) GetMinNodeCountOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.MaxNodeCount, true
+ return o.MinNodeCount, true
}
-// SetMaxNodeCount sets field value
-func (o *KubernetesAutoScaling) SetMaxNodeCount(v int32) {
+// SetMinNodeCount sets field value
+func (o *KubernetesAutoScaling) SetMinNodeCount(v int32) {
- o.MaxNodeCount = &v
+ o.MinNodeCount = &v
}
-// HasMaxNodeCount returns a boolean if a field has been set.
-func (o *KubernetesAutoScaling) HasMaxNodeCount() bool {
- if o != nil && o.MaxNodeCount != nil {
+// HasMinNodeCount returns a boolean if a field has been set.
+func (o *KubernetesAutoScaling) HasMinNodeCount() bool {
+ if o != nil && o.MinNodeCount != nil {
return true
}
@@ -121,12 +121,14 @@ func (o *KubernetesAutoScaling) HasMaxNodeCount() bool {
func (o KubernetesAutoScaling) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.MinNodeCount != nil {
- toSerialize["minNodeCount"] = o.MinNodeCount
- }
if o.MaxNodeCount != nil {
toSerialize["maxNodeCount"] = o.MaxNodeCount
}
+
+ if o.MinNodeCount != nil {
+ toSerialize["minNodeCount"] = o.MinNodeCount
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster.go
index 631bda92295..994a6ac2849 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster.go
@@ -16,15 +16,15 @@ import (
// KubernetesCluster struct for KubernetesCluster
type KubernetesCluster struct {
- // The resource unique identifier.
- Id *string `json:"id,omitempty"`
- // The object type.
- Type *string `json:"type,omitempty"`
+ Entities *KubernetesClusterEntities `json:"entities,omitempty"`
// The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *KubernetesClusterProperties `json:"properties"`
- Entities *KubernetesClusterEntities `json:"entities,omitempty"`
+ // The object type.
+ Type *string `json:"type,omitempty"`
}
// NewKubernetesCluster instantiates a new KubernetesCluster object
@@ -47,114 +47,114 @@ func NewKubernetesClusterWithDefaults() *KubernetesCluster {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesCluster) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesCluster) GetEntities() *KubernetesClusterEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesCluster) GetIdOk() (*string, bool) {
+func (o *KubernetesCluster) GetEntitiesOk() (*KubernetesClusterEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *KubernetesCluster) SetId(v string) {
+// SetEntities sets field value
+func (o *KubernetesCluster) SetEntities(v KubernetesClusterEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *KubernetesCluster) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *KubernetesCluster) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesCluster) GetType() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesCluster) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesCluster) GetTypeOk() (*string, bool) {
+func (o *KubernetesCluster) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *KubernetesCluster) SetType(v string) {
+// SetHref sets field value
+func (o *KubernetesCluster) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *KubernetesCluster) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *KubernetesCluster) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesCluster) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesCluster) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesCluster) GetHrefOk() (*string, bool) {
+func (o *KubernetesCluster) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *KubernetesCluster) SetHref(v string) {
+// SetId sets field value
+func (o *KubernetesCluster) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *KubernetesCluster) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *KubernetesCluster) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -162,7 +162,7 @@ func (o *KubernetesCluster) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesCluster) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
@@ -200,7 +200,7 @@ func (o *KubernetesCluster) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for KubernetesClusterProperties will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesCluster) GetProperties() *KubernetesClusterProperties {
if o == nil {
return nil
@@ -237,38 +237,38 @@ func (o *KubernetesCluster) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for KubernetesClusterEntities will be returned
-func (o *KubernetesCluster) GetEntities() *KubernetesClusterEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesCluster) GetType() *string {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesCluster) GetEntitiesOk() (*KubernetesClusterEntities, bool) {
+func (o *KubernetesCluster) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *KubernetesCluster) SetEntities(v KubernetesClusterEntities) {
+// SetType sets field value
+func (o *KubernetesCluster) SetType(v string) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *KubernetesCluster) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *KubernetesCluster) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -277,24 +277,30 @@ func (o *KubernetesCluster) HasEntities() bool {
func (o KubernetesCluster) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_entities.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_entities.go
index 3e5dbaf4dbe..0e7daca3465 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_entities.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_entities.go
@@ -38,7 +38,7 @@ func NewKubernetesClusterEntitiesWithDefaults() *KubernetesClusterEntities {
}
// GetNodepools returns the Nodepools field value
-// If the value is explicit nil, the zero value for KubernetesNodePools will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesClusterEntities) GetNodepools() *KubernetesNodePools {
if o == nil {
return nil
@@ -80,6 +80,7 @@ func (o KubernetesClusterEntities) MarshalJSON() ([]byte, error) {
if o.Nodepools != nil {
toSerialize["nodepools"] = o.Nodepools
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_for_post.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_for_post.go
index 1fbe331ad03..cf2d02e6209 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_for_post.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_for_post.go
@@ -16,15 +16,15 @@ import (
// KubernetesClusterForPost struct for KubernetesClusterForPost
type KubernetesClusterForPost struct {
- // The resource unique identifier.
- Id *string `json:"id,omitempty"`
- // The object type.
- Type *string `json:"type,omitempty"`
+ Entities *KubernetesClusterEntities `json:"entities,omitempty"`
// The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *KubernetesClusterPropertiesForPost `json:"properties"`
- Entities *KubernetesClusterEntities `json:"entities,omitempty"`
+ // The object type.
+ Type *string `json:"type,omitempty"`
}
// NewKubernetesClusterForPost instantiates a new KubernetesClusterForPost object
@@ -47,114 +47,114 @@ func NewKubernetesClusterForPostWithDefaults() *KubernetesClusterForPost {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusterForPost) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterForPost) GetEntities() *KubernetesClusterEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterForPost) GetIdOk() (*string, bool) {
+func (o *KubernetesClusterForPost) GetEntitiesOk() (*KubernetesClusterEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *KubernetesClusterForPost) SetId(v string) {
+// SetEntities sets field value
+func (o *KubernetesClusterForPost) SetEntities(v KubernetesClusterEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *KubernetesClusterForPost) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *KubernetesClusterForPost) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusterForPost) GetType() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterForPost) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterForPost) GetTypeOk() (*string, bool) {
+func (o *KubernetesClusterForPost) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *KubernetesClusterForPost) SetType(v string) {
+// SetHref sets field value
+func (o *KubernetesClusterForPost) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *KubernetesClusterForPost) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *KubernetesClusterForPost) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusterForPost) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterForPost) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterForPost) GetHrefOk() (*string, bool) {
+func (o *KubernetesClusterForPost) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *KubernetesClusterForPost) SetHref(v string) {
+// SetId sets field value
+func (o *KubernetesClusterForPost) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *KubernetesClusterForPost) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *KubernetesClusterForPost) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -162,7 +162,7 @@ func (o *KubernetesClusterForPost) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesClusterForPost) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
@@ -200,7 +200,7 @@ func (o *KubernetesClusterForPost) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for KubernetesClusterPropertiesForPost will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesClusterForPost) GetProperties() *KubernetesClusterPropertiesForPost {
if o == nil {
return nil
@@ -237,38 +237,38 @@ func (o *KubernetesClusterForPost) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for KubernetesClusterEntities will be returned
-func (o *KubernetesClusterForPost) GetEntities() *KubernetesClusterEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterForPost) GetType() *string {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterForPost) GetEntitiesOk() (*KubernetesClusterEntities, bool) {
+func (o *KubernetesClusterForPost) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *KubernetesClusterForPost) SetEntities(v KubernetesClusterEntities) {
+// SetType sets field value
+func (o *KubernetesClusterForPost) SetType(v string) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *KubernetesClusterForPost) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *KubernetesClusterForPost) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -277,24 +277,30 @@ func (o *KubernetesClusterForPost) HasEntities() bool {
func (o KubernetesClusterForPost) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_for_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_for_put.go
index 2873bf5c860..6edf7ca5fcc 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_for_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_for_put.go
@@ -16,15 +16,15 @@ import (
// KubernetesClusterForPut struct for KubernetesClusterForPut
type KubernetesClusterForPut struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object.
- Type *string `json:"type,omitempty"`
+ Entities *KubernetesClusterEntities `json:"entities,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *KubernetesClusterPropertiesForPut `json:"properties"`
- Entities *KubernetesClusterEntities `json:"entities,omitempty"`
+ // The type of object.
+ Type *string `json:"type,omitempty"`
}
// NewKubernetesClusterForPut instantiates a new KubernetesClusterForPut object
@@ -47,114 +47,114 @@ func NewKubernetesClusterForPutWithDefaults() *KubernetesClusterForPut {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusterForPut) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterForPut) GetEntities() *KubernetesClusterEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterForPut) GetIdOk() (*string, bool) {
+func (o *KubernetesClusterForPut) GetEntitiesOk() (*KubernetesClusterEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *KubernetesClusterForPut) SetId(v string) {
+// SetEntities sets field value
+func (o *KubernetesClusterForPut) SetEntities(v KubernetesClusterEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *KubernetesClusterForPut) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *KubernetesClusterForPut) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusterForPut) GetType() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterForPut) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterForPut) GetTypeOk() (*string, bool) {
+func (o *KubernetesClusterForPut) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *KubernetesClusterForPut) SetType(v string) {
+// SetHref sets field value
+func (o *KubernetesClusterForPut) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *KubernetesClusterForPut) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *KubernetesClusterForPut) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusterForPut) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterForPut) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterForPut) GetHrefOk() (*string, bool) {
+func (o *KubernetesClusterForPut) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *KubernetesClusterForPut) SetHref(v string) {
+// SetId sets field value
+func (o *KubernetesClusterForPut) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *KubernetesClusterForPut) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *KubernetesClusterForPut) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -162,7 +162,7 @@ func (o *KubernetesClusterForPut) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesClusterForPut) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
@@ -200,7 +200,7 @@ func (o *KubernetesClusterForPut) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for KubernetesClusterPropertiesForPut will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesClusterForPut) GetProperties() *KubernetesClusterPropertiesForPut {
if o == nil {
return nil
@@ -237,38 +237,38 @@ func (o *KubernetesClusterForPut) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for KubernetesClusterEntities will be returned
-func (o *KubernetesClusterForPut) GetEntities() *KubernetesClusterEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterForPut) GetType() *string {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterForPut) GetEntitiesOk() (*KubernetesClusterEntities, bool) {
+func (o *KubernetesClusterForPut) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *KubernetesClusterForPut) SetEntities(v KubernetesClusterEntities) {
+// SetType sets field value
+func (o *KubernetesClusterForPut) SetType(v string) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *KubernetesClusterForPut) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *KubernetesClusterForPut) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -277,24 +277,30 @@ func (o *KubernetesClusterForPut) HasEntities() bool {
func (o KubernetesClusterForPut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_properties.go
index d887173623f..66956d3f7bd 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_properties.go
@@ -16,19 +16,19 @@ import (
// KubernetesClusterProperties struct for KubernetesClusterProperties
type KubernetesClusterProperties struct {
- // A Kubernetes cluster name. Valid Kubernetes cluster name must be 63 characters or less and must be empty or begin and end with an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between.
- Name *string `json:"name"`
+ // Access to the K8s API server is restricted to these CIDRs. Traffic, internal to the cluster, is not affected by this restriction. If no allowlist is specified, access is not restricted. If an IP without subnet mask is provided, the default value is used: 32 for IPv4 and 128 for IPv6.
+ ApiSubnetAllowList *[]string `json:"apiSubnetAllowList,omitempty"`
+ // List of available versions for upgrading the cluster
+ AvailableUpgradeVersions *[]string `json:"availableUpgradeVersions,omitempty"`
// The Kubernetes version the cluster is running. This imposes restrictions on what Kubernetes versions can be run in a cluster's nodepools. Additionally, not all Kubernetes versions are viable upgrade targets for all prior versions.
K8sVersion *string `json:"k8sVersion,omitempty"`
MaintenanceWindow *KubernetesMaintenanceWindow `json:"maintenanceWindow,omitempty"`
- // List of available versions for upgrading the cluster
- AvailableUpgradeVersions *[]string `json:"availableUpgradeVersions,omitempty"`
- // List of versions that may be used for node pools under this cluster
- ViableNodePoolVersions *[]string `json:"viableNodePoolVersions,omitempty"`
- // Access to the K8s API server is restricted to these CIDRs. Traffic, internal to the cluster, is not affected by this restriction. If no allowlist is specified, access is not restricted. If an IP without subnet mask is provided, the default value is used: 32 for IPv4 and 128 for IPv6.
- ApiSubnetAllowList *[]string `json:"apiSubnetAllowList,omitempty"`
+ // A Kubernetes cluster name. Valid Kubernetes cluster name must be 63 characters or less and must be empty or begin and end with an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between.
+ Name *string `json:"name"`
// List of S3 bucket configured for K8s usage. For now it contains only an S3 bucket used to store K8s API audit logs
S3Buckets *[]S3Bucket `json:"s3Buckets,omitempty"`
+ // List of versions that may be used for node pools under this cluster
+ ViableNodePoolVersions *[]string `json:"viableNodePoolVersions,omitempty"`
}
// NewKubernetesClusterProperties instantiates a new KubernetesClusterProperties object
@@ -51,266 +51,266 @@ func NewKubernetesClusterPropertiesWithDefaults() *KubernetesClusterProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusterProperties) GetName() *string {
+// GetApiSubnetAllowList returns the ApiSubnetAllowList field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterProperties) GetApiSubnetAllowList() *[]string {
if o == nil {
return nil
}
- return o.Name
+ return o.ApiSubnetAllowList
}
-// GetNameOk returns a tuple with the Name field value
+// GetApiSubnetAllowListOk returns a tuple with the ApiSubnetAllowList field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterProperties) GetNameOk() (*string, bool) {
+func (o *KubernetesClusterProperties) GetApiSubnetAllowListOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.ApiSubnetAllowList, true
}
-// SetName sets field value
-func (o *KubernetesClusterProperties) SetName(v string) {
+// SetApiSubnetAllowList sets field value
+func (o *KubernetesClusterProperties) SetApiSubnetAllowList(v []string) {
- o.Name = &v
+ o.ApiSubnetAllowList = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *KubernetesClusterProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasApiSubnetAllowList returns a boolean if a field has been set.
+func (o *KubernetesClusterProperties) HasApiSubnetAllowList() bool {
+ if o != nil && o.ApiSubnetAllowList != nil {
return true
}
return false
}
-// GetK8sVersion returns the K8sVersion field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusterProperties) GetK8sVersion() *string {
+// GetAvailableUpgradeVersions returns the AvailableUpgradeVersions field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterProperties) GetAvailableUpgradeVersions() *[]string {
if o == nil {
return nil
}
- return o.K8sVersion
+ return o.AvailableUpgradeVersions
}
-// GetK8sVersionOk returns a tuple with the K8sVersion field value
+// GetAvailableUpgradeVersionsOk returns a tuple with the AvailableUpgradeVersions field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterProperties) GetK8sVersionOk() (*string, bool) {
+func (o *KubernetesClusterProperties) GetAvailableUpgradeVersionsOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.K8sVersion, true
+ return o.AvailableUpgradeVersions, true
}
-// SetK8sVersion sets field value
-func (o *KubernetesClusterProperties) SetK8sVersion(v string) {
+// SetAvailableUpgradeVersions sets field value
+func (o *KubernetesClusterProperties) SetAvailableUpgradeVersions(v []string) {
- o.K8sVersion = &v
+ o.AvailableUpgradeVersions = &v
}
-// HasK8sVersion returns a boolean if a field has been set.
-func (o *KubernetesClusterProperties) HasK8sVersion() bool {
- if o != nil && o.K8sVersion != nil {
+// HasAvailableUpgradeVersions returns a boolean if a field has been set.
+func (o *KubernetesClusterProperties) HasAvailableUpgradeVersions() bool {
+ if o != nil && o.AvailableUpgradeVersions != nil {
return true
}
return false
}
-// GetMaintenanceWindow returns the MaintenanceWindow field value
-// If the value is explicit nil, the zero value for KubernetesMaintenanceWindow will be returned
-func (o *KubernetesClusterProperties) GetMaintenanceWindow() *KubernetesMaintenanceWindow {
+// GetK8sVersion returns the K8sVersion field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterProperties) GetK8sVersion() *string {
if o == nil {
return nil
}
- return o.MaintenanceWindow
+ return o.K8sVersion
}
-// GetMaintenanceWindowOk returns a tuple with the MaintenanceWindow field value
+// GetK8sVersionOk returns a tuple with the K8sVersion field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterProperties) GetMaintenanceWindowOk() (*KubernetesMaintenanceWindow, bool) {
+func (o *KubernetesClusterProperties) GetK8sVersionOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.MaintenanceWindow, true
+ return o.K8sVersion, true
}
-// SetMaintenanceWindow sets field value
-func (o *KubernetesClusterProperties) SetMaintenanceWindow(v KubernetesMaintenanceWindow) {
+// SetK8sVersion sets field value
+func (o *KubernetesClusterProperties) SetK8sVersion(v string) {
- o.MaintenanceWindow = &v
+ o.K8sVersion = &v
}
-// HasMaintenanceWindow returns a boolean if a field has been set.
-func (o *KubernetesClusterProperties) HasMaintenanceWindow() bool {
- if o != nil && o.MaintenanceWindow != nil {
+// HasK8sVersion returns a boolean if a field has been set.
+func (o *KubernetesClusterProperties) HasK8sVersion() bool {
+ if o != nil && o.K8sVersion != nil {
return true
}
return false
}
-// GetAvailableUpgradeVersions returns the AvailableUpgradeVersions field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *KubernetesClusterProperties) GetAvailableUpgradeVersions() *[]string {
+// GetMaintenanceWindow returns the MaintenanceWindow field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterProperties) GetMaintenanceWindow() *KubernetesMaintenanceWindow {
if o == nil {
return nil
}
- return o.AvailableUpgradeVersions
+ return o.MaintenanceWindow
}
-// GetAvailableUpgradeVersionsOk returns a tuple with the AvailableUpgradeVersions field value
+// GetMaintenanceWindowOk returns a tuple with the MaintenanceWindow field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterProperties) GetAvailableUpgradeVersionsOk() (*[]string, bool) {
+func (o *KubernetesClusterProperties) GetMaintenanceWindowOk() (*KubernetesMaintenanceWindow, bool) {
if o == nil {
return nil, false
}
- return o.AvailableUpgradeVersions, true
+ return o.MaintenanceWindow, true
}
-// SetAvailableUpgradeVersions sets field value
-func (o *KubernetesClusterProperties) SetAvailableUpgradeVersions(v []string) {
+// SetMaintenanceWindow sets field value
+func (o *KubernetesClusterProperties) SetMaintenanceWindow(v KubernetesMaintenanceWindow) {
- o.AvailableUpgradeVersions = &v
+ o.MaintenanceWindow = &v
}
-// HasAvailableUpgradeVersions returns a boolean if a field has been set.
-func (o *KubernetesClusterProperties) HasAvailableUpgradeVersions() bool {
- if o != nil && o.AvailableUpgradeVersions != nil {
+// HasMaintenanceWindow returns a boolean if a field has been set.
+func (o *KubernetesClusterProperties) HasMaintenanceWindow() bool {
+ if o != nil && o.MaintenanceWindow != nil {
return true
}
return false
}
-// GetViableNodePoolVersions returns the ViableNodePoolVersions field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *KubernetesClusterProperties) GetViableNodePoolVersions() *[]string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterProperties) GetName() *string {
if o == nil {
return nil
}
- return o.ViableNodePoolVersions
+ return o.Name
}
-// GetViableNodePoolVersionsOk returns a tuple with the ViableNodePoolVersions field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterProperties) GetViableNodePoolVersionsOk() (*[]string, bool) {
+func (o *KubernetesClusterProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.ViableNodePoolVersions, true
+ return o.Name, true
}
-// SetViableNodePoolVersions sets field value
-func (o *KubernetesClusterProperties) SetViableNodePoolVersions(v []string) {
+// SetName sets field value
+func (o *KubernetesClusterProperties) SetName(v string) {
- o.ViableNodePoolVersions = &v
+ o.Name = &v
}
-// HasViableNodePoolVersions returns a boolean if a field has been set.
-func (o *KubernetesClusterProperties) HasViableNodePoolVersions() bool {
- if o != nil && o.ViableNodePoolVersions != nil {
+// HasName returns a boolean if a field has been set.
+func (o *KubernetesClusterProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetApiSubnetAllowList returns the ApiSubnetAllowList field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *KubernetesClusterProperties) GetApiSubnetAllowList() *[]string {
+// GetS3Buckets returns the S3Buckets field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterProperties) GetS3Buckets() *[]S3Bucket {
if o == nil {
return nil
}
- return o.ApiSubnetAllowList
+ return o.S3Buckets
}
-// GetApiSubnetAllowListOk returns a tuple with the ApiSubnetAllowList field value
+// GetS3BucketsOk returns a tuple with the S3Buckets field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterProperties) GetApiSubnetAllowListOk() (*[]string, bool) {
+func (o *KubernetesClusterProperties) GetS3BucketsOk() (*[]S3Bucket, bool) {
if o == nil {
return nil, false
}
- return o.ApiSubnetAllowList, true
+ return o.S3Buckets, true
}
-// SetApiSubnetAllowList sets field value
-func (o *KubernetesClusterProperties) SetApiSubnetAllowList(v []string) {
+// SetS3Buckets sets field value
+func (o *KubernetesClusterProperties) SetS3Buckets(v []S3Bucket) {
- o.ApiSubnetAllowList = &v
+ o.S3Buckets = &v
}
-// HasApiSubnetAllowList returns a boolean if a field has been set.
-func (o *KubernetesClusterProperties) HasApiSubnetAllowList() bool {
- if o != nil && o.ApiSubnetAllowList != nil {
+// HasS3Buckets returns a boolean if a field has been set.
+func (o *KubernetesClusterProperties) HasS3Buckets() bool {
+ if o != nil && o.S3Buckets != nil {
return true
}
return false
}
-// GetS3Buckets returns the S3Buckets field value
-// If the value is explicit nil, the zero value for []S3Bucket will be returned
-func (o *KubernetesClusterProperties) GetS3Buckets() *[]S3Bucket {
+// GetViableNodePoolVersions returns the ViableNodePoolVersions field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterProperties) GetViableNodePoolVersions() *[]string {
if o == nil {
return nil
}
- return o.S3Buckets
+ return o.ViableNodePoolVersions
}
-// GetS3BucketsOk returns a tuple with the S3Buckets field value
+// GetViableNodePoolVersionsOk returns a tuple with the ViableNodePoolVersions field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterProperties) GetS3BucketsOk() (*[]S3Bucket, bool) {
+func (o *KubernetesClusterProperties) GetViableNodePoolVersionsOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.S3Buckets, true
+ return o.ViableNodePoolVersions, true
}
-// SetS3Buckets sets field value
-func (o *KubernetesClusterProperties) SetS3Buckets(v []S3Bucket) {
+// SetViableNodePoolVersions sets field value
+func (o *KubernetesClusterProperties) SetViableNodePoolVersions(v []string) {
- o.S3Buckets = &v
+ o.ViableNodePoolVersions = &v
}
-// HasS3Buckets returns a boolean if a field has been set.
-func (o *KubernetesClusterProperties) HasS3Buckets() bool {
- if o != nil && o.S3Buckets != nil {
+// HasViableNodePoolVersions returns a boolean if a field has been set.
+func (o *KubernetesClusterProperties) HasViableNodePoolVersions() bool {
+ if o != nil && o.ViableNodePoolVersions != nil {
return true
}
@@ -319,27 +319,34 @@ func (o *KubernetesClusterProperties) HasS3Buckets() bool {
func (o KubernetesClusterProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
+ if o.ApiSubnetAllowList != nil {
+ toSerialize["apiSubnetAllowList"] = o.ApiSubnetAllowList
+ }
+
+ if o.AvailableUpgradeVersions != nil {
+ toSerialize["availableUpgradeVersions"] = o.AvailableUpgradeVersions
}
+
if o.K8sVersion != nil {
toSerialize["k8sVersion"] = o.K8sVersion
}
+
if o.MaintenanceWindow != nil {
toSerialize["maintenanceWindow"] = o.MaintenanceWindow
}
- if o.AvailableUpgradeVersions != nil {
- toSerialize["availableUpgradeVersions"] = o.AvailableUpgradeVersions
- }
- if o.ViableNodePoolVersions != nil {
- toSerialize["viableNodePoolVersions"] = o.ViableNodePoolVersions
- }
- if o.ApiSubnetAllowList != nil {
- toSerialize["apiSubnetAllowList"] = o.ApiSubnetAllowList
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
}
+
if o.S3Buckets != nil {
toSerialize["s3Buckets"] = o.S3Buckets
}
+
+ if o.ViableNodePoolVersions != nil {
+ toSerialize["viableNodePoolVersions"] = o.ViableNodePoolVersions
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_properties_for_post.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_properties_for_post.go
index b44a3227aeb..9215373b9ce 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_properties_for_post.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_properties_for_post.go
@@ -16,13 +16,13 @@ import (
// KubernetesClusterPropertiesForPost struct for KubernetesClusterPropertiesForPost
type KubernetesClusterPropertiesForPost struct {
- // A Kubernetes cluster name. Valid Kubernetes cluster name must be 63 characters or less and must be empty or begin and end with an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between.
- Name *string `json:"name"`
+ // Access to the K8s API server is restricted to these CIDRs. Intra-cluster traffic is not affected by this restriction. If no AllowList is specified, access is not limited. If an IP is specified without a subnet mask, the default value is 32 for IPv4 and 128 for IPv6.
+ ApiSubnetAllowList *[]string `json:"apiSubnetAllowList,omitempty"`
// The Kubernetes version that the cluster is running. This limits which Kubernetes versions can run in a cluster's node pools. Also, not all Kubernetes versions are suitable upgrade targets for all earlier versions.
K8sVersion *string `json:"k8sVersion,omitempty"`
MaintenanceWindow *KubernetesMaintenanceWindow `json:"maintenanceWindow,omitempty"`
- // Access to the K8s API server is restricted to these CIDRs. Intra-cluster traffic is not affected by this restriction. If no AllowList is specified, access is not limited. If an IP is specified without a subnet mask, the default value is 32 for IPv4 and 128 for IPv6.
- ApiSubnetAllowList *[]string `json:"apiSubnetAllowList,omitempty"`
+ // A Kubernetes cluster name. Valid Kubernetes cluster name must be 63 characters or less and must be empty or begin and end with an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between.
+ Name *string `json:"name"`
// List of S3 buckets configured for K8s usage. At the moment, it contains only one S3 bucket that is used to store K8s API audit logs.
S3Buckets *[]S3Bucket `json:"s3Buckets,omitempty"`
}
@@ -47,38 +47,38 @@ func NewKubernetesClusterPropertiesForPostWithDefaults() *KubernetesClusterPrope
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusterPropertiesForPost) GetName() *string {
+// GetApiSubnetAllowList returns the ApiSubnetAllowList field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterPropertiesForPost) GetApiSubnetAllowList() *[]string {
if o == nil {
return nil
}
- return o.Name
+ return o.ApiSubnetAllowList
}
-// GetNameOk returns a tuple with the Name field value
+// GetApiSubnetAllowListOk returns a tuple with the ApiSubnetAllowList field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterPropertiesForPost) GetNameOk() (*string, bool) {
+func (o *KubernetesClusterPropertiesForPost) GetApiSubnetAllowListOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.ApiSubnetAllowList, true
}
-// SetName sets field value
-func (o *KubernetesClusterPropertiesForPost) SetName(v string) {
+// SetApiSubnetAllowList sets field value
+func (o *KubernetesClusterPropertiesForPost) SetApiSubnetAllowList(v []string) {
- o.Name = &v
+ o.ApiSubnetAllowList = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *KubernetesClusterPropertiesForPost) HasName() bool {
- if o != nil && o.Name != nil {
+// HasApiSubnetAllowList returns a boolean if a field has been set.
+func (o *KubernetesClusterPropertiesForPost) HasApiSubnetAllowList() bool {
+ if o != nil && o.ApiSubnetAllowList != nil {
return true
}
@@ -86,7 +86,7 @@ func (o *KubernetesClusterPropertiesForPost) HasName() bool {
}
// GetK8sVersion returns the K8sVersion field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesClusterPropertiesForPost) GetK8sVersion() *string {
if o == nil {
return nil
@@ -124,7 +124,7 @@ func (o *KubernetesClusterPropertiesForPost) HasK8sVersion() bool {
}
// GetMaintenanceWindow returns the MaintenanceWindow field value
-// If the value is explicit nil, the zero value for KubernetesMaintenanceWindow will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesClusterPropertiesForPost) GetMaintenanceWindow() *KubernetesMaintenanceWindow {
if o == nil {
return nil
@@ -161,38 +161,38 @@ func (o *KubernetesClusterPropertiesForPost) HasMaintenanceWindow() bool {
return false
}
-// GetApiSubnetAllowList returns the ApiSubnetAllowList field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *KubernetesClusterPropertiesForPost) GetApiSubnetAllowList() *[]string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterPropertiesForPost) GetName() *string {
if o == nil {
return nil
}
- return o.ApiSubnetAllowList
+ return o.Name
}
-// GetApiSubnetAllowListOk returns a tuple with the ApiSubnetAllowList field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterPropertiesForPost) GetApiSubnetAllowListOk() (*[]string, bool) {
+func (o *KubernetesClusterPropertiesForPost) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.ApiSubnetAllowList, true
+ return o.Name, true
}
-// SetApiSubnetAllowList sets field value
-func (o *KubernetesClusterPropertiesForPost) SetApiSubnetAllowList(v []string) {
+// SetName sets field value
+func (o *KubernetesClusterPropertiesForPost) SetName(v string) {
- o.ApiSubnetAllowList = &v
+ o.Name = &v
}
-// HasApiSubnetAllowList returns a boolean if a field has been set.
-func (o *KubernetesClusterPropertiesForPost) HasApiSubnetAllowList() bool {
- if o != nil && o.ApiSubnetAllowList != nil {
+// HasName returns a boolean if a field has been set.
+func (o *KubernetesClusterPropertiesForPost) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -200,7 +200,7 @@ func (o *KubernetesClusterPropertiesForPost) HasApiSubnetAllowList() bool {
}
// GetS3Buckets returns the S3Buckets field value
-// If the value is explicit nil, the zero value for []S3Bucket will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesClusterPropertiesForPost) GetS3Buckets() *[]S3Bucket {
if o == nil {
return nil
@@ -239,21 +239,26 @@ func (o *KubernetesClusterPropertiesForPost) HasS3Buckets() bool {
func (o KubernetesClusterPropertiesForPost) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
+ if o.ApiSubnetAllowList != nil {
+ toSerialize["apiSubnetAllowList"] = o.ApiSubnetAllowList
}
+
if o.K8sVersion != nil {
toSerialize["k8sVersion"] = o.K8sVersion
}
+
if o.MaintenanceWindow != nil {
toSerialize["maintenanceWindow"] = o.MaintenanceWindow
}
- if o.ApiSubnetAllowList != nil {
- toSerialize["apiSubnetAllowList"] = o.ApiSubnetAllowList
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
}
+
if o.S3Buckets != nil {
toSerialize["s3Buckets"] = o.S3Buckets
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_properties_for_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_properties_for_put.go
index c2b9d44cdea..b2bc4980d7c 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_properties_for_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_cluster_properties_for_put.go
@@ -16,13 +16,13 @@ import (
// KubernetesClusterPropertiesForPut struct for KubernetesClusterPropertiesForPut
type KubernetesClusterPropertiesForPut struct {
- // A Kubernetes cluster name. Valid Kubernetes cluster name must be 63 characters or less and must be empty or begin and end with an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between.
- Name *string `json:"name"`
+ // Access to the K8s API server is restricted to these CIDRs. Intra-cluster traffic is not affected by this restriction. If no AllowList is specified, access is not limited. If an IP is specified without a subnet mask, the default value is 32 for IPv4 and 128 for IPv6.
+ ApiSubnetAllowList *[]string `json:"apiSubnetAllowList,omitempty"`
// The Kubernetes version that the cluster is running. This limits which Kubernetes versions can run in a cluster's node pools. Also, not all Kubernetes versions are suitable upgrade targets for all earlier versions.
K8sVersion *string `json:"k8sVersion,omitempty"`
MaintenanceWindow *KubernetesMaintenanceWindow `json:"maintenanceWindow,omitempty"`
- // Access to the K8s API server is restricted to these CIDRs. Intra-cluster traffic is not affected by this restriction. If no AllowList is specified, access is not limited. If an IP is specified without a subnet mask, the default value is 32 for IPv4 and 128 for IPv6.
- ApiSubnetAllowList *[]string `json:"apiSubnetAllowList,omitempty"`
+ // A Kubernetes cluster name. Valid Kubernetes cluster name must be 63 characters or less and must be empty or begin and end with an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between.
+ Name *string `json:"name"`
// List of S3 buckets configured for K8s usage. At the moment, it contains only one S3 bucket that is used to store K8s API audit logs.
S3Buckets *[]S3Bucket `json:"s3Buckets,omitempty"`
}
@@ -47,38 +47,38 @@ func NewKubernetesClusterPropertiesForPutWithDefaults() *KubernetesClusterProper
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusterPropertiesForPut) GetName() *string {
+// GetApiSubnetAllowList returns the ApiSubnetAllowList field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterPropertiesForPut) GetApiSubnetAllowList() *[]string {
if o == nil {
return nil
}
- return o.Name
+ return o.ApiSubnetAllowList
}
-// GetNameOk returns a tuple with the Name field value
+// GetApiSubnetAllowListOk returns a tuple with the ApiSubnetAllowList field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterPropertiesForPut) GetNameOk() (*string, bool) {
+func (o *KubernetesClusterPropertiesForPut) GetApiSubnetAllowListOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.ApiSubnetAllowList, true
}
-// SetName sets field value
-func (o *KubernetesClusterPropertiesForPut) SetName(v string) {
+// SetApiSubnetAllowList sets field value
+func (o *KubernetesClusterPropertiesForPut) SetApiSubnetAllowList(v []string) {
- o.Name = &v
+ o.ApiSubnetAllowList = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *KubernetesClusterPropertiesForPut) HasName() bool {
- if o != nil && o.Name != nil {
+// HasApiSubnetAllowList returns a boolean if a field has been set.
+func (o *KubernetesClusterPropertiesForPut) HasApiSubnetAllowList() bool {
+ if o != nil && o.ApiSubnetAllowList != nil {
return true
}
@@ -86,7 +86,7 @@ func (o *KubernetesClusterPropertiesForPut) HasName() bool {
}
// GetK8sVersion returns the K8sVersion field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesClusterPropertiesForPut) GetK8sVersion() *string {
if o == nil {
return nil
@@ -124,7 +124,7 @@ func (o *KubernetesClusterPropertiesForPut) HasK8sVersion() bool {
}
// GetMaintenanceWindow returns the MaintenanceWindow field value
-// If the value is explicit nil, the zero value for KubernetesMaintenanceWindow will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesClusterPropertiesForPut) GetMaintenanceWindow() *KubernetesMaintenanceWindow {
if o == nil {
return nil
@@ -161,38 +161,38 @@ func (o *KubernetesClusterPropertiesForPut) HasMaintenanceWindow() bool {
return false
}
-// GetApiSubnetAllowList returns the ApiSubnetAllowList field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *KubernetesClusterPropertiesForPut) GetApiSubnetAllowList() *[]string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusterPropertiesForPut) GetName() *string {
if o == nil {
return nil
}
- return o.ApiSubnetAllowList
+ return o.Name
}
-// GetApiSubnetAllowListOk returns a tuple with the ApiSubnetAllowList field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusterPropertiesForPut) GetApiSubnetAllowListOk() (*[]string, bool) {
+func (o *KubernetesClusterPropertiesForPut) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.ApiSubnetAllowList, true
+ return o.Name, true
}
-// SetApiSubnetAllowList sets field value
-func (o *KubernetesClusterPropertiesForPut) SetApiSubnetAllowList(v []string) {
+// SetName sets field value
+func (o *KubernetesClusterPropertiesForPut) SetName(v string) {
- o.ApiSubnetAllowList = &v
+ o.Name = &v
}
-// HasApiSubnetAllowList returns a boolean if a field has been set.
-func (o *KubernetesClusterPropertiesForPut) HasApiSubnetAllowList() bool {
- if o != nil && o.ApiSubnetAllowList != nil {
+// HasName returns a boolean if a field has been set.
+func (o *KubernetesClusterPropertiesForPut) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -200,7 +200,7 @@ func (o *KubernetesClusterPropertiesForPut) HasApiSubnetAllowList() bool {
}
// GetS3Buckets returns the S3Buckets field value
-// If the value is explicit nil, the zero value for []S3Bucket will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesClusterPropertiesForPut) GetS3Buckets() *[]S3Bucket {
if o == nil {
return nil
@@ -239,21 +239,26 @@ func (o *KubernetesClusterPropertiesForPut) HasS3Buckets() bool {
func (o KubernetesClusterPropertiesForPut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
+ if o.ApiSubnetAllowList != nil {
+ toSerialize["apiSubnetAllowList"] = o.ApiSubnetAllowList
}
+
if o.K8sVersion != nil {
toSerialize["k8sVersion"] = o.K8sVersion
}
+
if o.MaintenanceWindow != nil {
toSerialize["maintenanceWindow"] = o.MaintenanceWindow
}
- if o.ApiSubnetAllowList != nil {
- toSerialize["apiSubnetAllowList"] = o.ApiSubnetAllowList
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
}
+
if o.S3Buckets != nil {
toSerialize["s3Buckets"] = o.S3Buckets
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_clusters.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_clusters.go
index f1416d0eb8f..84f19c35cc5 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_clusters.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_clusters.go
@@ -16,14 +16,14 @@ import (
// KubernetesClusters struct for KubernetesClusters
type KubernetesClusters struct {
- // The unique representation of the K8s cluster as a resource collection.
- Id *string `json:"id,omitempty"`
- // The resource type within a collection.
- Type *string `json:"type,omitempty"`
// The URL to the collection representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The unique representation of the K8s cluster as a resource collection.
+ Id *string `json:"id,omitempty"`
// Array of K8s clusters in the collection.
Items *[]KubernetesCluster `json:"items,omitempty"`
+ // The resource type within a collection.
+ Type *string `json:"type,omitempty"`
}
// NewKubernetesClusters instantiates a new KubernetesClusters object
@@ -44,152 +44,152 @@ func NewKubernetesClustersWithDefaults() *KubernetesClusters {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusters) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusters) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusters) GetIdOk() (*string, bool) {
+func (o *KubernetesClusters) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *KubernetesClusters) SetId(v string) {
+// SetHref sets field value
+func (o *KubernetesClusters) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *KubernetesClusters) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *KubernetesClusters) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusters) GetType() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusters) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusters) GetTypeOk() (*string, bool) {
+func (o *KubernetesClusters) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *KubernetesClusters) SetType(v string) {
+// SetId sets field value
+func (o *KubernetesClusters) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *KubernetesClusters) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *KubernetesClusters) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesClusters) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusters) GetItems() *[]KubernetesCluster {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusters) GetHrefOk() (*string, bool) {
+func (o *KubernetesClusters) GetItemsOk() (*[]KubernetesCluster, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *KubernetesClusters) SetHref(v string) {
+// SetItems sets field value
+func (o *KubernetesClusters) SetItems(v []KubernetesCluster) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *KubernetesClusters) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *KubernetesClusters) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []KubernetesCluster will be returned
-func (o *KubernetesClusters) GetItems() *[]KubernetesCluster {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesClusters) GetType() *string {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesClusters) GetItemsOk() (*[]KubernetesCluster, bool) {
+func (o *KubernetesClusters) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *KubernetesClusters) SetItems(v []KubernetesCluster) {
+// SetType sets field value
+func (o *KubernetesClusters) SetType(v string) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *KubernetesClusters) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *KubernetesClusters) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *KubernetesClusters) HasItems() bool {
func (o KubernetesClusters) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_maintenance_window.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_maintenance_window.go
index d5decee54ca..86d57625344 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_maintenance_window.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_maintenance_window.go
@@ -44,7 +44,7 @@ func NewKubernetesMaintenanceWindowWithDefaults() *KubernetesMaintenanceWindow {
}
// GetDayOfTheWeek returns the DayOfTheWeek field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesMaintenanceWindow) GetDayOfTheWeek() *string {
if o == nil {
return nil
@@ -82,7 +82,7 @@ func (o *KubernetesMaintenanceWindow) HasDayOfTheWeek() bool {
}
// GetTime returns the Time field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesMaintenanceWindow) GetTime() *string {
if o == nil {
return nil
@@ -124,9 +124,11 @@ func (o KubernetesMaintenanceWindow) MarshalJSON() ([]byte, error) {
if o.DayOfTheWeek != nil {
toSerialize["dayOfTheWeek"] = o.DayOfTheWeek
}
+
if o.Time != nil {
toSerialize["time"] = o.Time
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node.go
index 936864aeca7..512c52312df 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node.go
@@ -16,14 +16,14 @@ import (
// KubernetesNode struct for KubernetesNode
type KubernetesNode struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The object type.
- Type *string `json:"type,omitempty"`
// The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *KubernetesNodeMetadata `json:"metadata,omitempty"`
Properties *KubernetesNodeProperties `json:"properties"`
+ // The object type.
+ Type *string `json:"type,omitempty"`
}
// NewKubernetesNode instantiates a new KubernetesNode object
@@ -46,190 +46,190 @@ func NewKubernetesNodeWithDefaults() *KubernetesNode {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNode) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNode) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNode) GetIdOk() (*string, bool) {
+func (o *KubernetesNode) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *KubernetesNode) SetId(v string) {
+// SetHref sets field value
+func (o *KubernetesNode) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *KubernetesNode) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *KubernetesNode) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNode) GetType() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNode) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNode) GetTypeOk() (*string, bool) {
+func (o *KubernetesNode) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *KubernetesNode) SetType(v string) {
+// SetId sets field value
+func (o *KubernetesNode) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *KubernetesNode) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *KubernetesNode) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNode) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNode) GetMetadata() *KubernetesNodeMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNode) GetHrefOk() (*string, bool) {
+func (o *KubernetesNode) GetMetadataOk() (*KubernetesNodeMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *KubernetesNode) SetHref(v string) {
+// SetMetadata sets field value
+func (o *KubernetesNode) SetMetadata(v KubernetesNodeMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *KubernetesNode) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *KubernetesNode) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for KubernetesNodeMetadata will be returned
-func (o *KubernetesNode) GetMetadata() *KubernetesNodeMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNode) GetProperties() *KubernetesNodeProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNode) GetMetadataOk() (*KubernetesNodeMetadata, bool) {
+func (o *KubernetesNode) GetPropertiesOk() (*KubernetesNodeProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *KubernetesNode) SetMetadata(v KubernetesNodeMetadata) {
+// SetProperties sets field value
+func (o *KubernetesNode) SetProperties(v KubernetesNodeProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *KubernetesNode) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *KubernetesNode) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for KubernetesNodeProperties will be returned
-func (o *KubernetesNode) GetProperties() *KubernetesNodeProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNode) GetType() *string {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNode) GetPropertiesOk() (*KubernetesNodeProperties, bool) {
+func (o *KubernetesNode) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *KubernetesNode) SetProperties(v KubernetesNodeProperties) {
+// SetType sets field value
+func (o *KubernetesNode) SetType(v string) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *KubernetesNode) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *KubernetesNode) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *KubernetesNode) HasProperties() bool {
func (o KubernetesNode) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_metadata.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_metadata.go
index 8110ddd61aa..3915ed80386 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_metadata.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_metadata.go
@@ -17,16 +17,16 @@ import (
// KubernetesNodeMetadata struct for KubernetesNodeMetadata
type KubernetesNodeMetadata struct {
- // The resource entity tag as defined in http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.11 Entity tags are also added as 'ETag' response headers to requests that do not use the 'depth' parameter.
- Etag *string `json:"etag,omitempty"`
// The date the resource was created.
CreatedDate *IonosTime
+ // The resource entity tag as defined in http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.11 Entity tags are also added as 'ETag' response headers to requests that do not use the 'depth' parameter.
+ Etag *string `json:"etag,omitempty"`
// The date the resource was last modified.
LastModifiedDate *IonosTime
- // The resource state.
- State *string `json:"state,omitempty"`
// The date when the software on the node was last updated.
LastSoftwareUpdatedDate *IonosTime
+ // The resource state.
+ State *string `json:"state,omitempty"`
}
// NewKubernetesNodeMetadata instantiates a new KubernetesNodeMetadata object
@@ -47,83 +47,83 @@ func NewKubernetesNodeMetadataWithDefaults() *KubernetesNodeMetadata {
return &this
}
-// GetEtag returns the Etag field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodeMetadata) GetEtag() *string {
+// GetCreatedDate returns the CreatedDate field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodeMetadata) GetCreatedDate() *time.Time {
if o == nil {
return nil
}
- return o.Etag
+ if o.CreatedDate == nil {
+ return nil
+ }
+ return &o.CreatedDate.Time
}
-// GetEtagOk returns a tuple with the Etag field value
+// GetCreatedDateOk returns a tuple with the CreatedDate field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodeMetadata) GetEtagOk() (*string, bool) {
+func (o *KubernetesNodeMetadata) GetCreatedDateOk() (*time.Time, bool) {
if o == nil {
return nil, false
}
- return o.Etag, true
+ if o.CreatedDate == nil {
+ return nil, false
+ }
+ return &o.CreatedDate.Time, true
+
}
-// SetEtag sets field value
-func (o *KubernetesNodeMetadata) SetEtag(v string) {
+// SetCreatedDate sets field value
+func (o *KubernetesNodeMetadata) SetCreatedDate(v time.Time) {
- o.Etag = &v
+ o.CreatedDate = &IonosTime{v}
}
-// HasEtag returns a boolean if a field has been set.
-func (o *KubernetesNodeMetadata) HasEtag() bool {
- if o != nil && o.Etag != nil {
+// HasCreatedDate returns a boolean if a field has been set.
+func (o *KubernetesNodeMetadata) HasCreatedDate() bool {
+ if o != nil && o.CreatedDate != nil {
return true
}
return false
}
-// GetCreatedDate returns the CreatedDate field value
-// If the value is explicit nil, the zero value for time.Time will be returned
-func (o *KubernetesNodeMetadata) GetCreatedDate() *time.Time {
+// GetEtag returns the Etag field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodeMetadata) GetEtag() *string {
if o == nil {
return nil
}
- if o.CreatedDate == nil {
- return nil
- }
- return &o.CreatedDate.Time
+ return o.Etag
}
-// GetCreatedDateOk returns a tuple with the CreatedDate field value
+// GetEtagOk returns a tuple with the Etag field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodeMetadata) GetCreatedDateOk() (*time.Time, bool) {
+func (o *KubernetesNodeMetadata) GetEtagOk() (*string, bool) {
if o == nil {
return nil, false
}
- if o.CreatedDate == nil {
- return nil, false
- }
- return &o.CreatedDate.Time, true
-
+ return o.Etag, true
}
-// SetCreatedDate sets field value
-func (o *KubernetesNodeMetadata) SetCreatedDate(v time.Time) {
+// SetEtag sets field value
+func (o *KubernetesNodeMetadata) SetEtag(v string) {
- o.CreatedDate = &IonosTime{v}
+ o.Etag = &v
}
-// HasCreatedDate returns a boolean if a field has been set.
-func (o *KubernetesNodeMetadata) HasCreatedDate() bool {
- if o != nil && o.CreatedDate != nil {
+// HasEtag returns a boolean if a field has been set.
+func (o *KubernetesNodeMetadata) HasEtag() bool {
+ if o != nil && o.Etag != nil {
return true
}
@@ -131,7 +131,7 @@ func (o *KubernetesNodeMetadata) HasCreatedDate() bool {
}
// GetLastModifiedDate returns the LastModifiedDate field value
-// If the value is explicit nil, the zero value for time.Time will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesNodeMetadata) GetLastModifiedDate() *time.Time {
if o == nil {
return nil
@@ -175,83 +175,83 @@ func (o *KubernetesNodeMetadata) HasLastModifiedDate() bool {
return false
}
-// GetState returns the State field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodeMetadata) GetState() *string {
+// GetLastSoftwareUpdatedDate returns the LastSoftwareUpdatedDate field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodeMetadata) GetLastSoftwareUpdatedDate() *time.Time {
if o == nil {
return nil
}
- return o.State
+ if o.LastSoftwareUpdatedDate == nil {
+ return nil
+ }
+ return &o.LastSoftwareUpdatedDate.Time
}
-// GetStateOk returns a tuple with the State field value
+// GetLastSoftwareUpdatedDateOk returns a tuple with the LastSoftwareUpdatedDate field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodeMetadata) GetStateOk() (*string, bool) {
+func (o *KubernetesNodeMetadata) GetLastSoftwareUpdatedDateOk() (*time.Time, bool) {
if o == nil {
return nil, false
}
- return o.State, true
+ if o.LastSoftwareUpdatedDate == nil {
+ return nil, false
+ }
+ return &o.LastSoftwareUpdatedDate.Time, true
+
}
-// SetState sets field value
-func (o *KubernetesNodeMetadata) SetState(v string) {
+// SetLastSoftwareUpdatedDate sets field value
+func (o *KubernetesNodeMetadata) SetLastSoftwareUpdatedDate(v time.Time) {
- o.State = &v
+ o.LastSoftwareUpdatedDate = &IonosTime{v}
}
-// HasState returns a boolean if a field has been set.
-func (o *KubernetesNodeMetadata) HasState() bool {
- if o != nil && o.State != nil {
+// HasLastSoftwareUpdatedDate returns a boolean if a field has been set.
+func (o *KubernetesNodeMetadata) HasLastSoftwareUpdatedDate() bool {
+ if o != nil && o.LastSoftwareUpdatedDate != nil {
return true
}
return false
}
-// GetLastSoftwareUpdatedDate returns the LastSoftwareUpdatedDate field value
-// If the value is explicit nil, the zero value for time.Time will be returned
-func (o *KubernetesNodeMetadata) GetLastSoftwareUpdatedDate() *time.Time {
+// GetState returns the State field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodeMetadata) GetState() *string {
if o == nil {
return nil
}
- if o.LastSoftwareUpdatedDate == nil {
- return nil
- }
- return &o.LastSoftwareUpdatedDate.Time
+ return o.State
}
-// GetLastSoftwareUpdatedDateOk returns a tuple with the LastSoftwareUpdatedDate field value
+// GetStateOk returns a tuple with the State field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodeMetadata) GetLastSoftwareUpdatedDateOk() (*time.Time, bool) {
+func (o *KubernetesNodeMetadata) GetStateOk() (*string, bool) {
if o == nil {
return nil, false
}
- if o.LastSoftwareUpdatedDate == nil {
- return nil, false
- }
- return &o.LastSoftwareUpdatedDate.Time, true
-
+ return o.State, true
}
-// SetLastSoftwareUpdatedDate sets field value
-func (o *KubernetesNodeMetadata) SetLastSoftwareUpdatedDate(v time.Time) {
+// SetState sets field value
+func (o *KubernetesNodeMetadata) SetState(v string) {
- o.LastSoftwareUpdatedDate = &IonosTime{v}
+ o.State = &v
}
-// HasLastSoftwareUpdatedDate returns a boolean if a field has been set.
-func (o *KubernetesNodeMetadata) HasLastSoftwareUpdatedDate() bool {
- if o != nil && o.LastSoftwareUpdatedDate != nil {
+// HasState returns a boolean if a field has been set.
+func (o *KubernetesNodeMetadata) HasState() bool {
+ if o != nil && o.State != nil {
return true
}
@@ -260,21 +260,26 @@ func (o *KubernetesNodeMetadata) HasLastSoftwareUpdatedDate() bool {
func (o KubernetesNodeMetadata) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Etag != nil {
- toSerialize["etag"] = o.Etag
- }
if o.CreatedDate != nil {
toSerialize["createdDate"] = o.CreatedDate
}
+
+ if o.Etag != nil {
+ toSerialize["etag"] = o.Etag
+ }
+
if o.LastModifiedDate != nil {
toSerialize["lastModifiedDate"] = o.LastModifiedDate
}
- if o.State != nil {
- toSerialize["state"] = o.State
- }
+
if o.LastSoftwareUpdatedDate != nil {
toSerialize["lastSoftwareUpdatedDate"] = o.LastSoftwareUpdatedDate
}
+
+ if o.State != nil {
+ toSerialize["state"] = o.State
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool.go
index a634f0a8b65..9649a8ad842 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool.go
@@ -16,14 +16,14 @@ import (
// KubernetesNodePool struct for KubernetesNodePool
type KubernetesNodePool struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The object type.
- Type *string `json:"type,omitempty"`
// The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *KubernetesNodePoolProperties `json:"properties"`
+ // The object type.
+ Type *string `json:"type,omitempty"`
}
// NewKubernetesNodePool instantiates a new KubernetesNodePool object
@@ -46,190 +46,190 @@ func NewKubernetesNodePoolWithDefaults() *KubernetesNodePool {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePool) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePool) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePool) GetIdOk() (*string, bool) {
+func (o *KubernetesNodePool) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *KubernetesNodePool) SetId(v string) {
+// SetHref sets field value
+func (o *KubernetesNodePool) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *KubernetesNodePool) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *KubernetesNodePool) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePool) GetType() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePool) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePool) GetTypeOk() (*string, bool) {
+func (o *KubernetesNodePool) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *KubernetesNodePool) SetType(v string) {
+// SetId sets field value
+func (o *KubernetesNodePool) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *KubernetesNodePool) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *KubernetesNodePool) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePool) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePool) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePool) GetHrefOk() (*string, bool) {
+func (o *KubernetesNodePool) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *KubernetesNodePool) SetHref(v string) {
+// SetMetadata sets field value
+func (o *KubernetesNodePool) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *KubernetesNodePool) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *KubernetesNodePool) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *KubernetesNodePool) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePool) GetProperties() *KubernetesNodePoolProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePool) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *KubernetesNodePool) GetPropertiesOk() (*KubernetesNodePoolProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *KubernetesNodePool) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *KubernetesNodePool) SetProperties(v KubernetesNodePoolProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *KubernetesNodePool) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *KubernetesNodePool) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for KubernetesNodePoolProperties will be returned
-func (o *KubernetesNodePool) GetProperties() *KubernetesNodePoolProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePool) GetType() *string {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePool) GetPropertiesOk() (*KubernetesNodePoolProperties, bool) {
+func (o *KubernetesNodePool) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *KubernetesNodePool) SetProperties(v KubernetesNodePoolProperties) {
+// SetType sets field value
+func (o *KubernetesNodePool) SetType(v string) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *KubernetesNodePool) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *KubernetesNodePool) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *KubernetesNodePool) HasProperties() bool {
func (o KubernetesNodePool) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_for_post.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_for_post.go
index 9a89d3d18bc..afeef99c7c7 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_for_post.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_for_post.go
@@ -16,14 +16,14 @@ import (
// KubernetesNodePoolForPost struct for KubernetesNodePoolForPost
type KubernetesNodePoolForPost struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The object type.
- Type *string `json:"type,omitempty"`
// The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *KubernetesNodePoolPropertiesForPost `json:"properties"`
+ // The object type.
+ Type *string `json:"type,omitempty"`
}
// NewKubernetesNodePoolForPost instantiates a new KubernetesNodePoolForPost object
@@ -46,190 +46,190 @@ func NewKubernetesNodePoolForPostWithDefaults() *KubernetesNodePoolForPost {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolForPost) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolForPost) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolForPost) GetIdOk() (*string, bool) {
+func (o *KubernetesNodePoolForPost) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *KubernetesNodePoolForPost) SetId(v string) {
+// SetHref sets field value
+func (o *KubernetesNodePoolForPost) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *KubernetesNodePoolForPost) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *KubernetesNodePoolForPost) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolForPost) GetType() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolForPost) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolForPost) GetTypeOk() (*string, bool) {
+func (o *KubernetesNodePoolForPost) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *KubernetesNodePoolForPost) SetType(v string) {
+// SetId sets field value
+func (o *KubernetesNodePoolForPost) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *KubernetesNodePoolForPost) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *KubernetesNodePoolForPost) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolForPost) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolForPost) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolForPost) GetHrefOk() (*string, bool) {
+func (o *KubernetesNodePoolForPost) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *KubernetesNodePoolForPost) SetHref(v string) {
+// SetMetadata sets field value
+func (o *KubernetesNodePoolForPost) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *KubernetesNodePoolForPost) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *KubernetesNodePoolForPost) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *KubernetesNodePoolForPost) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolForPost) GetProperties() *KubernetesNodePoolPropertiesForPost {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolForPost) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *KubernetesNodePoolForPost) GetPropertiesOk() (*KubernetesNodePoolPropertiesForPost, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *KubernetesNodePoolForPost) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *KubernetesNodePoolForPost) SetProperties(v KubernetesNodePoolPropertiesForPost) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *KubernetesNodePoolForPost) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *KubernetesNodePoolForPost) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for KubernetesNodePoolPropertiesForPost will be returned
-func (o *KubernetesNodePoolForPost) GetProperties() *KubernetesNodePoolPropertiesForPost {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolForPost) GetType() *string {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolForPost) GetPropertiesOk() (*KubernetesNodePoolPropertiesForPost, bool) {
+func (o *KubernetesNodePoolForPost) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *KubernetesNodePoolForPost) SetProperties(v KubernetesNodePoolPropertiesForPost) {
+// SetType sets field value
+func (o *KubernetesNodePoolForPost) SetType(v string) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *KubernetesNodePoolForPost) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *KubernetesNodePoolForPost) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *KubernetesNodePoolForPost) HasProperties() bool {
func (o KubernetesNodePoolForPost) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_for_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_for_put.go
index 10fa4f29057..94df03dd911 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_for_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_for_put.go
@@ -16,14 +16,14 @@ import (
// KubernetesNodePoolForPut struct for KubernetesNodePoolForPut
type KubernetesNodePoolForPut struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The object type.
- Type *string `json:"type,omitempty"`
// The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *KubernetesNodePoolPropertiesForPut `json:"properties"`
+ // The object type.
+ Type *string `json:"type,omitempty"`
}
// NewKubernetesNodePoolForPut instantiates a new KubernetesNodePoolForPut object
@@ -46,190 +46,190 @@ func NewKubernetesNodePoolForPutWithDefaults() *KubernetesNodePoolForPut {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolForPut) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolForPut) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolForPut) GetIdOk() (*string, bool) {
+func (o *KubernetesNodePoolForPut) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *KubernetesNodePoolForPut) SetId(v string) {
+// SetHref sets field value
+func (o *KubernetesNodePoolForPut) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *KubernetesNodePoolForPut) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *KubernetesNodePoolForPut) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolForPut) GetType() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolForPut) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolForPut) GetTypeOk() (*string, bool) {
+func (o *KubernetesNodePoolForPut) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *KubernetesNodePoolForPut) SetType(v string) {
+// SetId sets field value
+func (o *KubernetesNodePoolForPut) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *KubernetesNodePoolForPut) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *KubernetesNodePoolForPut) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolForPut) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolForPut) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolForPut) GetHrefOk() (*string, bool) {
+func (o *KubernetesNodePoolForPut) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *KubernetesNodePoolForPut) SetHref(v string) {
+// SetMetadata sets field value
+func (o *KubernetesNodePoolForPut) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *KubernetesNodePoolForPut) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *KubernetesNodePoolForPut) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *KubernetesNodePoolForPut) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolForPut) GetProperties() *KubernetesNodePoolPropertiesForPut {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolForPut) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *KubernetesNodePoolForPut) GetPropertiesOk() (*KubernetesNodePoolPropertiesForPut, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *KubernetesNodePoolForPut) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *KubernetesNodePoolForPut) SetProperties(v KubernetesNodePoolPropertiesForPut) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *KubernetesNodePoolForPut) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *KubernetesNodePoolForPut) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for KubernetesNodePoolPropertiesForPut will be returned
-func (o *KubernetesNodePoolForPut) GetProperties() *KubernetesNodePoolPropertiesForPut {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolForPut) GetType() *string {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolForPut) GetPropertiesOk() (*KubernetesNodePoolPropertiesForPut, bool) {
+func (o *KubernetesNodePoolForPut) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *KubernetesNodePoolForPut) SetProperties(v KubernetesNodePoolPropertiesForPut) {
+// SetType sets field value
+func (o *KubernetesNodePoolForPut) SetType(v string) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *KubernetesNodePoolForPut) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *KubernetesNodePoolForPut) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *KubernetesNodePoolForPut) HasProperties() bool {
func (o KubernetesNodePoolForPut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_lan.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_lan.go
index 012c0f4b7c6..926f1498aad 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_lan.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_lan.go
@@ -18,10 +18,10 @@ import (
type KubernetesNodePoolLan struct {
// The datacenter ID, requires system privileges, for internal usage only
DatacenterId *string `json:"datacenterId,omitempty"`
- // The LAN ID of an existing LAN at the related data center
- Id *int32 `json:"id"`
// Specifies whether the Kubernetes node pool LAN reserves an IP with DHCP.
Dhcp *bool `json:"dhcp,omitempty"`
+ // The LAN ID of an existing LAN at the related data center
+ Id *int32 `json:"id"`
// The array of additional LANs attached to worker nodes.
Routes *[]KubernetesNodePoolLanRoutes `json:"routes,omitempty"`
}
@@ -47,7 +47,7 @@ func NewKubernetesNodePoolLanWithDefaults() *KubernetesNodePoolLan {
}
// GetDatacenterId returns the DatacenterId field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesNodePoolLan) GetDatacenterId() *string {
if o == nil {
return nil
@@ -84,76 +84,76 @@ func (o *KubernetesNodePoolLan) HasDatacenterId() bool {
return false
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *KubernetesNodePoolLan) GetId() *int32 {
+// GetDhcp returns the Dhcp field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolLan) GetDhcp() *bool {
if o == nil {
return nil
}
- return o.Id
+ return o.Dhcp
}
-// GetIdOk returns a tuple with the Id field value
+// GetDhcpOk returns a tuple with the Dhcp field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolLan) GetIdOk() (*int32, bool) {
+func (o *KubernetesNodePoolLan) GetDhcpOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Dhcp, true
}
-// SetId sets field value
-func (o *KubernetesNodePoolLan) SetId(v int32) {
+// SetDhcp sets field value
+func (o *KubernetesNodePoolLan) SetDhcp(v bool) {
- o.Id = &v
+ o.Dhcp = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *KubernetesNodePoolLan) HasId() bool {
- if o != nil && o.Id != nil {
+// HasDhcp returns a boolean if a field has been set.
+func (o *KubernetesNodePoolLan) HasDhcp() bool {
+ if o != nil && o.Dhcp != nil {
return true
}
return false
}
-// GetDhcp returns the Dhcp field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *KubernetesNodePoolLan) GetDhcp() *bool {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolLan) GetId() *int32 {
if o == nil {
return nil
}
- return o.Dhcp
+ return o.Id
}
-// GetDhcpOk returns a tuple with the Dhcp field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolLan) GetDhcpOk() (*bool, bool) {
+func (o *KubernetesNodePoolLan) GetIdOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Dhcp, true
+ return o.Id, true
}
-// SetDhcp sets field value
-func (o *KubernetesNodePoolLan) SetDhcp(v bool) {
+// SetId sets field value
+func (o *KubernetesNodePoolLan) SetId(v int32) {
- o.Dhcp = &v
+ o.Id = &v
}
-// HasDhcp returns a boolean if a field has been set.
-func (o *KubernetesNodePoolLan) HasDhcp() bool {
- if o != nil && o.Dhcp != nil {
+// HasId returns a boolean if a field has been set.
+func (o *KubernetesNodePoolLan) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -161,7 +161,7 @@ func (o *KubernetesNodePoolLan) HasDhcp() bool {
}
// GetRoutes returns the Routes field value
-// If the value is explicit nil, the zero value for []KubernetesNodePoolLanRoutes will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesNodePoolLan) GetRoutes() *[]KubernetesNodePoolLanRoutes {
if o == nil {
return nil
@@ -203,15 +203,19 @@ func (o KubernetesNodePoolLan) MarshalJSON() ([]byte, error) {
if o.DatacenterId != nil {
toSerialize["datacenterId"] = o.DatacenterId
}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
+
if o.Dhcp != nil {
toSerialize["dhcp"] = o.Dhcp
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Routes != nil {
toSerialize["routes"] = o.Routes
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_lan_routes.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_lan_routes.go
index 0d57c45927f..7ba035e4473 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_lan_routes.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_lan_routes.go
@@ -16,10 +16,10 @@ import (
// KubernetesNodePoolLanRoutes struct for KubernetesNodePoolLanRoutes
type KubernetesNodePoolLanRoutes struct {
- // IPv4 or IPv6 CIDR to be routed via the interface.
- Network *string `json:"network,omitempty"`
// IPv4 or IPv6 Gateway IP for the route.
GatewayIp *string `json:"gatewayIp,omitempty"`
+ // IPv4 or IPv6 CIDR to be routed via the interface.
+ Network *string `json:"network,omitempty"`
}
// NewKubernetesNodePoolLanRoutes instantiates a new KubernetesNodePoolLanRoutes object
@@ -40,76 +40,76 @@ func NewKubernetesNodePoolLanRoutesWithDefaults() *KubernetesNodePoolLanRoutes {
return &this
}
-// GetNetwork returns the Network field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolLanRoutes) GetNetwork() *string {
+// GetGatewayIp returns the GatewayIp field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolLanRoutes) GetGatewayIp() *string {
if o == nil {
return nil
}
- return o.Network
+ return o.GatewayIp
}
-// GetNetworkOk returns a tuple with the Network field value
+// GetGatewayIpOk returns a tuple with the GatewayIp field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolLanRoutes) GetNetworkOk() (*string, bool) {
+func (o *KubernetesNodePoolLanRoutes) GetGatewayIpOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Network, true
+ return o.GatewayIp, true
}
-// SetNetwork sets field value
-func (o *KubernetesNodePoolLanRoutes) SetNetwork(v string) {
+// SetGatewayIp sets field value
+func (o *KubernetesNodePoolLanRoutes) SetGatewayIp(v string) {
- o.Network = &v
+ o.GatewayIp = &v
}
-// HasNetwork returns a boolean if a field has been set.
-func (o *KubernetesNodePoolLanRoutes) HasNetwork() bool {
- if o != nil && o.Network != nil {
+// HasGatewayIp returns a boolean if a field has been set.
+func (o *KubernetesNodePoolLanRoutes) HasGatewayIp() bool {
+ if o != nil && o.GatewayIp != nil {
return true
}
return false
}
-// GetGatewayIp returns the GatewayIp field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolLanRoutes) GetGatewayIp() *string {
+// GetNetwork returns the Network field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolLanRoutes) GetNetwork() *string {
if o == nil {
return nil
}
- return o.GatewayIp
+ return o.Network
}
-// GetGatewayIpOk returns a tuple with the GatewayIp field value
+// GetNetworkOk returns a tuple with the Network field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolLanRoutes) GetGatewayIpOk() (*string, bool) {
+func (o *KubernetesNodePoolLanRoutes) GetNetworkOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.GatewayIp, true
+ return o.Network, true
}
-// SetGatewayIp sets field value
-func (o *KubernetesNodePoolLanRoutes) SetGatewayIp(v string) {
+// SetNetwork sets field value
+func (o *KubernetesNodePoolLanRoutes) SetNetwork(v string) {
- o.GatewayIp = &v
+ o.Network = &v
}
-// HasGatewayIp returns a boolean if a field has been set.
-func (o *KubernetesNodePoolLanRoutes) HasGatewayIp() bool {
- if o != nil && o.GatewayIp != nil {
+// HasNetwork returns a boolean if a field has been set.
+func (o *KubernetesNodePoolLanRoutes) HasNetwork() bool {
+ if o != nil && o.Network != nil {
return true
}
@@ -118,12 +118,14 @@ func (o *KubernetesNodePoolLanRoutes) HasGatewayIp() bool {
func (o KubernetesNodePoolLanRoutes) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Network != nil {
- toSerialize["network"] = o.Network
- }
if o.GatewayIp != nil {
toSerialize["gatewayIp"] = o.GatewayIp
}
+
+ if o.Network != nil {
+ toSerialize["network"] = o.Network
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_properties.go
index 5e18701de76..376120c0c3b 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_properties.go
@@ -16,56 +16,56 @@ import (
// KubernetesNodePoolProperties struct for KubernetesNodePoolProperties
type KubernetesNodePoolProperties struct {
- // A Kubernetes node pool name. Valid Kubernetes node pool name must be 63 characters or less and must be empty or begin and end with an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between.
- Name *string `json:"name"`
+ // The annotations attached to the node pool.
+ Annotations *map[string]string `json:"annotations,omitempty"`
+ AutoScaling *KubernetesAutoScaling `json:"autoScaling,omitempty"`
+ // The availability zone in which the target VM should be provisioned.
+ AvailabilityZone *string `json:"availabilityZone"`
+ // The list of available versions for upgrading the node pool.
+ AvailableUpgradeVersions *[]string `json:"availableUpgradeVersions,omitempty"`
+ // The total number of cores for the nodes.
+ CoresCount *int32 `json:"coresCount"`
+ // The CPU type for the nodes.
+ CpuFamily *string `json:"cpuFamily"`
// The unique identifier of the VDC where the worker nodes of the node pool are provisioned.Note that the data center is located in the exact place where the parent cluster of the node pool is located.
DatacenterId *string `json:"datacenterId"`
+ // The Kubernetes version running in the node pool. Note that this imposes restrictions on which Kubernetes versions can run in the node pools of a cluster. Also, not all Kubernetes versions are suitable upgrade targets for all earlier versions.
+ K8sVersion *string `json:"k8sVersion,omitempty"`
+ // The labels attached to the node pool.
+ Labels *map[string]string `json:"labels,omitempty"`
+ // The array of existing private LANs to attach to worker nodes.
+ Lans *[]KubernetesNodePoolLan `json:"lans,omitempty"`
+ MaintenanceWindow *KubernetesMaintenanceWindow `json:"maintenanceWindow,omitempty"`
+ // A Kubernetes node pool name. Valid Kubernetes node pool name must be 63 characters or less and must be empty or begin and end with an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between.
+ Name *string `json:"name"`
// The number of worker nodes of the node pool.
NodeCount *int32 `json:"nodeCount"`
- // The CPU type for the nodes.
- CpuFamily *string `json:"cpuFamily"`
- // The total number of cores for the nodes.
- CoresCount *int32 `json:"coresCount"`
+ // Optional array of reserved public IP addresses to be used by the nodes. The IPs must be from the exact location of the node pool's data center. If autoscaling is used, the array must contain one more IP than the maximum possible number of nodes (nodeCount+1 for a fixed number of nodes or maxNodeCount+1). The extra IP is used when the nodes are rebuilt.
+ PublicIps *[]string `json:"publicIps,omitempty"`
// The RAM size for the nodes. Must be specified in multiples of 1024 MB, with a minimum size of 2048 MB.
RamSize *int32 `json:"ramSize"`
- // The availability zone in which the target VM should be provisioned.
- AvailabilityZone *string `json:"availabilityZone"`
- // The storage type for the nodes.
- StorageType *string `json:"storageType"`
// The allocated volume size in GB. The allocated volume size in GB. To achieve good performance, we recommend a size greater than 100GB for SSD.
StorageSize *int32 `json:"storageSize"`
- // The Kubernetes version running in the node pool. Note that this imposes restrictions on which Kubernetes versions can run in the node pools of a cluster. Also, not all Kubernetes versions are suitable upgrade targets for all earlier versions.
- K8sVersion *string `json:"k8sVersion,omitempty"`
- MaintenanceWindow *KubernetesMaintenanceWindow `json:"maintenanceWindow,omitempty"`
- AutoScaling *KubernetesAutoScaling `json:"autoScaling,omitempty"`
- // The array of existing private LANs to attach to worker nodes.
- Lans *[]KubernetesNodePoolLan `json:"lans,omitempty"`
- // The labels attached to the node pool.
- Labels *map[string]string `json:"labels,omitempty"`
- // The annotations attached to the node pool.
- Annotations *map[string]string `json:"annotations,omitempty"`
- // Optional array of reserved public IP addresses to be used by the nodes. The IPs must be from the exact location of the node pool's data center. If autoscaling is used, the array must contain one more IP than the maximum possible number of nodes (nodeCount+1 for a fixed number of nodes or maxNodeCount+1). The extra IP is used when the nodes are rebuilt.
- PublicIps *[]string `json:"publicIps,omitempty"`
- // The list of available versions for upgrading the node pool.
- AvailableUpgradeVersions *[]string `json:"availableUpgradeVersions,omitempty"`
+ // The storage type for the nodes.
+ StorageType *string `json:"storageType"`
}
// NewKubernetesNodePoolProperties instantiates a new KubernetesNodePoolProperties object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewKubernetesNodePoolProperties(name string, datacenterId string, nodeCount int32, cpuFamily string, coresCount int32, ramSize int32, availabilityZone string, storageType string, storageSize int32) *KubernetesNodePoolProperties {
+func NewKubernetesNodePoolProperties(availabilityZone string, coresCount int32, cpuFamily string, datacenterId string, name string, nodeCount int32, ramSize int32, storageSize int32, storageType string) *KubernetesNodePoolProperties {
this := KubernetesNodePoolProperties{}
- this.Name = &name
+ this.AvailabilityZone = &availabilityZone
+ this.CoresCount = &coresCount
+ this.CpuFamily = &cpuFamily
this.DatacenterId = &datacenterId
+ this.Name = &name
this.NodeCount = &nodeCount
- this.CpuFamily = &cpuFamily
- this.CoresCount = &coresCount
this.RamSize = &ramSize
- this.AvailabilityZone = &availabilityZone
- this.StorageType = &storageType
this.StorageSize = &storageSize
+ this.StorageType = &storageType
return &this
}
@@ -78,152 +78,152 @@ func NewKubernetesNodePoolPropertiesWithDefaults() *KubernetesNodePoolProperties
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolProperties) GetName() *string {
+// GetAnnotations returns the Annotations field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetAnnotations() *map[string]string {
if o == nil {
return nil
}
- return o.Name
+ return o.Annotations
}
-// GetNameOk returns a tuple with the Name field value
+// GetAnnotationsOk returns a tuple with the Annotations field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetNameOk() (*string, bool) {
+func (o *KubernetesNodePoolProperties) GetAnnotationsOk() (*map[string]string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.Annotations, true
}
-// SetName sets field value
-func (o *KubernetesNodePoolProperties) SetName(v string) {
+// SetAnnotations sets field value
+func (o *KubernetesNodePoolProperties) SetAnnotations(v map[string]string) {
- o.Name = &v
+ o.Annotations = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasAnnotations returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasAnnotations() bool {
+ if o != nil && o.Annotations != nil {
return true
}
return false
}
-// GetDatacenterId returns the DatacenterId field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolProperties) GetDatacenterId() *string {
+// GetAutoScaling returns the AutoScaling field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetAutoScaling() *KubernetesAutoScaling {
if o == nil {
return nil
}
- return o.DatacenterId
+ return o.AutoScaling
}
-// GetDatacenterIdOk returns a tuple with the DatacenterId field value
+// GetAutoScalingOk returns a tuple with the AutoScaling field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetDatacenterIdOk() (*string, bool) {
+func (o *KubernetesNodePoolProperties) GetAutoScalingOk() (*KubernetesAutoScaling, bool) {
if o == nil {
return nil, false
}
- return o.DatacenterId, true
+ return o.AutoScaling, true
}
-// SetDatacenterId sets field value
-func (o *KubernetesNodePoolProperties) SetDatacenterId(v string) {
+// SetAutoScaling sets field value
+func (o *KubernetesNodePoolProperties) SetAutoScaling(v KubernetesAutoScaling) {
- o.DatacenterId = &v
+ o.AutoScaling = &v
}
-// HasDatacenterId returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasDatacenterId() bool {
- if o != nil && o.DatacenterId != nil {
+// HasAutoScaling returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasAutoScaling() bool {
+ if o != nil && o.AutoScaling != nil {
return true
}
return false
}
-// GetNodeCount returns the NodeCount field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *KubernetesNodePoolProperties) GetNodeCount() *int32 {
+// GetAvailabilityZone returns the AvailabilityZone field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetAvailabilityZone() *string {
if o == nil {
return nil
}
- return o.NodeCount
+ return o.AvailabilityZone
}
-// GetNodeCountOk returns a tuple with the NodeCount field value
+// GetAvailabilityZoneOk returns a tuple with the AvailabilityZone field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetNodeCountOk() (*int32, bool) {
+func (o *KubernetesNodePoolProperties) GetAvailabilityZoneOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.NodeCount, true
+ return o.AvailabilityZone, true
}
-// SetNodeCount sets field value
-func (o *KubernetesNodePoolProperties) SetNodeCount(v int32) {
+// SetAvailabilityZone sets field value
+func (o *KubernetesNodePoolProperties) SetAvailabilityZone(v string) {
- o.NodeCount = &v
+ o.AvailabilityZone = &v
}
-// HasNodeCount returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasNodeCount() bool {
- if o != nil && o.NodeCount != nil {
+// HasAvailabilityZone returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasAvailabilityZone() bool {
+ if o != nil && o.AvailabilityZone != nil {
return true
}
return false
}
-// GetCpuFamily returns the CpuFamily field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolProperties) GetCpuFamily() *string {
+// GetAvailableUpgradeVersions returns the AvailableUpgradeVersions field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetAvailableUpgradeVersions() *[]string {
if o == nil {
return nil
}
- return o.CpuFamily
+ return o.AvailableUpgradeVersions
}
-// GetCpuFamilyOk returns a tuple with the CpuFamily field value
+// GetAvailableUpgradeVersionsOk returns a tuple with the AvailableUpgradeVersions field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetCpuFamilyOk() (*string, bool) {
+func (o *KubernetesNodePoolProperties) GetAvailableUpgradeVersionsOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.CpuFamily, true
+ return o.AvailableUpgradeVersions, true
}
-// SetCpuFamily sets field value
-func (o *KubernetesNodePoolProperties) SetCpuFamily(v string) {
+// SetAvailableUpgradeVersions sets field value
+func (o *KubernetesNodePoolProperties) SetAvailableUpgradeVersions(v []string) {
- o.CpuFamily = &v
+ o.AvailableUpgradeVersions = &v
}
-// HasCpuFamily returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasCpuFamily() bool {
- if o != nil && o.CpuFamily != nil {
+// HasAvailableUpgradeVersions returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasAvailableUpgradeVersions() bool {
+ if o != nil && o.AvailableUpgradeVersions != nil {
return true
}
@@ -231,7 +231,7 @@ func (o *KubernetesNodePoolProperties) HasCpuFamily() bool {
}
// GetCoresCount returns the CoresCount field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesNodePoolProperties) GetCoresCount() *int32 {
if o == nil {
return nil
@@ -268,190 +268,190 @@ func (o *KubernetesNodePoolProperties) HasCoresCount() bool {
return false
}
-// GetRamSize returns the RamSize field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *KubernetesNodePoolProperties) GetRamSize() *int32 {
+// GetCpuFamily returns the CpuFamily field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetCpuFamily() *string {
if o == nil {
return nil
}
- return o.RamSize
+ return o.CpuFamily
}
-// GetRamSizeOk returns a tuple with the RamSize field value
+// GetCpuFamilyOk returns a tuple with the CpuFamily field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetRamSizeOk() (*int32, bool) {
+func (o *KubernetesNodePoolProperties) GetCpuFamilyOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.RamSize, true
+ return o.CpuFamily, true
}
-// SetRamSize sets field value
-func (o *KubernetesNodePoolProperties) SetRamSize(v int32) {
+// SetCpuFamily sets field value
+func (o *KubernetesNodePoolProperties) SetCpuFamily(v string) {
- o.RamSize = &v
+ o.CpuFamily = &v
}
-// HasRamSize returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasRamSize() bool {
- if o != nil && o.RamSize != nil {
+// HasCpuFamily returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasCpuFamily() bool {
+ if o != nil && o.CpuFamily != nil {
return true
}
return false
}
-// GetAvailabilityZone returns the AvailabilityZone field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolProperties) GetAvailabilityZone() *string {
+// GetDatacenterId returns the DatacenterId field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetDatacenterId() *string {
if o == nil {
return nil
}
- return o.AvailabilityZone
+ return o.DatacenterId
}
-// GetAvailabilityZoneOk returns a tuple with the AvailabilityZone field value
+// GetDatacenterIdOk returns a tuple with the DatacenterId field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetAvailabilityZoneOk() (*string, bool) {
+func (o *KubernetesNodePoolProperties) GetDatacenterIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.AvailabilityZone, true
+ return o.DatacenterId, true
}
-// SetAvailabilityZone sets field value
-func (o *KubernetesNodePoolProperties) SetAvailabilityZone(v string) {
+// SetDatacenterId sets field value
+func (o *KubernetesNodePoolProperties) SetDatacenterId(v string) {
- o.AvailabilityZone = &v
+ o.DatacenterId = &v
}
-// HasAvailabilityZone returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasAvailabilityZone() bool {
- if o != nil && o.AvailabilityZone != nil {
+// HasDatacenterId returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasDatacenterId() bool {
+ if o != nil && o.DatacenterId != nil {
return true
}
return false
}
-// GetStorageType returns the StorageType field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolProperties) GetStorageType() *string {
+// GetK8sVersion returns the K8sVersion field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetK8sVersion() *string {
if o == nil {
return nil
}
- return o.StorageType
+ return o.K8sVersion
}
-// GetStorageTypeOk returns a tuple with the StorageType field value
+// GetK8sVersionOk returns a tuple with the K8sVersion field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetStorageTypeOk() (*string, bool) {
+func (o *KubernetesNodePoolProperties) GetK8sVersionOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.StorageType, true
+ return o.K8sVersion, true
}
-// SetStorageType sets field value
-func (o *KubernetesNodePoolProperties) SetStorageType(v string) {
+// SetK8sVersion sets field value
+func (o *KubernetesNodePoolProperties) SetK8sVersion(v string) {
- o.StorageType = &v
+ o.K8sVersion = &v
}
-// HasStorageType returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasStorageType() bool {
- if o != nil && o.StorageType != nil {
+// HasK8sVersion returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasK8sVersion() bool {
+ if o != nil && o.K8sVersion != nil {
return true
}
return false
}
-// GetStorageSize returns the StorageSize field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *KubernetesNodePoolProperties) GetStorageSize() *int32 {
+// GetLabels returns the Labels field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetLabels() *map[string]string {
if o == nil {
return nil
}
- return o.StorageSize
+ return o.Labels
}
-// GetStorageSizeOk returns a tuple with the StorageSize field value
+// GetLabelsOk returns a tuple with the Labels field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetStorageSizeOk() (*int32, bool) {
+func (o *KubernetesNodePoolProperties) GetLabelsOk() (*map[string]string, bool) {
if o == nil {
return nil, false
}
- return o.StorageSize, true
+ return o.Labels, true
}
-// SetStorageSize sets field value
-func (o *KubernetesNodePoolProperties) SetStorageSize(v int32) {
+// SetLabels sets field value
+func (o *KubernetesNodePoolProperties) SetLabels(v map[string]string) {
- o.StorageSize = &v
+ o.Labels = &v
}
-// HasStorageSize returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasStorageSize() bool {
- if o != nil && o.StorageSize != nil {
+// HasLabels returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasLabels() bool {
+ if o != nil && o.Labels != nil {
return true
}
return false
}
-// GetK8sVersion returns the K8sVersion field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolProperties) GetK8sVersion() *string {
+// GetLans returns the Lans field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetLans() *[]KubernetesNodePoolLan {
if o == nil {
return nil
}
- return o.K8sVersion
+ return o.Lans
}
-// GetK8sVersionOk returns a tuple with the K8sVersion field value
+// GetLansOk returns a tuple with the Lans field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetK8sVersionOk() (*string, bool) {
+func (o *KubernetesNodePoolProperties) GetLansOk() (*[]KubernetesNodePoolLan, bool) {
if o == nil {
return nil, false
}
- return o.K8sVersion, true
+ return o.Lans, true
}
-// SetK8sVersion sets field value
-func (o *KubernetesNodePoolProperties) SetK8sVersion(v string) {
+// SetLans sets field value
+func (o *KubernetesNodePoolProperties) SetLans(v []KubernetesNodePoolLan) {
- o.K8sVersion = &v
+ o.Lans = &v
}
-// HasK8sVersion returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasK8sVersion() bool {
- if o != nil && o.K8sVersion != nil {
+// HasLans returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasLans() bool {
+ if o != nil && o.Lans != nil {
return true
}
@@ -459,7 +459,7 @@ func (o *KubernetesNodePoolProperties) HasK8sVersion() bool {
}
// GetMaintenanceWindow returns the MaintenanceWindow field value
-// If the value is explicit nil, the zero value for KubernetesMaintenanceWindow will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesNodePoolProperties) GetMaintenanceWindow() *KubernetesMaintenanceWindow {
if o == nil {
return nil
@@ -496,228 +496,228 @@ func (o *KubernetesNodePoolProperties) HasMaintenanceWindow() bool {
return false
}
-// GetAutoScaling returns the AutoScaling field value
-// If the value is explicit nil, the zero value for KubernetesAutoScaling will be returned
-func (o *KubernetesNodePoolProperties) GetAutoScaling() *KubernetesAutoScaling {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetName() *string {
if o == nil {
return nil
}
- return o.AutoScaling
+ return o.Name
}
-// GetAutoScalingOk returns a tuple with the AutoScaling field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetAutoScalingOk() (*KubernetesAutoScaling, bool) {
+func (o *KubernetesNodePoolProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.AutoScaling, true
+ return o.Name, true
}
-// SetAutoScaling sets field value
-func (o *KubernetesNodePoolProperties) SetAutoScaling(v KubernetesAutoScaling) {
+// SetName sets field value
+func (o *KubernetesNodePoolProperties) SetName(v string) {
- o.AutoScaling = &v
+ o.Name = &v
}
-// HasAutoScaling returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasAutoScaling() bool {
- if o != nil && o.AutoScaling != nil {
+// HasName returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetLans returns the Lans field value
-// If the value is explicit nil, the zero value for []KubernetesNodePoolLan will be returned
-func (o *KubernetesNodePoolProperties) GetLans() *[]KubernetesNodePoolLan {
+// GetNodeCount returns the NodeCount field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetNodeCount() *int32 {
if o == nil {
return nil
}
- return o.Lans
+ return o.NodeCount
}
-// GetLansOk returns a tuple with the Lans field value
+// GetNodeCountOk returns a tuple with the NodeCount field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetLansOk() (*[]KubernetesNodePoolLan, bool) {
+func (o *KubernetesNodePoolProperties) GetNodeCountOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Lans, true
+ return o.NodeCount, true
}
-// SetLans sets field value
-func (o *KubernetesNodePoolProperties) SetLans(v []KubernetesNodePoolLan) {
+// SetNodeCount sets field value
+func (o *KubernetesNodePoolProperties) SetNodeCount(v int32) {
- o.Lans = &v
+ o.NodeCount = &v
}
-// HasLans returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasLans() bool {
- if o != nil && o.Lans != nil {
+// HasNodeCount returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasNodeCount() bool {
+ if o != nil && o.NodeCount != nil {
return true
}
return false
}
-// GetLabels returns the Labels field value
-// If the value is explicit nil, the zero value for map[string]string will be returned
-func (o *KubernetesNodePoolProperties) GetLabels() *map[string]string {
+// GetPublicIps returns the PublicIps field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetPublicIps() *[]string {
if o == nil {
return nil
}
- return o.Labels
+ return o.PublicIps
}
-// GetLabelsOk returns a tuple with the Labels field value
+// GetPublicIpsOk returns a tuple with the PublicIps field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetLabelsOk() (*map[string]string, bool) {
+func (o *KubernetesNodePoolProperties) GetPublicIpsOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.Labels, true
+ return o.PublicIps, true
}
-// SetLabels sets field value
-func (o *KubernetesNodePoolProperties) SetLabels(v map[string]string) {
+// SetPublicIps sets field value
+func (o *KubernetesNodePoolProperties) SetPublicIps(v []string) {
- o.Labels = &v
+ o.PublicIps = &v
}
-// HasLabels returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasLabels() bool {
- if o != nil && o.Labels != nil {
+// HasPublicIps returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasPublicIps() bool {
+ if o != nil && o.PublicIps != nil {
return true
}
return false
}
-// GetAnnotations returns the Annotations field value
-// If the value is explicit nil, the zero value for map[string]string will be returned
-func (o *KubernetesNodePoolProperties) GetAnnotations() *map[string]string {
+// GetRamSize returns the RamSize field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetRamSize() *int32 {
if o == nil {
return nil
}
- return o.Annotations
+ return o.RamSize
}
-// GetAnnotationsOk returns a tuple with the Annotations field value
+// GetRamSizeOk returns a tuple with the RamSize field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetAnnotationsOk() (*map[string]string, bool) {
+func (o *KubernetesNodePoolProperties) GetRamSizeOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Annotations, true
+ return o.RamSize, true
}
-// SetAnnotations sets field value
-func (o *KubernetesNodePoolProperties) SetAnnotations(v map[string]string) {
+// SetRamSize sets field value
+func (o *KubernetesNodePoolProperties) SetRamSize(v int32) {
- o.Annotations = &v
+ o.RamSize = &v
}
-// HasAnnotations returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasAnnotations() bool {
- if o != nil && o.Annotations != nil {
+// HasRamSize returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasRamSize() bool {
+ if o != nil && o.RamSize != nil {
return true
}
return false
}
-// GetPublicIps returns the PublicIps field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *KubernetesNodePoolProperties) GetPublicIps() *[]string {
+// GetStorageSize returns the StorageSize field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetStorageSize() *int32 {
if o == nil {
return nil
}
- return o.PublicIps
+ return o.StorageSize
}
-// GetPublicIpsOk returns a tuple with the PublicIps field value
+// GetStorageSizeOk returns a tuple with the StorageSize field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetPublicIpsOk() (*[]string, bool) {
+func (o *KubernetesNodePoolProperties) GetStorageSizeOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.PublicIps, true
+ return o.StorageSize, true
}
-// SetPublicIps sets field value
-func (o *KubernetesNodePoolProperties) SetPublicIps(v []string) {
+// SetStorageSize sets field value
+func (o *KubernetesNodePoolProperties) SetStorageSize(v int32) {
- o.PublicIps = &v
+ o.StorageSize = &v
}
-// HasPublicIps returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasPublicIps() bool {
- if o != nil && o.PublicIps != nil {
+// HasStorageSize returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasStorageSize() bool {
+ if o != nil && o.StorageSize != nil {
return true
}
return false
}
-// GetAvailableUpgradeVersions returns the AvailableUpgradeVersions field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *KubernetesNodePoolProperties) GetAvailableUpgradeVersions() *[]string {
+// GetStorageType returns the StorageType field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolProperties) GetStorageType() *string {
if o == nil {
return nil
}
- return o.AvailableUpgradeVersions
+ return o.StorageType
}
-// GetAvailableUpgradeVersionsOk returns a tuple with the AvailableUpgradeVersions field value
+// GetStorageTypeOk returns a tuple with the StorageType field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolProperties) GetAvailableUpgradeVersionsOk() (*[]string, bool) {
+func (o *KubernetesNodePoolProperties) GetStorageTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.AvailableUpgradeVersions, true
+ return o.StorageType, true
}
-// SetAvailableUpgradeVersions sets field value
-func (o *KubernetesNodePoolProperties) SetAvailableUpgradeVersions(v []string) {
+// SetStorageType sets field value
+func (o *KubernetesNodePoolProperties) SetStorageType(v string) {
- o.AvailableUpgradeVersions = &v
+ o.StorageType = &v
}
-// HasAvailableUpgradeVersions returns a boolean if a field has been set.
-func (o *KubernetesNodePoolProperties) HasAvailableUpgradeVersions() bool {
- if o != nil && o.AvailableUpgradeVersions != nil {
+// HasStorageType returns a boolean if a field has been set.
+func (o *KubernetesNodePoolProperties) HasStorageType() bool {
+ if o != nil && o.StorageType != nil {
return true
}
@@ -726,57 +726,74 @@ func (o *KubernetesNodePoolProperties) HasAvailableUpgradeVersions() bool {
func (o KubernetesNodePoolProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
+ if o.Annotations != nil {
+ toSerialize["annotations"] = o.Annotations
}
- if o.DatacenterId != nil {
- toSerialize["datacenterId"] = o.DatacenterId
+
+ if o.AutoScaling != nil {
+ toSerialize["autoScaling"] = o.AutoScaling
}
- if o.NodeCount != nil {
- toSerialize["nodeCount"] = o.NodeCount
+
+ if o.AvailabilityZone != nil {
+ toSerialize["availabilityZone"] = o.AvailabilityZone
}
- if o.CpuFamily != nil {
- toSerialize["cpuFamily"] = o.CpuFamily
+
+ if o.AvailableUpgradeVersions != nil {
+ toSerialize["availableUpgradeVersions"] = o.AvailableUpgradeVersions
}
+
if o.CoresCount != nil {
toSerialize["coresCount"] = o.CoresCount
}
- if o.RamSize != nil {
- toSerialize["ramSize"] = o.RamSize
- }
- if o.AvailabilityZone != nil {
- toSerialize["availabilityZone"] = o.AvailabilityZone
- }
- if o.StorageType != nil {
- toSerialize["storageType"] = o.StorageType
+
+ if o.CpuFamily != nil {
+ toSerialize["cpuFamily"] = o.CpuFamily
}
- if o.StorageSize != nil {
- toSerialize["storageSize"] = o.StorageSize
+
+ if o.DatacenterId != nil {
+ toSerialize["datacenterId"] = o.DatacenterId
}
+
if o.K8sVersion != nil {
toSerialize["k8sVersion"] = o.K8sVersion
}
- if o.MaintenanceWindow != nil {
- toSerialize["maintenanceWindow"] = o.MaintenanceWindow
- }
- if o.AutoScaling != nil {
- toSerialize["autoScaling"] = o.AutoScaling
+
+ if o.Labels != nil {
+ toSerialize["labels"] = o.Labels
}
+
if o.Lans != nil {
toSerialize["lans"] = o.Lans
}
- if o.Labels != nil {
- toSerialize["labels"] = o.Labels
+
+ if o.MaintenanceWindow != nil {
+ toSerialize["maintenanceWindow"] = o.MaintenanceWindow
}
- if o.Annotations != nil {
- toSerialize["annotations"] = o.Annotations
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
+ if o.NodeCount != nil {
+ toSerialize["nodeCount"] = o.NodeCount
}
+
if o.PublicIps != nil {
toSerialize["publicIps"] = o.PublicIps
}
- if o.AvailableUpgradeVersions != nil {
- toSerialize["availableUpgradeVersions"] = o.AvailableUpgradeVersions
+
+ if o.RamSize != nil {
+ toSerialize["ramSize"] = o.RamSize
}
+
+ if o.StorageSize != nil {
+ toSerialize["storageSize"] = o.StorageSize
+ }
+
+ if o.StorageType != nil {
+ toSerialize["storageType"] = o.StorageType
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_properties_for_post.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_properties_for_post.go
index dff10d33854..c55191cfa07 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_properties_for_post.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_properties_for_post.go
@@ -16,54 +16,54 @@ import (
// KubernetesNodePoolPropertiesForPost struct for KubernetesNodePoolPropertiesForPost
type KubernetesNodePoolPropertiesForPost struct {
- // A Kubernetes node pool name. Valid Kubernetes node pool name must be 63 characters or less and must be empty or begin and end with an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between.
- Name *string `json:"name"`
+ // The annotations attached to the node pool.
+ Annotations *map[string]string `json:"annotations,omitempty"`
+ AutoScaling *KubernetesAutoScaling `json:"autoScaling,omitempty"`
+ // The availability zone in which the target VM should be provisioned.
+ AvailabilityZone *string `json:"availabilityZone"`
+ // The total number of cores for the nodes.
+ CoresCount *int32 `json:"coresCount"`
+ // The CPU type for the nodes.
+ CpuFamily *string `json:"cpuFamily"`
// The unique identifier of the VDC where the worker nodes of the node pool are provisioned.Note that the data center is located in the exact place where the parent cluster of the node pool is located.
DatacenterId *string `json:"datacenterId"`
+ // The Kubernetes version running in the node pool. Note that this imposes restrictions on which Kubernetes versions can run in the node pools of a cluster. Also, not all Kubernetes versions are suitable upgrade targets for all earlier versions.
+ K8sVersion *string `json:"k8sVersion,omitempty"`
+ // The labels attached to the node pool.
+ Labels *map[string]string `json:"labels,omitempty"`
+ // The array of existing private LANs to attach to worker nodes.
+ Lans *[]KubernetesNodePoolLan `json:"lans,omitempty"`
+ MaintenanceWindow *KubernetesMaintenanceWindow `json:"maintenanceWindow,omitempty"`
+ // A Kubernetes node pool name. Valid Kubernetes node pool name must be 63 characters or less and must be empty or begin and end with an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between.
+ Name *string `json:"name"`
// The number of worker nodes of the node pool.
NodeCount *int32 `json:"nodeCount"`
- // The CPU type for the nodes.
- CpuFamily *string `json:"cpuFamily"`
- // The total number of cores for the nodes.
- CoresCount *int32 `json:"coresCount"`
+ // Optional array of reserved public IP addresses to be used by the nodes. The IPs must be from the exact location of the node pool's data center. If autoscaling is used, the array must contain one more IP than the maximum possible number of nodes (nodeCount+1 for a fixed number of nodes or maxNodeCount+1). The extra IP is used when the nodes are rebuilt.
+ PublicIps *[]string `json:"publicIps,omitempty"`
// The RAM size for the nodes. Must be specified in multiples of 1024 MB, with a minimum size of 2048 MB.
RamSize *int32 `json:"ramSize"`
- // The availability zone in which the target VM should be provisioned.
- AvailabilityZone *string `json:"availabilityZone"`
- // The storage type for the nodes.
- StorageType *string `json:"storageType"`
// The allocated volume size in GB. The allocated volume size in GB. To achieve good performance, we recommend a size greater than 100GB for SSD.
StorageSize *int32 `json:"storageSize"`
- // The Kubernetes version running in the node pool. Note that this imposes restrictions on which Kubernetes versions can run in the node pools of a cluster. Also, not all Kubernetes versions are suitable upgrade targets for all earlier versions.
- K8sVersion *string `json:"k8sVersion,omitempty"`
- MaintenanceWindow *KubernetesMaintenanceWindow `json:"maintenanceWindow,omitempty"`
- AutoScaling *KubernetesAutoScaling `json:"autoScaling,omitempty"`
- // The array of existing private LANs to attach to worker nodes.
- Lans *[]KubernetesNodePoolLan `json:"lans,omitempty"`
- // The labels attached to the node pool.
- Labels *map[string]string `json:"labels,omitempty"`
- // The annotations attached to the node pool.
- Annotations *map[string]string `json:"annotations,omitempty"`
- // Optional array of reserved public IP addresses to be used by the nodes. The IPs must be from the exact location of the node pool's data center. If autoscaling is used, the array must contain one more IP than the maximum possible number of nodes (nodeCount+1 for a fixed number of nodes or maxNodeCount+1). The extra IP is used when the nodes are rebuilt.
- PublicIps *[]string `json:"publicIps,omitempty"`
+ // The storage type for the nodes.
+ StorageType *string `json:"storageType"`
}
// NewKubernetesNodePoolPropertiesForPost instantiates a new KubernetesNodePoolPropertiesForPost object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewKubernetesNodePoolPropertiesForPost(name string, datacenterId string, nodeCount int32, cpuFamily string, coresCount int32, ramSize int32, availabilityZone string, storageType string, storageSize int32) *KubernetesNodePoolPropertiesForPost {
+func NewKubernetesNodePoolPropertiesForPost(availabilityZone string, coresCount int32, cpuFamily string, datacenterId string, name string, nodeCount int32, ramSize int32, storageSize int32, storageType string) *KubernetesNodePoolPropertiesForPost {
this := KubernetesNodePoolPropertiesForPost{}
- this.Name = &name
+ this.AvailabilityZone = &availabilityZone
+ this.CoresCount = &coresCount
+ this.CpuFamily = &cpuFamily
this.DatacenterId = &datacenterId
+ this.Name = &name
this.NodeCount = &nodeCount
- this.CpuFamily = &cpuFamily
- this.CoresCount = &coresCount
this.RamSize = &ramSize
- this.AvailabilityZone = &availabilityZone
- this.StorageType = &storageType
this.StorageSize = &storageSize
+ this.StorageType = &storageType
return &this
}
@@ -76,608 +76,608 @@ func NewKubernetesNodePoolPropertiesForPostWithDefaults() *KubernetesNodePoolPro
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetName() *string {
+// GetAnnotations returns the Annotations field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetAnnotations() *map[string]string {
if o == nil {
return nil
}
- return o.Name
+ return o.Annotations
}
-// GetNameOk returns a tuple with the Name field value
+// GetAnnotationsOk returns a tuple with the Annotations field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetNameOk() (*string, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetAnnotationsOk() (*map[string]string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.Annotations, true
}
-// SetName sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetName(v string) {
+// SetAnnotations sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetAnnotations(v map[string]string) {
- o.Name = &v
+ o.Annotations = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasName() bool {
- if o != nil && o.Name != nil {
+// HasAnnotations returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasAnnotations() bool {
+ if o != nil && o.Annotations != nil {
return true
}
return false
}
-// GetDatacenterId returns the DatacenterId field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetDatacenterId() *string {
+// GetAutoScaling returns the AutoScaling field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetAutoScaling() *KubernetesAutoScaling {
if o == nil {
return nil
}
- return o.DatacenterId
+ return o.AutoScaling
}
-// GetDatacenterIdOk returns a tuple with the DatacenterId field value
+// GetAutoScalingOk returns a tuple with the AutoScaling field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetDatacenterIdOk() (*string, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetAutoScalingOk() (*KubernetesAutoScaling, bool) {
if o == nil {
return nil, false
}
- return o.DatacenterId, true
+ return o.AutoScaling, true
}
-// SetDatacenterId sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetDatacenterId(v string) {
+// SetAutoScaling sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetAutoScaling(v KubernetesAutoScaling) {
- o.DatacenterId = &v
+ o.AutoScaling = &v
}
-// HasDatacenterId returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasDatacenterId() bool {
- if o != nil && o.DatacenterId != nil {
+// HasAutoScaling returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasAutoScaling() bool {
+ if o != nil && o.AutoScaling != nil {
return true
}
return false
}
-// GetNodeCount returns the NodeCount field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetNodeCount() *int32 {
+// GetAvailabilityZone returns the AvailabilityZone field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetAvailabilityZone() *string {
if o == nil {
return nil
}
- return o.NodeCount
+ return o.AvailabilityZone
}
-// GetNodeCountOk returns a tuple with the NodeCount field value
+// GetAvailabilityZoneOk returns a tuple with the AvailabilityZone field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetNodeCountOk() (*int32, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetAvailabilityZoneOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.NodeCount, true
+ return o.AvailabilityZone, true
}
-// SetNodeCount sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetNodeCount(v int32) {
+// SetAvailabilityZone sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetAvailabilityZone(v string) {
- o.NodeCount = &v
+ o.AvailabilityZone = &v
}
-// HasNodeCount returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasNodeCount() bool {
- if o != nil && o.NodeCount != nil {
+// HasAvailabilityZone returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasAvailabilityZone() bool {
+ if o != nil && o.AvailabilityZone != nil {
return true
}
return false
}
-// GetCpuFamily returns the CpuFamily field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetCpuFamily() *string {
+// GetCoresCount returns the CoresCount field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetCoresCount() *int32 {
if o == nil {
return nil
}
- return o.CpuFamily
+ return o.CoresCount
}
-// GetCpuFamilyOk returns a tuple with the CpuFamily field value
+// GetCoresCountOk returns a tuple with the CoresCount field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetCpuFamilyOk() (*string, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetCoresCountOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.CpuFamily, true
+ return o.CoresCount, true
}
-// SetCpuFamily sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetCpuFamily(v string) {
+// SetCoresCount sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetCoresCount(v int32) {
- o.CpuFamily = &v
+ o.CoresCount = &v
}
-// HasCpuFamily returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasCpuFamily() bool {
- if o != nil && o.CpuFamily != nil {
+// HasCoresCount returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasCoresCount() bool {
+ if o != nil && o.CoresCount != nil {
return true
}
return false
}
-// GetCoresCount returns the CoresCount field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetCoresCount() *int32 {
+// GetCpuFamily returns the CpuFamily field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetCpuFamily() *string {
if o == nil {
return nil
}
- return o.CoresCount
+ return o.CpuFamily
}
-// GetCoresCountOk returns a tuple with the CoresCount field value
+// GetCpuFamilyOk returns a tuple with the CpuFamily field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetCoresCountOk() (*int32, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetCpuFamilyOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.CoresCount, true
+ return o.CpuFamily, true
}
-// SetCoresCount sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetCoresCount(v int32) {
+// SetCpuFamily sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetCpuFamily(v string) {
- o.CoresCount = &v
+ o.CpuFamily = &v
}
-// HasCoresCount returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasCoresCount() bool {
- if o != nil && o.CoresCount != nil {
+// HasCpuFamily returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasCpuFamily() bool {
+ if o != nil && o.CpuFamily != nil {
return true
}
return false
}
-// GetRamSize returns the RamSize field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetRamSize() *int32 {
+// GetDatacenterId returns the DatacenterId field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetDatacenterId() *string {
if o == nil {
return nil
}
- return o.RamSize
+ return o.DatacenterId
}
-// GetRamSizeOk returns a tuple with the RamSize field value
+// GetDatacenterIdOk returns a tuple with the DatacenterId field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetRamSizeOk() (*int32, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetDatacenterIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.RamSize, true
+ return o.DatacenterId, true
}
-// SetRamSize sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetRamSize(v int32) {
+// SetDatacenterId sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetDatacenterId(v string) {
- o.RamSize = &v
+ o.DatacenterId = &v
}
-// HasRamSize returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasRamSize() bool {
- if o != nil && o.RamSize != nil {
+// HasDatacenterId returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasDatacenterId() bool {
+ if o != nil && o.DatacenterId != nil {
return true
}
return false
}
-// GetAvailabilityZone returns the AvailabilityZone field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetAvailabilityZone() *string {
+// GetK8sVersion returns the K8sVersion field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetK8sVersion() *string {
if o == nil {
return nil
}
- return o.AvailabilityZone
+ return o.K8sVersion
}
-// GetAvailabilityZoneOk returns a tuple with the AvailabilityZone field value
+// GetK8sVersionOk returns a tuple with the K8sVersion field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetAvailabilityZoneOk() (*string, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetK8sVersionOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.AvailabilityZone, true
+ return o.K8sVersion, true
}
-// SetAvailabilityZone sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetAvailabilityZone(v string) {
+// SetK8sVersion sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetK8sVersion(v string) {
- o.AvailabilityZone = &v
+ o.K8sVersion = &v
}
-// HasAvailabilityZone returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasAvailabilityZone() bool {
- if o != nil && o.AvailabilityZone != nil {
+// HasK8sVersion returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasK8sVersion() bool {
+ if o != nil && o.K8sVersion != nil {
return true
}
return false
}
-// GetStorageType returns the StorageType field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetStorageType() *string {
+// GetLabels returns the Labels field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetLabels() *map[string]string {
if o == nil {
return nil
}
- return o.StorageType
+ return o.Labels
}
-// GetStorageTypeOk returns a tuple with the StorageType field value
+// GetLabelsOk returns a tuple with the Labels field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetStorageTypeOk() (*string, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetLabelsOk() (*map[string]string, bool) {
if o == nil {
return nil, false
}
- return o.StorageType, true
+ return o.Labels, true
}
-// SetStorageType sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetStorageType(v string) {
+// SetLabels sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetLabels(v map[string]string) {
- o.StorageType = &v
+ o.Labels = &v
}
-// HasStorageType returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasStorageType() bool {
- if o != nil && o.StorageType != nil {
+// HasLabels returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasLabels() bool {
+ if o != nil && o.Labels != nil {
return true
}
return false
}
-// GetStorageSize returns the StorageSize field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetStorageSize() *int32 {
+// GetLans returns the Lans field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetLans() *[]KubernetesNodePoolLan {
if o == nil {
return nil
}
- return o.StorageSize
+ return o.Lans
}
-// GetStorageSizeOk returns a tuple with the StorageSize field value
+// GetLansOk returns a tuple with the Lans field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetStorageSizeOk() (*int32, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetLansOk() (*[]KubernetesNodePoolLan, bool) {
if o == nil {
return nil, false
}
- return o.StorageSize, true
+ return o.Lans, true
}
-// SetStorageSize sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetStorageSize(v int32) {
+// SetLans sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetLans(v []KubernetesNodePoolLan) {
- o.StorageSize = &v
+ o.Lans = &v
}
-// HasStorageSize returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasStorageSize() bool {
- if o != nil && o.StorageSize != nil {
+// HasLans returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasLans() bool {
+ if o != nil && o.Lans != nil {
return true
}
return false
}
-// GetK8sVersion returns the K8sVersion field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetK8sVersion() *string {
+// GetMaintenanceWindow returns the MaintenanceWindow field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetMaintenanceWindow() *KubernetesMaintenanceWindow {
if o == nil {
return nil
}
- return o.K8sVersion
+ return o.MaintenanceWindow
}
-// GetK8sVersionOk returns a tuple with the K8sVersion field value
+// GetMaintenanceWindowOk returns a tuple with the MaintenanceWindow field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetK8sVersionOk() (*string, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetMaintenanceWindowOk() (*KubernetesMaintenanceWindow, bool) {
if o == nil {
return nil, false
}
- return o.K8sVersion, true
+ return o.MaintenanceWindow, true
}
-// SetK8sVersion sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetK8sVersion(v string) {
+// SetMaintenanceWindow sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetMaintenanceWindow(v KubernetesMaintenanceWindow) {
- o.K8sVersion = &v
+ o.MaintenanceWindow = &v
}
-// HasK8sVersion returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasK8sVersion() bool {
- if o != nil && o.K8sVersion != nil {
+// HasMaintenanceWindow returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasMaintenanceWindow() bool {
+ if o != nil && o.MaintenanceWindow != nil {
return true
}
return false
}
-// GetMaintenanceWindow returns the MaintenanceWindow field value
-// If the value is explicit nil, the zero value for KubernetesMaintenanceWindow will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetMaintenanceWindow() *KubernetesMaintenanceWindow {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetName() *string {
if o == nil {
return nil
}
- return o.MaintenanceWindow
+ return o.Name
}
-// GetMaintenanceWindowOk returns a tuple with the MaintenanceWindow field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetMaintenanceWindowOk() (*KubernetesMaintenanceWindow, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.MaintenanceWindow, true
+ return o.Name, true
}
-// SetMaintenanceWindow sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetMaintenanceWindow(v KubernetesMaintenanceWindow) {
+// SetName sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetName(v string) {
- o.MaintenanceWindow = &v
+ o.Name = &v
}
-// HasMaintenanceWindow returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasMaintenanceWindow() bool {
- if o != nil && o.MaintenanceWindow != nil {
+// HasName returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetAutoScaling returns the AutoScaling field value
-// If the value is explicit nil, the zero value for KubernetesAutoScaling will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetAutoScaling() *KubernetesAutoScaling {
+// GetNodeCount returns the NodeCount field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetNodeCount() *int32 {
if o == nil {
return nil
}
- return o.AutoScaling
+ return o.NodeCount
}
-// GetAutoScalingOk returns a tuple with the AutoScaling field value
+// GetNodeCountOk returns a tuple with the NodeCount field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetAutoScalingOk() (*KubernetesAutoScaling, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetNodeCountOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.AutoScaling, true
+ return o.NodeCount, true
}
-// SetAutoScaling sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetAutoScaling(v KubernetesAutoScaling) {
+// SetNodeCount sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetNodeCount(v int32) {
- o.AutoScaling = &v
+ o.NodeCount = &v
}
-// HasAutoScaling returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasAutoScaling() bool {
- if o != nil && o.AutoScaling != nil {
+// HasNodeCount returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasNodeCount() bool {
+ if o != nil && o.NodeCount != nil {
return true
}
return false
}
-// GetLans returns the Lans field value
-// If the value is explicit nil, the zero value for []KubernetesNodePoolLan will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetLans() *[]KubernetesNodePoolLan {
+// GetPublicIps returns the PublicIps field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetPublicIps() *[]string {
if o == nil {
return nil
}
- return o.Lans
+ return o.PublicIps
}
-// GetLansOk returns a tuple with the Lans field value
+// GetPublicIpsOk returns a tuple with the PublicIps field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetLansOk() (*[]KubernetesNodePoolLan, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetPublicIpsOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.Lans, true
+ return o.PublicIps, true
}
-// SetLans sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetLans(v []KubernetesNodePoolLan) {
+// SetPublicIps sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetPublicIps(v []string) {
- o.Lans = &v
+ o.PublicIps = &v
}
-// HasLans returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasLans() bool {
- if o != nil && o.Lans != nil {
+// HasPublicIps returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasPublicIps() bool {
+ if o != nil && o.PublicIps != nil {
return true
}
return false
}
-// GetLabels returns the Labels field value
-// If the value is explicit nil, the zero value for map[string]string will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetLabels() *map[string]string {
+// GetRamSize returns the RamSize field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetRamSize() *int32 {
if o == nil {
return nil
}
- return o.Labels
+ return o.RamSize
}
-// GetLabelsOk returns a tuple with the Labels field value
+// GetRamSizeOk returns a tuple with the RamSize field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetLabelsOk() (*map[string]string, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetRamSizeOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Labels, true
+ return o.RamSize, true
}
-// SetLabels sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetLabels(v map[string]string) {
+// SetRamSize sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetRamSize(v int32) {
- o.Labels = &v
+ o.RamSize = &v
}
-// HasLabels returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasLabels() bool {
- if o != nil && o.Labels != nil {
+// HasRamSize returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasRamSize() bool {
+ if o != nil && o.RamSize != nil {
return true
}
return false
}
-// GetAnnotations returns the Annotations field value
-// If the value is explicit nil, the zero value for map[string]string will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetAnnotations() *map[string]string {
+// GetStorageSize returns the StorageSize field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetStorageSize() *int32 {
if o == nil {
return nil
}
- return o.Annotations
+ return o.StorageSize
}
-// GetAnnotationsOk returns a tuple with the Annotations field value
+// GetStorageSizeOk returns a tuple with the StorageSize field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetAnnotationsOk() (*map[string]string, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetStorageSizeOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Annotations, true
+ return o.StorageSize, true
}
-// SetAnnotations sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetAnnotations(v map[string]string) {
+// SetStorageSize sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetStorageSize(v int32) {
- o.Annotations = &v
+ o.StorageSize = &v
}
-// HasAnnotations returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasAnnotations() bool {
- if o != nil && o.Annotations != nil {
+// HasStorageSize returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasStorageSize() bool {
+ if o != nil && o.StorageSize != nil {
return true
}
return false
}
-// GetPublicIps returns the PublicIps field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetPublicIps() *[]string {
+// GetStorageType returns the StorageType field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPost) GetStorageType() *string {
if o == nil {
return nil
}
- return o.PublicIps
+ return o.StorageType
}
-// GetPublicIpsOk returns a tuple with the PublicIps field value
+// GetStorageTypeOk returns a tuple with the StorageType field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPost) GetPublicIpsOk() (*[]string, bool) {
+func (o *KubernetesNodePoolPropertiesForPost) GetStorageTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.PublicIps, true
+ return o.StorageType, true
}
-// SetPublicIps sets field value
-func (o *KubernetesNodePoolPropertiesForPost) SetPublicIps(v []string) {
+// SetStorageType sets field value
+func (o *KubernetesNodePoolPropertiesForPost) SetStorageType(v string) {
- o.PublicIps = &v
+ o.StorageType = &v
}
-// HasPublicIps returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPost) HasPublicIps() bool {
- if o != nil && o.PublicIps != nil {
+// HasStorageType returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPost) HasStorageType() bool {
+ if o != nil && o.StorageType != nil {
return true
}
@@ -686,54 +686,70 @@ func (o *KubernetesNodePoolPropertiesForPost) HasPublicIps() bool {
func (o KubernetesNodePoolPropertiesForPost) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
- }
- if o.DatacenterId != nil {
- toSerialize["datacenterId"] = o.DatacenterId
+ if o.Annotations != nil {
+ toSerialize["annotations"] = o.Annotations
}
- if o.NodeCount != nil {
- toSerialize["nodeCount"] = o.NodeCount
+
+ if o.AutoScaling != nil {
+ toSerialize["autoScaling"] = o.AutoScaling
}
- if o.CpuFamily != nil {
- toSerialize["cpuFamily"] = o.CpuFamily
+
+ if o.AvailabilityZone != nil {
+ toSerialize["availabilityZone"] = o.AvailabilityZone
}
+
if o.CoresCount != nil {
toSerialize["coresCount"] = o.CoresCount
}
- if o.RamSize != nil {
- toSerialize["ramSize"] = o.RamSize
- }
- if o.AvailabilityZone != nil {
- toSerialize["availabilityZone"] = o.AvailabilityZone
- }
- if o.StorageType != nil {
- toSerialize["storageType"] = o.StorageType
+
+ if o.CpuFamily != nil {
+ toSerialize["cpuFamily"] = o.CpuFamily
}
- if o.StorageSize != nil {
- toSerialize["storageSize"] = o.StorageSize
+
+ if o.DatacenterId != nil {
+ toSerialize["datacenterId"] = o.DatacenterId
}
+
if o.K8sVersion != nil {
toSerialize["k8sVersion"] = o.K8sVersion
}
- if o.MaintenanceWindow != nil {
- toSerialize["maintenanceWindow"] = o.MaintenanceWindow
- }
- if o.AutoScaling != nil {
- toSerialize["autoScaling"] = o.AutoScaling
+
+ if o.Labels != nil {
+ toSerialize["labels"] = o.Labels
}
+
if o.Lans != nil {
toSerialize["lans"] = o.Lans
}
- if o.Labels != nil {
- toSerialize["labels"] = o.Labels
+
+ if o.MaintenanceWindow != nil {
+ toSerialize["maintenanceWindow"] = o.MaintenanceWindow
}
- if o.Annotations != nil {
- toSerialize["annotations"] = o.Annotations
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
}
+
+ if o.NodeCount != nil {
+ toSerialize["nodeCount"] = o.NodeCount
+ }
+
if o.PublicIps != nil {
toSerialize["publicIps"] = o.PublicIps
}
+
+ if o.RamSize != nil {
+ toSerialize["ramSize"] = o.RamSize
+ }
+
+ if o.StorageSize != nil {
+ toSerialize["storageSize"] = o.StorageSize
+ }
+
+ if o.StorageType != nil {
+ toSerialize["storageType"] = o.StorageType
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_properties_for_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_properties_for_put.go
index 88c31def64e..3e82ea9c496 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_properties_for_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pool_properties_for_put.go
@@ -16,20 +16,20 @@ import (
// KubernetesNodePoolPropertiesForPut struct for KubernetesNodePoolPropertiesForPut
type KubernetesNodePoolPropertiesForPut struct {
+ // The annotations attached to the node pool.
+ Annotations *map[string]string `json:"annotations,omitempty"`
+ AutoScaling *KubernetesAutoScaling `json:"autoScaling,omitempty"`
+ // The Kubernetes version running in the node pool. Note that this imposes restrictions on which Kubernetes versions can run in the node pools of a cluster. Also, not all Kubernetes versions are suitable upgrade targets for all earlier versions.
+ K8sVersion *string `json:"k8sVersion,omitempty"`
+ // The labels attached to the node pool.
+ Labels *map[string]string `json:"labels,omitempty"`
+ // The array of existing private LANs to attach to worker nodes.
+ Lans *[]KubernetesNodePoolLan `json:"lans,omitempty"`
+ MaintenanceWindow *KubernetesMaintenanceWindow `json:"maintenanceWindow,omitempty"`
// A Kubernetes node pool name. Valid Kubernetes node pool name must be 63 characters or less and must be empty or begin and end with an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between.
Name *string `json:"name,omitempty"`
// The number of worker nodes of the node pool.
NodeCount *int32 `json:"nodeCount"`
- // The Kubernetes version running in the node pool. Note that this imposes restrictions on which Kubernetes versions can run in the node pools of a cluster. Also, not all Kubernetes versions are suitable upgrade targets for all earlier versions.
- K8sVersion *string `json:"k8sVersion,omitempty"`
- MaintenanceWindow *KubernetesMaintenanceWindow `json:"maintenanceWindow,omitempty"`
- AutoScaling *KubernetesAutoScaling `json:"autoScaling,omitempty"`
- // The array of existing private LANs to attach to worker nodes.
- Lans *[]KubernetesNodePoolLan `json:"lans,omitempty"`
- // The labels attached to the node pool.
- Labels *map[string]string `json:"labels,omitempty"`
- // The annotations attached to the node pool.
- Annotations *map[string]string `json:"annotations,omitempty"`
// Optional array of reserved public IP addresses to be used by the nodes. The IPs must be from the exact location of the node pool's data center. If autoscaling is used, the array must contain one more IP than the maximum possible number of nodes (nodeCount+1 for a fixed number of nodes or maxNodeCount+1). The extra IP is used when the nodes are rebuilt.
PublicIps *[]string `json:"publicIps,omitempty"`
}
@@ -54,76 +54,76 @@ func NewKubernetesNodePoolPropertiesForPutWithDefaults() *KubernetesNodePoolProp
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetName() *string {
+// GetAnnotations returns the Annotations field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPut) GetAnnotations() *map[string]string {
if o == nil {
return nil
}
- return o.Name
+ return o.Annotations
}
-// GetNameOk returns a tuple with the Name field value
+// GetAnnotationsOk returns a tuple with the Annotations field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetNameOk() (*string, bool) {
+func (o *KubernetesNodePoolPropertiesForPut) GetAnnotationsOk() (*map[string]string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.Annotations, true
}
-// SetName sets field value
-func (o *KubernetesNodePoolPropertiesForPut) SetName(v string) {
+// SetAnnotations sets field value
+func (o *KubernetesNodePoolPropertiesForPut) SetAnnotations(v map[string]string) {
- o.Name = &v
+ o.Annotations = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPut) HasName() bool {
- if o != nil && o.Name != nil {
+// HasAnnotations returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPut) HasAnnotations() bool {
+ if o != nil && o.Annotations != nil {
return true
}
return false
}
-// GetNodeCount returns the NodeCount field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetNodeCount() *int32 {
+// GetAutoScaling returns the AutoScaling field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPut) GetAutoScaling() *KubernetesAutoScaling {
if o == nil {
return nil
}
- return o.NodeCount
+ return o.AutoScaling
}
-// GetNodeCountOk returns a tuple with the NodeCount field value
+// GetAutoScalingOk returns a tuple with the AutoScaling field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetNodeCountOk() (*int32, bool) {
+func (o *KubernetesNodePoolPropertiesForPut) GetAutoScalingOk() (*KubernetesAutoScaling, bool) {
if o == nil {
return nil, false
}
- return o.NodeCount, true
+ return o.AutoScaling, true
}
-// SetNodeCount sets field value
-func (o *KubernetesNodePoolPropertiesForPut) SetNodeCount(v int32) {
+// SetAutoScaling sets field value
+func (o *KubernetesNodePoolPropertiesForPut) SetAutoScaling(v KubernetesAutoScaling) {
- o.NodeCount = &v
+ o.AutoScaling = &v
}
-// HasNodeCount returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPut) HasNodeCount() bool {
- if o != nil && o.NodeCount != nil {
+// HasAutoScaling returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPut) HasAutoScaling() bool {
+ if o != nil && o.AutoScaling != nil {
return true
}
@@ -131,7 +131,7 @@ func (o *KubernetesNodePoolPropertiesForPut) HasNodeCount() bool {
}
// GetK8sVersion returns the K8sVersion field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesNodePoolPropertiesForPut) GetK8sVersion() *string {
if o == nil {
return nil
@@ -168,190 +168,190 @@ func (o *KubernetesNodePoolPropertiesForPut) HasK8sVersion() bool {
return false
}
-// GetMaintenanceWindow returns the MaintenanceWindow field value
-// If the value is explicit nil, the zero value for KubernetesMaintenanceWindow will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetMaintenanceWindow() *KubernetesMaintenanceWindow {
+// GetLabels returns the Labels field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPut) GetLabels() *map[string]string {
if o == nil {
return nil
}
- return o.MaintenanceWindow
+ return o.Labels
}
-// GetMaintenanceWindowOk returns a tuple with the MaintenanceWindow field value
+// GetLabelsOk returns a tuple with the Labels field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetMaintenanceWindowOk() (*KubernetesMaintenanceWindow, bool) {
+func (o *KubernetesNodePoolPropertiesForPut) GetLabelsOk() (*map[string]string, bool) {
if o == nil {
return nil, false
}
- return o.MaintenanceWindow, true
+ return o.Labels, true
}
-// SetMaintenanceWindow sets field value
-func (o *KubernetesNodePoolPropertiesForPut) SetMaintenanceWindow(v KubernetesMaintenanceWindow) {
+// SetLabels sets field value
+func (o *KubernetesNodePoolPropertiesForPut) SetLabels(v map[string]string) {
- o.MaintenanceWindow = &v
+ o.Labels = &v
}
-// HasMaintenanceWindow returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPut) HasMaintenanceWindow() bool {
- if o != nil && o.MaintenanceWindow != nil {
+// HasLabels returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPut) HasLabels() bool {
+ if o != nil && o.Labels != nil {
return true
}
return false
}
-// GetAutoScaling returns the AutoScaling field value
-// If the value is explicit nil, the zero value for KubernetesAutoScaling will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetAutoScaling() *KubernetesAutoScaling {
+// GetLans returns the Lans field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPut) GetLans() *[]KubernetesNodePoolLan {
if o == nil {
return nil
}
- return o.AutoScaling
+ return o.Lans
}
-// GetAutoScalingOk returns a tuple with the AutoScaling field value
+// GetLansOk returns a tuple with the Lans field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetAutoScalingOk() (*KubernetesAutoScaling, bool) {
+func (o *KubernetesNodePoolPropertiesForPut) GetLansOk() (*[]KubernetesNodePoolLan, bool) {
if o == nil {
return nil, false
}
- return o.AutoScaling, true
+ return o.Lans, true
}
-// SetAutoScaling sets field value
-func (o *KubernetesNodePoolPropertiesForPut) SetAutoScaling(v KubernetesAutoScaling) {
+// SetLans sets field value
+func (o *KubernetesNodePoolPropertiesForPut) SetLans(v []KubernetesNodePoolLan) {
- o.AutoScaling = &v
+ o.Lans = &v
}
-// HasAutoScaling returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPut) HasAutoScaling() bool {
- if o != nil && o.AutoScaling != nil {
+// HasLans returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPut) HasLans() bool {
+ if o != nil && o.Lans != nil {
return true
}
return false
}
-// GetLans returns the Lans field value
-// If the value is explicit nil, the zero value for []KubernetesNodePoolLan will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetLans() *[]KubernetesNodePoolLan {
+// GetMaintenanceWindow returns the MaintenanceWindow field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPut) GetMaintenanceWindow() *KubernetesMaintenanceWindow {
if o == nil {
return nil
}
- return o.Lans
+ return o.MaintenanceWindow
}
-// GetLansOk returns a tuple with the Lans field value
+// GetMaintenanceWindowOk returns a tuple with the MaintenanceWindow field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetLansOk() (*[]KubernetesNodePoolLan, bool) {
+func (o *KubernetesNodePoolPropertiesForPut) GetMaintenanceWindowOk() (*KubernetesMaintenanceWindow, bool) {
if o == nil {
return nil, false
}
- return o.Lans, true
+ return o.MaintenanceWindow, true
}
-// SetLans sets field value
-func (o *KubernetesNodePoolPropertiesForPut) SetLans(v []KubernetesNodePoolLan) {
+// SetMaintenanceWindow sets field value
+func (o *KubernetesNodePoolPropertiesForPut) SetMaintenanceWindow(v KubernetesMaintenanceWindow) {
- o.Lans = &v
+ o.MaintenanceWindow = &v
}
-// HasLans returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPut) HasLans() bool {
- if o != nil && o.Lans != nil {
+// HasMaintenanceWindow returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPut) HasMaintenanceWindow() bool {
+ if o != nil && o.MaintenanceWindow != nil {
return true
}
return false
}
-// GetLabels returns the Labels field value
-// If the value is explicit nil, the zero value for map[string]string will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetLabels() *map[string]string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPut) GetName() *string {
if o == nil {
return nil
}
- return o.Labels
+ return o.Name
}
-// GetLabelsOk returns a tuple with the Labels field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetLabelsOk() (*map[string]string, bool) {
+func (o *KubernetesNodePoolPropertiesForPut) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Labels, true
+ return o.Name, true
}
-// SetLabels sets field value
-func (o *KubernetesNodePoolPropertiesForPut) SetLabels(v map[string]string) {
+// SetName sets field value
+func (o *KubernetesNodePoolPropertiesForPut) SetName(v string) {
- o.Labels = &v
+ o.Name = &v
}
-// HasLabels returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPut) HasLabels() bool {
- if o != nil && o.Labels != nil {
+// HasName returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPut) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetAnnotations returns the Annotations field value
-// If the value is explicit nil, the zero value for map[string]string will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetAnnotations() *map[string]string {
+// GetNodeCount returns the NodeCount field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePoolPropertiesForPut) GetNodeCount() *int32 {
if o == nil {
return nil
}
- return o.Annotations
+ return o.NodeCount
}
-// GetAnnotationsOk returns a tuple with the Annotations field value
+// GetNodeCountOk returns a tuple with the NodeCount field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePoolPropertiesForPut) GetAnnotationsOk() (*map[string]string, bool) {
+func (o *KubernetesNodePoolPropertiesForPut) GetNodeCountOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Annotations, true
+ return o.NodeCount, true
}
-// SetAnnotations sets field value
-func (o *KubernetesNodePoolPropertiesForPut) SetAnnotations(v map[string]string) {
+// SetNodeCount sets field value
+func (o *KubernetesNodePoolPropertiesForPut) SetNodeCount(v int32) {
- o.Annotations = &v
+ o.NodeCount = &v
}
-// HasAnnotations returns a boolean if a field has been set.
-func (o *KubernetesNodePoolPropertiesForPut) HasAnnotations() bool {
- if o != nil && o.Annotations != nil {
+// HasNodeCount returns a boolean if a field has been set.
+func (o *KubernetesNodePoolPropertiesForPut) HasNodeCount() bool {
+ if o != nil && o.NodeCount != nil {
return true
}
@@ -359,7 +359,7 @@ func (o *KubernetesNodePoolPropertiesForPut) HasAnnotations() bool {
}
// GetPublicIps returns the PublicIps field value
-// If the value is explicit nil, the zero value for []string will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesNodePoolPropertiesForPut) GetPublicIps() *[]string {
if o == nil {
return nil
@@ -398,33 +398,42 @@ func (o *KubernetesNodePoolPropertiesForPut) HasPublicIps() bool {
func (o KubernetesNodePoolPropertiesForPut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
+ if o.Annotations != nil {
+ toSerialize["annotations"] = o.Annotations
}
- if o.NodeCount != nil {
- toSerialize["nodeCount"] = o.NodeCount
+
+ if o.AutoScaling != nil {
+ toSerialize["autoScaling"] = o.AutoScaling
}
+
if o.K8sVersion != nil {
toSerialize["k8sVersion"] = o.K8sVersion
}
- if o.MaintenanceWindow != nil {
- toSerialize["maintenanceWindow"] = o.MaintenanceWindow
- }
- if o.AutoScaling != nil {
- toSerialize["autoScaling"] = o.AutoScaling
+
+ if o.Labels != nil {
+ toSerialize["labels"] = o.Labels
}
+
if o.Lans != nil {
toSerialize["lans"] = o.Lans
}
- if o.Labels != nil {
- toSerialize["labels"] = o.Labels
+
+ if o.MaintenanceWindow != nil {
+ toSerialize["maintenanceWindow"] = o.MaintenanceWindow
}
- if o.Annotations != nil {
- toSerialize["annotations"] = o.Annotations
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
}
+
+ if o.NodeCount != nil {
+ toSerialize["nodeCount"] = o.NodeCount
+ }
+
if o.PublicIps != nil {
toSerialize["publicIps"] = o.PublicIps
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pools.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pools.go
index 61df80e6dba..50ebf55680c 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pools.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_pools.go
@@ -16,14 +16,14 @@ import (
// KubernetesNodePools struct for KubernetesNodePools
type KubernetesNodePools struct {
- // A unique representation of the Kubernetes node pool as a resource collection.
- Id *string `json:"id,omitempty"`
- // The resource type within a collection.
- Type *string `json:"type,omitempty"`
// The URL to the collection representation (absolute path).
Href *string `json:"href,omitempty"`
+ // A unique representation of the Kubernetes node pool as a resource collection.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]KubernetesNodePool `json:"items,omitempty"`
+ // The resource type within a collection.
+ Type *string `json:"type,omitempty"`
}
// NewKubernetesNodePools instantiates a new KubernetesNodePools object
@@ -44,152 +44,152 @@ func NewKubernetesNodePoolsWithDefaults() *KubernetesNodePools {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePools) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePools) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePools) GetIdOk() (*string, bool) {
+func (o *KubernetesNodePools) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *KubernetesNodePools) SetId(v string) {
+// SetHref sets field value
+func (o *KubernetesNodePools) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *KubernetesNodePools) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *KubernetesNodePools) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePools) GetType() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePools) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePools) GetTypeOk() (*string, bool) {
+func (o *KubernetesNodePools) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *KubernetesNodePools) SetType(v string) {
+// SetId sets field value
+func (o *KubernetesNodePools) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *KubernetesNodePools) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *KubernetesNodePools) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodePools) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePools) GetItems() *[]KubernetesNodePool {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePools) GetHrefOk() (*string, bool) {
+func (o *KubernetesNodePools) GetItemsOk() (*[]KubernetesNodePool, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *KubernetesNodePools) SetHref(v string) {
+// SetItems sets field value
+func (o *KubernetesNodePools) SetItems(v []KubernetesNodePool) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *KubernetesNodePools) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *KubernetesNodePools) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []KubernetesNodePool will be returned
-func (o *KubernetesNodePools) GetItems() *[]KubernetesNodePool {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodePools) GetType() *string {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodePools) GetItemsOk() (*[]KubernetesNodePool, bool) {
+func (o *KubernetesNodePools) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *KubernetesNodePools) SetItems(v []KubernetesNodePool) {
+// SetType sets field value
+func (o *KubernetesNodePools) SetType(v string) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *KubernetesNodePools) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *KubernetesNodePools) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *KubernetesNodePools) HasItems() bool {
func (o KubernetesNodePools) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_properties.go
index 652521484c2..e5f67c963a9 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_node_properties.go
@@ -16,25 +16,25 @@ import (
// KubernetesNodeProperties struct for KubernetesNodeProperties
type KubernetesNodeProperties struct {
+ // The Kubernetes version running in the node pool. Note that this imposes restrictions on which Kubernetes versions can run in the node pools of a cluster. Also, not all Kubernetes versions are suitable upgrade targets for all earlier versions.
+ K8sVersion *string `json:"k8sVersion"`
// The Kubernetes node name.
Name *string `json:"name"`
- // The public IP associated with the node.
- PublicIP *string `json:"publicIP,omitempty"`
// The private IP associated with the node.
PrivateIP *string `json:"privateIP,omitempty"`
- // The Kubernetes version running in the node pool. Note that this imposes restrictions on which Kubernetes versions can run in the node pools of a cluster. Also, not all Kubernetes versions are suitable upgrade targets for all earlier versions.
- K8sVersion *string `json:"k8sVersion"`
+ // The public IP associated with the node.
+ PublicIP *string `json:"publicIP,omitempty"`
}
// NewKubernetesNodeProperties instantiates a new KubernetesNodeProperties object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewKubernetesNodeProperties(name string, k8sVersion string) *KubernetesNodeProperties {
+func NewKubernetesNodeProperties(k8sVersion string, name string) *KubernetesNodeProperties {
this := KubernetesNodeProperties{}
- this.Name = &name
this.K8sVersion = &k8sVersion
+ this.Name = &name
return &this
}
@@ -47,76 +47,76 @@ func NewKubernetesNodePropertiesWithDefaults() *KubernetesNodeProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodeProperties) GetName() *string {
+// GetK8sVersion returns the K8sVersion field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodeProperties) GetK8sVersion() *string {
if o == nil {
return nil
}
- return o.Name
+ return o.K8sVersion
}
-// GetNameOk returns a tuple with the Name field value
+// GetK8sVersionOk returns a tuple with the K8sVersion field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodeProperties) GetNameOk() (*string, bool) {
+func (o *KubernetesNodeProperties) GetK8sVersionOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.K8sVersion, true
}
-// SetName sets field value
-func (o *KubernetesNodeProperties) SetName(v string) {
+// SetK8sVersion sets field value
+func (o *KubernetesNodeProperties) SetK8sVersion(v string) {
- o.Name = &v
+ o.K8sVersion = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *KubernetesNodeProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasK8sVersion returns a boolean if a field has been set.
+func (o *KubernetesNodeProperties) HasK8sVersion() bool {
+ if o != nil && o.K8sVersion != nil {
return true
}
return false
}
-// GetPublicIP returns the PublicIP field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodeProperties) GetPublicIP() *string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodeProperties) GetName() *string {
if o == nil {
return nil
}
- return o.PublicIP
+ return o.Name
}
-// GetPublicIPOk returns a tuple with the PublicIP field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodeProperties) GetPublicIPOk() (*string, bool) {
+func (o *KubernetesNodeProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.PublicIP, true
+ return o.Name, true
}
-// SetPublicIP sets field value
-func (o *KubernetesNodeProperties) SetPublicIP(v string) {
+// SetName sets field value
+func (o *KubernetesNodeProperties) SetName(v string) {
- o.PublicIP = &v
+ o.Name = &v
}
-// HasPublicIP returns a boolean if a field has been set.
-func (o *KubernetesNodeProperties) HasPublicIP() bool {
- if o != nil && o.PublicIP != nil {
+// HasName returns a boolean if a field has been set.
+func (o *KubernetesNodeProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -124,7 +124,7 @@ func (o *KubernetesNodeProperties) HasPublicIP() bool {
}
// GetPrivateIP returns the PrivateIP field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *KubernetesNodeProperties) GetPrivateIP() *string {
if o == nil {
return nil
@@ -161,38 +161,38 @@ func (o *KubernetesNodeProperties) HasPrivateIP() bool {
return false
}
-// GetK8sVersion returns the K8sVersion field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodeProperties) GetK8sVersion() *string {
+// GetPublicIP returns the PublicIP field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodeProperties) GetPublicIP() *string {
if o == nil {
return nil
}
- return o.K8sVersion
+ return o.PublicIP
}
-// GetK8sVersionOk returns a tuple with the K8sVersion field value
+// GetPublicIPOk returns a tuple with the PublicIP field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodeProperties) GetK8sVersionOk() (*string, bool) {
+func (o *KubernetesNodeProperties) GetPublicIPOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.K8sVersion, true
+ return o.PublicIP, true
}
-// SetK8sVersion sets field value
-func (o *KubernetesNodeProperties) SetK8sVersion(v string) {
+// SetPublicIP sets field value
+func (o *KubernetesNodeProperties) SetPublicIP(v string) {
- o.K8sVersion = &v
+ o.PublicIP = &v
}
-// HasK8sVersion returns a boolean if a field has been set.
-func (o *KubernetesNodeProperties) HasK8sVersion() bool {
- if o != nil && o.K8sVersion != nil {
+// HasPublicIP returns a boolean if a field has been set.
+func (o *KubernetesNodeProperties) HasPublicIP() bool {
+ if o != nil && o.PublicIP != nil {
return true
}
@@ -201,18 +201,22 @@ func (o *KubernetesNodeProperties) HasK8sVersion() bool {
func (o KubernetesNodeProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
+ if o.K8sVersion != nil {
+ toSerialize["k8sVersion"] = o.K8sVersion
+ }
+
if o.Name != nil {
toSerialize["name"] = o.Name
}
- if o.PublicIP != nil {
- toSerialize["publicIP"] = o.PublicIP
- }
+
if o.PrivateIP != nil {
toSerialize["privateIP"] = o.PrivateIP
}
- if o.K8sVersion != nil {
- toSerialize["k8sVersion"] = o.K8sVersion
+
+ if o.PublicIP != nil {
+ toSerialize["publicIP"] = o.PublicIP
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_nodes.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_nodes.go
index e54f0c8d0dd..a96c038486a 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_nodes.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_kubernetes_nodes.go
@@ -16,14 +16,14 @@ import (
// KubernetesNodes struct for KubernetesNodes
type KubernetesNodes struct {
- // A unique representation of the Kubernetes node pool as a resource collection.
- Id *string `json:"id,omitempty"`
- // The resource type within a collection.
- Type *string `json:"type,omitempty"`
// The URL to the collection representation (absolute path).
Href *string `json:"href,omitempty"`
+ // A unique representation of the Kubernetes node pool as a resource collection.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]KubernetesNode `json:"items,omitempty"`
+ // The resource type within a collection.
+ Type *string `json:"type,omitempty"`
}
// NewKubernetesNodes instantiates a new KubernetesNodes object
@@ -44,152 +44,152 @@ func NewKubernetesNodesWithDefaults() *KubernetesNodes {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodes) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodes) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodes) GetIdOk() (*string, bool) {
+func (o *KubernetesNodes) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *KubernetesNodes) SetId(v string) {
+// SetHref sets field value
+func (o *KubernetesNodes) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *KubernetesNodes) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *KubernetesNodes) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodes) GetType() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodes) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodes) GetTypeOk() (*string, bool) {
+func (o *KubernetesNodes) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *KubernetesNodes) SetType(v string) {
+// SetId sets field value
+func (o *KubernetesNodes) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *KubernetesNodes) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *KubernetesNodes) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *KubernetesNodes) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodes) GetItems() *[]KubernetesNode {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodes) GetHrefOk() (*string, bool) {
+func (o *KubernetesNodes) GetItemsOk() (*[]KubernetesNode, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *KubernetesNodes) SetHref(v string) {
+// SetItems sets field value
+func (o *KubernetesNodes) SetItems(v []KubernetesNode) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *KubernetesNodes) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *KubernetesNodes) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []KubernetesNode will be returned
-func (o *KubernetesNodes) GetItems() *[]KubernetesNode {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *KubernetesNodes) GetType() *string {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *KubernetesNodes) GetItemsOk() (*[]KubernetesNode, bool) {
+func (o *KubernetesNodes) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *KubernetesNodes) SetItems(v []KubernetesNode) {
+// SetType sets field value
+func (o *KubernetesNodes) SetType(v string) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *KubernetesNodes) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *KubernetesNodes) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *KubernetesNodes) HasItems() bool {
func (o KubernetesNodes) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_label.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_label.go
index c162e676334..f28f2af5936 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_label.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_label.go
@@ -16,14 +16,14 @@ import (
// Label struct for Label
type Label struct {
- // Label is identified using standard URN.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *string `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // Label is identified using standard URN.
+ Id *string `json:"id,omitempty"`
Metadata *NoStateMetaData `json:"metadata,omitempty"`
Properties *LabelProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *string `json:"type,omitempty"`
}
// NewLabel instantiates a new Label object
@@ -46,190 +46,190 @@ func NewLabelWithDefaults() *Label {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Label) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Label) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Label) GetIdOk() (*string, bool) {
+func (o *Label) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Label) SetId(v string) {
+// SetHref sets field value
+func (o *Label) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Label) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Label) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Label) GetType() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Label) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Label) GetTypeOk() (*string, bool) {
+func (o *Label) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Label) SetType(v string) {
+// SetId sets field value
+func (o *Label) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Label) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Label) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Label) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *Label) GetMetadata() *NoStateMetaData {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Label) GetHrefOk() (*string, bool) {
+func (o *Label) GetMetadataOk() (*NoStateMetaData, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *Label) SetHref(v string) {
+// SetMetadata sets field value
+func (o *Label) SetMetadata(v NoStateMetaData) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Label) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *Label) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for NoStateMetaData will be returned
-func (o *Label) GetMetadata() *NoStateMetaData {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *Label) GetProperties() *LabelProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Label) GetMetadataOk() (*NoStateMetaData, bool) {
+func (o *Label) GetPropertiesOk() (*LabelProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *Label) SetMetadata(v NoStateMetaData) {
+// SetProperties sets field value
+func (o *Label) SetProperties(v LabelProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *Label) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *Label) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for LabelProperties will be returned
-func (o *Label) GetProperties() *LabelProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Label) GetType() *string {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Label) GetPropertiesOk() (*LabelProperties, bool) {
+func (o *Label) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *Label) SetProperties(v LabelProperties) {
+// SetType sets field value
+func (o *Label) SetType(v string) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *Label) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Label) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *Label) HasProperties() bool {
func (o Label) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_properties.go
index a7a0d794cf5..f561a5fb773 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_properties.go
@@ -18,14 +18,14 @@ import (
type LabelProperties struct {
// A label key
Key *string `json:"key,omitempty"`
- // A label value
- Value *string `json:"value,omitempty"`
+ // URL to the Resource (absolute path) on which the label is applied.
+ ResourceHref *string `json:"resourceHref,omitempty"`
// The ID of the resource.
ResourceId *string `json:"resourceId,omitempty"`
// The type of the resource on which the label is applied.
ResourceType *string `json:"resourceType,omitempty"`
- // URL to the Resource (absolute path) on which the label is applied.
- ResourceHref *string `json:"resourceHref,omitempty"`
+ // A label value
+ Value *string `json:"value,omitempty"`
}
// NewLabelProperties instantiates a new LabelProperties object
@@ -47,7 +47,7 @@ func NewLabelPropertiesWithDefaults() *LabelProperties {
}
// GetKey returns the Key field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *LabelProperties) GetKey() *string {
if o == nil {
return nil
@@ -84,38 +84,38 @@ func (o *LabelProperties) HasKey() bool {
return false
}
-// GetValue returns the Value field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LabelProperties) GetValue() *string {
+// GetResourceHref returns the ResourceHref field value
+// If the value is explicit nil, nil is returned
+func (o *LabelProperties) GetResourceHref() *string {
if o == nil {
return nil
}
- return o.Value
+ return o.ResourceHref
}
-// GetValueOk returns a tuple with the Value field value
+// GetResourceHrefOk returns a tuple with the ResourceHref field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelProperties) GetValueOk() (*string, bool) {
+func (o *LabelProperties) GetResourceHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Value, true
+ return o.ResourceHref, true
}
-// SetValue sets field value
-func (o *LabelProperties) SetValue(v string) {
+// SetResourceHref sets field value
+func (o *LabelProperties) SetResourceHref(v string) {
- o.Value = &v
+ o.ResourceHref = &v
}
-// HasValue returns a boolean if a field has been set.
-func (o *LabelProperties) HasValue() bool {
- if o != nil && o.Value != nil {
+// HasResourceHref returns a boolean if a field has been set.
+func (o *LabelProperties) HasResourceHref() bool {
+ if o != nil && o.ResourceHref != nil {
return true
}
@@ -123,7 +123,7 @@ func (o *LabelProperties) HasValue() bool {
}
// GetResourceId returns the ResourceId field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *LabelProperties) GetResourceId() *string {
if o == nil {
return nil
@@ -161,7 +161,7 @@ func (o *LabelProperties) HasResourceId() bool {
}
// GetResourceType returns the ResourceType field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *LabelProperties) GetResourceType() *string {
if o == nil {
return nil
@@ -198,38 +198,38 @@ func (o *LabelProperties) HasResourceType() bool {
return false
}
-// GetResourceHref returns the ResourceHref field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LabelProperties) GetResourceHref() *string {
+// GetValue returns the Value field value
+// If the value is explicit nil, nil is returned
+func (o *LabelProperties) GetValue() *string {
if o == nil {
return nil
}
- return o.ResourceHref
+ return o.Value
}
-// GetResourceHrefOk returns a tuple with the ResourceHref field value
+// GetValueOk returns a tuple with the Value field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelProperties) GetResourceHrefOk() (*string, bool) {
+func (o *LabelProperties) GetValueOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.ResourceHref, true
+ return o.Value, true
}
-// SetResourceHref sets field value
-func (o *LabelProperties) SetResourceHref(v string) {
+// SetValue sets field value
+func (o *LabelProperties) SetValue(v string) {
- o.ResourceHref = &v
+ o.Value = &v
}
-// HasResourceHref returns a boolean if a field has been set.
-func (o *LabelProperties) HasResourceHref() bool {
- if o != nil && o.ResourceHref != nil {
+// HasValue returns a boolean if a field has been set.
+func (o *LabelProperties) HasValue() bool {
+ if o != nil && o.Value != nil {
return true
}
@@ -241,18 +241,23 @@ func (o LabelProperties) MarshalJSON() ([]byte, error) {
if o.Key != nil {
toSerialize["key"] = o.Key
}
- if o.Value != nil {
- toSerialize["value"] = o.Value
+
+ if o.ResourceHref != nil {
+ toSerialize["resourceHref"] = o.ResourceHref
}
+
if o.ResourceId != nil {
toSerialize["resourceId"] = o.ResourceId
}
+
if o.ResourceType != nil {
toSerialize["resourceType"] = o.ResourceType
}
- if o.ResourceHref != nil {
- toSerialize["resourceHref"] = o.ResourceHref
+
+ if o.Value != nil {
+ toSerialize["value"] = o.Value
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_resource.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_resource.go
index 29ebef96dfe..9963122acc9 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_resource.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_resource.go
@@ -16,14 +16,14 @@ import (
// LabelResource struct for LabelResource
type LabelResource struct {
- // Label on a resource is identified using label key.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *string `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // Label on a resource is identified using label key.
+ Id *string `json:"id,omitempty"`
Metadata *NoStateMetaData `json:"metadata,omitempty"`
Properties *LabelResourceProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *string `json:"type,omitempty"`
}
// NewLabelResource instantiates a new LabelResource object
@@ -46,190 +46,190 @@ func NewLabelResourceWithDefaults() *LabelResource {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LabelResource) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *LabelResource) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelResource) GetIdOk() (*string, bool) {
+func (o *LabelResource) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *LabelResource) SetId(v string) {
+// SetHref sets field value
+func (o *LabelResource) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *LabelResource) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *LabelResource) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LabelResource) GetType() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *LabelResource) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelResource) GetTypeOk() (*string, bool) {
+func (o *LabelResource) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *LabelResource) SetType(v string) {
+// SetId sets field value
+func (o *LabelResource) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *LabelResource) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *LabelResource) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LabelResource) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *LabelResource) GetMetadata() *NoStateMetaData {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelResource) GetHrefOk() (*string, bool) {
+func (o *LabelResource) GetMetadataOk() (*NoStateMetaData, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *LabelResource) SetHref(v string) {
+// SetMetadata sets field value
+func (o *LabelResource) SetMetadata(v NoStateMetaData) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *LabelResource) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *LabelResource) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for NoStateMetaData will be returned
-func (o *LabelResource) GetMetadata() *NoStateMetaData {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *LabelResource) GetProperties() *LabelResourceProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelResource) GetMetadataOk() (*NoStateMetaData, bool) {
+func (o *LabelResource) GetPropertiesOk() (*LabelResourceProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *LabelResource) SetMetadata(v NoStateMetaData) {
+// SetProperties sets field value
+func (o *LabelResource) SetProperties(v LabelResourceProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *LabelResource) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *LabelResource) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for LabelResourceProperties will be returned
-func (o *LabelResource) GetProperties() *LabelResourceProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *LabelResource) GetType() *string {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelResource) GetPropertiesOk() (*LabelResourceProperties, bool) {
+func (o *LabelResource) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *LabelResource) SetProperties(v LabelResourceProperties) {
+// SetType sets field value
+func (o *LabelResource) SetType(v string) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *LabelResource) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *LabelResource) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *LabelResource) HasProperties() bool {
func (o LabelResource) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_resource_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_resource_properties.go
index ef0836dff59..e83bc0c9fcd 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_resource_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_resource_properties.go
@@ -41,7 +41,7 @@ func NewLabelResourcePropertiesWithDefaults() *LabelResourceProperties {
}
// GetKey returns the Key field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *LabelResourceProperties) GetKey() *string {
if o == nil {
return nil
@@ -79,7 +79,7 @@ func (o *LabelResourceProperties) HasKey() bool {
}
// GetValue returns the Value field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *LabelResourceProperties) GetValue() *string {
if o == nil {
return nil
@@ -121,9 +121,11 @@ func (o LabelResourceProperties) MarshalJSON() ([]byte, error) {
if o.Key != nil {
toSerialize["key"] = o.Key
}
+
if o.Value != nil {
toSerialize["value"] = o.Value
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_resources.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_resources.go
index 673f4f3283f..43bf07e052d 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_resources.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_label_resources.go
@@ -16,19 +16,19 @@ import (
// LabelResources struct for LabelResources
type LabelResources struct {
- // A unique representation of the label as a resource collection.
- Id *string `json:"id,omitempty"`
- // The type of resource within a collection.
- Type *string `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the collection representation (absolute path).
Href *string `json:"href,omitempty"`
+ // A unique representation of the label as a resource collection.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]LabelResource `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of resource within a collection.
+ Type *string `json:"type,omitempty"`
}
// NewLabelResources instantiates a new LabelResources object
@@ -49,114 +49,114 @@ func NewLabelResourcesWithDefaults() *LabelResources {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LabelResources) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *LabelResources) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelResources) GetIdOk() (*string, bool) {
+func (o *LabelResources) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *LabelResources) SetId(v string) {
+// SetLinks sets field value
+func (o *LabelResources) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *LabelResources) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *LabelResources) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LabelResources) GetType() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *LabelResources) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelResources) GetTypeOk() (*string, bool) {
+func (o *LabelResources) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *LabelResources) SetType(v string) {
+// SetHref sets field value
+func (o *LabelResources) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *LabelResources) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *LabelResources) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LabelResources) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *LabelResources) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelResources) GetHrefOk() (*string, bool) {
+func (o *LabelResources) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *LabelResources) SetHref(v string) {
+// SetId sets field value
+func (o *LabelResources) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *LabelResources) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *LabelResources) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *LabelResources) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []LabelResource will be returned
+// If the value is explicit nil, nil is returned
func (o *LabelResources) GetItems() *[]LabelResource {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *LabelResources) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *LabelResources) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *LabelResources) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelResources) GetOffsetOk() (*float32, bool) {
+func (o *LabelResources) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *LabelResources) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *LabelResources) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *LabelResources) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *LabelResources) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *LabelResources) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *LabelResources) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelResources) GetLimitOk() (*float32, bool) {
+func (o *LabelResources) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *LabelResources) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *LabelResources) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *LabelResources) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *LabelResources) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *LabelResources) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *LabelResources) GetType() *string {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LabelResources) GetLinksOk() (*PaginationLinks, bool) {
+func (o *LabelResources) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *LabelResources) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *LabelResources) SetType(v string) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *LabelResources) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *LabelResources) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *LabelResources) HasLinks() bool {
func (o LabelResources) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_labels.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_labels.go
index d83bdbcfcd4..f2be7da33b5 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_labels.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_labels.go
@@ -16,14 +16,14 @@ import (
// Labels struct for Labels
type Labels struct {
- // A unique representation of the label as a resource collection.
- Id *string `json:"id,omitempty"`
- // The type of resource within a collection.
- Type *string `json:"type,omitempty"`
// URL to the collection representation (absolute path).
Href *string `json:"href,omitempty"`
+ // A unique representation of the label as a resource collection.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Label `json:"items,omitempty"`
+ // The type of resource within a collection.
+ Type *string `json:"type,omitempty"`
}
// NewLabels instantiates a new Labels object
@@ -44,152 +44,152 @@ func NewLabelsWithDefaults() *Labels {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Labels) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Labels) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Labels) GetIdOk() (*string, bool) {
+func (o *Labels) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Labels) SetId(v string) {
+// SetHref sets field value
+func (o *Labels) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Labels) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Labels) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Labels) GetType() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Labels) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Labels) GetTypeOk() (*string, bool) {
+func (o *Labels) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Labels) SetType(v string) {
+// SetId sets field value
+func (o *Labels) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Labels) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Labels) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Labels) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *Labels) GetItems() *[]Label {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Labels) GetHrefOk() (*string, bool) {
+func (o *Labels) GetItemsOk() (*[]Label, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *Labels) SetHref(v string) {
+// SetItems sets field value
+func (o *Labels) SetItems(v []Label) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Labels) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *Labels) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Label will be returned
-func (o *Labels) GetItems() *[]Label {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Labels) GetType() *string {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Labels) GetItemsOk() (*[]Label, bool) {
+func (o *Labels) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *Labels) SetItems(v []Label) {
+// SetType sets field value
+func (o *Labels) SetType(v string) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *Labels) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Labels) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *Labels) HasItems() bool {
func (o Labels) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan.go
index 120c2f17f53..09a44f4e375 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan.go
@@ -16,15 +16,15 @@ import (
// Lan struct for Lan
type Lan struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Entities *LanEntities `json:"entities,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *LanProperties `json:"properties"`
- Entities *LanEntities `json:"entities,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewLan instantiates a new Lan object
@@ -47,114 +47,114 @@ func NewLanWithDefaults() *Lan {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Lan) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *Lan) GetEntities() *LanEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Lan) GetIdOk() (*string, bool) {
+func (o *Lan) GetEntitiesOk() (*LanEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *Lan) SetId(v string) {
+// SetEntities sets field value
+func (o *Lan) SetEntities(v LanEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Lan) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *Lan) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Lan) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Lan) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Lan) GetTypeOk() (*Type, bool) {
+func (o *Lan) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Lan) SetType(v Type) {
+// SetHref sets field value
+func (o *Lan) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Lan) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Lan) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Lan) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Lan) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Lan) GetHrefOk() (*string, bool) {
+func (o *Lan) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Lan) SetHref(v string) {
+// SetId sets field value
+func (o *Lan) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Lan) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Lan) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -162,7 +162,7 @@ func (o *Lan) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *Lan) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
@@ -200,7 +200,7 @@ func (o *Lan) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for LanProperties will be returned
+// If the value is explicit nil, nil is returned
func (o *Lan) GetProperties() *LanProperties {
if o == nil {
return nil
@@ -237,38 +237,38 @@ func (o *Lan) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for LanEntities will be returned
-func (o *Lan) GetEntities() *LanEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Lan) GetType() *Type {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Lan) GetEntitiesOk() (*LanEntities, bool) {
+func (o *Lan) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *Lan) SetEntities(v LanEntities) {
+// SetType sets field value
+func (o *Lan) SetType(v Type) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *Lan) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Lan) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -277,24 +277,30 @@ func (o *Lan) HasEntities() bool {
func (o Lan) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_entities.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_entities.go
index f4d242ac811..368746a4323 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_entities.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_entities.go
@@ -38,7 +38,7 @@ func NewLanEntitiesWithDefaults() *LanEntities {
}
// GetNics returns the Nics field value
-// If the value is explicit nil, the zero value for LanNics will be returned
+// If the value is explicit nil, nil is returned
func (o *LanEntities) GetNics() *LanNics {
if o == nil {
return nil
@@ -80,6 +80,7 @@ func (o LanEntities) MarshalJSON() ([]byte, error) {
if o.Nics != nil {
toSerialize["nics"] = o.Nics
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_nics.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_nics.go
index f348c1458a4..06cc683fe5f 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_nics.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_nics.go
@@ -16,19 +16,19 @@ import (
// LanNics struct for LanNics
type LanNics struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Nic `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewLanNics instantiates a new LanNics object
@@ -49,114 +49,114 @@ func NewLanNicsWithDefaults() *LanNics {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LanNics) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *LanNics) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LanNics) GetIdOk() (*string, bool) {
+func (o *LanNics) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *LanNics) SetId(v string) {
+// SetLinks sets field value
+func (o *LanNics) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *LanNics) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *LanNics) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *LanNics) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *LanNics) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LanNics) GetTypeOk() (*Type, bool) {
+func (o *LanNics) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *LanNics) SetType(v Type) {
+// SetHref sets field value
+func (o *LanNics) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *LanNics) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *LanNics) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LanNics) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *LanNics) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LanNics) GetHrefOk() (*string, bool) {
+func (o *LanNics) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *LanNics) SetHref(v string) {
+// SetId sets field value
+func (o *LanNics) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *LanNics) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *LanNics) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *LanNics) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Nic will be returned
+// If the value is explicit nil, nil is returned
func (o *LanNics) GetItems() *[]Nic {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *LanNics) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *LanNics) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *LanNics) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LanNics) GetOffsetOk() (*float32, bool) {
+func (o *LanNics) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *LanNics) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *LanNics) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *LanNics) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *LanNics) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *LanNics) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *LanNics) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LanNics) GetLimitOk() (*float32, bool) {
+func (o *LanNics) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *LanNics) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *LanNics) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *LanNics) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *LanNics) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *LanNics) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *LanNics) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LanNics) GetLinksOk() (*PaginationLinks, bool) {
+func (o *LanNics) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *LanNics) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *LanNics) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *LanNics) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *LanNics) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *LanNics) HasLinks() bool {
func (o LanNics) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_post.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_post.go
new file mode 100644
index 00000000000..ce97f15f027
--- /dev/null
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_post.go
@@ -0,0 +1,341 @@
+/*
+ * CLOUD API
+ *
+ * IONOS Enterprise-grade Infrastructure as a Service (IaaS) solutions can be managed through the Cloud API, in addition or as an alternative to the \"Data Center Designer\" (DCD) browser-based tool. Both methods employ consistent concepts and features, deliver similar power and flexibility, and can be used to perform a multitude of management tasks, including adding servers, volumes, configuring networks, and so on.
+ *
+ * API version: 6.0
+ */
+
+// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
+
+package ionoscloud
+
+import (
+ "encoding/json"
+)
+
+// LanPost struct for LanPost
+type LanPost struct {
+ Entities *LanEntities `json:"entities,omitempty"`
+ // URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
+ Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
+ Properties *LanPropertiesPost `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
+}
+
+// NewLanPost instantiates a new LanPost object
+// This constructor will assign default values to properties that have it defined,
+// and makes sure properties required by API are set, but the set of arguments
+// will change when the set of required properties is changed
+func NewLanPost(properties LanPropertiesPost) *LanPost {
+ this := LanPost{}
+
+ this.Properties = &properties
+
+ return &this
+}
+
+// NewLanPostWithDefaults instantiates a new LanPost object
+// This constructor will only assign default values to properties that have it defined,
+// but it doesn't guarantee that properties required by API are set
+func NewLanPostWithDefaults() *LanPost {
+ this := LanPost{}
+ return &this
+}
+
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *LanPost) GetEntities() *LanEntities {
+ if o == nil {
+ return nil
+ }
+
+ return o.Entities
+
+}
+
+// GetEntitiesOk returns a tuple with the Entities field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *LanPost) GetEntitiesOk() (*LanEntities, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Entities, true
+}
+
+// SetEntities sets field value
+func (o *LanPost) SetEntities(v LanEntities) {
+
+ o.Entities = &v
+
+}
+
+// HasEntities returns a boolean if a field has been set.
+func (o *LanPost) HasEntities() bool {
+ if o != nil && o.Entities != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *LanPost) GetHref() *string {
+ if o == nil {
+ return nil
+ }
+
+ return o.Href
+
+}
+
+// GetHrefOk returns a tuple with the Href field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *LanPost) GetHrefOk() (*string, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Href, true
+}
+
+// SetHref sets field value
+func (o *LanPost) SetHref(v string) {
+
+ o.Href = &v
+
+}
+
+// HasHref returns a boolean if a field has been set.
+func (o *LanPost) HasHref() bool {
+ if o != nil && o.Href != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *LanPost) GetId() *string {
+ if o == nil {
+ return nil
+ }
+
+ return o.Id
+
+}
+
+// GetIdOk returns a tuple with the Id field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *LanPost) GetIdOk() (*string, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Id, true
+}
+
+// SetId sets field value
+func (o *LanPost) SetId(v string) {
+
+ o.Id = &v
+
+}
+
+// HasId returns a boolean if a field has been set.
+func (o *LanPost) HasId() bool {
+ if o != nil && o.Id != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *LanPost) GetMetadata() *DatacenterElementMetadata {
+ if o == nil {
+ return nil
+ }
+
+ return o.Metadata
+
+}
+
+// GetMetadataOk returns a tuple with the Metadata field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *LanPost) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Metadata, true
+}
+
+// SetMetadata sets field value
+func (o *LanPost) SetMetadata(v DatacenterElementMetadata) {
+
+ o.Metadata = &v
+
+}
+
+// HasMetadata returns a boolean if a field has been set.
+func (o *LanPost) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *LanPost) GetProperties() *LanPropertiesPost {
+ if o == nil {
+ return nil
+ }
+
+ return o.Properties
+
+}
+
+// GetPropertiesOk returns a tuple with the Properties field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *LanPost) GetPropertiesOk() (*LanPropertiesPost, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Properties, true
+}
+
+// SetProperties sets field value
+func (o *LanPost) SetProperties(v LanPropertiesPost) {
+
+ o.Properties = &v
+
+}
+
+// HasProperties returns a boolean if a field has been set.
+func (o *LanPost) HasProperties() bool {
+ if o != nil && o.Properties != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *LanPost) GetType() *Type {
+ if o == nil {
+ return nil
+ }
+
+ return o.Type
+
+}
+
+// GetTypeOk returns a tuple with the Type field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *LanPost) GetTypeOk() (*Type, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Type, true
+}
+
+// SetType sets field value
+func (o *LanPost) SetType(v Type) {
+
+ o.Type = &v
+
+}
+
+// HasType returns a boolean if a field has been set.
+func (o *LanPost) HasType() bool {
+ if o != nil && o.Type != nil {
+ return true
+ }
+
+ return false
+}
+
+func (o LanPost) MarshalJSON() ([]byte, error) {
+ toSerialize := map[string]interface{}{}
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
+ }
+
+ if o.Href != nil {
+ toSerialize["href"] = o.Href
+ }
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
+ if o.Metadata != nil {
+ toSerialize["metadata"] = o.Metadata
+ }
+
+ if o.Properties != nil {
+ toSerialize["properties"] = o.Properties
+ }
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
+ return json.Marshal(toSerialize)
+}
+
+type NullableLanPost struct {
+ value *LanPost
+ isSet bool
+}
+
+func (v NullableLanPost) Get() *LanPost {
+ return v.value
+}
+
+func (v *NullableLanPost) Set(val *LanPost) {
+ v.value = val
+ v.isSet = true
+}
+
+func (v NullableLanPost) IsSet() bool {
+ return v.isSet
+}
+
+func (v *NullableLanPost) Unset() {
+ v.value = nil
+ v.isSet = false
+}
+
+func NewNullableLanPost(val *LanPost) *NullableLanPost {
+ return &NullableLanPost{value: val, isSet: true}
+}
+
+func (v NullableLanPost) MarshalJSON() ([]byte, error) {
+ return json.Marshal(v.value)
+}
+
+func (v *NullableLanPost) UnmarshalJSON(src []byte) error {
+ v.isSet = true
+ return json.Unmarshal(src, &v.value)
+}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_properties.go
index 763ced62b1d..47af4d21839 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_properties.go
@@ -16,10 +16,10 @@ import (
// LanProperties struct for LanProperties
type LanProperties struct {
- // The name of the resource.
- Name *string `json:"name,omitempty"`
// IP failover configurations for lan
IpFailover *[]IPFailover `json:"ipFailover,omitempty"`
+ // The name of the resource.
+ Name *string `json:"name,omitempty"`
// The unique identifier of the private Cross-Connect the LAN is connected to, if any.
Pcc *string `json:"pcc,omitempty"`
// This LAN faces the public Internet.
@@ -44,76 +44,76 @@ func NewLanPropertiesWithDefaults() *LanProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LanProperties) GetName() *string {
+// GetIpFailover returns the IpFailover field value
+// If the value is explicit nil, nil is returned
+func (o *LanProperties) GetIpFailover() *[]IPFailover {
if o == nil {
return nil
}
- return o.Name
+ return o.IpFailover
}
-// GetNameOk returns a tuple with the Name field value
+// GetIpFailoverOk returns a tuple with the IpFailover field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LanProperties) GetNameOk() (*string, bool) {
+func (o *LanProperties) GetIpFailoverOk() (*[]IPFailover, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.IpFailover, true
}
-// SetName sets field value
-func (o *LanProperties) SetName(v string) {
+// SetIpFailover sets field value
+func (o *LanProperties) SetIpFailover(v []IPFailover) {
- o.Name = &v
+ o.IpFailover = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *LanProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasIpFailover returns a boolean if a field has been set.
+func (o *LanProperties) HasIpFailover() bool {
+ if o != nil && o.IpFailover != nil {
return true
}
return false
}
-// GetIpFailover returns the IpFailover field value
-// If the value is explicit nil, the zero value for []IPFailover will be returned
-func (o *LanProperties) GetIpFailover() *[]IPFailover {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *LanProperties) GetName() *string {
if o == nil {
return nil
}
- return o.IpFailover
+ return o.Name
}
-// GetIpFailoverOk returns a tuple with the IpFailover field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LanProperties) GetIpFailoverOk() (*[]IPFailover, bool) {
+func (o *LanProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.IpFailover, true
+ return o.Name, true
}
-// SetIpFailover sets field value
-func (o *LanProperties) SetIpFailover(v []IPFailover) {
+// SetName sets field value
+func (o *LanProperties) SetName(v string) {
- o.IpFailover = &v
+ o.Name = &v
}
-// HasIpFailover returns a boolean if a field has been set.
-func (o *LanProperties) HasIpFailover() bool {
- if o != nil && o.IpFailover != nil {
+// HasName returns a boolean if a field has been set.
+func (o *LanProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -121,7 +121,7 @@ func (o *LanProperties) HasIpFailover() bool {
}
// GetPcc returns the Pcc field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *LanProperties) GetPcc() *string {
if o == nil {
return nil
@@ -159,7 +159,7 @@ func (o *LanProperties) HasPcc() bool {
}
// GetPublic returns the Public field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *LanProperties) GetPublic() *bool {
if o == nil {
return nil
@@ -198,18 +198,22 @@ func (o *LanProperties) HasPublic() bool {
func (o LanProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
- }
if o.IpFailover != nil {
toSerialize["ipFailover"] = o.IpFailover
}
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
if o.Pcc != nil {
toSerialize["pcc"] = o.Pcc
}
+
if o.Public != nil {
toSerialize["public"] = o.Public
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_properties_post.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_properties_post.go
new file mode 100644
index 00000000000..c9761d28952
--- /dev/null
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lan_properties_post.go
@@ -0,0 +1,254 @@
+/*
+ * CLOUD API
+ *
+ * IONOS Enterprise-grade Infrastructure as a Service (IaaS) solutions can be managed through the Cloud API, in addition or as an alternative to the \"Data Center Designer\" (DCD) browser-based tool. Both methods employ consistent concepts and features, deliver similar power and flexibility, and can be used to perform a multitude of management tasks, including adding servers, volumes, configuring networks, and so on.
+ *
+ * API version: 6.0
+ */
+
+// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
+
+package ionoscloud
+
+import (
+ "encoding/json"
+)
+
+// LanPropertiesPost struct for LanPropertiesPost
+type LanPropertiesPost struct {
+ // IP failover configurations for lan
+ IpFailover *[]IPFailover `json:"ipFailover,omitempty"`
+ // The name of the resource.
+ Name *string `json:"name,omitempty"`
+ // The unique identifier of the private Cross-Connect the LAN is connected to, if any.
+ Pcc *string `json:"pcc,omitempty"`
+ // This LAN faces the public Internet.
+ Public *bool `json:"public,omitempty"`
+}
+
+// NewLanPropertiesPost instantiates a new LanPropertiesPost object
+// This constructor will assign default values to properties that have it defined,
+// and makes sure properties required by API are set, but the set of arguments
+// will change when the set of required properties is changed
+func NewLanPropertiesPost() *LanPropertiesPost {
+ this := LanPropertiesPost{}
+
+ return &this
+}
+
+// NewLanPropertiesPostWithDefaults instantiates a new LanPropertiesPost object
+// This constructor will only assign default values to properties that have it defined,
+// but it doesn't guarantee that properties required by API are set
+func NewLanPropertiesPostWithDefaults() *LanPropertiesPost {
+ this := LanPropertiesPost{}
+ return &this
+}
+
+// GetIpFailover returns the IpFailover field value
+// If the value is explicit nil, nil is returned
+func (o *LanPropertiesPost) GetIpFailover() *[]IPFailover {
+ if o == nil {
+ return nil
+ }
+
+ return o.IpFailover
+
+}
+
+// GetIpFailoverOk returns a tuple with the IpFailover field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *LanPropertiesPost) GetIpFailoverOk() (*[]IPFailover, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.IpFailover, true
+}
+
+// SetIpFailover sets field value
+func (o *LanPropertiesPost) SetIpFailover(v []IPFailover) {
+
+ o.IpFailover = &v
+
+}
+
+// HasIpFailover returns a boolean if a field has been set.
+func (o *LanPropertiesPost) HasIpFailover() bool {
+ if o != nil && o.IpFailover != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *LanPropertiesPost) GetName() *string {
+ if o == nil {
+ return nil
+ }
+
+ return o.Name
+
+}
+
+// GetNameOk returns a tuple with the Name field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *LanPropertiesPost) GetNameOk() (*string, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Name, true
+}
+
+// SetName sets field value
+func (o *LanPropertiesPost) SetName(v string) {
+
+ o.Name = &v
+
+}
+
+// HasName returns a boolean if a field has been set.
+func (o *LanPropertiesPost) HasName() bool {
+ if o != nil && o.Name != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetPcc returns the Pcc field value
+// If the value is explicit nil, nil is returned
+func (o *LanPropertiesPost) GetPcc() *string {
+ if o == nil {
+ return nil
+ }
+
+ return o.Pcc
+
+}
+
+// GetPccOk returns a tuple with the Pcc field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *LanPropertiesPost) GetPccOk() (*string, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Pcc, true
+}
+
+// SetPcc sets field value
+func (o *LanPropertiesPost) SetPcc(v string) {
+
+ o.Pcc = &v
+
+}
+
+// HasPcc returns a boolean if a field has been set.
+func (o *LanPropertiesPost) HasPcc() bool {
+ if o != nil && o.Pcc != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetPublic returns the Public field value
+// If the value is explicit nil, nil is returned
+func (o *LanPropertiesPost) GetPublic() *bool {
+ if o == nil {
+ return nil
+ }
+
+ return o.Public
+
+}
+
+// GetPublicOk returns a tuple with the Public field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *LanPropertiesPost) GetPublicOk() (*bool, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Public, true
+}
+
+// SetPublic sets field value
+func (o *LanPropertiesPost) SetPublic(v bool) {
+
+ o.Public = &v
+
+}
+
+// HasPublic returns a boolean if a field has been set.
+func (o *LanPropertiesPost) HasPublic() bool {
+ if o != nil && o.Public != nil {
+ return true
+ }
+
+ return false
+}
+
+func (o LanPropertiesPost) MarshalJSON() ([]byte, error) {
+ toSerialize := map[string]interface{}{}
+ if o.IpFailover != nil {
+ toSerialize["ipFailover"] = o.IpFailover
+ }
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
+ if o.Pcc != nil {
+ toSerialize["pcc"] = o.Pcc
+ }
+
+ if o.Public != nil {
+ toSerialize["public"] = o.Public
+ }
+
+ return json.Marshal(toSerialize)
+}
+
+type NullableLanPropertiesPost struct {
+ value *LanPropertiesPost
+ isSet bool
+}
+
+func (v NullableLanPropertiesPost) Get() *LanPropertiesPost {
+ return v.value
+}
+
+func (v *NullableLanPropertiesPost) Set(val *LanPropertiesPost) {
+ v.value = val
+ v.isSet = true
+}
+
+func (v NullableLanPropertiesPost) IsSet() bool {
+ return v.isSet
+}
+
+func (v *NullableLanPropertiesPost) Unset() {
+ v.value = nil
+ v.isSet = false
+}
+
+func NewNullableLanPropertiesPost(val *LanPropertiesPost) *NullableLanPropertiesPost {
+ return &NullableLanPropertiesPost{value: val, isSet: true}
+}
+
+func (v NullableLanPropertiesPost) MarshalJSON() ([]byte, error) {
+ return json.Marshal(v.value)
+}
+
+func (v *NullableLanPropertiesPost) UnmarshalJSON(src []byte) error {
+ v.isSet = true
+ return json.Unmarshal(src, &v.value)
+}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_lans.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lans.go
index 361b3809f92..b0ee52ca2fd 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_lans.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_lans.go
@@ -16,19 +16,19 @@ import (
// Lans struct for Lans
type Lans struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Lan `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewLans instantiates a new Lans object
@@ -49,114 +49,114 @@ func NewLansWithDefaults() *Lans {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Lans) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *Lans) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Lans) GetIdOk() (*string, bool) {
+func (o *Lans) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *Lans) SetId(v string) {
+// SetLinks sets field value
+func (o *Lans) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Lans) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *Lans) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Lans) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Lans) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Lans) GetTypeOk() (*Type, bool) {
+func (o *Lans) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Lans) SetType(v Type) {
+// SetHref sets field value
+func (o *Lans) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Lans) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Lans) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Lans) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Lans) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Lans) GetHrefOk() (*string, bool) {
+func (o *Lans) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Lans) SetHref(v string) {
+// SetId sets field value
+func (o *Lans) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Lans) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Lans) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *Lans) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Lan will be returned
+// If the value is explicit nil, nil is returned
func (o *Lans) GetItems() *[]Lan {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *Lans) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Lans) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *Lans) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Lans) GetOffsetOk() (*float32, bool) {
+func (o *Lans) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *Lans) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *Lans) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *Lans) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *Lans) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Lans) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *Lans) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Lans) GetLimitOk() (*float32, bool) {
+func (o *Lans) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *Lans) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *Lans) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *Lans) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *Lans) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *Lans) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Lans) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Lans) GetLinksOk() (*PaginationLinks, bool) {
+func (o *Lans) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *Lans) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *Lans) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *Lans) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Lans) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *Lans) HasLinks() bool {
func (o Lans) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancer.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancer.go
index 822d7f1c38e..064e5eb9962 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancer.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancer.go
@@ -16,15 +16,15 @@ import (
// Loadbalancer struct for Loadbalancer
type Loadbalancer struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Entities *LoadbalancerEntities `json:"entities,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *LoadbalancerProperties `json:"properties"`
- Entities *LoadbalancerEntities `json:"entities,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewLoadbalancer instantiates a new Loadbalancer object
@@ -47,114 +47,114 @@ func NewLoadbalancerWithDefaults() *Loadbalancer {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Loadbalancer) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *Loadbalancer) GetEntities() *LoadbalancerEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Loadbalancer) GetIdOk() (*string, bool) {
+func (o *Loadbalancer) GetEntitiesOk() (*LoadbalancerEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *Loadbalancer) SetId(v string) {
+// SetEntities sets field value
+func (o *Loadbalancer) SetEntities(v LoadbalancerEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Loadbalancer) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *Loadbalancer) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Loadbalancer) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Loadbalancer) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Loadbalancer) GetTypeOk() (*Type, bool) {
+func (o *Loadbalancer) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Loadbalancer) SetType(v Type) {
+// SetHref sets field value
+func (o *Loadbalancer) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Loadbalancer) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Loadbalancer) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Loadbalancer) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Loadbalancer) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Loadbalancer) GetHrefOk() (*string, bool) {
+func (o *Loadbalancer) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Loadbalancer) SetHref(v string) {
+// SetId sets field value
+func (o *Loadbalancer) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Loadbalancer) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Loadbalancer) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -162,7 +162,7 @@ func (o *Loadbalancer) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *Loadbalancer) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
@@ -200,7 +200,7 @@ func (o *Loadbalancer) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for LoadbalancerProperties will be returned
+// If the value is explicit nil, nil is returned
func (o *Loadbalancer) GetProperties() *LoadbalancerProperties {
if o == nil {
return nil
@@ -237,38 +237,38 @@ func (o *Loadbalancer) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for LoadbalancerEntities will be returned
-func (o *Loadbalancer) GetEntities() *LoadbalancerEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Loadbalancer) GetType() *Type {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Loadbalancer) GetEntitiesOk() (*LoadbalancerEntities, bool) {
+func (o *Loadbalancer) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *Loadbalancer) SetEntities(v LoadbalancerEntities) {
+// SetType sets field value
+func (o *Loadbalancer) SetType(v Type) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *Loadbalancer) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Loadbalancer) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -277,24 +277,30 @@ func (o *Loadbalancer) HasEntities() bool {
func (o Loadbalancer) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancer_entities.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancer_entities.go
index 129844dcbd8..8a4c5049c9a 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancer_entities.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancer_entities.go
@@ -38,7 +38,7 @@ func NewLoadbalancerEntitiesWithDefaults() *LoadbalancerEntities {
}
// GetBalancednics returns the Balancednics field value
-// If the value is explicit nil, the zero value for BalancedNics will be returned
+// If the value is explicit nil, nil is returned
func (o *LoadbalancerEntities) GetBalancednics() *BalancedNics {
if o == nil {
return nil
@@ -80,6 +80,7 @@ func (o LoadbalancerEntities) MarshalJSON() ([]byte, error) {
if o.Balancednics != nil {
toSerialize["balancednics"] = o.Balancednics
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancer_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancer_properties.go
index e6b9b02fb28..9d1f3cee7ea 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancer_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancer_properties.go
@@ -16,12 +16,13 @@ import (
// LoadbalancerProperties struct for LoadbalancerProperties
type LoadbalancerProperties struct {
- // The name of the resource.
- Name *string `json:"name,omitempty"`
- // IPv4 address of the loadbalancer. All attached NICs will inherit this IP. Leaving value null will assign IP automatically.
- Ip *string `json:"ip,omitempty"`
// Indicates if the loadbalancer will reserve an IP using DHCP.
Dhcp *bool `json:"dhcp,omitempty"`
+ // IPv4 address of the loadbalancer. All attached NICs will inherit this IP. Leaving value null will assign IP automatically.
+ // to set this field to `nil` in order to be marshalled, the explicit nil address `Nilstring` can be used, or the setter `SetIpNil`
+ Ip *string `json:"ip,omitempty"`
+ // The name of the resource.
+ Name *string `json:"name,omitempty"`
}
// NewLoadbalancerProperties instantiates a new LoadbalancerProperties object
@@ -42,38 +43,38 @@ func NewLoadbalancerPropertiesWithDefaults() *LoadbalancerProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LoadbalancerProperties) GetName() *string {
+// GetDhcp returns the Dhcp field value
+// If the value is explicit nil, nil is returned
+func (o *LoadbalancerProperties) GetDhcp() *bool {
if o == nil {
return nil
}
- return o.Name
+ return o.Dhcp
}
-// GetNameOk returns a tuple with the Name field value
+// GetDhcpOk returns a tuple with the Dhcp field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LoadbalancerProperties) GetNameOk() (*string, bool) {
+func (o *LoadbalancerProperties) GetDhcpOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.Dhcp, true
}
-// SetName sets field value
-func (o *LoadbalancerProperties) SetName(v string) {
+// SetDhcp sets field value
+func (o *LoadbalancerProperties) SetDhcp(v bool) {
- o.Name = &v
+ o.Dhcp = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *LoadbalancerProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasDhcp returns a boolean if a field has been set.
+func (o *LoadbalancerProperties) HasDhcp() bool {
+ if o != nil && o.Dhcp != nil {
return true
}
@@ -81,7 +82,7 @@ func (o *LoadbalancerProperties) HasName() bool {
}
// GetIp returns the Ip field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *LoadbalancerProperties) GetIp() *string {
if o == nil {
return nil
@@ -109,6 +110,11 @@ func (o *LoadbalancerProperties) SetIp(v string) {
}
+// sets Ip to the explicit address that will be encoded as nil when marshaled
+func (o *LoadbalancerProperties) SetIpNil() {
+ o.Ip = &Nilstring
+}
+
// HasIp returns a boolean if a field has been set.
func (o *LoadbalancerProperties) HasIp() bool {
if o != nil && o.Ip != nil {
@@ -118,38 +124,38 @@ func (o *LoadbalancerProperties) HasIp() bool {
return false
}
-// GetDhcp returns the Dhcp field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *LoadbalancerProperties) GetDhcp() *bool {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *LoadbalancerProperties) GetName() *string {
if o == nil {
return nil
}
- return o.Dhcp
+ return o.Name
}
-// GetDhcpOk returns a tuple with the Dhcp field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LoadbalancerProperties) GetDhcpOk() (*bool, bool) {
+func (o *LoadbalancerProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Dhcp, true
+ return o.Name, true
}
-// SetDhcp sets field value
-func (o *LoadbalancerProperties) SetDhcp(v bool) {
+// SetName sets field value
+func (o *LoadbalancerProperties) SetName(v string) {
- o.Dhcp = &v
+ o.Name = &v
}
-// HasDhcp returns a boolean if a field has been set.
-func (o *LoadbalancerProperties) HasDhcp() bool {
- if o != nil && o.Dhcp != nil {
+// HasName returns a boolean if a field has been set.
+func (o *LoadbalancerProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -158,13 +164,19 @@ func (o *LoadbalancerProperties) HasDhcp() bool {
func (o LoadbalancerProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
- }
- toSerialize["ip"] = o.Ip
if o.Dhcp != nil {
toSerialize["dhcp"] = o.Dhcp
}
+
+ if o.Ip == &Nilstring {
+ toSerialize["ip"] = nil
+ } else if o.Ip != nil {
+ toSerialize["ip"] = o.Ip
+ }
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancers.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancers.go
index 166560f99b0..267eba36f4d 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancers.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_loadbalancers.go
@@ -16,19 +16,19 @@ import (
// Loadbalancers struct for Loadbalancers
type Loadbalancers struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Loadbalancer `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewLoadbalancers instantiates a new Loadbalancers object
@@ -49,114 +49,114 @@ func NewLoadbalancersWithDefaults() *Loadbalancers {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Loadbalancers) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *Loadbalancers) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Loadbalancers) GetIdOk() (*string, bool) {
+func (o *Loadbalancers) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *Loadbalancers) SetId(v string) {
+// SetLinks sets field value
+func (o *Loadbalancers) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Loadbalancers) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *Loadbalancers) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Loadbalancers) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Loadbalancers) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Loadbalancers) GetTypeOk() (*Type, bool) {
+func (o *Loadbalancers) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Loadbalancers) SetType(v Type) {
+// SetHref sets field value
+func (o *Loadbalancers) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Loadbalancers) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Loadbalancers) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Loadbalancers) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Loadbalancers) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Loadbalancers) GetHrefOk() (*string, bool) {
+func (o *Loadbalancers) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Loadbalancers) SetHref(v string) {
+// SetId sets field value
+func (o *Loadbalancers) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Loadbalancers) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Loadbalancers) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *Loadbalancers) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Loadbalancer will be returned
+// If the value is explicit nil, nil is returned
func (o *Loadbalancers) GetItems() *[]Loadbalancer {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *Loadbalancers) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Loadbalancers) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *Loadbalancers) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Loadbalancers) GetOffsetOk() (*float32, bool) {
+func (o *Loadbalancers) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *Loadbalancers) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *Loadbalancers) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *Loadbalancers) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *Loadbalancers) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Loadbalancers) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *Loadbalancers) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Loadbalancers) GetLimitOk() (*float32, bool) {
+func (o *Loadbalancers) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *Loadbalancers) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *Loadbalancers) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *Loadbalancers) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *Loadbalancers) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *Loadbalancers) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Loadbalancers) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Loadbalancers) GetLinksOk() (*PaginationLinks, bool) {
+func (o *Loadbalancers) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *Loadbalancers) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *Loadbalancers) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *Loadbalancers) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Loadbalancers) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *Loadbalancers) HasLinks() bool {
func (o Loadbalancers) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_location.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_location.go
index 59a250d4529..379723ff1a9 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_location.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_location.go
@@ -16,14 +16,14 @@ import (
// Location struct for Location
type Location struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *LocationProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewLocation instantiates a new Location object
@@ -46,190 +46,190 @@ func NewLocationWithDefaults() *Location {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Location) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Location) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Location) GetIdOk() (*string, bool) {
+func (o *Location) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Location) SetId(v string) {
+// SetHref sets field value
+func (o *Location) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Location) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Location) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Location) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Location) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Location) GetTypeOk() (*Type, bool) {
+func (o *Location) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Location) SetType(v Type) {
+// SetId sets field value
+func (o *Location) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Location) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Location) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Location) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *Location) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Location) GetHrefOk() (*string, bool) {
+func (o *Location) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *Location) SetHref(v string) {
+// SetMetadata sets field value
+func (o *Location) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Location) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *Location) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *Location) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *Location) GetProperties() *LocationProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Location) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *Location) GetPropertiesOk() (*LocationProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *Location) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *Location) SetProperties(v LocationProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *Location) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *Location) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for LocationProperties will be returned
-func (o *Location) GetProperties() *LocationProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Location) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Location) GetPropertiesOk() (*LocationProperties, bool) {
+func (o *Location) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *Location) SetProperties(v LocationProperties) {
+// SetType sets field value
+func (o *Location) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *Location) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Location) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *Location) HasProperties() bool {
func (o Location) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_location_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_location_properties.go
index 9e8e623b606..95da4abb396 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_location_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_location_properties.go
@@ -16,14 +16,14 @@ import (
// LocationProperties struct for LocationProperties
type LocationProperties struct {
- // The location name.
- Name *string `json:"name,omitempty"`
+ // A list of available CPU types and related resources available in the location.
+ CpuArchitecture *[]CpuArchitectureProperties `json:"cpuArchitecture,omitempty"`
// A list of available features in the location.
Features *[]string `json:"features,omitempty"`
// A list of image aliases available in the location.
ImageAliases *[]string `json:"imageAliases,omitempty"`
- // A list of available CPU types and related resources available in the location.
- CpuArchitecture *[]CpuArchitectureProperties `json:"cpuArchitecture,omitempty"`
+ // The location name.
+ Name *string `json:"name,omitempty"`
}
// NewLocationProperties instantiates a new LocationProperties object
@@ -44,38 +44,38 @@ func NewLocationPropertiesWithDefaults() *LocationProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *LocationProperties) GetName() *string {
+// GetCpuArchitecture returns the CpuArchitecture field value
+// If the value is explicit nil, nil is returned
+func (o *LocationProperties) GetCpuArchitecture() *[]CpuArchitectureProperties {
if o == nil {
return nil
}
- return o.Name
+ return o.CpuArchitecture
}
-// GetNameOk returns a tuple with the Name field value
+// GetCpuArchitectureOk returns a tuple with the CpuArchitecture field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LocationProperties) GetNameOk() (*string, bool) {
+func (o *LocationProperties) GetCpuArchitectureOk() (*[]CpuArchitectureProperties, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.CpuArchitecture, true
}
-// SetName sets field value
-func (o *LocationProperties) SetName(v string) {
+// SetCpuArchitecture sets field value
+func (o *LocationProperties) SetCpuArchitecture(v []CpuArchitectureProperties) {
- o.Name = &v
+ o.CpuArchitecture = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *LocationProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasCpuArchitecture returns a boolean if a field has been set.
+func (o *LocationProperties) HasCpuArchitecture() bool {
+ if o != nil && o.CpuArchitecture != nil {
return true
}
@@ -83,7 +83,7 @@ func (o *LocationProperties) HasName() bool {
}
// GetFeatures returns the Features field value
-// If the value is explicit nil, the zero value for []string will be returned
+// If the value is explicit nil, nil is returned
func (o *LocationProperties) GetFeatures() *[]string {
if o == nil {
return nil
@@ -121,7 +121,7 @@ func (o *LocationProperties) HasFeatures() bool {
}
// GetImageAliases returns the ImageAliases field value
-// If the value is explicit nil, the zero value for []string will be returned
+// If the value is explicit nil, nil is returned
func (o *LocationProperties) GetImageAliases() *[]string {
if o == nil {
return nil
@@ -158,38 +158,38 @@ func (o *LocationProperties) HasImageAliases() bool {
return false
}
-// GetCpuArchitecture returns the CpuArchitecture field value
-// If the value is explicit nil, the zero value for []CpuArchitectureProperties will be returned
-func (o *LocationProperties) GetCpuArchitecture() *[]CpuArchitectureProperties {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *LocationProperties) GetName() *string {
if o == nil {
return nil
}
- return o.CpuArchitecture
+ return o.Name
}
-// GetCpuArchitectureOk returns a tuple with the CpuArchitecture field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *LocationProperties) GetCpuArchitectureOk() (*[]CpuArchitectureProperties, bool) {
+func (o *LocationProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.CpuArchitecture, true
+ return o.Name, true
}
-// SetCpuArchitecture sets field value
-func (o *LocationProperties) SetCpuArchitecture(v []CpuArchitectureProperties) {
+// SetName sets field value
+func (o *LocationProperties) SetName(v string) {
- o.CpuArchitecture = &v
+ o.Name = &v
}
-// HasCpuArchitecture returns a boolean if a field has been set.
-func (o *LocationProperties) HasCpuArchitecture() bool {
- if o != nil && o.CpuArchitecture != nil {
+// HasName returns a boolean if a field has been set.
+func (o *LocationProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *LocationProperties) HasCpuArchitecture() bool {
func (o LocationProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
+ if o.CpuArchitecture != nil {
+ toSerialize["cpuArchitecture"] = o.CpuArchitecture
}
+
if o.Features != nil {
toSerialize["features"] = o.Features
}
+
if o.ImageAliases != nil {
toSerialize["imageAliases"] = o.ImageAliases
}
- if o.CpuArchitecture != nil {
- toSerialize["cpuArchitecture"] = o.CpuArchitecture
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_locations.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_locations.go
index ba9354acec7..d3311051b43 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_locations.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_locations.go
@@ -16,14 +16,14 @@ import (
// Locations struct for Locations
type Locations struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Location `json:"items,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewLocations instantiates a new Locations object
@@ -44,152 +44,152 @@ func NewLocationsWithDefaults() *Locations {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Locations) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Locations) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Locations) GetIdOk() (*string, bool) {
+func (o *Locations) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Locations) SetId(v string) {
+// SetHref sets field value
+func (o *Locations) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Locations) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Locations) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Locations) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Locations) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Locations) GetTypeOk() (*Type, bool) {
+func (o *Locations) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Locations) SetType(v Type) {
+// SetId sets field value
+func (o *Locations) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Locations) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Locations) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Locations) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *Locations) GetItems() *[]Location {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Locations) GetHrefOk() (*string, bool) {
+func (o *Locations) GetItemsOk() (*[]Location, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *Locations) SetHref(v string) {
+// SetItems sets field value
+func (o *Locations) SetItems(v []Location) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Locations) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *Locations) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Location will be returned
-func (o *Locations) GetItems() *[]Location {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Locations) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Locations) GetItemsOk() (*[]Location, bool) {
+func (o *Locations) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *Locations) SetItems(v []Location) {
+// SetType sets field value
+func (o *Locations) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *Locations) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Locations) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *Locations) HasItems() bool {
func (o Locations) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway.go
index 70f8e92a9bd..2feaa609f98 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway.go
@@ -16,15 +16,15 @@ import (
// NatGateway struct for NatGateway
type NatGateway struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Entities *NatGatewayEntities `json:"entities,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *NatGatewayProperties `json:"properties"`
- Entities *NatGatewayEntities `json:"entities,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewNatGateway instantiates a new NatGateway object
@@ -47,114 +47,114 @@ func NewNatGatewayWithDefaults() *NatGateway {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGateway) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *NatGateway) GetEntities() *NatGatewayEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGateway) GetIdOk() (*string, bool) {
+func (o *NatGateway) GetEntitiesOk() (*NatGatewayEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *NatGateway) SetId(v string) {
+// SetEntities sets field value
+func (o *NatGateway) SetEntities(v NatGatewayEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NatGateway) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *NatGateway) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NatGateway) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NatGateway) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGateway) GetTypeOk() (*Type, bool) {
+func (o *NatGateway) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *NatGateway) SetType(v Type) {
+// SetHref sets field value
+func (o *NatGateway) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NatGateway) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NatGateway) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGateway) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NatGateway) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGateway) GetHrefOk() (*string, bool) {
+func (o *NatGateway) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *NatGateway) SetHref(v string) {
+// SetId sets field value
+func (o *NatGateway) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NatGateway) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NatGateway) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -162,7 +162,7 @@ func (o *NatGateway) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *NatGateway) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
@@ -200,7 +200,7 @@ func (o *NatGateway) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for NatGatewayProperties will be returned
+// If the value is explicit nil, nil is returned
func (o *NatGateway) GetProperties() *NatGatewayProperties {
if o == nil {
return nil
@@ -237,38 +237,38 @@ func (o *NatGateway) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for NatGatewayEntities will be returned
-func (o *NatGateway) GetEntities() *NatGatewayEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NatGateway) GetType() *Type {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGateway) GetEntitiesOk() (*NatGatewayEntities, bool) {
+func (o *NatGateway) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *NatGateway) SetEntities(v NatGatewayEntities) {
+// SetType sets field value
+func (o *NatGateway) SetType(v Type) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *NatGateway) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NatGateway) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -277,24 +277,30 @@ func (o *NatGateway) HasEntities() bool {
func (o NatGateway) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_entities.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_entities.go
index d51cb9543ce..94fae49c42a 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_entities.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_entities.go
@@ -16,8 +16,8 @@ import (
// NatGatewayEntities struct for NatGatewayEntities
type NatGatewayEntities struct {
- Rules *NatGatewayRules `json:"rules,omitempty"`
Flowlogs *FlowLogs `json:"flowlogs,omitempty"`
+ Rules *NatGatewayRules `json:"rules,omitempty"`
}
// NewNatGatewayEntities instantiates a new NatGatewayEntities object
@@ -38,76 +38,76 @@ func NewNatGatewayEntitiesWithDefaults() *NatGatewayEntities {
return &this
}
-// GetRules returns the Rules field value
-// If the value is explicit nil, the zero value for NatGatewayRules will be returned
-func (o *NatGatewayEntities) GetRules() *NatGatewayRules {
+// GetFlowlogs returns the Flowlogs field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayEntities) GetFlowlogs() *FlowLogs {
if o == nil {
return nil
}
- return o.Rules
+ return o.Flowlogs
}
-// GetRulesOk returns a tuple with the Rules field value
+// GetFlowlogsOk returns a tuple with the Flowlogs field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayEntities) GetRulesOk() (*NatGatewayRules, bool) {
+func (o *NatGatewayEntities) GetFlowlogsOk() (*FlowLogs, bool) {
if o == nil {
return nil, false
}
- return o.Rules, true
+ return o.Flowlogs, true
}
-// SetRules sets field value
-func (o *NatGatewayEntities) SetRules(v NatGatewayRules) {
+// SetFlowlogs sets field value
+func (o *NatGatewayEntities) SetFlowlogs(v FlowLogs) {
- o.Rules = &v
+ o.Flowlogs = &v
}
-// HasRules returns a boolean if a field has been set.
-func (o *NatGatewayEntities) HasRules() bool {
- if o != nil && o.Rules != nil {
+// HasFlowlogs returns a boolean if a field has been set.
+func (o *NatGatewayEntities) HasFlowlogs() bool {
+ if o != nil && o.Flowlogs != nil {
return true
}
return false
}
-// GetFlowlogs returns the Flowlogs field value
-// If the value is explicit nil, the zero value for FlowLogs will be returned
-func (o *NatGatewayEntities) GetFlowlogs() *FlowLogs {
+// GetRules returns the Rules field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayEntities) GetRules() *NatGatewayRules {
if o == nil {
return nil
}
- return o.Flowlogs
+ return o.Rules
}
-// GetFlowlogsOk returns a tuple with the Flowlogs field value
+// GetRulesOk returns a tuple with the Rules field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayEntities) GetFlowlogsOk() (*FlowLogs, bool) {
+func (o *NatGatewayEntities) GetRulesOk() (*NatGatewayRules, bool) {
if o == nil {
return nil, false
}
- return o.Flowlogs, true
+ return o.Rules, true
}
-// SetFlowlogs sets field value
-func (o *NatGatewayEntities) SetFlowlogs(v FlowLogs) {
+// SetRules sets field value
+func (o *NatGatewayEntities) SetRules(v NatGatewayRules) {
- o.Flowlogs = &v
+ o.Rules = &v
}
-// HasFlowlogs returns a boolean if a field has been set.
-func (o *NatGatewayEntities) HasFlowlogs() bool {
- if o != nil && o.Flowlogs != nil {
+// HasRules returns a boolean if a field has been set.
+func (o *NatGatewayEntities) HasRules() bool {
+ if o != nil && o.Rules != nil {
return true
}
@@ -116,12 +116,14 @@ func (o *NatGatewayEntities) HasFlowlogs() bool {
func (o NatGatewayEntities) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Rules != nil {
- toSerialize["rules"] = o.Rules
- }
if o.Flowlogs != nil {
toSerialize["flowlogs"] = o.Flowlogs
}
+
+ if o.Rules != nil {
+ toSerialize["rules"] = o.Rules
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_lan_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_lan_properties.go
index 007a57d6903..068b141bebb 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_lan_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_lan_properties.go
@@ -16,10 +16,10 @@ import (
// NatGatewayLanProperties struct for NatGatewayLanProperties
type NatGatewayLanProperties struct {
- // Id for the LAN connected to the NAT Gateway
- Id *int32 `json:"id"`
// Collection of gateway IP addresses of the NAT Gateway. Will be auto-generated if not provided. Should ideally be an IP belonging to the same subnet as the LAN
GatewayIps *[]string `json:"gatewayIps,omitempty"`
+ // Id for the LAN connected to the NAT Gateway
+ Id *int32 `json:"id"`
}
// NewNatGatewayLanProperties instantiates a new NatGatewayLanProperties object
@@ -42,76 +42,76 @@ func NewNatGatewayLanPropertiesWithDefaults() *NatGatewayLanProperties {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *NatGatewayLanProperties) GetId() *int32 {
+// GetGatewayIps returns the GatewayIps field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayLanProperties) GetGatewayIps() *[]string {
if o == nil {
return nil
}
- return o.Id
+ return o.GatewayIps
}
-// GetIdOk returns a tuple with the Id field value
+// GetGatewayIpsOk returns a tuple with the GatewayIps field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayLanProperties) GetIdOk() (*int32, bool) {
+func (o *NatGatewayLanProperties) GetGatewayIpsOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.GatewayIps, true
}
-// SetId sets field value
-func (o *NatGatewayLanProperties) SetId(v int32) {
+// SetGatewayIps sets field value
+func (o *NatGatewayLanProperties) SetGatewayIps(v []string) {
- o.Id = &v
+ o.GatewayIps = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NatGatewayLanProperties) HasId() bool {
- if o != nil && o.Id != nil {
+// HasGatewayIps returns a boolean if a field has been set.
+func (o *NatGatewayLanProperties) HasGatewayIps() bool {
+ if o != nil && o.GatewayIps != nil {
return true
}
return false
}
-// GetGatewayIps returns the GatewayIps field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *NatGatewayLanProperties) GetGatewayIps() *[]string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayLanProperties) GetId() *int32 {
if o == nil {
return nil
}
- return o.GatewayIps
+ return o.Id
}
-// GetGatewayIpsOk returns a tuple with the GatewayIps field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayLanProperties) GetGatewayIpsOk() (*[]string, bool) {
+func (o *NatGatewayLanProperties) GetIdOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.GatewayIps, true
+ return o.Id, true
}
-// SetGatewayIps sets field value
-func (o *NatGatewayLanProperties) SetGatewayIps(v []string) {
+// SetId sets field value
+func (o *NatGatewayLanProperties) SetId(v int32) {
- o.GatewayIps = &v
+ o.Id = &v
}
-// HasGatewayIps returns a boolean if a field has been set.
-func (o *NatGatewayLanProperties) HasGatewayIps() bool {
- if o != nil && o.GatewayIps != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NatGatewayLanProperties) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -120,12 +120,14 @@ func (o *NatGatewayLanProperties) HasGatewayIps() bool {
func (o NatGatewayLanProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
if o.GatewayIps != nil {
toSerialize["gatewayIps"] = o.GatewayIps
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_properties.go
index 6eea997ef31..ad784ad9f97 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_properties.go
@@ -16,12 +16,12 @@ import (
// NatGatewayProperties struct for NatGatewayProperties
type NatGatewayProperties struct {
+ // Collection of LANs connected to the NAT Gateway. IPs must contain a valid subnet mask. If no IP is provided, the system will generate an IP with /24 subnet.
+ Lans *[]NatGatewayLanProperties `json:"lans,omitempty"`
// Name of the NAT Gateway.
Name *string `json:"name"`
// Collection of public IP addresses of the NAT Gateway. Should be customer reserved IP addresses in that location.
PublicIps *[]string `json:"publicIps"`
- // Collection of LANs connected to the NAT Gateway. IPs must contain a valid subnet mask. If no IP is provided, the system will generate an IP with /24 subnet.
- Lans *[]NatGatewayLanProperties `json:"lans,omitempty"`
}
// NewNatGatewayProperties instantiates a new NatGatewayProperties object
@@ -45,114 +45,114 @@ func NewNatGatewayPropertiesWithDefaults() *NatGatewayProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGatewayProperties) GetName() *string {
+// GetLans returns the Lans field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayProperties) GetLans() *[]NatGatewayLanProperties {
if o == nil {
return nil
}
- return o.Name
+ return o.Lans
}
-// GetNameOk returns a tuple with the Name field value
+// GetLansOk returns a tuple with the Lans field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayProperties) GetNameOk() (*string, bool) {
+func (o *NatGatewayProperties) GetLansOk() (*[]NatGatewayLanProperties, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.Lans, true
}
-// SetName sets field value
-func (o *NatGatewayProperties) SetName(v string) {
+// SetLans sets field value
+func (o *NatGatewayProperties) SetLans(v []NatGatewayLanProperties) {
- o.Name = &v
+ o.Lans = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *NatGatewayProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasLans returns a boolean if a field has been set.
+func (o *NatGatewayProperties) HasLans() bool {
+ if o != nil && o.Lans != nil {
return true
}
return false
}
-// GetPublicIps returns the PublicIps field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *NatGatewayProperties) GetPublicIps() *[]string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayProperties) GetName() *string {
if o == nil {
return nil
}
- return o.PublicIps
+ return o.Name
}
-// GetPublicIpsOk returns a tuple with the PublicIps field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayProperties) GetPublicIpsOk() (*[]string, bool) {
+func (o *NatGatewayProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.PublicIps, true
+ return o.Name, true
}
-// SetPublicIps sets field value
-func (o *NatGatewayProperties) SetPublicIps(v []string) {
+// SetName sets field value
+func (o *NatGatewayProperties) SetName(v string) {
- o.PublicIps = &v
+ o.Name = &v
}
-// HasPublicIps returns a boolean if a field has been set.
-func (o *NatGatewayProperties) HasPublicIps() bool {
- if o != nil && o.PublicIps != nil {
+// HasName returns a boolean if a field has been set.
+func (o *NatGatewayProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetLans returns the Lans field value
-// If the value is explicit nil, the zero value for []NatGatewayLanProperties will be returned
-func (o *NatGatewayProperties) GetLans() *[]NatGatewayLanProperties {
+// GetPublicIps returns the PublicIps field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayProperties) GetPublicIps() *[]string {
if o == nil {
return nil
}
- return o.Lans
+ return o.PublicIps
}
-// GetLansOk returns a tuple with the Lans field value
+// GetPublicIpsOk returns a tuple with the PublicIps field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayProperties) GetLansOk() (*[]NatGatewayLanProperties, bool) {
+func (o *NatGatewayProperties) GetPublicIpsOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.Lans, true
+ return o.PublicIps, true
}
-// SetLans sets field value
-func (o *NatGatewayProperties) SetLans(v []NatGatewayLanProperties) {
+// SetPublicIps sets field value
+func (o *NatGatewayProperties) SetPublicIps(v []string) {
- o.Lans = &v
+ o.PublicIps = &v
}
-// HasLans returns a boolean if a field has been set.
-func (o *NatGatewayProperties) HasLans() bool {
- if o != nil && o.Lans != nil {
+// HasPublicIps returns a boolean if a field has been set.
+func (o *NatGatewayProperties) HasPublicIps() bool {
+ if o != nil && o.PublicIps != nil {
return true
}
@@ -161,15 +161,18 @@ func (o *NatGatewayProperties) HasLans() bool {
func (o NatGatewayProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
+ if o.Lans != nil {
+ toSerialize["lans"] = o.Lans
+ }
+
if o.Name != nil {
toSerialize["name"] = o.Name
}
+
if o.PublicIps != nil {
toSerialize["publicIps"] = o.PublicIps
}
- if o.Lans != nil {
- toSerialize["lans"] = o.Lans
- }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_put.go
index cf9a8a0486f..5bd37720efb 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_put.go
@@ -16,13 +16,13 @@ import (
// NatGatewayPut struct for NatGatewayPut
type NatGatewayPut struct {
+ // URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
- Id *string `json:"id,omitempty"`
+ Id *string `json:"id,omitempty"`
+ Properties *NatGatewayProperties `json:"properties"`
// The type of object that has been created.
Type *Type `json:"type,omitempty"`
- // URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
- Properties *NatGatewayProperties `json:"properties"`
}
// NewNatGatewayPut instantiates a new NatGatewayPut object
@@ -45,152 +45,152 @@ func NewNatGatewayPutWithDefaults() *NatGatewayPut {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGatewayPut) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayPut) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayPut) GetIdOk() (*string, bool) {
+func (o *NatGatewayPut) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *NatGatewayPut) SetId(v string) {
+// SetHref sets field value
+func (o *NatGatewayPut) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NatGatewayPut) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NatGatewayPut) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NatGatewayPut) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayPut) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayPut) GetTypeOk() (*Type, bool) {
+func (o *NatGatewayPut) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *NatGatewayPut) SetType(v Type) {
+// SetId sets field value
+func (o *NatGatewayPut) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NatGatewayPut) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NatGatewayPut) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGatewayPut) GetHref() *string {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayPut) GetProperties() *NatGatewayProperties {
if o == nil {
return nil
}
- return o.Href
+ return o.Properties
}
-// GetHrefOk returns a tuple with the Href field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayPut) GetHrefOk() (*string, bool) {
+func (o *NatGatewayPut) GetPropertiesOk() (*NatGatewayProperties, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Properties, true
}
-// SetHref sets field value
-func (o *NatGatewayPut) SetHref(v string) {
+// SetProperties sets field value
+func (o *NatGatewayPut) SetProperties(v NatGatewayProperties) {
- o.Href = &v
+ o.Properties = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NatGatewayPut) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *NatGatewayPut) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for NatGatewayProperties will be returned
-func (o *NatGatewayPut) GetProperties() *NatGatewayProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayPut) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayPut) GetPropertiesOk() (*NatGatewayProperties, bool) {
+func (o *NatGatewayPut) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *NatGatewayPut) SetProperties(v NatGatewayProperties) {
+// SetType sets field value
+func (o *NatGatewayPut) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *NatGatewayPut) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NatGatewayPut) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -199,18 +199,22 @@ func (o *NatGatewayPut) HasProperties() bool {
func (o NatGatewayPut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rule.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rule.go
index 42d20aac891..4693555cafa 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rule.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rule.go
@@ -16,14 +16,14 @@ import (
// NatGatewayRule struct for NatGatewayRule
type NatGatewayRule struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *NatGatewayRuleProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewNatGatewayRule instantiates a new NatGatewayRule object
@@ -46,190 +46,190 @@ func NewNatGatewayRuleWithDefaults() *NatGatewayRule {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGatewayRule) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRule) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRule) GetIdOk() (*string, bool) {
+func (o *NatGatewayRule) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *NatGatewayRule) SetId(v string) {
+// SetHref sets field value
+func (o *NatGatewayRule) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NatGatewayRule) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NatGatewayRule) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NatGatewayRule) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRule) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRule) GetTypeOk() (*Type, bool) {
+func (o *NatGatewayRule) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *NatGatewayRule) SetType(v Type) {
+// SetId sets field value
+func (o *NatGatewayRule) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NatGatewayRule) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NatGatewayRule) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGatewayRule) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRule) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRule) GetHrefOk() (*string, bool) {
+func (o *NatGatewayRule) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *NatGatewayRule) SetHref(v string) {
+// SetMetadata sets field value
+func (o *NatGatewayRule) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NatGatewayRule) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *NatGatewayRule) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *NatGatewayRule) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRule) GetProperties() *NatGatewayRuleProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRule) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *NatGatewayRule) GetPropertiesOk() (*NatGatewayRuleProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *NatGatewayRule) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *NatGatewayRule) SetProperties(v NatGatewayRuleProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *NatGatewayRule) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *NatGatewayRule) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for NatGatewayRuleProperties will be returned
-func (o *NatGatewayRule) GetProperties() *NatGatewayRuleProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRule) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRule) GetPropertiesOk() (*NatGatewayRuleProperties, bool) {
+func (o *NatGatewayRule) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *NatGatewayRule) SetProperties(v NatGatewayRuleProperties) {
+// SetType sets field value
+func (o *NatGatewayRule) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *NatGatewayRule) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NatGatewayRule) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *NatGatewayRule) HasProperties() bool {
func (o NatGatewayRule) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rule_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rule_properties.go
index 8b3da441e6c..32330acee59 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rule_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rule_properties.go
@@ -18,29 +18,29 @@ import (
type NatGatewayRuleProperties struct {
// The name of the NAT Gateway rule.
Name *string `json:"name"`
- // Type of the NAT Gateway rule.
- Type *NatGatewayRuleType `json:"type,omitempty"`
// Protocol of the NAT Gateway rule. Defaults to ALL. If protocol is 'ICMP' then targetPortRange start and end cannot be set.
Protocol *NatGatewayRuleProtocol `json:"protocol,omitempty"`
- // Source subnet of the NAT Gateway rule. For SNAT rules it specifies which packets this translation rule applies to based on the packets source IP address.
- SourceSubnet *string `json:"sourceSubnet"`
// Public IP address of the NAT Gateway rule. Specifies the address used for masking outgoing packets source address field. Should be one of the customer reserved IP address already configured on the NAT Gateway resource
PublicIp *string `json:"publicIp"`
- // Target or destination subnet of the NAT Gateway rule. For SNAT rules it specifies which packets this translation rule applies to based on the packets destination IP address. If none is provided, rule will match any address.
- TargetSubnet *string `json:"targetSubnet,omitempty"`
+ // Source subnet of the NAT Gateway rule. For SNAT rules it specifies which packets this translation rule applies to based on the packets source IP address.
+ SourceSubnet *string `json:"sourceSubnet"`
TargetPortRange *TargetPortRange `json:"targetPortRange,omitempty"`
+ // Target or destination subnet of the NAT Gateway rule. For SNAT rules it specifies which packets this translation rule applies to based on the packets destination IP address. If none is provided, rule will match any address.
+ TargetSubnet *string `json:"targetSubnet,omitempty"`
+ // Type of the NAT Gateway rule.
+ Type *NatGatewayRuleType `json:"type,omitempty"`
}
// NewNatGatewayRuleProperties instantiates a new NatGatewayRuleProperties object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewNatGatewayRuleProperties(name string, sourceSubnet string, publicIp string) *NatGatewayRuleProperties {
+func NewNatGatewayRuleProperties(name string, publicIp string, sourceSubnet string) *NatGatewayRuleProperties {
this := NatGatewayRuleProperties{}
this.Name = &name
- this.SourceSubnet = &sourceSubnet
this.PublicIp = &publicIp
+ this.SourceSubnet = &sourceSubnet
return &this
}
@@ -54,7 +54,7 @@ func NewNatGatewayRulePropertiesWithDefaults() *NatGatewayRuleProperties {
}
// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *NatGatewayRuleProperties) GetName() *string {
if o == nil {
return nil
@@ -91,76 +91,76 @@ func (o *NatGatewayRuleProperties) HasName() bool {
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for NatGatewayRuleType will be returned
-func (o *NatGatewayRuleProperties) GetType() *NatGatewayRuleType {
+// GetProtocol returns the Protocol field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRuleProperties) GetProtocol() *NatGatewayRuleProtocol {
if o == nil {
return nil
}
- return o.Type
+ return o.Protocol
}
-// GetTypeOk returns a tuple with the Type field value
+// GetProtocolOk returns a tuple with the Protocol field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRuleProperties) GetTypeOk() (*NatGatewayRuleType, bool) {
+func (o *NatGatewayRuleProperties) GetProtocolOk() (*NatGatewayRuleProtocol, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Protocol, true
}
-// SetType sets field value
-func (o *NatGatewayRuleProperties) SetType(v NatGatewayRuleType) {
+// SetProtocol sets field value
+func (o *NatGatewayRuleProperties) SetProtocol(v NatGatewayRuleProtocol) {
- o.Type = &v
+ o.Protocol = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NatGatewayRuleProperties) HasType() bool {
- if o != nil && o.Type != nil {
+// HasProtocol returns a boolean if a field has been set.
+func (o *NatGatewayRuleProperties) HasProtocol() bool {
+ if o != nil && o.Protocol != nil {
return true
}
return false
}
-// GetProtocol returns the Protocol field value
-// If the value is explicit nil, the zero value for NatGatewayRuleProtocol will be returned
-func (o *NatGatewayRuleProperties) GetProtocol() *NatGatewayRuleProtocol {
+// GetPublicIp returns the PublicIp field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRuleProperties) GetPublicIp() *string {
if o == nil {
return nil
}
- return o.Protocol
+ return o.PublicIp
}
-// GetProtocolOk returns a tuple with the Protocol field value
+// GetPublicIpOk returns a tuple with the PublicIp field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRuleProperties) GetProtocolOk() (*NatGatewayRuleProtocol, bool) {
+func (o *NatGatewayRuleProperties) GetPublicIpOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Protocol, true
+ return o.PublicIp, true
}
-// SetProtocol sets field value
-func (o *NatGatewayRuleProperties) SetProtocol(v NatGatewayRuleProtocol) {
+// SetPublicIp sets field value
+func (o *NatGatewayRuleProperties) SetPublicIp(v string) {
- o.Protocol = &v
+ o.PublicIp = &v
}
-// HasProtocol returns a boolean if a field has been set.
-func (o *NatGatewayRuleProperties) HasProtocol() bool {
- if o != nil && o.Protocol != nil {
+// HasPublicIp returns a boolean if a field has been set.
+func (o *NatGatewayRuleProperties) HasPublicIp() bool {
+ if o != nil && o.PublicIp != nil {
return true
}
@@ -168,7 +168,7 @@ func (o *NatGatewayRuleProperties) HasProtocol() bool {
}
// GetSourceSubnet returns the SourceSubnet field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *NatGatewayRuleProperties) GetSourceSubnet() *string {
if o == nil {
return nil
@@ -205,38 +205,38 @@ func (o *NatGatewayRuleProperties) HasSourceSubnet() bool {
return false
}
-// GetPublicIp returns the PublicIp field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGatewayRuleProperties) GetPublicIp() *string {
+// GetTargetPortRange returns the TargetPortRange field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRuleProperties) GetTargetPortRange() *TargetPortRange {
if o == nil {
return nil
}
- return o.PublicIp
+ return o.TargetPortRange
}
-// GetPublicIpOk returns a tuple with the PublicIp field value
+// GetTargetPortRangeOk returns a tuple with the TargetPortRange field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRuleProperties) GetPublicIpOk() (*string, bool) {
+func (o *NatGatewayRuleProperties) GetTargetPortRangeOk() (*TargetPortRange, bool) {
if o == nil {
return nil, false
}
- return o.PublicIp, true
+ return o.TargetPortRange, true
}
-// SetPublicIp sets field value
-func (o *NatGatewayRuleProperties) SetPublicIp(v string) {
+// SetTargetPortRange sets field value
+func (o *NatGatewayRuleProperties) SetTargetPortRange(v TargetPortRange) {
- o.PublicIp = &v
+ o.TargetPortRange = &v
}
-// HasPublicIp returns a boolean if a field has been set.
-func (o *NatGatewayRuleProperties) HasPublicIp() bool {
- if o != nil && o.PublicIp != nil {
+// HasTargetPortRange returns a boolean if a field has been set.
+func (o *NatGatewayRuleProperties) HasTargetPortRange() bool {
+ if o != nil && o.TargetPortRange != nil {
return true
}
@@ -244,7 +244,7 @@ func (o *NatGatewayRuleProperties) HasPublicIp() bool {
}
// GetTargetSubnet returns the TargetSubnet field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *NatGatewayRuleProperties) GetTargetSubnet() *string {
if o == nil {
return nil
@@ -281,38 +281,38 @@ func (o *NatGatewayRuleProperties) HasTargetSubnet() bool {
return false
}
-// GetTargetPortRange returns the TargetPortRange field value
-// If the value is explicit nil, the zero value for TargetPortRange will be returned
-func (o *NatGatewayRuleProperties) GetTargetPortRange() *TargetPortRange {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRuleProperties) GetType() *NatGatewayRuleType {
if o == nil {
return nil
}
- return o.TargetPortRange
+ return o.Type
}
-// GetTargetPortRangeOk returns a tuple with the TargetPortRange field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRuleProperties) GetTargetPortRangeOk() (*TargetPortRange, bool) {
+func (o *NatGatewayRuleProperties) GetTypeOk() (*NatGatewayRuleType, bool) {
if o == nil {
return nil, false
}
- return o.TargetPortRange, true
+ return o.Type, true
}
-// SetTargetPortRange sets field value
-func (o *NatGatewayRuleProperties) SetTargetPortRange(v TargetPortRange) {
+// SetType sets field value
+func (o *NatGatewayRuleProperties) SetType(v NatGatewayRuleType) {
- o.TargetPortRange = &v
+ o.Type = &v
}
-// HasTargetPortRange returns a boolean if a field has been set.
-func (o *NatGatewayRuleProperties) HasTargetPortRange() bool {
- if o != nil && o.TargetPortRange != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NatGatewayRuleProperties) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -324,24 +324,31 @@ func (o NatGatewayRuleProperties) MarshalJSON() ([]byte, error) {
if o.Name != nil {
toSerialize["name"] = o.Name
}
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
+
if o.Protocol != nil {
toSerialize["protocol"] = o.Protocol
}
+
+ if o.PublicIp != nil {
+ toSerialize["publicIp"] = o.PublicIp
+ }
+
if o.SourceSubnet != nil {
toSerialize["sourceSubnet"] = o.SourceSubnet
}
- if o.PublicIp != nil {
- toSerialize["publicIp"] = o.PublicIp
+
+ if o.TargetPortRange != nil {
+ toSerialize["targetPortRange"] = o.TargetPortRange
}
+
if o.TargetSubnet != nil {
toSerialize["targetSubnet"] = o.TargetSubnet
}
- if o.TargetPortRange != nil {
- toSerialize["targetPortRange"] = o.TargetPortRange
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rule_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rule_put.go
index 2f709351b0f..e0f92b4099e 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rule_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rule_put.go
@@ -16,13 +16,13 @@ import (
// NatGatewayRulePut struct for NatGatewayRulePut
type NatGatewayRulePut struct {
+ // URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
- Id *string `json:"id,omitempty"`
+ Id *string `json:"id,omitempty"`
+ Properties *NatGatewayRuleProperties `json:"properties"`
// The type of object that has been created.
Type *Type `json:"type,omitempty"`
- // URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
- Properties *NatGatewayRuleProperties `json:"properties"`
}
// NewNatGatewayRulePut instantiates a new NatGatewayRulePut object
@@ -45,152 +45,152 @@ func NewNatGatewayRulePutWithDefaults() *NatGatewayRulePut {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGatewayRulePut) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRulePut) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRulePut) GetIdOk() (*string, bool) {
+func (o *NatGatewayRulePut) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *NatGatewayRulePut) SetId(v string) {
+// SetHref sets field value
+func (o *NatGatewayRulePut) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NatGatewayRulePut) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NatGatewayRulePut) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NatGatewayRulePut) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRulePut) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRulePut) GetTypeOk() (*Type, bool) {
+func (o *NatGatewayRulePut) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *NatGatewayRulePut) SetType(v Type) {
+// SetId sets field value
+func (o *NatGatewayRulePut) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NatGatewayRulePut) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NatGatewayRulePut) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGatewayRulePut) GetHref() *string {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRulePut) GetProperties() *NatGatewayRuleProperties {
if o == nil {
return nil
}
- return o.Href
+ return o.Properties
}
-// GetHrefOk returns a tuple with the Href field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRulePut) GetHrefOk() (*string, bool) {
+func (o *NatGatewayRulePut) GetPropertiesOk() (*NatGatewayRuleProperties, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Properties, true
}
-// SetHref sets field value
-func (o *NatGatewayRulePut) SetHref(v string) {
+// SetProperties sets field value
+func (o *NatGatewayRulePut) SetProperties(v NatGatewayRuleProperties) {
- o.Href = &v
+ o.Properties = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NatGatewayRulePut) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *NatGatewayRulePut) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for NatGatewayRuleProperties will be returned
-func (o *NatGatewayRulePut) GetProperties() *NatGatewayRuleProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRulePut) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRulePut) GetPropertiesOk() (*NatGatewayRuleProperties, bool) {
+func (o *NatGatewayRulePut) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *NatGatewayRulePut) SetProperties(v NatGatewayRuleProperties) {
+// SetType sets field value
+func (o *NatGatewayRulePut) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *NatGatewayRulePut) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NatGatewayRulePut) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -199,18 +199,22 @@ func (o *NatGatewayRulePut) HasProperties() bool {
func (o NatGatewayRulePut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rules.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rules.go
index 780bef1f9d8..9d3d4135331 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rules.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateway_rules.go
@@ -16,14 +16,14 @@ import (
// NatGatewayRules struct for NatGatewayRules
type NatGatewayRules struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]NatGatewayRule `json:"items,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewNatGatewayRules instantiates a new NatGatewayRules object
@@ -44,152 +44,152 @@ func NewNatGatewayRulesWithDefaults() *NatGatewayRules {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGatewayRules) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRules) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRules) GetIdOk() (*string, bool) {
+func (o *NatGatewayRules) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *NatGatewayRules) SetId(v string) {
+// SetHref sets field value
+func (o *NatGatewayRules) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NatGatewayRules) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NatGatewayRules) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NatGatewayRules) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRules) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRules) GetTypeOk() (*Type, bool) {
+func (o *NatGatewayRules) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *NatGatewayRules) SetType(v Type) {
+// SetId sets field value
+func (o *NatGatewayRules) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NatGatewayRules) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NatGatewayRules) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGatewayRules) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRules) GetItems() *[]NatGatewayRule {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRules) GetHrefOk() (*string, bool) {
+func (o *NatGatewayRules) GetItemsOk() (*[]NatGatewayRule, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *NatGatewayRules) SetHref(v string) {
+// SetItems sets field value
+func (o *NatGatewayRules) SetItems(v []NatGatewayRule) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NatGatewayRules) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *NatGatewayRules) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []NatGatewayRule will be returned
-func (o *NatGatewayRules) GetItems() *[]NatGatewayRule {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NatGatewayRules) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGatewayRules) GetItemsOk() (*[]NatGatewayRule, bool) {
+func (o *NatGatewayRules) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *NatGatewayRules) SetItems(v []NatGatewayRule) {
+// SetType sets field value
+func (o *NatGatewayRules) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *NatGatewayRules) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NatGatewayRules) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *NatGatewayRules) HasItems() bool {
func (o NatGatewayRules) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateways.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateways.go
index ea80671fe87..2139508ccc1 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateways.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nat_gateways.go
@@ -16,19 +16,19 @@ import (
// NatGateways struct for NatGateways
type NatGateways struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]NatGateway `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewNatGateways instantiates a new NatGateways object
@@ -49,114 +49,114 @@ func NewNatGatewaysWithDefaults() *NatGateways {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGateways) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *NatGateways) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGateways) GetIdOk() (*string, bool) {
+func (o *NatGateways) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *NatGateways) SetId(v string) {
+// SetLinks sets field value
+func (o *NatGateways) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NatGateways) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *NatGateways) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NatGateways) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NatGateways) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGateways) GetTypeOk() (*Type, bool) {
+func (o *NatGateways) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *NatGateways) SetType(v Type) {
+// SetHref sets field value
+func (o *NatGateways) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NatGateways) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NatGateways) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NatGateways) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NatGateways) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGateways) GetHrefOk() (*string, bool) {
+func (o *NatGateways) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *NatGateways) SetHref(v string) {
+// SetId sets field value
+func (o *NatGateways) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NatGateways) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NatGateways) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *NatGateways) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []NatGateway will be returned
+// If the value is explicit nil, nil is returned
func (o *NatGateways) GetItems() *[]NatGateway {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *NatGateways) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *NatGateways) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *NatGateways) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGateways) GetOffsetOk() (*float32, bool) {
+func (o *NatGateways) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *NatGateways) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *NatGateways) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *NatGateways) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *NatGateways) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *NatGateways) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *NatGateways) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGateways) GetLimitOk() (*float32, bool) {
+func (o *NatGateways) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *NatGateways) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *NatGateways) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *NatGateways) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *NatGateways) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *NatGateways) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NatGateways) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NatGateways) GetLinksOk() (*PaginationLinks, bool) {
+func (o *NatGateways) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *NatGateways) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *NatGateways) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *NatGateways) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NatGateways) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *NatGateways) HasLinks() bool {
func (o NatGateways) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer.go
index 265e075faa2..efaed067d8e 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer.go
@@ -16,15 +16,15 @@ import (
// NetworkLoadBalancer struct for NetworkLoadBalancer
type NetworkLoadBalancer struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Entities *NetworkLoadBalancerEntities `json:"entities,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *NetworkLoadBalancerProperties `json:"properties"`
- Entities *NetworkLoadBalancerEntities `json:"entities,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewNetworkLoadBalancer instantiates a new NetworkLoadBalancer object
@@ -47,114 +47,114 @@ func NewNetworkLoadBalancerWithDefaults() *NetworkLoadBalancer {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancer) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancer) GetEntities() *NetworkLoadBalancerEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancer) GetIdOk() (*string, bool) {
+func (o *NetworkLoadBalancer) GetEntitiesOk() (*NetworkLoadBalancerEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *NetworkLoadBalancer) SetId(v string) {
+// SetEntities sets field value
+func (o *NetworkLoadBalancer) SetEntities(v NetworkLoadBalancerEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NetworkLoadBalancer) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *NetworkLoadBalancer) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NetworkLoadBalancer) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancer) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancer) GetTypeOk() (*Type, bool) {
+func (o *NetworkLoadBalancer) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *NetworkLoadBalancer) SetType(v Type) {
+// SetHref sets field value
+func (o *NetworkLoadBalancer) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NetworkLoadBalancer) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NetworkLoadBalancer) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancer) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancer) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancer) GetHrefOk() (*string, bool) {
+func (o *NetworkLoadBalancer) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *NetworkLoadBalancer) SetHref(v string) {
+// SetId sets field value
+func (o *NetworkLoadBalancer) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NetworkLoadBalancer) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NetworkLoadBalancer) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -162,7 +162,7 @@ func (o *NetworkLoadBalancer) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancer) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
@@ -200,7 +200,7 @@ func (o *NetworkLoadBalancer) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for NetworkLoadBalancerProperties will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancer) GetProperties() *NetworkLoadBalancerProperties {
if o == nil {
return nil
@@ -237,38 +237,38 @@ func (o *NetworkLoadBalancer) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for NetworkLoadBalancerEntities will be returned
-func (o *NetworkLoadBalancer) GetEntities() *NetworkLoadBalancerEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancer) GetType() *Type {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancer) GetEntitiesOk() (*NetworkLoadBalancerEntities, bool) {
+func (o *NetworkLoadBalancer) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *NetworkLoadBalancer) SetEntities(v NetworkLoadBalancerEntities) {
+// SetType sets field value
+func (o *NetworkLoadBalancer) SetType(v Type) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *NetworkLoadBalancer) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NetworkLoadBalancer) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -277,24 +277,30 @@ func (o *NetworkLoadBalancer) HasEntities() bool {
func (o NetworkLoadBalancer) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_entities.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_entities.go
index 85dd3bbd6be..cdd74071c33 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_entities.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_entities.go
@@ -39,7 +39,7 @@ func NewNetworkLoadBalancerEntitiesWithDefaults() *NetworkLoadBalancerEntities {
}
// GetFlowlogs returns the Flowlogs field value
-// If the value is explicit nil, the zero value for FlowLogs will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerEntities) GetFlowlogs() *FlowLogs {
if o == nil {
return nil
@@ -77,7 +77,7 @@ func (o *NetworkLoadBalancerEntities) HasFlowlogs() bool {
}
// GetForwardingrules returns the Forwardingrules field value
-// If the value is explicit nil, the zero value for NetworkLoadBalancerForwardingRules will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerEntities) GetForwardingrules() *NetworkLoadBalancerForwardingRules {
if o == nil {
return nil
@@ -119,9 +119,11 @@ func (o NetworkLoadBalancerEntities) MarshalJSON() ([]byte, error) {
if o.Flowlogs != nil {
toSerialize["flowlogs"] = o.Flowlogs
}
+
if o.Forwardingrules != nil {
toSerialize["forwardingrules"] = o.Forwardingrules
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule.go
index 8f054c8855a..d5018315f1a 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule.go
@@ -16,14 +16,14 @@ import (
// NetworkLoadBalancerForwardingRule struct for NetworkLoadBalancerForwardingRule
type NetworkLoadBalancerForwardingRule struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *NetworkLoadBalancerForwardingRuleProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewNetworkLoadBalancerForwardingRule instantiates a new NetworkLoadBalancerForwardingRule object
@@ -46,190 +46,190 @@ func NewNetworkLoadBalancerForwardingRuleWithDefaults() *NetworkLoadBalancerForw
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancerForwardingRule) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRule) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRule) GetIdOk() (*string, bool) {
+func (o *NetworkLoadBalancerForwardingRule) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *NetworkLoadBalancerForwardingRule) SetId(v string) {
+// SetHref sets field value
+func (o *NetworkLoadBalancerForwardingRule) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRule) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRule) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NetworkLoadBalancerForwardingRule) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRule) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRule) GetTypeOk() (*Type, bool) {
+func (o *NetworkLoadBalancerForwardingRule) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *NetworkLoadBalancerForwardingRule) SetType(v Type) {
+// SetId sets field value
+func (o *NetworkLoadBalancerForwardingRule) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRule) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRule) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancerForwardingRule) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRule) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRule) GetHrefOk() (*string, bool) {
+func (o *NetworkLoadBalancerForwardingRule) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *NetworkLoadBalancerForwardingRule) SetHref(v string) {
+// SetMetadata sets field value
+func (o *NetworkLoadBalancerForwardingRule) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRule) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRule) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *NetworkLoadBalancerForwardingRule) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRule) GetProperties() *NetworkLoadBalancerForwardingRuleProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRule) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *NetworkLoadBalancerForwardingRule) GetPropertiesOk() (*NetworkLoadBalancerForwardingRuleProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *NetworkLoadBalancerForwardingRule) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *NetworkLoadBalancerForwardingRule) SetProperties(v NetworkLoadBalancerForwardingRuleProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRule) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRule) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for NetworkLoadBalancerForwardingRuleProperties will be returned
-func (o *NetworkLoadBalancerForwardingRule) GetProperties() *NetworkLoadBalancerForwardingRuleProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRule) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRule) GetPropertiesOk() (*NetworkLoadBalancerForwardingRuleProperties, bool) {
+func (o *NetworkLoadBalancerForwardingRule) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *NetworkLoadBalancerForwardingRule) SetProperties(v NetworkLoadBalancerForwardingRuleProperties) {
+// SetType sets field value
+func (o *NetworkLoadBalancerForwardingRule) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRule) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRule) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *NetworkLoadBalancerForwardingRule) HasProperties() bool {
func (o NetworkLoadBalancerForwardingRule) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_health_check.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_health_check.go
index 3fa9df4f4b4..cd16a13efc7 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_health_check.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_health_check.go
@@ -20,10 +20,10 @@ type NetworkLoadBalancerForwardingRuleHealthCheck struct {
ClientTimeout *int32 `json:"clientTimeout,omitempty"`
// The maximum time in milliseconds to wait for a connection attempt to a target to succeed; default is 5000 (five seconds).
ConnectTimeout *int32 `json:"connectTimeout,omitempty"`
- // The maximum time in milliseconds that a target can remain inactive; default is 50,000 (50 seconds).
- TargetTimeout *int32 `json:"targetTimeout,omitempty"`
// The maximum number of attempts to reconnect to a target after a connection failure. Valid range is 0 to 65535 and default is three reconnection attempts.
Retries *int32 `json:"retries,omitempty"`
+ // The maximum time in milliseconds that a target can remain inactive; default is 50,000 (50 seconds).
+ TargetTimeout *int32 `json:"targetTimeout,omitempty"`
}
// NewNetworkLoadBalancerForwardingRuleHealthCheck instantiates a new NetworkLoadBalancerForwardingRuleHealthCheck object
@@ -45,7 +45,7 @@ func NewNetworkLoadBalancerForwardingRuleHealthCheckWithDefaults() *NetworkLoadB
}
// GetClientTimeout returns the ClientTimeout field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRuleHealthCheck) GetClientTimeout() *int32 {
if o == nil {
return nil
@@ -83,7 +83,7 @@ func (o *NetworkLoadBalancerForwardingRuleHealthCheck) HasClientTimeout() bool {
}
// GetConnectTimeout returns the ConnectTimeout field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRuleHealthCheck) GetConnectTimeout() *int32 {
if o == nil {
return nil
@@ -120,76 +120,76 @@ func (o *NetworkLoadBalancerForwardingRuleHealthCheck) HasConnectTimeout() bool
return false
}
-// GetTargetTimeout returns the TargetTimeout field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *NetworkLoadBalancerForwardingRuleHealthCheck) GetTargetTimeout() *int32 {
+// GetRetries returns the Retries field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRuleHealthCheck) GetRetries() *int32 {
if o == nil {
return nil
}
- return o.TargetTimeout
+ return o.Retries
}
-// GetTargetTimeoutOk returns a tuple with the TargetTimeout field value
+// GetRetriesOk returns a tuple with the Retries field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRuleHealthCheck) GetTargetTimeoutOk() (*int32, bool) {
+func (o *NetworkLoadBalancerForwardingRuleHealthCheck) GetRetriesOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.TargetTimeout, true
+ return o.Retries, true
}
-// SetTargetTimeout sets field value
-func (o *NetworkLoadBalancerForwardingRuleHealthCheck) SetTargetTimeout(v int32) {
+// SetRetries sets field value
+func (o *NetworkLoadBalancerForwardingRuleHealthCheck) SetRetries(v int32) {
- o.TargetTimeout = &v
+ o.Retries = &v
}
-// HasTargetTimeout returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRuleHealthCheck) HasTargetTimeout() bool {
- if o != nil && o.TargetTimeout != nil {
+// HasRetries returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRuleHealthCheck) HasRetries() bool {
+ if o != nil && o.Retries != nil {
return true
}
return false
}
-// GetRetries returns the Retries field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *NetworkLoadBalancerForwardingRuleHealthCheck) GetRetries() *int32 {
+// GetTargetTimeout returns the TargetTimeout field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRuleHealthCheck) GetTargetTimeout() *int32 {
if o == nil {
return nil
}
- return o.Retries
+ return o.TargetTimeout
}
-// GetRetriesOk returns a tuple with the Retries field value
+// GetTargetTimeoutOk returns a tuple with the TargetTimeout field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRuleHealthCheck) GetRetriesOk() (*int32, bool) {
+func (o *NetworkLoadBalancerForwardingRuleHealthCheck) GetTargetTimeoutOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Retries, true
+ return o.TargetTimeout, true
}
-// SetRetries sets field value
-func (o *NetworkLoadBalancerForwardingRuleHealthCheck) SetRetries(v int32) {
+// SetTargetTimeout sets field value
+func (o *NetworkLoadBalancerForwardingRuleHealthCheck) SetTargetTimeout(v int32) {
- o.Retries = &v
+ o.TargetTimeout = &v
}
-// HasRetries returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRuleHealthCheck) HasRetries() bool {
- if o != nil && o.Retries != nil {
+// HasTargetTimeout returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRuleHealthCheck) HasTargetTimeout() bool {
+ if o != nil && o.TargetTimeout != nil {
return true
}
@@ -201,15 +201,19 @@ func (o NetworkLoadBalancerForwardingRuleHealthCheck) MarshalJSON() ([]byte, err
if o.ClientTimeout != nil {
toSerialize["clientTimeout"] = o.ClientTimeout
}
+
if o.ConnectTimeout != nil {
toSerialize["connectTimeout"] = o.ConnectTimeout
}
- if o.TargetTimeout != nil {
- toSerialize["targetTimeout"] = o.TargetTimeout
- }
+
if o.Retries != nil {
toSerialize["retries"] = o.Retries
}
+
+ if o.TargetTimeout != nil {
+ toSerialize["targetTimeout"] = o.TargetTimeout
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_properties.go
index 35e45278725..c3131afa171 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_properties.go
@@ -16,17 +16,17 @@ import (
// NetworkLoadBalancerForwardingRuleProperties struct for NetworkLoadBalancerForwardingRuleProperties
type NetworkLoadBalancerForwardingRuleProperties struct {
- // The name of the Network Load Balancer forwarding rule.
- Name *string `json:"name"`
// Balancing algorithm
- Algorithm *string `json:"algorithm"`
- // Balancing protocol
- Protocol *string `json:"protocol"`
+ Algorithm *string `json:"algorithm"`
+ HealthCheck *NetworkLoadBalancerForwardingRuleHealthCheck `json:"healthCheck,omitempty"`
// Listening (inbound) IP.
ListenerIp *string `json:"listenerIp"`
// Listening (inbound) port number; valid range is 1 to 65535.
- ListenerPort *int32 `json:"listenerPort"`
- HealthCheck *NetworkLoadBalancerForwardingRuleHealthCheck `json:"healthCheck,omitempty"`
+ ListenerPort *int32 `json:"listenerPort"`
+ // The name of the Network Load Balancer forwarding rule.
+ Name *string `json:"name"`
+ // Balancing protocol
+ Protocol *string `json:"protocol"`
// Array of items in the collection.
Targets *[]NetworkLoadBalancerForwardingRuleTarget `json:"targets"`
}
@@ -35,14 +35,14 @@ type NetworkLoadBalancerForwardingRuleProperties struct {
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewNetworkLoadBalancerForwardingRuleProperties(name string, algorithm string, protocol string, listenerIp string, listenerPort int32, targets []NetworkLoadBalancerForwardingRuleTarget) *NetworkLoadBalancerForwardingRuleProperties {
+func NewNetworkLoadBalancerForwardingRuleProperties(algorithm string, listenerIp string, listenerPort int32, name string, protocol string, targets []NetworkLoadBalancerForwardingRuleTarget) *NetworkLoadBalancerForwardingRuleProperties {
this := NetworkLoadBalancerForwardingRuleProperties{}
- this.Name = &name
this.Algorithm = &algorithm
- this.Protocol = &protocol
this.ListenerIp = &listenerIp
this.ListenerPort = &listenerPort
+ this.Name = &name
+ this.Protocol = &protocol
this.Targets = &targets
return &this
@@ -56,46 +56,8 @@ func NewNetworkLoadBalancerForwardingRulePropertiesWithDefaults() *NetworkLoadBa
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancerForwardingRuleProperties) GetName() *string {
- if o == nil {
- return nil
- }
-
- return o.Name
-
-}
-
-// GetNameOk returns a tuple with the Name field value
-// and a boolean to check if the value has been set.
-// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRuleProperties) GetNameOk() (*string, bool) {
- if o == nil {
- return nil, false
- }
-
- return o.Name, true
-}
-
-// SetName sets field value
-func (o *NetworkLoadBalancerForwardingRuleProperties) SetName(v string) {
-
- o.Name = &v
-
-}
-
-// HasName returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRuleProperties) HasName() bool {
- if o != nil && o.Name != nil {
- return true
- }
-
- return false
-}
-
// GetAlgorithm returns the Algorithm field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRuleProperties) GetAlgorithm() *string {
if o == nil {
return nil
@@ -132,38 +94,38 @@ func (o *NetworkLoadBalancerForwardingRuleProperties) HasAlgorithm() bool {
return false
}
-// GetProtocol returns the Protocol field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancerForwardingRuleProperties) GetProtocol() *string {
+// GetHealthCheck returns the HealthCheck field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRuleProperties) GetHealthCheck() *NetworkLoadBalancerForwardingRuleHealthCheck {
if o == nil {
return nil
}
- return o.Protocol
+ return o.HealthCheck
}
-// GetProtocolOk returns a tuple with the Protocol field value
+// GetHealthCheckOk returns a tuple with the HealthCheck field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRuleProperties) GetProtocolOk() (*string, bool) {
+func (o *NetworkLoadBalancerForwardingRuleProperties) GetHealthCheckOk() (*NetworkLoadBalancerForwardingRuleHealthCheck, bool) {
if o == nil {
return nil, false
}
- return o.Protocol, true
+ return o.HealthCheck, true
}
-// SetProtocol sets field value
-func (o *NetworkLoadBalancerForwardingRuleProperties) SetProtocol(v string) {
+// SetHealthCheck sets field value
+func (o *NetworkLoadBalancerForwardingRuleProperties) SetHealthCheck(v NetworkLoadBalancerForwardingRuleHealthCheck) {
- o.Protocol = &v
+ o.HealthCheck = &v
}
-// HasProtocol returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRuleProperties) HasProtocol() bool {
- if o != nil && o.Protocol != nil {
+// HasHealthCheck returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRuleProperties) HasHealthCheck() bool {
+ if o != nil && o.HealthCheck != nil {
return true
}
@@ -171,7 +133,7 @@ func (o *NetworkLoadBalancerForwardingRuleProperties) HasProtocol() bool {
}
// GetListenerIp returns the ListenerIp field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRuleProperties) GetListenerIp() *string {
if o == nil {
return nil
@@ -209,7 +171,7 @@ func (o *NetworkLoadBalancerForwardingRuleProperties) HasListenerIp() bool {
}
// GetListenerPort returns the ListenerPort field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRuleProperties) GetListenerPort() *int32 {
if o == nil {
return nil
@@ -246,38 +208,76 @@ func (o *NetworkLoadBalancerForwardingRuleProperties) HasListenerPort() bool {
return false
}
-// GetHealthCheck returns the HealthCheck field value
-// If the value is explicit nil, the zero value for NetworkLoadBalancerForwardingRuleHealthCheck will be returned
-func (o *NetworkLoadBalancerForwardingRuleProperties) GetHealthCheck() *NetworkLoadBalancerForwardingRuleHealthCheck {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRuleProperties) GetName() *string {
if o == nil {
return nil
}
- return o.HealthCheck
+ return o.Name
}
-// GetHealthCheckOk returns a tuple with the HealthCheck field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRuleProperties) GetHealthCheckOk() (*NetworkLoadBalancerForwardingRuleHealthCheck, bool) {
+func (o *NetworkLoadBalancerForwardingRuleProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.HealthCheck, true
+ return o.Name, true
}
-// SetHealthCheck sets field value
-func (o *NetworkLoadBalancerForwardingRuleProperties) SetHealthCheck(v NetworkLoadBalancerForwardingRuleHealthCheck) {
+// SetName sets field value
+func (o *NetworkLoadBalancerForwardingRuleProperties) SetName(v string) {
- o.HealthCheck = &v
+ o.Name = &v
}
-// HasHealthCheck returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRuleProperties) HasHealthCheck() bool {
- if o != nil && o.HealthCheck != nil {
+// HasName returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRuleProperties) HasName() bool {
+ if o != nil && o.Name != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetProtocol returns the Protocol field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRuleProperties) GetProtocol() *string {
+ if o == nil {
+ return nil
+ }
+
+ return o.Protocol
+
+}
+
+// GetProtocolOk returns a tuple with the Protocol field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *NetworkLoadBalancerForwardingRuleProperties) GetProtocolOk() (*string, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Protocol, true
+}
+
+// SetProtocol sets field value
+func (o *NetworkLoadBalancerForwardingRuleProperties) SetProtocol(v string) {
+
+ o.Protocol = &v
+
+}
+
+// HasProtocol returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRuleProperties) HasProtocol() bool {
+ if o != nil && o.Protocol != nil {
return true
}
@@ -285,7 +285,7 @@ func (o *NetworkLoadBalancerForwardingRuleProperties) HasHealthCheck() bool {
}
// GetTargets returns the Targets field value
-// If the value is explicit nil, the zero value for []NetworkLoadBalancerForwardingRuleTarget will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRuleProperties) GetTargets() *[]NetworkLoadBalancerForwardingRuleTarget {
if o == nil {
return nil
@@ -324,27 +324,34 @@ func (o *NetworkLoadBalancerForwardingRuleProperties) HasTargets() bool {
func (o NetworkLoadBalancerForwardingRuleProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
- }
if o.Algorithm != nil {
toSerialize["algorithm"] = o.Algorithm
}
- if o.Protocol != nil {
- toSerialize["protocol"] = o.Protocol
+
+ if o.HealthCheck != nil {
+ toSerialize["healthCheck"] = o.HealthCheck
}
+
if o.ListenerIp != nil {
toSerialize["listenerIp"] = o.ListenerIp
}
+
if o.ListenerPort != nil {
toSerialize["listenerPort"] = o.ListenerPort
}
- if o.HealthCheck != nil {
- toSerialize["healthCheck"] = o.HealthCheck
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
}
+
+ if o.Protocol != nil {
+ toSerialize["protocol"] = o.Protocol
+ }
+
if o.Targets != nil {
toSerialize["targets"] = o.Targets
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_put.go
index ee8f95aeae7..16c6e39bb7c 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_put.go
@@ -16,13 +16,13 @@ import (
// NetworkLoadBalancerForwardingRulePut struct for NetworkLoadBalancerForwardingRulePut
type NetworkLoadBalancerForwardingRulePut struct {
+ // URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
- Id *string `json:"id,omitempty"`
+ Id *string `json:"id,omitempty"`
+ Properties *NetworkLoadBalancerForwardingRuleProperties `json:"properties"`
// The type of object that has been created.
Type *Type `json:"type,omitempty"`
- // URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
- Properties *NetworkLoadBalancerForwardingRuleProperties `json:"properties"`
}
// NewNetworkLoadBalancerForwardingRulePut instantiates a new NetworkLoadBalancerForwardingRulePut object
@@ -45,152 +45,152 @@ func NewNetworkLoadBalancerForwardingRulePutWithDefaults() *NetworkLoadBalancerF
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancerForwardingRulePut) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRulePut) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRulePut) GetIdOk() (*string, bool) {
+func (o *NetworkLoadBalancerForwardingRulePut) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *NetworkLoadBalancerForwardingRulePut) SetId(v string) {
+// SetHref sets field value
+func (o *NetworkLoadBalancerForwardingRulePut) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRulePut) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRulePut) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NetworkLoadBalancerForwardingRulePut) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRulePut) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRulePut) GetTypeOk() (*Type, bool) {
+func (o *NetworkLoadBalancerForwardingRulePut) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *NetworkLoadBalancerForwardingRulePut) SetType(v Type) {
+// SetId sets field value
+func (o *NetworkLoadBalancerForwardingRulePut) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRulePut) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRulePut) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancerForwardingRulePut) GetHref() *string {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRulePut) GetProperties() *NetworkLoadBalancerForwardingRuleProperties {
if o == nil {
return nil
}
- return o.Href
+ return o.Properties
}
-// GetHrefOk returns a tuple with the Href field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRulePut) GetHrefOk() (*string, bool) {
+func (o *NetworkLoadBalancerForwardingRulePut) GetPropertiesOk() (*NetworkLoadBalancerForwardingRuleProperties, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Properties, true
}
-// SetHref sets field value
-func (o *NetworkLoadBalancerForwardingRulePut) SetHref(v string) {
+// SetProperties sets field value
+func (o *NetworkLoadBalancerForwardingRulePut) SetProperties(v NetworkLoadBalancerForwardingRuleProperties) {
- o.Href = &v
+ o.Properties = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRulePut) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRulePut) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for NetworkLoadBalancerForwardingRuleProperties will be returned
-func (o *NetworkLoadBalancerForwardingRulePut) GetProperties() *NetworkLoadBalancerForwardingRuleProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRulePut) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRulePut) GetPropertiesOk() (*NetworkLoadBalancerForwardingRuleProperties, bool) {
+func (o *NetworkLoadBalancerForwardingRulePut) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *NetworkLoadBalancerForwardingRulePut) SetProperties(v NetworkLoadBalancerForwardingRuleProperties) {
+// SetType sets field value
+func (o *NetworkLoadBalancerForwardingRulePut) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRulePut) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRulePut) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -199,18 +199,22 @@ func (o *NetworkLoadBalancerForwardingRulePut) HasProperties() bool {
func (o NetworkLoadBalancerForwardingRulePut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_target.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_target.go
index 502d5bda87b..b1a9e448270 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_target.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_target.go
@@ -16,13 +16,13 @@ import (
// NetworkLoadBalancerForwardingRuleTarget struct for NetworkLoadBalancerForwardingRuleTarget
type NetworkLoadBalancerForwardingRuleTarget struct {
+ HealthCheck *NetworkLoadBalancerForwardingRuleTargetHealthCheck `json:"healthCheck,omitempty"`
// The IP of the balanced target VM.
Ip *string `json:"ip"`
// The port of the balanced target service; valid range is 1 to 65535.
Port *int32 `json:"port"`
// Traffic is distributed in proportion to target weight, relative to the combined weight of all targets. A target with higher weight receives a greater share of traffic. Valid range is 0 to 256 and default is 1. Targets with weight of 0 do not participate in load balancing but still accept persistent connections. It is best to assign weights in the middle of the range to leave room for later adjustments.
- Weight *int32 `json:"weight"`
- HealthCheck *NetworkLoadBalancerForwardingRuleTargetHealthCheck `json:"healthCheck,omitempty"`
+ Weight *int32 `json:"weight"`
}
// NewNetworkLoadBalancerForwardingRuleTarget instantiates a new NetworkLoadBalancerForwardingRuleTarget object
@@ -47,8 +47,46 @@ func NewNetworkLoadBalancerForwardingRuleTargetWithDefaults() *NetworkLoadBalanc
return &this
}
+// GetHealthCheck returns the HealthCheck field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRuleTarget) GetHealthCheck() *NetworkLoadBalancerForwardingRuleTargetHealthCheck {
+ if o == nil {
+ return nil
+ }
+
+ return o.HealthCheck
+
+}
+
+// GetHealthCheckOk returns a tuple with the HealthCheck field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *NetworkLoadBalancerForwardingRuleTarget) GetHealthCheckOk() (*NetworkLoadBalancerForwardingRuleTargetHealthCheck, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.HealthCheck, true
+}
+
+// SetHealthCheck sets field value
+func (o *NetworkLoadBalancerForwardingRuleTarget) SetHealthCheck(v NetworkLoadBalancerForwardingRuleTargetHealthCheck) {
+
+ o.HealthCheck = &v
+
+}
+
+// HasHealthCheck returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRuleTarget) HasHealthCheck() bool {
+ if o != nil && o.HealthCheck != nil {
+ return true
+ }
+
+ return false
+}
+
// GetIp returns the Ip field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRuleTarget) GetIp() *string {
if o == nil {
return nil
@@ -86,7 +124,7 @@ func (o *NetworkLoadBalancerForwardingRuleTarget) HasIp() bool {
}
// GetPort returns the Port field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRuleTarget) GetPort() *int32 {
if o == nil {
return nil
@@ -124,7 +162,7 @@ func (o *NetworkLoadBalancerForwardingRuleTarget) HasPort() bool {
}
// GetWeight returns the Weight field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRuleTarget) GetWeight() *int32 {
if o == nil {
return nil
@@ -161,58 +199,24 @@ func (o *NetworkLoadBalancerForwardingRuleTarget) HasWeight() bool {
return false
}
-// GetHealthCheck returns the HealthCheck field value
-// If the value is explicit nil, the zero value for NetworkLoadBalancerForwardingRuleTargetHealthCheck will be returned
-func (o *NetworkLoadBalancerForwardingRuleTarget) GetHealthCheck() *NetworkLoadBalancerForwardingRuleTargetHealthCheck {
- if o == nil {
- return nil
- }
-
- return o.HealthCheck
-
-}
-
-// GetHealthCheckOk returns a tuple with the HealthCheck field value
-// and a boolean to check if the value has been set.
-// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRuleTarget) GetHealthCheckOk() (*NetworkLoadBalancerForwardingRuleTargetHealthCheck, bool) {
- if o == nil {
- return nil, false
- }
-
- return o.HealthCheck, true
-}
-
-// SetHealthCheck sets field value
-func (o *NetworkLoadBalancerForwardingRuleTarget) SetHealthCheck(v NetworkLoadBalancerForwardingRuleTargetHealthCheck) {
-
- o.HealthCheck = &v
-
-}
-
-// HasHealthCheck returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRuleTarget) HasHealthCheck() bool {
- if o != nil && o.HealthCheck != nil {
- return true
- }
-
- return false
-}
-
func (o NetworkLoadBalancerForwardingRuleTarget) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
+ if o.HealthCheck != nil {
+ toSerialize["healthCheck"] = o.HealthCheck
+ }
+
if o.Ip != nil {
toSerialize["ip"] = o.Ip
}
+
if o.Port != nil {
toSerialize["port"] = o.Port
}
+
if o.Weight != nil {
toSerialize["weight"] = o.Weight
}
- if o.HealthCheck != nil {
- toSerialize["healthCheck"] = o.HealthCheck
- }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_target_health_check.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_target_health_check.go
index 8fac2b6dbd0..8d7e994a32c 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_target_health_check.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rule_target_health_check.go
@@ -43,7 +43,7 @@ func NewNetworkLoadBalancerForwardingRuleTargetHealthCheckWithDefaults() *Networ
}
// GetCheck returns the Check field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRuleTargetHealthCheck) GetCheck() *bool {
if o == nil {
return nil
@@ -81,7 +81,7 @@ func (o *NetworkLoadBalancerForwardingRuleTargetHealthCheck) HasCheck() bool {
}
// GetCheckInterval returns the CheckInterval field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRuleTargetHealthCheck) GetCheckInterval() *int32 {
if o == nil {
return nil
@@ -119,7 +119,7 @@ func (o *NetworkLoadBalancerForwardingRuleTargetHealthCheck) HasCheckInterval()
}
// GetMaintenance returns the Maintenance field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRuleTargetHealthCheck) GetMaintenance() *bool {
if o == nil {
return nil
@@ -161,12 +161,15 @@ func (o NetworkLoadBalancerForwardingRuleTargetHealthCheck) MarshalJSON() ([]byt
if o.Check != nil {
toSerialize["check"] = o.Check
}
+
if o.CheckInterval != nil {
toSerialize["checkInterval"] = o.CheckInterval
}
+
if o.Maintenance != nil {
toSerialize["maintenance"] = o.Maintenance
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rules.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rules.go
index a23c7740825..2668d63287e 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rules.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_forwarding_rules.go
@@ -16,19 +16,19 @@ import (
// NetworkLoadBalancerForwardingRules struct for NetworkLoadBalancerForwardingRules
type NetworkLoadBalancerForwardingRules struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]NetworkLoadBalancerForwardingRule `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewNetworkLoadBalancerForwardingRules instantiates a new NetworkLoadBalancerForwardingRules object
@@ -49,114 +49,114 @@ func NewNetworkLoadBalancerForwardingRulesWithDefaults() *NetworkLoadBalancerFor
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancerForwardingRules) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRules) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRules) GetIdOk() (*string, bool) {
+func (o *NetworkLoadBalancerForwardingRules) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *NetworkLoadBalancerForwardingRules) SetId(v string) {
+// SetLinks sets field value
+func (o *NetworkLoadBalancerForwardingRules) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRules) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRules) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NetworkLoadBalancerForwardingRules) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRules) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRules) GetTypeOk() (*Type, bool) {
+func (o *NetworkLoadBalancerForwardingRules) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *NetworkLoadBalancerForwardingRules) SetType(v Type) {
+// SetHref sets field value
+func (o *NetworkLoadBalancerForwardingRules) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRules) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRules) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancerForwardingRules) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRules) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRules) GetHrefOk() (*string, bool) {
+func (o *NetworkLoadBalancerForwardingRules) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *NetworkLoadBalancerForwardingRules) SetHref(v string) {
+// SetId sets field value
+func (o *NetworkLoadBalancerForwardingRules) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRules) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRules) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *NetworkLoadBalancerForwardingRules) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []NetworkLoadBalancerForwardingRule will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerForwardingRules) GetItems() *[]NetworkLoadBalancerForwardingRule {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *NetworkLoadBalancerForwardingRules) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *NetworkLoadBalancerForwardingRules) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRules) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRules) GetOffsetOk() (*float32, bool) {
+func (o *NetworkLoadBalancerForwardingRules) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *NetworkLoadBalancerForwardingRules) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *NetworkLoadBalancerForwardingRules) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRules) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRules) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *NetworkLoadBalancerForwardingRules) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRules) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRules) GetLimitOk() (*float32, bool) {
+func (o *NetworkLoadBalancerForwardingRules) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *NetworkLoadBalancerForwardingRules) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *NetworkLoadBalancerForwardingRules) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRules) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRules) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *NetworkLoadBalancerForwardingRules) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerForwardingRules) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerForwardingRules) GetLinksOk() (*PaginationLinks, bool) {
+func (o *NetworkLoadBalancerForwardingRules) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *NetworkLoadBalancerForwardingRules) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *NetworkLoadBalancerForwardingRules) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerForwardingRules) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerForwardingRules) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *NetworkLoadBalancerForwardingRules) HasLinks() bool {
func (o NetworkLoadBalancerForwardingRules) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_properties.go
index 94170d456e0..114b8b08a15 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_properties.go
@@ -16,27 +16,27 @@ import (
// NetworkLoadBalancerProperties struct for NetworkLoadBalancerProperties
type NetworkLoadBalancerProperties struct {
- // The name of the Network Load Balancer.
- Name *string `json:"name"`
- // ID of the listening LAN (inbound).
- ListenerLan *int32 `json:"listenerLan"`
// Collection of the Network Load Balancer IP addresses. (Inbound and outbound) IPs of the listenerLan must be customer-reserved IPs for public Load Balancers, and private IPs for private Load Balancers.
Ips *[]string `json:"ips,omitempty"`
- // ID of the balanced private target LAN (outbound).
- TargetLan *int32 `json:"targetLan"`
// Collection of private IP addresses with subnet mask of the Network Load Balancer. IPs must contain a valid subnet mask. If no IP is provided, the system will generate an IP with /24 subnet.
LbPrivateIps *[]string `json:"lbPrivateIps,omitempty"`
+ // ID of the listening LAN (inbound).
+ ListenerLan *int32 `json:"listenerLan"`
+ // The name of the Network Load Balancer.
+ Name *string `json:"name"`
+ // ID of the balanced private target LAN (outbound).
+ TargetLan *int32 `json:"targetLan"`
}
// NewNetworkLoadBalancerProperties instantiates a new NetworkLoadBalancerProperties object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewNetworkLoadBalancerProperties(name string, listenerLan int32, targetLan int32) *NetworkLoadBalancerProperties {
+func NewNetworkLoadBalancerProperties(listenerLan int32, name string, targetLan int32) *NetworkLoadBalancerProperties {
this := NetworkLoadBalancerProperties{}
- this.Name = &name
this.ListenerLan = &listenerLan
+ this.Name = &name
this.TargetLan = &targetLan
return &this
@@ -50,38 +50,76 @@ func NewNetworkLoadBalancerPropertiesWithDefaults() *NetworkLoadBalancerProperti
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancerProperties) GetName() *string {
+// GetIps returns the Ips field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerProperties) GetIps() *[]string {
if o == nil {
return nil
}
- return o.Name
+ return o.Ips
}
-// GetNameOk returns a tuple with the Name field value
+// GetIpsOk returns a tuple with the Ips field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerProperties) GetNameOk() (*string, bool) {
+func (o *NetworkLoadBalancerProperties) GetIpsOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.Ips, true
}
-// SetName sets field value
-func (o *NetworkLoadBalancerProperties) SetName(v string) {
+// SetIps sets field value
+func (o *NetworkLoadBalancerProperties) SetIps(v []string) {
- o.Name = &v
+ o.Ips = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasIps returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerProperties) HasIps() bool {
+ if o != nil && o.Ips != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetLbPrivateIps returns the LbPrivateIps field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerProperties) GetLbPrivateIps() *[]string {
+ if o == nil {
+ return nil
+ }
+
+ return o.LbPrivateIps
+
+}
+
+// GetLbPrivateIpsOk returns a tuple with the LbPrivateIps field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *NetworkLoadBalancerProperties) GetLbPrivateIpsOk() (*[]string, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.LbPrivateIps, true
+}
+
+// SetLbPrivateIps sets field value
+func (o *NetworkLoadBalancerProperties) SetLbPrivateIps(v []string) {
+
+ o.LbPrivateIps = &v
+
+}
+
+// HasLbPrivateIps returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerProperties) HasLbPrivateIps() bool {
+ if o != nil && o.LbPrivateIps != nil {
return true
}
@@ -89,7 +127,7 @@ func (o *NetworkLoadBalancerProperties) HasName() bool {
}
// GetListenerLan returns the ListenerLan field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerProperties) GetListenerLan() *int32 {
if o == nil {
return nil
@@ -126,38 +164,38 @@ func (o *NetworkLoadBalancerProperties) HasListenerLan() bool {
return false
}
-// GetIps returns the Ips field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *NetworkLoadBalancerProperties) GetIps() *[]string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerProperties) GetName() *string {
if o == nil {
return nil
}
- return o.Ips
+ return o.Name
}
-// GetIpsOk returns a tuple with the Ips field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerProperties) GetIpsOk() (*[]string, bool) {
+func (o *NetworkLoadBalancerProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Ips, true
+ return o.Name, true
}
-// SetIps sets field value
-func (o *NetworkLoadBalancerProperties) SetIps(v []string) {
+// SetName sets field value
+func (o *NetworkLoadBalancerProperties) SetName(v string) {
- o.Ips = &v
+ o.Name = &v
}
-// HasIps returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerProperties) HasIps() bool {
- if o != nil && o.Ips != nil {
+// HasName returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -165,7 +203,7 @@ func (o *NetworkLoadBalancerProperties) HasIps() bool {
}
// GetTargetLan returns the TargetLan field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancerProperties) GetTargetLan() *int32 {
if o == nil {
return nil
@@ -202,61 +240,28 @@ func (o *NetworkLoadBalancerProperties) HasTargetLan() bool {
return false
}
-// GetLbPrivateIps returns the LbPrivateIps field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *NetworkLoadBalancerProperties) GetLbPrivateIps() *[]string {
- if o == nil {
- return nil
+func (o NetworkLoadBalancerProperties) MarshalJSON() ([]byte, error) {
+ toSerialize := map[string]interface{}{}
+ if o.Ips != nil {
+ toSerialize["ips"] = o.Ips
}
- return o.LbPrivateIps
-
-}
-
-// GetLbPrivateIpsOk returns a tuple with the LbPrivateIps field value
-// and a boolean to check if the value has been set.
-// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerProperties) GetLbPrivateIpsOk() (*[]string, bool) {
- if o == nil {
- return nil, false
+ if o.LbPrivateIps != nil {
+ toSerialize["lbPrivateIps"] = o.LbPrivateIps
}
- return o.LbPrivateIps, true
-}
-
-// SetLbPrivateIps sets field value
-func (o *NetworkLoadBalancerProperties) SetLbPrivateIps(v []string) {
-
- o.LbPrivateIps = &v
-
-}
-
-// HasLbPrivateIps returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerProperties) HasLbPrivateIps() bool {
- if o != nil && o.LbPrivateIps != nil {
- return true
+ if o.ListenerLan != nil {
+ toSerialize["listenerLan"] = o.ListenerLan
}
- return false
-}
-
-func (o NetworkLoadBalancerProperties) MarshalJSON() ([]byte, error) {
- toSerialize := map[string]interface{}{}
if o.Name != nil {
toSerialize["name"] = o.Name
}
- if o.ListenerLan != nil {
- toSerialize["listenerLan"] = o.ListenerLan
- }
- if o.Ips != nil {
- toSerialize["ips"] = o.Ips
- }
+
if o.TargetLan != nil {
toSerialize["targetLan"] = o.TargetLan
}
- if o.LbPrivateIps != nil {
- toSerialize["lbPrivateIps"] = o.LbPrivateIps
- }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_put.go
index 05bde508cbb..ec4deb54b3a 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancer_put.go
@@ -16,13 +16,13 @@ import (
// NetworkLoadBalancerPut struct for NetworkLoadBalancerPut
type NetworkLoadBalancerPut struct {
+ // URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
- Id *string `json:"id,omitempty"`
+ Id *string `json:"id,omitempty"`
+ Properties *NetworkLoadBalancerProperties `json:"properties"`
// The type of object that has been created.
Type *Type `json:"type,omitempty"`
- // URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
- Properties *NetworkLoadBalancerProperties `json:"properties"`
}
// NewNetworkLoadBalancerPut instantiates a new NetworkLoadBalancerPut object
@@ -45,152 +45,152 @@ func NewNetworkLoadBalancerPutWithDefaults() *NetworkLoadBalancerPut {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancerPut) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerPut) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerPut) GetIdOk() (*string, bool) {
+func (o *NetworkLoadBalancerPut) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *NetworkLoadBalancerPut) SetId(v string) {
+// SetHref sets field value
+func (o *NetworkLoadBalancerPut) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerPut) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerPut) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NetworkLoadBalancerPut) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerPut) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerPut) GetTypeOk() (*Type, bool) {
+func (o *NetworkLoadBalancerPut) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *NetworkLoadBalancerPut) SetType(v Type) {
+// SetId sets field value
+func (o *NetworkLoadBalancerPut) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerPut) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerPut) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancerPut) GetHref() *string {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerPut) GetProperties() *NetworkLoadBalancerProperties {
if o == nil {
return nil
}
- return o.Href
+ return o.Properties
}
-// GetHrefOk returns a tuple with the Href field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerPut) GetHrefOk() (*string, bool) {
+func (o *NetworkLoadBalancerPut) GetPropertiesOk() (*NetworkLoadBalancerProperties, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Properties, true
}
-// SetHref sets field value
-func (o *NetworkLoadBalancerPut) SetHref(v string) {
+// SetProperties sets field value
+func (o *NetworkLoadBalancerPut) SetProperties(v NetworkLoadBalancerProperties) {
- o.Href = &v
+ o.Properties = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerPut) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerPut) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for NetworkLoadBalancerProperties will be returned
-func (o *NetworkLoadBalancerPut) GetProperties() *NetworkLoadBalancerProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancerPut) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancerPut) GetPropertiesOk() (*NetworkLoadBalancerProperties, bool) {
+func (o *NetworkLoadBalancerPut) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *NetworkLoadBalancerPut) SetProperties(v NetworkLoadBalancerProperties) {
+// SetType sets field value
+func (o *NetworkLoadBalancerPut) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *NetworkLoadBalancerPut) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NetworkLoadBalancerPut) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -199,18 +199,22 @@ func (o *NetworkLoadBalancerPut) HasProperties() bool {
func (o NetworkLoadBalancerPut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancers.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancers.go
index 91bbe63e1fb..b4ccbbc8734 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancers.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_network_load_balancers.go
@@ -16,19 +16,19 @@ import (
// NetworkLoadBalancers struct for NetworkLoadBalancers
type NetworkLoadBalancers struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]NetworkLoadBalancer `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewNetworkLoadBalancers instantiates a new NetworkLoadBalancers object
@@ -49,114 +49,114 @@ func NewNetworkLoadBalancersWithDefaults() *NetworkLoadBalancers {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancers) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancers) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancers) GetIdOk() (*string, bool) {
+func (o *NetworkLoadBalancers) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *NetworkLoadBalancers) SetId(v string) {
+// SetLinks sets field value
+func (o *NetworkLoadBalancers) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NetworkLoadBalancers) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *NetworkLoadBalancers) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NetworkLoadBalancers) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancers) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancers) GetTypeOk() (*Type, bool) {
+func (o *NetworkLoadBalancers) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *NetworkLoadBalancers) SetType(v Type) {
+// SetHref sets field value
+func (o *NetworkLoadBalancers) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NetworkLoadBalancers) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NetworkLoadBalancers) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NetworkLoadBalancers) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancers) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancers) GetHrefOk() (*string, bool) {
+func (o *NetworkLoadBalancers) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *NetworkLoadBalancers) SetHref(v string) {
+// SetId sets field value
+func (o *NetworkLoadBalancers) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NetworkLoadBalancers) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NetworkLoadBalancers) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *NetworkLoadBalancers) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []NetworkLoadBalancer will be returned
+// If the value is explicit nil, nil is returned
func (o *NetworkLoadBalancers) GetItems() *[]NetworkLoadBalancer {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *NetworkLoadBalancers) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *NetworkLoadBalancers) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancers) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancers) GetOffsetOk() (*float32, bool) {
+func (o *NetworkLoadBalancers) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *NetworkLoadBalancers) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *NetworkLoadBalancers) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *NetworkLoadBalancers) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *NetworkLoadBalancers) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *NetworkLoadBalancers) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancers) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancers) GetLimitOk() (*float32, bool) {
+func (o *NetworkLoadBalancers) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *NetworkLoadBalancers) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *NetworkLoadBalancers) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *NetworkLoadBalancers) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *NetworkLoadBalancers) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *NetworkLoadBalancers) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NetworkLoadBalancers) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NetworkLoadBalancers) GetLinksOk() (*PaginationLinks, bool) {
+func (o *NetworkLoadBalancers) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *NetworkLoadBalancers) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *NetworkLoadBalancers) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *NetworkLoadBalancers) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NetworkLoadBalancers) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *NetworkLoadBalancers) HasLinks() bool {
func (o NetworkLoadBalancers) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic.go
index 9d8378c6f32..6a9c05537b2 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic.go
@@ -16,15 +16,15 @@ import (
// Nic struct for Nic
type Nic struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Entities *NicEntities `json:"entities,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *NicProperties `json:"properties"`
- Entities *NicEntities `json:"entities,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewNic instantiates a new Nic object
@@ -47,114 +47,114 @@ func NewNicWithDefaults() *Nic {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Nic) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *Nic) GetEntities() *NicEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Nic) GetIdOk() (*string, bool) {
+func (o *Nic) GetEntitiesOk() (*NicEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *Nic) SetId(v string) {
+// SetEntities sets field value
+func (o *Nic) SetEntities(v NicEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Nic) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *Nic) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Nic) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Nic) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Nic) GetTypeOk() (*Type, bool) {
+func (o *Nic) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Nic) SetType(v Type) {
+// SetHref sets field value
+func (o *Nic) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Nic) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Nic) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Nic) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Nic) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Nic) GetHrefOk() (*string, bool) {
+func (o *Nic) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Nic) SetHref(v string) {
+// SetId sets field value
+func (o *Nic) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Nic) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Nic) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -162,7 +162,7 @@ func (o *Nic) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *Nic) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
@@ -200,7 +200,7 @@ func (o *Nic) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for NicProperties will be returned
+// If the value is explicit nil, nil is returned
func (o *Nic) GetProperties() *NicProperties {
if o == nil {
return nil
@@ -237,38 +237,38 @@ func (o *Nic) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for NicEntities will be returned
-func (o *Nic) GetEntities() *NicEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Nic) GetType() *Type {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Nic) GetEntitiesOk() (*NicEntities, bool) {
+func (o *Nic) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *Nic) SetEntities(v NicEntities) {
+// SetType sets field value
+func (o *Nic) SetType(v Type) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *Nic) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Nic) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -277,24 +277,30 @@ func (o *Nic) HasEntities() bool {
func (o Nic) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic_entities.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic_entities.go
index b1a5553a7e8..ab19ab4ac91 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic_entities.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic_entities.go
@@ -16,8 +16,8 @@ import (
// NicEntities struct for NicEntities
type NicEntities struct {
- Flowlogs *FlowLogs `json:"flowlogs,omitempty"`
Firewallrules *FirewallRules `json:"firewallrules,omitempty"`
+ Flowlogs *FlowLogs `json:"flowlogs,omitempty"`
}
// NewNicEntities instantiates a new NicEntities object
@@ -38,76 +38,76 @@ func NewNicEntitiesWithDefaults() *NicEntities {
return &this
}
-// GetFlowlogs returns the Flowlogs field value
-// If the value is explicit nil, the zero value for FlowLogs will be returned
-func (o *NicEntities) GetFlowlogs() *FlowLogs {
+// GetFirewallrules returns the Firewallrules field value
+// If the value is explicit nil, nil is returned
+func (o *NicEntities) GetFirewallrules() *FirewallRules {
if o == nil {
return nil
}
- return o.Flowlogs
+ return o.Firewallrules
}
-// GetFlowlogsOk returns a tuple with the Flowlogs field value
+// GetFirewallrulesOk returns a tuple with the Firewallrules field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicEntities) GetFlowlogsOk() (*FlowLogs, bool) {
+func (o *NicEntities) GetFirewallrulesOk() (*FirewallRules, bool) {
if o == nil {
return nil, false
}
- return o.Flowlogs, true
+ return o.Firewallrules, true
}
-// SetFlowlogs sets field value
-func (o *NicEntities) SetFlowlogs(v FlowLogs) {
+// SetFirewallrules sets field value
+func (o *NicEntities) SetFirewallrules(v FirewallRules) {
- o.Flowlogs = &v
+ o.Firewallrules = &v
}
-// HasFlowlogs returns a boolean if a field has been set.
-func (o *NicEntities) HasFlowlogs() bool {
- if o != nil && o.Flowlogs != nil {
+// HasFirewallrules returns a boolean if a field has been set.
+func (o *NicEntities) HasFirewallrules() bool {
+ if o != nil && o.Firewallrules != nil {
return true
}
return false
}
-// GetFirewallrules returns the Firewallrules field value
-// If the value is explicit nil, the zero value for FirewallRules will be returned
-func (o *NicEntities) GetFirewallrules() *FirewallRules {
+// GetFlowlogs returns the Flowlogs field value
+// If the value is explicit nil, nil is returned
+func (o *NicEntities) GetFlowlogs() *FlowLogs {
if o == nil {
return nil
}
- return o.Firewallrules
+ return o.Flowlogs
}
-// GetFirewallrulesOk returns a tuple with the Firewallrules field value
+// GetFlowlogsOk returns a tuple with the Flowlogs field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicEntities) GetFirewallrulesOk() (*FirewallRules, bool) {
+func (o *NicEntities) GetFlowlogsOk() (*FlowLogs, bool) {
if o == nil {
return nil, false
}
- return o.Firewallrules, true
+ return o.Flowlogs, true
}
-// SetFirewallrules sets field value
-func (o *NicEntities) SetFirewallrules(v FirewallRules) {
+// SetFlowlogs sets field value
+func (o *NicEntities) SetFlowlogs(v FlowLogs) {
- o.Firewallrules = &v
+ o.Flowlogs = &v
}
-// HasFirewallrules returns a boolean if a field has been set.
-func (o *NicEntities) HasFirewallrules() bool {
- if o != nil && o.Firewallrules != nil {
+// HasFlowlogs returns a boolean if a field has been set.
+func (o *NicEntities) HasFlowlogs() bool {
+ if o != nil && o.Flowlogs != nil {
return true
}
@@ -116,12 +116,14 @@ func (o *NicEntities) HasFirewallrules() bool {
func (o NicEntities) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Flowlogs != nil {
- toSerialize["flowlogs"] = o.Flowlogs
- }
if o.Firewallrules != nil {
toSerialize["firewallrules"] = o.Firewallrules
}
+
+ if o.Flowlogs != nil {
+ toSerialize["flowlogs"] = o.Flowlogs
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic_properties.go
index 20d0323ace0..f59a5d86278 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic_properties.go
@@ -16,24 +16,27 @@ import (
// NicProperties struct for NicProperties
type NicProperties struct {
- // The name of the resource.
- Name *string `json:"name,omitempty"`
- // The MAC address of the NIC.
- Mac *string `json:"mac,omitempty"`
- // Collection of IP addresses, assigned to the NIC. Explicitly assigned public IPs need to come from reserved IP blocks. Passing value null or empty array will assign an IP address automatically.
- Ips *[]string `json:"ips,omitempty"`
+ // The Logical Unit Number (LUN) of the storage volume. Null if this NIC was created using Cloud API and no DCD changes were performed on the Datacenter.
+ DeviceNumber *int32 `json:"deviceNumber,omitempty"`
// Indicates if the NIC will reserve an IP using DHCP.
Dhcp *bool `json:"dhcp,omitempty"`
- // The LAN ID the NIC will be on. If the LAN ID does not exist, it will be implicitly created.
- Lan *int32 `json:"lan"`
// Activate or deactivate the firewall. By default, an active firewall without any defined rules will block all incoming network traffic except for the firewall rules that explicitly allows certain protocols, IP addresses and ports.
FirewallActive *bool `json:"firewallActive,omitempty"`
// The type of firewall rules that will be allowed on the NIC. If not specified, the default INGRESS value is used.
FirewallType *string `json:"firewallType,omitempty"`
- // The Logical Unit Number (LUN) of the storage volume. Null if this NIC was created using Cloud API and no DCD changes were performed on the Datacenter.
- DeviceNumber *int32 `json:"deviceNumber,omitempty"`
+ // Collection of IP addresses, assigned to the NIC. Explicitly assigned public IPs need to come from reserved IP blocks. Passing value null or empty array will assign an IP address automatically.
+ // to set this field to `nil` in order to be marshalled, the explicit nil address `Nil[]string` can be used, or the setter `SetIpsNil`
+ Ips *[]string `json:"ips,omitempty"`
+ // The LAN ID the NIC will be on. If the LAN ID does not exist, it will be implicitly created.
+ Lan *int32 `json:"lan"`
+ // The MAC address of the NIC.
+ Mac *string `json:"mac,omitempty"`
+ // The name of the resource.
+ Name *string `json:"name,omitempty"`
// The PCI slot number for the NIC.
PciSlot *int32 `json:"pciSlot,omitempty"`
+ // The vnet ID that belongs to this NIC; Requires system privileges
+ Vnet *string `json:"vnet,omitempty"`
}
// NewNicProperties instantiates a new NicProperties object
@@ -60,304 +63,304 @@ func NewNicPropertiesWithDefaults() *NicProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NicProperties) GetName() *string {
+// GetDeviceNumber returns the DeviceNumber field value
+// If the value is explicit nil, nil is returned
+func (o *NicProperties) GetDeviceNumber() *int32 {
if o == nil {
return nil
}
- return o.Name
+ return o.DeviceNumber
}
-// GetNameOk returns a tuple with the Name field value
+// GetDeviceNumberOk returns a tuple with the DeviceNumber field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicProperties) GetNameOk() (*string, bool) {
+func (o *NicProperties) GetDeviceNumberOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.DeviceNumber, true
}
-// SetName sets field value
-func (o *NicProperties) SetName(v string) {
+// SetDeviceNumber sets field value
+func (o *NicProperties) SetDeviceNumber(v int32) {
- o.Name = &v
+ o.DeviceNumber = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *NicProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasDeviceNumber returns a boolean if a field has been set.
+func (o *NicProperties) HasDeviceNumber() bool {
+ if o != nil && o.DeviceNumber != nil {
return true
}
return false
}
-// GetMac returns the Mac field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NicProperties) GetMac() *string {
+// GetDhcp returns the Dhcp field value
+// If the value is explicit nil, nil is returned
+func (o *NicProperties) GetDhcp() *bool {
if o == nil {
return nil
}
- return o.Mac
+ return o.Dhcp
}
-// GetMacOk returns a tuple with the Mac field value
+// GetDhcpOk returns a tuple with the Dhcp field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicProperties) GetMacOk() (*string, bool) {
+func (o *NicProperties) GetDhcpOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Mac, true
+ return o.Dhcp, true
}
-// SetMac sets field value
-func (o *NicProperties) SetMac(v string) {
+// SetDhcp sets field value
+func (o *NicProperties) SetDhcp(v bool) {
- o.Mac = &v
+ o.Dhcp = &v
}
-// HasMac returns a boolean if a field has been set.
-func (o *NicProperties) HasMac() bool {
- if o != nil && o.Mac != nil {
+// HasDhcp returns a boolean if a field has been set.
+func (o *NicProperties) HasDhcp() bool {
+ if o != nil && o.Dhcp != nil {
return true
}
return false
}
-// GetIps returns the Ips field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *NicProperties) GetIps() *[]string {
+// GetFirewallActive returns the FirewallActive field value
+// If the value is explicit nil, nil is returned
+func (o *NicProperties) GetFirewallActive() *bool {
if o == nil {
return nil
}
- return o.Ips
+ return o.FirewallActive
}
-// GetIpsOk returns a tuple with the Ips field value
+// GetFirewallActiveOk returns a tuple with the FirewallActive field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicProperties) GetIpsOk() (*[]string, bool) {
+func (o *NicProperties) GetFirewallActiveOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Ips, true
+ return o.FirewallActive, true
}
-// SetIps sets field value
-func (o *NicProperties) SetIps(v []string) {
+// SetFirewallActive sets field value
+func (o *NicProperties) SetFirewallActive(v bool) {
- o.Ips = &v
+ o.FirewallActive = &v
}
-// HasIps returns a boolean if a field has been set.
-func (o *NicProperties) HasIps() bool {
- if o != nil && o.Ips != nil {
+// HasFirewallActive returns a boolean if a field has been set.
+func (o *NicProperties) HasFirewallActive() bool {
+ if o != nil && o.FirewallActive != nil {
return true
}
return false
}
-// GetDhcp returns the Dhcp field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *NicProperties) GetDhcp() *bool {
+// GetFirewallType returns the FirewallType field value
+// If the value is explicit nil, nil is returned
+func (o *NicProperties) GetFirewallType() *string {
if o == nil {
return nil
}
- return o.Dhcp
+ return o.FirewallType
}
-// GetDhcpOk returns a tuple with the Dhcp field value
+// GetFirewallTypeOk returns a tuple with the FirewallType field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicProperties) GetDhcpOk() (*bool, bool) {
+func (o *NicProperties) GetFirewallTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Dhcp, true
+ return o.FirewallType, true
}
-// SetDhcp sets field value
-func (o *NicProperties) SetDhcp(v bool) {
+// SetFirewallType sets field value
+func (o *NicProperties) SetFirewallType(v string) {
- o.Dhcp = &v
+ o.FirewallType = &v
}
-// HasDhcp returns a boolean if a field has been set.
-func (o *NicProperties) HasDhcp() bool {
- if o != nil && o.Dhcp != nil {
+// HasFirewallType returns a boolean if a field has been set.
+func (o *NicProperties) HasFirewallType() bool {
+ if o != nil && o.FirewallType != nil {
return true
}
return false
}
-// GetLan returns the Lan field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *NicProperties) GetLan() *int32 {
+// GetIps returns the Ips field value
+// If the value is explicit nil, nil is returned
+func (o *NicProperties) GetIps() *[]string {
if o == nil {
return nil
}
- return o.Lan
+ return o.Ips
}
-// GetLanOk returns a tuple with the Lan field value
+// GetIpsOk returns a tuple with the Ips field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicProperties) GetLanOk() (*int32, bool) {
+func (o *NicProperties) GetIpsOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.Lan, true
+ return o.Ips, true
}
-// SetLan sets field value
-func (o *NicProperties) SetLan(v int32) {
+// SetIps sets field value
+func (o *NicProperties) SetIps(v []string) {
- o.Lan = &v
+ o.Ips = &v
}
-// HasLan returns a boolean if a field has been set.
-func (o *NicProperties) HasLan() bool {
- if o != nil && o.Lan != nil {
+// HasIps returns a boolean if a field has been set.
+func (o *NicProperties) HasIps() bool {
+ if o != nil && o.Ips != nil {
return true
}
return false
}
-// GetFirewallActive returns the FirewallActive field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *NicProperties) GetFirewallActive() *bool {
+// GetLan returns the Lan field value
+// If the value is explicit nil, nil is returned
+func (o *NicProperties) GetLan() *int32 {
if o == nil {
return nil
}
- return o.FirewallActive
+ return o.Lan
}
-// GetFirewallActiveOk returns a tuple with the FirewallActive field value
+// GetLanOk returns a tuple with the Lan field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicProperties) GetFirewallActiveOk() (*bool, bool) {
+func (o *NicProperties) GetLanOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.FirewallActive, true
+ return o.Lan, true
}
-// SetFirewallActive sets field value
-func (o *NicProperties) SetFirewallActive(v bool) {
+// SetLan sets field value
+func (o *NicProperties) SetLan(v int32) {
- o.FirewallActive = &v
+ o.Lan = &v
}
-// HasFirewallActive returns a boolean if a field has been set.
-func (o *NicProperties) HasFirewallActive() bool {
- if o != nil && o.FirewallActive != nil {
+// HasLan returns a boolean if a field has been set.
+func (o *NicProperties) HasLan() bool {
+ if o != nil && o.Lan != nil {
return true
}
return false
}
-// GetFirewallType returns the FirewallType field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NicProperties) GetFirewallType() *string {
+// GetMac returns the Mac field value
+// If the value is explicit nil, nil is returned
+func (o *NicProperties) GetMac() *string {
if o == nil {
return nil
}
- return o.FirewallType
+ return o.Mac
}
-// GetFirewallTypeOk returns a tuple with the FirewallType field value
+// GetMacOk returns a tuple with the Mac field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicProperties) GetFirewallTypeOk() (*string, bool) {
+func (o *NicProperties) GetMacOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.FirewallType, true
+ return o.Mac, true
}
-// SetFirewallType sets field value
-func (o *NicProperties) SetFirewallType(v string) {
+// SetMac sets field value
+func (o *NicProperties) SetMac(v string) {
- o.FirewallType = &v
+ o.Mac = &v
}
-// HasFirewallType returns a boolean if a field has been set.
-func (o *NicProperties) HasFirewallType() bool {
- if o != nil && o.FirewallType != nil {
+// HasMac returns a boolean if a field has been set.
+func (o *NicProperties) HasMac() bool {
+ if o != nil && o.Mac != nil {
return true
}
return false
}
-// GetDeviceNumber returns the DeviceNumber field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *NicProperties) GetDeviceNumber() *int32 {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *NicProperties) GetName() *string {
if o == nil {
return nil
}
- return o.DeviceNumber
+ return o.Name
}
-// GetDeviceNumberOk returns a tuple with the DeviceNumber field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicProperties) GetDeviceNumberOk() (*int32, bool) {
+func (o *NicProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.DeviceNumber, true
+ return o.Name, true
}
-// SetDeviceNumber sets field value
-func (o *NicProperties) SetDeviceNumber(v int32) {
+// SetName sets field value
+func (o *NicProperties) SetName(v string) {
- o.DeviceNumber = &v
+ o.Name = &v
}
-// HasDeviceNumber returns a boolean if a field has been set.
-func (o *NicProperties) HasDeviceNumber() bool {
- if o != nil && o.DeviceNumber != nil {
+// HasName returns a boolean if a field has been set.
+func (o *NicProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -365,7 +368,7 @@ func (o *NicProperties) HasDeviceNumber() bool {
}
// GetPciSlot returns the PciSlot field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *NicProperties) GetPciSlot() *int32 {
if o == nil {
return nil
@@ -402,33 +405,85 @@ func (o *NicProperties) HasPciSlot() bool {
return false
}
+// GetVnet returns the Vnet field value
+// If the value is explicit nil, nil is returned
+func (o *NicProperties) GetVnet() *string {
+ if o == nil {
+ return nil
+ }
+
+ return o.Vnet
+
+}
+
+// GetVnetOk returns a tuple with the Vnet field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *NicProperties) GetVnetOk() (*string, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Vnet, true
+}
+
+// SetVnet sets field value
+func (o *NicProperties) SetVnet(v string) {
+
+ o.Vnet = &v
+
+}
+
+// HasVnet returns a boolean if a field has been set.
+func (o *NicProperties) HasVnet() bool {
+ if o != nil && o.Vnet != nil {
+ return true
+ }
+
+ return false
+}
+
func (o NicProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
- }
- if o.Mac != nil {
- toSerialize["mac"] = o.Mac
+ if o.DeviceNumber != nil {
+ toSerialize["deviceNumber"] = o.DeviceNumber
}
- toSerialize["ips"] = o.Ips
+
if o.Dhcp != nil {
toSerialize["dhcp"] = o.Dhcp
}
- if o.Lan != nil {
- toSerialize["lan"] = o.Lan
- }
+
if o.FirewallActive != nil {
toSerialize["firewallActive"] = o.FirewallActive
}
+
if o.FirewallType != nil {
toSerialize["firewallType"] = o.FirewallType
}
- if o.DeviceNumber != nil {
- toSerialize["deviceNumber"] = o.DeviceNumber
+
+ if o.Ips != nil {
+ toSerialize["ips"] = o.Ips
+ }
+ if o.Lan != nil {
+ toSerialize["lan"] = o.Lan
+ }
+
+ if o.Mac != nil {
+ toSerialize["mac"] = o.Mac
}
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
if o.PciSlot != nil {
toSerialize["pciSlot"] = o.PciSlot
}
+
+ if o.Vnet != nil {
+ toSerialize["vnet"] = o.Vnet
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic_put.go
index e37c81075e9..0029a6eab01 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nic_put.go
@@ -16,13 +16,13 @@ import (
// NicPut struct for NicPut
type NicPut struct {
+ // URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
- Id *string `json:"id,omitempty"`
+ Id *string `json:"id,omitempty"`
+ Properties *NicProperties `json:"properties"`
// The type of object that has been created.
Type *Type `json:"type,omitempty"`
- // URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
- Properties *NicProperties `json:"properties"`
}
// NewNicPut instantiates a new NicPut object
@@ -45,152 +45,152 @@ func NewNicPutWithDefaults() *NicPut {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NicPut) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *NicPut) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicPut) GetIdOk() (*string, bool) {
+func (o *NicPut) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *NicPut) SetId(v string) {
+// SetHref sets field value
+func (o *NicPut) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *NicPut) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *NicPut) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *NicPut) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *NicPut) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicPut) GetTypeOk() (*Type, bool) {
+func (o *NicPut) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *NicPut) SetType(v Type) {
+// SetId sets field value
+func (o *NicPut) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *NicPut) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *NicPut) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NicPut) GetHref() *string {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *NicPut) GetProperties() *NicProperties {
if o == nil {
return nil
}
- return o.Href
+ return o.Properties
}
-// GetHrefOk returns a tuple with the Href field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicPut) GetHrefOk() (*string, bool) {
+func (o *NicPut) GetPropertiesOk() (*NicProperties, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Properties, true
}
-// SetHref sets field value
-func (o *NicPut) SetHref(v string) {
+// SetProperties sets field value
+func (o *NicPut) SetProperties(v NicProperties) {
- o.Href = &v
+ o.Properties = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *NicPut) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *NicPut) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for NicProperties will be returned
-func (o *NicPut) GetProperties() *NicProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *NicPut) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NicPut) GetPropertiesOk() (*NicProperties, bool) {
+func (o *NicPut) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *NicPut) SetProperties(v NicProperties) {
+// SetType sets field value
+func (o *NicPut) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *NicPut) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *NicPut) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -199,18 +199,22 @@ func (o *NicPut) HasProperties() bool {
func (o NicPut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nics.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nics.go
index 80ff9957fbb..6fe1220a488 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_nics.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_nics.go
@@ -16,19 +16,19 @@ import (
// Nics struct for Nics
type Nics struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Nic `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewNics instantiates a new Nics object
@@ -49,114 +49,114 @@ func NewNicsWithDefaults() *Nics {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Nics) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *Nics) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Nics) GetIdOk() (*string, bool) {
+func (o *Nics) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *Nics) SetId(v string) {
+// SetLinks sets field value
+func (o *Nics) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Nics) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *Nics) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Nics) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Nics) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Nics) GetTypeOk() (*Type, bool) {
+func (o *Nics) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Nics) SetType(v Type) {
+// SetHref sets field value
+func (o *Nics) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Nics) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Nics) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Nics) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Nics) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Nics) GetHrefOk() (*string, bool) {
+func (o *Nics) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Nics) SetHref(v string) {
+// SetId sets field value
+func (o *Nics) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Nics) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Nics) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *Nics) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Nic will be returned
+// If the value is explicit nil, nil is returned
func (o *Nics) GetItems() *[]Nic {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *Nics) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Nics) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *Nics) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Nics) GetOffsetOk() (*float32, bool) {
+func (o *Nics) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *Nics) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *Nics) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *Nics) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *Nics) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Nics) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *Nics) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Nics) GetLimitOk() (*float32, bool) {
+func (o *Nics) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *Nics) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *Nics) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *Nics) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *Nics) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *Nics) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Nics) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Nics) GetLinksOk() (*PaginationLinks, bool) {
+func (o *Nics) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *Nics) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *Nics) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *Nics) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Nics) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *Nics) HasLinks() bool {
func (o Nics) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_no_state_meta_data.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_no_state_meta_data.go
index 4d1488a1de2..bf6d643dd42 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_no_state_meta_data.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_no_state_meta_data.go
@@ -17,20 +17,20 @@ import (
// NoStateMetaData struct for NoStateMetaData
type NoStateMetaData struct {
- // Resource's Entity Tag as defined in http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.11 Entity Tag is also added as an 'ETag response header to requests which don't use 'depth' parameter.
- Etag *string `json:"etag,omitempty"`
- // The time when the resource was created.
- CreatedDate *IonosTime
// The user who has created the resource.
CreatedBy *string `json:"createdBy,omitempty"`
// The unique ID of the user who created the resource.
CreatedByUserId *string `json:"createdByUserId,omitempty"`
- // The last time the resource was modified.
- LastModifiedDate *IonosTime
+ // The time when the resource was created.
+ CreatedDate *IonosTime
+ // Resource's Entity Tag as defined in http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.11 Entity Tag is also added as an 'ETag response header to requests which don't use 'depth' parameter.
+ Etag *string `json:"etag,omitempty"`
// The user who last modified the resource.
LastModifiedBy *string `json:"lastModifiedBy,omitempty"`
// The unique ID of the user who last modified the resource.
LastModifiedByUserId *string `json:"lastModifiedByUserId,omitempty"`
+ // The last time the resource was modified.
+ LastModifiedDate *IonosTime
}
// NewNoStateMetaData instantiates a new NoStateMetaData object
@@ -51,91 +51,8 @@ func NewNoStateMetaDataWithDefaults() *NoStateMetaData {
return &this
}
-// GetEtag returns the Etag field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *NoStateMetaData) GetEtag() *string {
- if o == nil {
- return nil
- }
-
- return o.Etag
-
-}
-
-// GetEtagOk returns a tuple with the Etag field value
-// and a boolean to check if the value has been set.
-// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NoStateMetaData) GetEtagOk() (*string, bool) {
- if o == nil {
- return nil, false
- }
-
- return o.Etag, true
-}
-
-// SetEtag sets field value
-func (o *NoStateMetaData) SetEtag(v string) {
-
- o.Etag = &v
-
-}
-
-// HasEtag returns a boolean if a field has been set.
-func (o *NoStateMetaData) HasEtag() bool {
- if o != nil && o.Etag != nil {
- return true
- }
-
- return false
-}
-
-// GetCreatedDate returns the CreatedDate field value
-// If the value is explicit nil, the zero value for time.Time will be returned
-func (o *NoStateMetaData) GetCreatedDate() *time.Time {
- if o == nil {
- return nil
- }
-
- if o.CreatedDate == nil {
- return nil
- }
- return &o.CreatedDate.Time
-
-}
-
-// GetCreatedDateOk returns a tuple with the CreatedDate field value
-// and a boolean to check if the value has been set.
-// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NoStateMetaData) GetCreatedDateOk() (*time.Time, bool) {
- if o == nil {
- return nil, false
- }
-
- if o.CreatedDate == nil {
- return nil, false
- }
- return &o.CreatedDate.Time, true
-
-}
-
-// SetCreatedDate sets field value
-func (o *NoStateMetaData) SetCreatedDate(v time.Time) {
-
- o.CreatedDate = &IonosTime{v}
-
-}
-
-// HasCreatedDate returns a boolean if a field has been set.
-func (o *NoStateMetaData) HasCreatedDate() bool {
- if o != nil && o.CreatedDate != nil {
- return true
- }
-
- return false
-}
-
// GetCreatedBy returns the CreatedBy field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *NoStateMetaData) GetCreatedBy() *string {
if o == nil {
return nil
@@ -173,7 +90,7 @@ func (o *NoStateMetaData) HasCreatedBy() bool {
}
// GetCreatedByUserId returns the CreatedByUserId field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *NoStateMetaData) GetCreatedByUserId() *string {
if o == nil {
return nil
@@ -210,45 +127,83 @@ func (o *NoStateMetaData) HasCreatedByUserId() bool {
return false
}
-// GetLastModifiedDate returns the LastModifiedDate field value
-// If the value is explicit nil, the zero value for time.Time will be returned
-func (o *NoStateMetaData) GetLastModifiedDate() *time.Time {
+// GetCreatedDate returns the CreatedDate field value
+// If the value is explicit nil, nil is returned
+func (o *NoStateMetaData) GetCreatedDate() *time.Time {
if o == nil {
return nil
}
- if o.LastModifiedDate == nil {
+ if o.CreatedDate == nil {
return nil
}
- return &o.LastModifiedDate.Time
+ return &o.CreatedDate.Time
}
-// GetLastModifiedDateOk returns a tuple with the LastModifiedDate field value
+// GetCreatedDateOk returns a tuple with the CreatedDate field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *NoStateMetaData) GetLastModifiedDateOk() (*time.Time, bool) {
+func (o *NoStateMetaData) GetCreatedDateOk() (*time.Time, bool) {
if o == nil {
return nil, false
}
- if o.LastModifiedDate == nil {
+ if o.CreatedDate == nil {
return nil, false
}
- return &o.LastModifiedDate.Time, true
+ return &o.CreatedDate.Time, true
}
-// SetLastModifiedDate sets field value
-func (o *NoStateMetaData) SetLastModifiedDate(v time.Time) {
+// SetCreatedDate sets field value
+func (o *NoStateMetaData) SetCreatedDate(v time.Time) {
- o.LastModifiedDate = &IonosTime{v}
+ o.CreatedDate = &IonosTime{v}
}
-// HasLastModifiedDate returns a boolean if a field has been set.
-func (o *NoStateMetaData) HasLastModifiedDate() bool {
- if o != nil && o.LastModifiedDate != nil {
+// HasCreatedDate returns a boolean if a field has been set.
+func (o *NoStateMetaData) HasCreatedDate() bool {
+ if o != nil && o.CreatedDate != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetEtag returns the Etag field value
+// If the value is explicit nil, nil is returned
+func (o *NoStateMetaData) GetEtag() *string {
+ if o == nil {
+ return nil
+ }
+
+ return o.Etag
+
+}
+
+// GetEtagOk returns a tuple with the Etag field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *NoStateMetaData) GetEtagOk() (*string, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.Etag, true
+}
+
+// SetEtag sets field value
+func (o *NoStateMetaData) SetEtag(v string) {
+
+ o.Etag = &v
+
+}
+
+// HasEtag returns a boolean if a field has been set.
+func (o *NoStateMetaData) HasEtag() bool {
+ if o != nil && o.Etag != nil {
return true
}
@@ -256,7 +211,7 @@ func (o *NoStateMetaData) HasLastModifiedDate() bool {
}
// GetLastModifiedBy returns the LastModifiedBy field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *NoStateMetaData) GetLastModifiedBy() *string {
if o == nil {
return nil
@@ -294,7 +249,7 @@ func (o *NoStateMetaData) HasLastModifiedBy() bool {
}
// GetLastModifiedByUserId returns the LastModifiedByUserId field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *NoStateMetaData) GetLastModifiedByUserId() *string {
if o == nil {
return nil
@@ -331,29 +286,81 @@ func (o *NoStateMetaData) HasLastModifiedByUserId() bool {
return false
}
-func (o NoStateMetaData) MarshalJSON() ([]byte, error) {
- toSerialize := map[string]interface{}{}
- if o.Etag != nil {
- toSerialize["etag"] = o.Etag
+// GetLastModifiedDate returns the LastModifiedDate field value
+// If the value is explicit nil, nil is returned
+func (o *NoStateMetaData) GetLastModifiedDate() *time.Time {
+ if o == nil {
+ return nil
}
- if o.CreatedDate != nil {
- toSerialize["createdDate"] = o.CreatedDate
+
+ if o.LastModifiedDate == nil {
+ return nil
+ }
+ return &o.LastModifiedDate.Time
+
+}
+
+// GetLastModifiedDateOk returns a tuple with the LastModifiedDate field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *NoStateMetaData) GetLastModifiedDateOk() (*time.Time, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ if o.LastModifiedDate == nil {
+ return nil, false
+ }
+ return &o.LastModifiedDate.Time, true
+
+}
+
+// SetLastModifiedDate sets field value
+func (o *NoStateMetaData) SetLastModifiedDate(v time.Time) {
+
+ o.LastModifiedDate = &IonosTime{v}
+
+}
+
+// HasLastModifiedDate returns a boolean if a field has been set.
+func (o *NoStateMetaData) HasLastModifiedDate() bool {
+ if o != nil && o.LastModifiedDate != nil {
+ return true
}
+
+ return false
+}
+
+func (o NoStateMetaData) MarshalJSON() ([]byte, error) {
+ toSerialize := map[string]interface{}{}
if o.CreatedBy != nil {
toSerialize["createdBy"] = o.CreatedBy
}
+
if o.CreatedByUserId != nil {
toSerialize["createdByUserId"] = o.CreatedByUserId
}
- if o.LastModifiedDate != nil {
- toSerialize["lastModifiedDate"] = o.LastModifiedDate
+
+ if o.CreatedDate != nil {
+ toSerialize["createdDate"] = o.CreatedDate
+ }
+
+ if o.Etag != nil {
+ toSerialize["etag"] = o.Etag
}
+
if o.LastModifiedBy != nil {
toSerialize["lastModifiedBy"] = o.LastModifiedBy
}
+
if o.LastModifiedByUserId != nil {
toSerialize["lastModifiedByUserId"] = o.LastModifiedByUserId
}
+
+ if o.LastModifiedDate != nil {
+ toSerialize["lastModifiedDate"] = o.LastModifiedDate
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_pagination_links.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_pagination_links.go
index fa3c76dee8d..5b8bef3043f 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_pagination_links.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_pagination_links.go
@@ -16,12 +16,12 @@ import (
// PaginationLinks struct for PaginationLinks
type PaginationLinks struct {
+ // URL (with offset and limit parameters) of the next page; only present if offset + limit is less than the total number of elements.
+ Next *string `json:"next,omitempty"`
// URL (with offset and limit parameters) of the previous page; only present if offset is greater than 0.
Prev *string `json:"prev,omitempty"`
// URL (with offset and limit parameters) of the current page.
Self *string `json:"self,omitempty"`
- // URL (with offset and limit parameters) of the next page; only present if offset + limit is less than the total number of elements.
- Next *string `json:"next,omitempty"`
}
// NewPaginationLinks instantiates a new PaginationLinks object
@@ -42,114 +42,114 @@ func NewPaginationLinksWithDefaults() *PaginationLinks {
return &this
}
-// GetPrev returns the Prev field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *PaginationLinks) GetPrev() *string {
+// GetNext returns the Next field value
+// If the value is explicit nil, nil is returned
+func (o *PaginationLinks) GetNext() *string {
if o == nil {
return nil
}
- return o.Prev
+ return o.Next
}
-// GetPrevOk returns a tuple with the Prev field value
+// GetNextOk returns a tuple with the Next field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PaginationLinks) GetPrevOk() (*string, bool) {
+func (o *PaginationLinks) GetNextOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Prev, true
+ return o.Next, true
}
-// SetPrev sets field value
-func (o *PaginationLinks) SetPrev(v string) {
+// SetNext sets field value
+func (o *PaginationLinks) SetNext(v string) {
- o.Prev = &v
+ o.Next = &v
}
-// HasPrev returns a boolean if a field has been set.
-func (o *PaginationLinks) HasPrev() bool {
- if o != nil && o.Prev != nil {
+// HasNext returns a boolean if a field has been set.
+func (o *PaginationLinks) HasNext() bool {
+ if o != nil && o.Next != nil {
return true
}
return false
}
-// GetSelf returns the Self field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *PaginationLinks) GetSelf() *string {
+// GetPrev returns the Prev field value
+// If the value is explicit nil, nil is returned
+func (o *PaginationLinks) GetPrev() *string {
if o == nil {
return nil
}
- return o.Self
+ return o.Prev
}
-// GetSelfOk returns a tuple with the Self field value
+// GetPrevOk returns a tuple with the Prev field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PaginationLinks) GetSelfOk() (*string, bool) {
+func (o *PaginationLinks) GetPrevOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Self, true
+ return o.Prev, true
}
-// SetSelf sets field value
-func (o *PaginationLinks) SetSelf(v string) {
+// SetPrev sets field value
+func (o *PaginationLinks) SetPrev(v string) {
- o.Self = &v
+ o.Prev = &v
}
-// HasSelf returns a boolean if a field has been set.
-func (o *PaginationLinks) HasSelf() bool {
- if o != nil && o.Self != nil {
+// HasPrev returns a boolean if a field has been set.
+func (o *PaginationLinks) HasPrev() bool {
+ if o != nil && o.Prev != nil {
return true
}
return false
}
-// GetNext returns the Next field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *PaginationLinks) GetNext() *string {
+// GetSelf returns the Self field value
+// If the value is explicit nil, nil is returned
+func (o *PaginationLinks) GetSelf() *string {
if o == nil {
return nil
}
- return o.Next
+ return o.Self
}
-// GetNextOk returns a tuple with the Next field value
+// GetSelfOk returns a tuple with the Self field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PaginationLinks) GetNextOk() (*string, bool) {
+func (o *PaginationLinks) GetSelfOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Next, true
+ return o.Self, true
}
-// SetNext sets field value
-func (o *PaginationLinks) SetNext(v string) {
+// SetSelf sets field value
+func (o *PaginationLinks) SetSelf(v string) {
- o.Next = &v
+ o.Self = &v
}
-// HasNext returns a boolean if a field has been set.
-func (o *PaginationLinks) HasNext() bool {
- if o != nil && o.Next != nil {
+// HasSelf returns a boolean if a field has been set.
+func (o *PaginationLinks) HasSelf() bool {
+ if o != nil && o.Self != nil {
return true
}
@@ -158,15 +158,18 @@ func (o *PaginationLinks) HasNext() bool {
func (o PaginationLinks) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
+ if o.Next != nil {
+ toSerialize["next"] = o.Next
+ }
+
if o.Prev != nil {
toSerialize["prev"] = o.Prev
}
+
if o.Self != nil {
toSerialize["self"] = o.Self
}
- if o.Next != nil {
- toSerialize["next"] = o.Next
- }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_peer.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_peer.go
index db7c562be66..582ff98a946 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_peer.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_peer.go
@@ -16,11 +16,11 @@ import (
// Peer struct for Peer
type Peer struct {
- Id *string `json:"id,omitempty"`
- Name *string `json:"name,omitempty"`
DatacenterId *string `json:"datacenterId,omitempty"`
DatacenterName *string `json:"datacenterName,omitempty"`
+ Id *string `json:"id,omitempty"`
Location *string `json:"location,omitempty"`
+ Name *string `json:"name,omitempty"`
}
// NewPeer instantiates a new Peer object
@@ -41,190 +41,190 @@ func NewPeerWithDefaults() *Peer {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Peer) GetId() *string {
+// GetDatacenterId returns the DatacenterId field value
+// If the value is explicit nil, nil is returned
+func (o *Peer) GetDatacenterId() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.DatacenterId
}
-// GetIdOk returns a tuple with the Id field value
+// GetDatacenterIdOk returns a tuple with the DatacenterId field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Peer) GetIdOk() (*string, bool) {
+func (o *Peer) GetDatacenterIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.DatacenterId, true
}
-// SetId sets field value
-func (o *Peer) SetId(v string) {
+// SetDatacenterId sets field value
+func (o *Peer) SetDatacenterId(v string) {
- o.Id = &v
+ o.DatacenterId = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Peer) HasId() bool {
- if o != nil && o.Id != nil {
+// HasDatacenterId returns a boolean if a field has been set.
+func (o *Peer) HasDatacenterId() bool {
+ if o != nil && o.DatacenterId != nil {
return true
}
return false
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Peer) GetName() *string {
+// GetDatacenterName returns the DatacenterName field value
+// If the value is explicit nil, nil is returned
+func (o *Peer) GetDatacenterName() *string {
if o == nil {
return nil
}
- return o.Name
+ return o.DatacenterName
}
-// GetNameOk returns a tuple with the Name field value
+// GetDatacenterNameOk returns a tuple with the DatacenterName field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Peer) GetNameOk() (*string, bool) {
+func (o *Peer) GetDatacenterNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.DatacenterName, true
}
-// SetName sets field value
-func (o *Peer) SetName(v string) {
+// SetDatacenterName sets field value
+func (o *Peer) SetDatacenterName(v string) {
- o.Name = &v
+ o.DatacenterName = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *Peer) HasName() bool {
- if o != nil && o.Name != nil {
+// HasDatacenterName returns a boolean if a field has been set.
+func (o *Peer) HasDatacenterName() bool {
+ if o != nil && o.DatacenterName != nil {
return true
}
return false
}
-// GetDatacenterId returns the DatacenterId field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Peer) GetDatacenterId() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Peer) GetId() *string {
if o == nil {
return nil
}
- return o.DatacenterId
+ return o.Id
}
-// GetDatacenterIdOk returns a tuple with the DatacenterId field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Peer) GetDatacenterIdOk() (*string, bool) {
+func (o *Peer) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.DatacenterId, true
+ return o.Id, true
}
-// SetDatacenterId sets field value
-func (o *Peer) SetDatacenterId(v string) {
+// SetId sets field value
+func (o *Peer) SetId(v string) {
- o.DatacenterId = &v
+ o.Id = &v
}
-// HasDatacenterId returns a boolean if a field has been set.
-func (o *Peer) HasDatacenterId() bool {
- if o != nil && o.DatacenterId != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Peer) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetDatacenterName returns the DatacenterName field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Peer) GetDatacenterName() *string {
+// GetLocation returns the Location field value
+// If the value is explicit nil, nil is returned
+func (o *Peer) GetLocation() *string {
if o == nil {
return nil
}
- return o.DatacenterName
+ return o.Location
}
-// GetDatacenterNameOk returns a tuple with the DatacenterName field value
+// GetLocationOk returns a tuple with the Location field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Peer) GetDatacenterNameOk() (*string, bool) {
+func (o *Peer) GetLocationOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.DatacenterName, true
+ return o.Location, true
}
-// SetDatacenterName sets field value
-func (o *Peer) SetDatacenterName(v string) {
+// SetLocation sets field value
+func (o *Peer) SetLocation(v string) {
- o.DatacenterName = &v
+ o.Location = &v
}
-// HasDatacenterName returns a boolean if a field has been set.
-func (o *Peer) HasDatacenterName() bool {
- if o != nil && o.DatacenterName != nil {
+// HasLocation returns a boolean if a field has been set.
+func (o *Peer) HasLocation() bool {
+ if o != nil && o.Location != nil {
return true
}
return false
}
-// GetLocation returns the Location field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Peer) GetLocation() *string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *Peer) GetName() *string {
if o == nil {
return nil
}
- return o.Location
+ return o.Name
}
-// GetLocationOk returns a tuple with the Location field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Peer) GetLocationOk() (*string, bool) {
+func (o *Peer) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Location, true
+ return o.Name, true
}
-// SetLocation sets field value
-func (o *Peer) SetLocation(v string) {
+// SetName sets field value
+func (o *Peer) SetName(v string) {
- o.Location = &v
+ o.Name = &v
}
-// HasLocation returns a boolean if a field has been set.
-func (o *Peer) HasLocation() bool {
- if o != nil && o.Location != nil {
+// HasName returns a boolean if a field has been set.
+func (o *Peer) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -233,21 +233,26 @@ func (o *Peer) HasLocation() bool {
func (o Peer) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Name != nil {
- toSerialize["name"] = o.Name
- }
if o.DatacenterId != nil {
toSerialize["datacenterId"] = o.DatacenterId
}
+
if o.DatacenterName != nil {
toSerialize["datacenterName"] = o.DatacenterName
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Location != nil {
toSerialize["location"] = o.Location
}
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_private_cross_connect.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_private_cross_connect.go
index f0aa7eb8f50..1a417e85c5e 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_private_cross_connect.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_private_cross_connect.go
@@ -16,14 +16,14 @@ import (
// PrivateCrossConnect struct for PrivateCrossConnect
type PrivateCrossConnect struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *PrivateCrossConnectProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewPrivateCrossConnect instantiates a new PrivateCrossConnect object
@@ -46,190 +46,190 @@ func NewPrivateCrossConnectWithDefaults() *PrivateCrossConnect {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *PrivateCrossConnect) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *PrivateCrossConnect) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PrivateCrossConnect) GetIdOk() (*string, bool) {
+func (o *PrivateCrossConnect) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *PrivateCrossConnect) SetId(v string) {
+// SetHref sets field value
+func (o *PrivateCrossConnect) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *PrivateCrossConnect) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *PrivateCrossConnect) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *PrivateCrossConnect) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *PrivateCrossConnect) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PrivateCrossConnect) GetTypeOk() (*Type, bool) {
+func (o *PrivateCrossConnect) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *PrivateCrossConnect) SetType(v Type) {
+// SetId sets field value
+func (o *PrivateCrossConnect) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *PrivateCrossConnect) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *PrivateCrossConnect) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *PrivateCrossConnect) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *PrivateCrossConnect) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PrivateCrossConnect) GetHrefOk() (*string, bool) {
+func (o *PrivateCrossConnect) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *PrivateCrossConnect) SetHref(v string) {
+// SetMetadata sets field value
+func (o *PrivateCrossConnect) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *PrivateCrossConnect) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *PrivateCrossConnect) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *PrivateCrossConnect) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *PrivateCrossConnect) GetProperties() *PrivateCrossConnectProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PrivateCrossConnect) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *PrivateCrossConnect) GetPropertiesOk() (*PrivateCrossConnectProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *PrivateCrossConnect) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *PrivateCrossConnect) SetProperties(v PrivateCrossConnectProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *PrivateCrossConnect) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *PrivateCrossConnect) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for PrivateCrossConnectProperties will be returned
-func (o *PrivateCrossConnect) GetProperties() *PrivateCrossConnectProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *PrivateCrossConnect) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PrivateCrossConnect) GetPropertiesOk() (*PrivateCrossConnectProperties, bool) {
+func (o *PrivateCrossConnect) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *PrivateCrossConnect) SetProperties(v PrivateCrossConnectProperties) {
+// SetType sets field value
+func (o *PrivateCrossConnect) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *PrivateCrossConnect) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *PrivateCrossConnect) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *PrivateCrossConnect) HasProperties() bool {
func (o PrivateCrossConnect) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_private_cross_connect_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_private_cross_connect_properties.go
index a92dc80982e..864e5ada1ea 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_private_cross_connect_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_private_cross_connect_properties.go
@@ -16,14 +16,14 @@ import (
// PrivateCrossConnectProperties struct for PrivateCrossConnectProperties
type PrivateCrossConnectProperties struct {
- // The name of the resource.
- Name *string `json:"name,omitempty"`
+ // Read-Only attribute. Lists data centers that can be joined to this private Cross-Connect.
+ ConnectableDatacenters *[]ConnectableDatacenter `json:"connectableDatacenters,omitempty"`
// Human-readable description.
Description *string `json:"description,omitempty"`
+ // The name of the resource.
+ Name *string `json:"name,omitempty"`
// Read-Only attribute. Lists LAN's joined to this private Cross-Connect.
Peers *[]Peer `json:"peers,omitempty"`
- // Read-Only attribute. Lists data centers that can be joined to this private Cross-Connect.
- ConnectableDatacenters *[]ConnectableDatacenter `json:"connectableDatacenters,omitempty"`
}
// NewPrivateCrossConnectProperties instantiates a new PrivateCrossConnectProperties object
@@ -44,38 +44,38 @@ func NewPrivateCrossConnectPropertiesWithDefaults() *PrivateCrossConnectProperti
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *PrivateCrossConnectProperties) GetName() *string {
+// GetConnectableDatacenters returns the ConnectableDatacenters field value
+// If the value is explicit nil, nil is returned
+func (o *PrivateCrossConnectProperties) GetConnectableDatacenters() *[]ConnectableDatacenter {
if o == nil {
return nil
}
- return o.Name
+ return o.ConnectableDatacenters
}
-// GetNameOk returns a tuple with the Name field value
+// GetConnectableDatacentersOk returns a tuple with the ConnectableDatacenters field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PrivateCrossConnectProperties) GetNameOk() (*string, bool) {
+func (o *PrivateCrossConnectProperties) GetConnectableDatacentersOk() (*[]ConnectableDatacenter, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.ConnectableDatacenters, true
}
-// SetName sets field value
-func (o *PrivateCrossConnectProperties) SetName(v string) {
+// SetConnectableDatacenters sets field value
+func (o *PrivateCrossConnectProperties) SetConnectableDatacenters(v []ConnectableDatacenter) {
- o.Name = &v
+ o.ConnectableDatacenters = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *PrivateCrossConnectProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasConnectableDatacenters returns a boolean if a field has been set.
+func (o *PrivateCrossConnectProperties) HasConnectableDatacenters() bool {
+ if o != nil && o.ConnectableDatacenters != nil {
return true
}
@@ -83,7 +83,7 @@ func (o *PrivateCrossConnectProperties) HasName() bool {
}
// GetDescription returns the Description field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *PrivateCrossConnectProperties) GetDescription() *string {
if o == nil {
return nil
@@ -120,76 +120,76 @@ func (o *PrivateCrossConnectProperties) HasDescription() bool {
return false
}
-// GetPeers returns the Peers field value
-// If the value is explicit nil, the zero value for []Peer will be returned
-func (o *PrivateCrossConnectProperties) GetPeers() *[]Peer {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *PrivateCrossConnectProperties) GetName() *string {
if o == nil {
return nil
}
- return o.Peers
+ return o.Name
}
-// GetPeersOk returns a tuple with the Peers field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PrivateCrossConnectProperties) GetPeersOk() (*[]Peer, bool) {
+func (o *PrivateCrossConnectProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Peers, true
+ return o.Name, true
}
-// SetPeers sets field value
-func (o *PrivateCrossConnectProperties) SetPeers(v []Peer) {
+// SetName sets field value
+func (o *PrivateCrossConnectProperties) SetName(v string) {
- o.Peers = &v
+ o.Name = &v
}
-// HasPeers returns a boolean if a field has been set.
-func (o *PrivateCrossConnectProperties) HasPeers() bool {
- if o != nil && o.Peers != nil {
+// HasName returns a boolean if a field has been set.
+func (o *PrivateCrossConnectProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetConnectableDatacenters returns the ConnectableDatacenters field value
-// If the value is explicit nil, the zero value for []ConnectableDatacenter will be returned
-func (o *PrivateCrossConnectProperties) GetConnectableDatacenters() *[]ConnectableDatacenter {
+// GetPeers returns the Peers field value
+// If the value is explicit nil, nil is returned
+func (o *PrivateCrossConnectProperties) GetPeers() *[]Peer {
if o == nil {
return nil
}
- return o.ConnectableDatacenters
+ return o.Peers
}
-// GetConnectableDatacentersOk returns a tuple with the ConnectableDatacenters field value
+// GetPeersOk returns a tuple with the Peers field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PrivateCrossConnectProperties) GetConnectableDatacentersOk() (*[]ConnectableDatacenter, bool) {
+func (o *PrivateCrossConnectProperties) GetPeersOk() (*[]Peer, bool) {
if o == nil {
return nil, false
}
- return o.ConnectableDatacenters, true
+ return o.Peers, true
}
-// SetConnectableDatacenters sets field value
-func (o *PrivateCrossConnectProperties) SetConnectableDatacenters(v []ConnectableDatacenter) {
+// SetPeers sets field value
+func (o *PrivateCrossConnectProperties) SetPeers(v []Peer) {
- o.ConnectableDatacenters = &v
+ o.Peers = &v
}
-// HasConnectableDatacenters returns a boolean if a field has been set.
-func (o *PrivateCrossConnectProperties) HasConnectableDatacenters() bool {
- if o != nil && o.ConnectableDatacenters != nil {
+// HasPeers returns a boolean if a field has been set.
+func (o *PrivateCrossConnectProperties) HasPeers() bool {
+ if o != nil && o.Peers != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *PrivateCrossConnectProperties) HasConnectableDatacenters() bool {
func (o PrivateCrossConnectProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
+ if o.ConnectableDatacenters != nil {
+ toSerialize["connectableDatacenters"] = o.ConnectableDatacenters
}
+
if o.Description != nil {
toSerialize["description"] = o.Description
}
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
if o.Peers != nil {
toSerialize["peers"] = o.Peers
}
- if o.ConnectableDatacenters != nil {
- toSerialize["connectableDatacenters"] = o.ConnectableDatacenters
- }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_private_cross_connects.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_private_cross_connects.go
index 7112f9a35aa..3c82ad39f7e 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_private_cross_connects.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_private_cross_connects.go
@@ -16,14 +16,14 @@ import (
// PrivateCrossConnects struct for PrivateCrossConnects
type PrivateCrossConnects struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]PrivateCrossConnect `json:"items,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewPrivateCrossConnects instantiates a new PrivateCrossConnects object
@@ -44,152 +44,152 @@ func NewPrivateCrossConnectsWithDefaults() *PrivateCrossConnects {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *PrivateCrossConnects) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *PrivateCrossConnects) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PrivateCrossConnects) GetIdOk() (*string, bool) {
+func (o *PrivateCrossConnects) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *PrivateCrossConnects) SetId(v string) {
+// SetHref sets field value
+func (o *PrivateCrossConnects) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *PrivateCrossConnects) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *PrivateCrossConnects) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *PrivateCrossConnects) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *PrivateCrossConnects) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PrivateCrossConnects) GetTypeOk() (*Type, bool) {
+func (o *PrivateCrossConnects) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *PrivateCrossConnects) SetType(v Type) {
+// SetId sets field value
+func (o *PrivateCrossConnects) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *PrivateCrossConnects) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *PrivateCrossConnects) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *PrivateCrossConnects) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *PrivateCrossConnects) GetItems() *[]PrivateCrossConnect {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PrivateCrossConnects) GetHrefOk() (*string, bool) {
+func (o *PrivateCrossConnects) GetItemsOk() (*[]PrivateCrossConnect, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *PrivateCrossConnects) SetHref(v string) {
+// SetItems sets field value
+func (o *PrivateCrossConnects) SetItems(v []PrivateCrossConnect) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *PrivateCrossConnects) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *PrivateCrossConnects) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []PrivateCrossConnect will be returned
-func (o *PrivateCrossConnects) GetItems() *[]PrivateCrossConnect {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *PrivateCrossConnects) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *PrivateCrossConnects) GetItemsOk() (*[]PrivateCrossConnect, bool) {
+func (o *PrivateCrossConnects) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *PrivateCrossConnects) SetItems(v []PrivateCrossConnect) {
+// SetType sets field value
+func (o *PrivateCrossConnects) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *PrivateCrossConnects) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *PrivateCrossConnects) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *PrivateCrossConnects) HasItems() bool {
func (o PrivateCrossConnects) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_remote_console_url.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_remote_console_url.go
index 4088c7a8c36..74f96ce383d 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_remote_console_url.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_remote_console_url.go
@@ -39,7 +39,7 @@ func NewRemoteConsoleUrlWithDefaults() *RemoteConsoleUrl {
}
// GetUrl returns the Url field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *RemoteConsoleUrl) GetUrl() *string {
if o == nil {
return nil
@@ -81,6 +81,7 @@ func (o RemoteConsoleUrl) MarshalJSON() ([]byte, error) {
if o.Url != nil {
toSerialize["url"] = o.Url
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_request.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_request.go
index 5ac4f4851d1..adc351ff954 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_request.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_request.go
@@ -16,14 +16,14 @@ import (
// Request struct for Request
type Request struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *RequestMetadata `json:"metadata,omitempty"`
Properties *RequestProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewRequest instantiates a new Request object
@@ -46,190 +46,190 @@ func NewRequestWithDefaults() *Request {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Request) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Request) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Request) GetIdOk() (*string, bool) {
+func (o *Request) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Request) SetId(v string) {
+// SetHref sets field value
+func (o *Request) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Request) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Request) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Request) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Request) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Request) GetTypeOk() (*Type, bool) {
+func (o *Request) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Request) SetType(v Type) {
+// SetId sets field value
+func (o *Request) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Request) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Request) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Request) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *Request) GetMetadata() *RequestMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Request) GetHrefOk() (*string, bool) {
+func (o *Request) GetMetadataOk() (*RequestMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *Request) SetHref(v string) {
+// SetMetadata sets field value
+func (o *Request) SetMetadata(v RequestMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Request) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *Request) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for RequestMetadata will be returned
-func (o *Request) GetMetadata() *RequestMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *Request) GetProperties() *RequestProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Request) GetMetadataOk() (*RequestMetadata, bool) {
+func (o *Request) GetPropertiesOk() (*RequestProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *Request) SetMetadata(v RequestMetadata) {
+// SetProperties sets field value
+func (o *Request) SetProperties(v RequestProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *Request) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *Request) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for RequestProperties will be returned
-func (o *Request) GetProperties() *RequestProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Request) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Request) GetPropertiesOk() (*RequestProperties, bool) {
+func (o *Request) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *Request) SetProperties(v RequestProperties) {
+// SetType sets field value
+func (o *Request) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *Request) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Request) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *Request) HasProperties() bool {
func (o Request) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_metadata.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_metadata.go
index 3ea319b3132..1b634615ec4 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_metadata.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_metadata.go
@@ -17,10 +17,10 @@ import (
// RequestMetadata struct for RequestMetadata
type RequestMetadata struct {
- // The last time the resource was created.
- CreatedDate *IonosTime
// The user who created the resource.
CreatedBy *string `json:"createdBy,omitempty"`
+ // The last time the resource was created.
+ CreatedDate *IonosTime
// Resource's Entity Tag as defined in http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.11 Entity Tag is also added as an 'ETag response header to requests which don't use 'depth' parameter.
Etag *string `json:"etag,omitempty"`
RequestStatus *RequestStatus `json:"requestStatus,omitempty"`
@@ -44,83 +44,83 @@ func NewRequestMetadataWithDefaults() *RequestMetadata {
return &this
}
-// GetCreatedDate returns the CreatedDate field value
-// If the value is explicit nil, the zero value for time.Time will be returned
-func (o *RequestMetadata) GetCreatedDate() *time.Time {
+// GetCreatedBy returns the CreatedBy field value
+// If the value is explicit nil, nil is returned
+func (o *RequestMetadata) GetCreatedBy() *string {
if o == nil {
return nil
}
- if o.CreatedDate == nil {
- return nil
- }
- return &o.CreatedDate.Time
+ return o.CreatedBy
}
-// GetCreatedDateOk returns a tuple with the CreatedDate field value
+// GetCreatedByOk returns a tuple with the CreatedBy field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *RequestMetadata) GetCreatedDateOk() (*time.Time, bool) {
+func (o *RequestMetadata) GetCreatedByOk() (*string, bool) {
if o == nil {
return nil, false
}
- if o.CreatedDate == nil {
- return nil, false
- }
- return &o.CreatedDate.Time, true
-
+ return o.CreatedBy, true
}
-// SetCreatedDate sets field value
-func (o *RequestMetadata) SetCreatedDate(v time.Time) {
+// SetCreatedBy sets field value
+func (o *RequestMetadata) SetCreatedBy(v string) {
- o.CreatedDate = &IonosTime{v}
+ o.CreatedBy = &v
}
-// HasCreatedDate returns a boolean if a field has been set.
-func (o *RequestMetadata) HasCreatedDate() bool {
- if o != nil && o.CreatedDate != nil {
+// HasCreatedBy returns a boolean if a field has been set.
+func (o *RequestMetadata) HasCreatedBy() bool {
+ if o != nil && o.CreatedBy != nil {
return true
}
return false
}
-// GetCreatedBy returns the CreatedBy field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *RequestMetadata) GetCreatedBy() *string {
+// GetCreatedDate returns the CreatedDate field value
+// If the value is explicit nil, nil is returned
+func (o *RequestMetadata) GetCreatedDate() *time.Time {
if o == nil {
return nil
}
- return o.CreatedBy
+ if o.CreatedDate == nil {
+ return nil
+ }
+ return &o.CreatedDate.Time
}
-// GetCreatedByOk returns a tuple with the CreatedBy field value
+// GetCreatedDateOk returns a tuple with the CreatedDate field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *RequestMetadata) GetCreatedByOk() (*string, bool) {
+func (o *RequestMetadata) GetCreatedDateOk() (*time.Time, bool) {
if o == nil {
return nil, false
}
- return o.CreatedBy, true
+ if o.CreatedDate == nil {
+ return nil, false
+ }
+ return &o.CreatedDate.Time, true
+
}
-// SetCreatedBy sets field value
-func (o *RequestMetadata) SetCreatedBy(v string) {
+// SetCreatedDate sets field value
+func (o *RequestMetadata) SetCreatedDate(v time.Time) {
- o.CreatedBy = &v
+ o.CreatedDate = &IonosTime{v}
}
-// HasCreatedBy returns a boolean if a field has been set.
-func (o *RequestMetadata) HasCreatedBy() bool {
- if o != nil && o.CreatedBy != nil {
+// HasCreatedDate returns a boolean if a field has been set.
+func (o *RequestMetadata) HasCreatedDate() bool {
+ if o != nil && o.CreatedDate != nil {
return true
}
@@ -128,7 +128,7 @@ func (o *RequestMetadata) HasCreatedBy() bool {
}
// GetEtag returns the Etag field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *RequestMetadata) GetEtag() *string {
if o == nil {
return nil
@@ -166,7 +166,7 @@ func (o *RequestMetadata) HasEtag() bool {
}
// GetRequestStatus returns the RequestStatus field value
-// If the value is explicit nil, the zero value for RequestStatus will be returned
+// If the value is explicit nil, nil is returned
func (o *RequestMetadata) GetRequestStatus() *RequestStatus {
if o == nil {
return nil
@@ -205,18 +205,22 @@ func (o *RequestMetadata) HasRequestStatus() bool {
func (o RequestMetadata) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.CreatedDate != nil {
- toSerialize["createdDate"] = o.CreatedDate
- }
if o.CreatedBy != nil {
toSerialize["createdBy"] = o.CreatedBy
}
+
+ if o.CreatedDate != nil {
+ toSerialize["createdDate"] = o.CreatedDate
+ }
+
if o.Etag != nil {
toSerialize["etag"] = o.Etag
}
+
if o.RequestStatus != nil {
toSerialize["requestStatus"] = o.RequestStatus
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_properties.go
index 94d04093970..e43b39d983b 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_properties.go
@@ -16,9 +16,9 @@ import (
// RequestProperties struct for RequestProperties
type RequestProperties struct {
- Method *string `json:"method,omitempty"`
- Headers *map[string]string `json:"headers,omitempty"`
Body *string `json:"body,omitempty"`
+ Headers *map[string]string `json:"headers,omitempty"`
+ Method *string `json:"method,omitempty"`
Url *string `json:"url,omitempty"`
}
@@ -40,38 +40,38 @@ func NewRequestPropertiesWithDefaults() *RequestProperties {
return &this
}
-// GetMethod returns the Method field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *RequestProperties) GetMethod() *string {
+// GetBody returns the Body field value
+// If the value is explicit nil, nil is returned
+func (o *RequestProperties) GetBody() *string {
if o == nil {
return nil
}
- return o.Method
+ return o.Body
}
-// GetMethodOk returns a tuple with the Method field value
+// GetBodyOk returns a tuple with the Body field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *RequestProperties) GetMethodOk() (*string, bool) {
+func (o *RequestProperties) GetBodyOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Method, true
+ return o.Body, true
}
-// SetMethod sets field value
-func (o *RequestProperties) SetMethod(v string) {
+// SetBody sets field value
+func (o *RequestProperties) SetBody(v string) {
- o.Method = &v
+ o.Body = &v
}
-// HasMethod returns a boolean if a field has been set.
-func (o *RequestProperties) HasMethod() bool {
- if o != nil && o.Method != nil {
+// HasBody returns a boolean if a field has been set.
+func (o *RequestProperties) HasBody() bool {
+ if o != nil && o.Body != nil {
return true
}
@@ -79,7 +79,7 @@ func (o *RequestProperties) HasMethod() bool {
}
// GetHeaders returns the Headers field value
-// If the value is explicit nil, the zero value for map[string]string will be returned
+// If the value is explicit nil, nil is returned
func (o *RequestProperties) GetHeaders() *map[string]string {
if o == nil {
return nil
@@ -116,38 +116,38 @@ func (o *RequestProperties) HasHeaders() bool {
return false
}
-// GetBody returns the Body field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *RequestProperties) GetBody() *string {
+// GetMethod returns the Method field value
+// If the value is explicit nil, nil is returned
+func (o *RequestProperties) GetMethod() *string {
if o == nil {
return nil
}
- return o.Body
+ return o.Method
}
-// GetBodyOk returns a tuple with the Body field value
+// GetMethodOk returns a tuple with the Method field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *RequestProperties) GetBodyOk() (*string, bool) {
+func (o *RequestProperties) GetMethodOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Body, true
+ return o.Method, true
}
-// SetBody sets field value
-func (o *RequestProperties) SetBody(v string) {
+// SetMethod sets field value
+func (o *RequestProperties) SetMethod(v string) {
- o.Body = &v
+ o.Method = &v
}
-// HasBody returns a boolean if a field has been set.
-func (o *RequestProperties) HasBody() bool {
- if o != nil && o.Body != nil {
+// HasMethod returns a boolean if a field has been set.
+func (o *RequestProperties) HasMethod() bool {
+ if o != nil && o.Method != nil {
return true
}
@@ -155,7 +155,7 @@ func (o *RequestProperties) HasBody() bool {
}
// GetUrl returns the Url field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *RequestProperties) GetUrl() *string {
if o == nil {
return nil
@@ -194,18 +194,22 @@ func (o *RequestProperties) HasUrl() bool {
func (o RequestProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Method != nil {
- toSerialize["method"] = o.Method
+ if o.Body != nil {
+ toSerialize["body"] = o.Body
}
+
if o.Headers != nil {
toSerialize["headers"] = o.Headers
}
- if o.Body != nil {
- toSerialize["body"] = o.Body
+
+ if o.Method != nil {
+ toSerialize["method"] = o.Method
}
+
if o.Url != nil {
toSerialize["url"] = o.Url
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_status.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_status.go
index e772df8e640..f4ca3ceeffe 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_status.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_status.go
@@ -16,13 +16,13 @@ import (
// RequestStatus struct for RequestStatus
type RequestStatus struct {
+ // URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
- Id *string `json:"id,omitempty"`
+ Id *string `json:"id,omitempty"`
+ Metadata *RequestStatusMetadata `json:"metadata,omitempty"`
// The type of object that has been created.
Type *Type `json:"type,omitempty"`
- // URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
- Metadata *RequestStatusMetadata `json:"metadata,omitempty"`
}
// NewRequestStatus instantiates a new RequestStatus object
@@ -43,152 +43,152 @@ func NewRequestStatusWithDefaults() *RequestStatus {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *RequestStatus) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *RequestStatus) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *RequestStatus) GetIdOk() (*string, bool) {
+func (o *RequestStatus) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *RequestStatus) SetId(v string) {
+// SetHref sets field value
+func (o *RequestStatus) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *RequestStatus) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *RequestStatus) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *RequestStatus) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *RequestStatus) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *RequestStatus) GetTypeOk() (*Type, bool) {
+func (o *RequestStatus) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *RequestStatus) SetType(v Type) {
+// SetId sets field value
+func (o *RequestStatus) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *RequestStatus) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *RequestStatus) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *RequestStatus) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *RequestStatus) GetMetadata() *RequestStatusMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *RequestStatus) GetHrefOk() (*string, bool) {
+func (o *RequestStatus) GetMetadataOk() (*RequestStatusMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *RequestStatus) SetHref(v string) {
+// SetMetadata sets field value
+func (o *RequestStatus) SetMetadata(v RequestStatusMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *RequestStatus) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *RequestStatus) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for RequestStatusMetadata will be returned
-func (o *RequestStatus) GetMetadata() *RequestStatusMetadata {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *RequestStatus) GetType() *Type {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Type
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *RequestStatus) GetMetadataOk() (*RequestStatusMetadata, bool) {
+func (o *RequestStatus) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Type, true
}
-// SetMetadata sets field value
-func (o *RequestStatus) SetMetadata(v RequestStatusMetadata) {
+// SetType sets field value
+func (o *RequestStatus) SetType(v Type) {
- o.Metadata = &v
+ o.Type = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *RequestStatus) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasType returns a boolean if a field has been set.
+func (o *RequestStatus) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -197,18 +197,22 @@ func (o *RequestStatus) HasMetadata() bool {
func (o RequestStatus) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_status_metadata.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_status_metadata.go
index ef97dbedb13..29b9967c852 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_status_metadata.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_status_metadata.go
@@ -16,10 +16,10 @@ import (
// RequestStatusMetadata struct for RequestStatusMetadata
type RequestStatusMetadata struct {
- Status *string `json:"status,omitempty"`
- Message *string `json:"message,omitempty"`
// Resource's Entity Tag as defined in http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.11 Entity Tag is also added as an 'ETag response header to requests which don't use 'depth' parameter.
Etag *string `json:"etag,omitempty"`
+ Message *string `json:"message,omitempty"`
+ Status *string `json:"status,omitempty"`
Targets *[]RequestTarget `json:"targets,omitempty"`
}
@@ -41,38 +41,38 @@ func NewRequestStatusMetadataWithDefaults() *RequestStatusMetadata {
return &this
}
-// GetStatus returns the Status field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *RequestStatusMetadata) GetStatus() *string {
+// GetEtag returns the Etag field value
+// If the value is explicit nil, nil is returned
+func (o *RequestStatusMetadata) GetEtag() *string {
if o == nil {
return nil
}
- return o.Status
+ return o.Etag
}
-// GetStatusOk returns a tuple with the Status field value
+// GetEtagOk returns a tuple with the Etag field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *RequestStatusMetadata) GetStatusOk() (*string, bool) {
+func (o *RequestStatusMetadata) GetEtagOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Status, true
+ return o.Etag, true
}
-// SetStatus sets field value
-func (o *RequestStatusMetadata) SetStatus(v string) {
+// SetEtag sets field value
+func (o *RequestStatusMetadata) SetEtag(v string) {
- o.Status = &v
+ o.Etag = &v
}
-// HasStatus returns a boolean if a field has been set.
-func (o *RequestStatusMetadata) HasStatus() bool {
- if o != nil && o.Status != nil {
+// HasEtag returns a boolean if a field has been set.
+func (o *RequestStatusMetadata) HasEtag() bool {
+ if o != nil && o.Etag != nil {
return true
}
@@ -80,7 +80,7 @@ func (o *RequestStatusMetadata) HasStatus() bool {
}
// GetMessage returns the Message field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *RequestStatusMetadata) GetMessage() *string {
if o == nil {
return nil
@@ -117,38 +117,38 @@ func (o *RequestStatusMetadata) HasMessage() bool {
return false
}
-// GetEtag returns the Etag field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *RequestStatusMetadata) GetEtag() *string {
+// GetStatus returns the Status field value
+// If the value is explicit nil, nil is returned
+func (o *RequestStatusMetadata) GetStatus() *string {
if o == nil {
return nil
}
- return o.Etag
+ return o.Status
}
-// GetEtagOk returns a tuple with the Etag field value
+// GetStatusOk returns a tuple with the Status field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *RequestStatusMetadata) GetEtagOk() (*string, bool) {
+func (o *RequestStatusMetadata) GetStatusOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Etag, true
+ return o.Status, true
}
-// SetEtag sets field value
-func (o *RequestStatusMetadata) SetEtag(v string) {
+// SetStatus sets field value
+func (o *RequestStatusMetadata) SetStatus(v string) {
- o.Etag = &v
+ o.Status = &v
}
-// HasEtag returns a boolean if a field has been set.
-func (o *RequestStatusMetadata) HasEtag() bool {
- if o != nil && o.Etag != nil {
+// HasStatus returns a boolean if a field has been set.
+func (o *RequestStatusMetadata) HasStatus() bool {
+ if o != nil && o.Status != nil {
return true
}
@@ -156,7 +156,7 @@ func (o *RequestStatusMetadata) HasEtag() bool {
}
// GetTargets returns the Targets field value
-// If the value is explicit nil, the zero value for []RequestTarget will be returned
+// If the value is explicit nil, nil is returned
func (o *RequestStatusMetadata) GetTargets() *[]RequestTarget {
if o == nil {
return nil
@@ -195,18 +195,22 @@ func (o *RequestStatusMetadata) HasTargets() bool {
func (o RequestStatusMetadata) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Status != nil {
- toSerialize["status"] = o.Status
+ if o.Etag != nil {
+ toSerialize["etag"] = o.Etag
}
+
if o.Message != nil {
toSerialize["message"] = o.Message
}
- if o.Etag != nil {
- toSerialize["etag"] = o.Etag
+
+ if o.Status != nil {
+ toSerialize["status"] = o.Status
}
+
if o.Targets != nil {
toSerialize["targets"] = o.Targets
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_target.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_target.go
index 590a5dfae8a..dc56f80ab63 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_target.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_request_target.go
@@ -16,8 +16,8 @@ import (
// RequestTarget struct for RequestTarget
type RequestTarget struct {
- Target *ResourceReference `json:"target,omitempty"`
Status *string `json:"status,omitempty"`
+ Target *ResourceReference `json:"target,omitempty"`
}
// NewRequestTarget instantiates a new RequestTarget object
@@ -38,76 +38,76 @@ func NewRequestTargetWithDefaults() *RequestTarget {
return &this
}
-// GetTarget returns the Target field value
-// If the value is explicit nil, the zero value for ResourceReference will be returned
-func (o *RequestTarget) GetTarget() *ResourceReference {
+// GetStatus returns the Status field value
+// If the value is explicit nil, nil is returned
+func (o *RequestTarget) GetStatus() *string {
if o == nil {
return nil
}
- return o.Target
+ return o.Status
}
-// GetTargetOk returns a tuple with the Target field value
+// GetStatusOk returns a tuple with the Status field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *RequestTarget) GetTargetOk() (*ResourceReference, bool) {
+func (o *RequestTarget) GetStatusOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Target, true
+ return o.Status, true
}
-// SetTarget sets field value
-func (o *RequestTarget) SetTarget(v ResourceReference) {
+// SetStatus sets field value
+func (o *RequestTarget) SetStatus(v string) {
- o.Target = &v
+ o.Status = &v
}
-// HasTarget returns a boolean if a field has been set.
-func (o *RequestTarget) HasTarget() bool {
- if o != nil && o.Target != nil {
+// HasStatus returns a boolean if a field has been set.
+func (o *RequestTarget) HasStatus() bool {
+ if o != nil && o.Status != nil {
return true
}
return false
}
-// GetStatus returns the Status field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *RequestTarget) GetStatus() *string {
+// GetTarget returns the Target field value
+// If the value is explicit nil, nil is returned
+func (o *RequestTarget) GetTarget() *ResourceReference {
if o == nil {
return nil
}
- return o.Status
+ return o.Target
}
-// GetStatusOk returns a tuple with the Status field value
+// GetTargetOk returns a tuple with the Target field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *RequestTarget) GetStatusOk() (*string, bool) {
+func (o *RequestTarget) GetTargetOk() (*ResourceReference, bool) {
if o == nil {
return nil, false
}
- return o.Status, true
+ return o.Target, true
}
-// SetStatus sets field value
-func (o *RequestTarget) SetStatus(v string) {
+// SetTarget sets field value
+func (o *RequestTarget) SetTarget(v ResourceReference) {
- o.Status = &v
+ o.Target = &v
}
-// HasStatus returns a boolean if a field has been set.
-func (o *RequestTarget) HasStatus() bool {
- if o != nil && o.Status != nil {
+// HasTarget returns a boolean if a field has been set.
+func (o *RequestTarget) HasTarget() bool {
+ if o != nil && o.Target != nil {
return true
}
@@ -116,12 +116,14 @@ func (o *RequestTarget) HasStatus() bool {
func (o RequestTarget) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Target != nil {
- toSerialize["target"] = o.Target
- }
if o.Status != nil {
toSerialize["status"] = o.Status
}
+
+ if o.Target != nil {
+ toSerialize["target"] = o.Target
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_requests.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_requests.go
index 3d67bdc8188..0bf44ade828 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_requests.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_requests.go
@@ -16,31 +16,31 @@ import (
// Requests struct for Requests
type Requests struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Request `json:"items,omitempty"`
+ // The limit, specified in the request (if not specified, the endpoint's default pagination limit is used).
+ Limit *float32 `json:"limit"`
// The offset, specified in the request (if not is specified, 0 is used by default).
Offset *float32 `json:"offset"`
- // The limit, specified in the request (if not specified, the endpoint's default pagination limit is used).
- Limit *float32 `json:"limit"`
- Links *PaginationLinks `json:"_links"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewRequests instantiates a new Requests object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewRequests(offset float32, limit float32, links PaginationLinks) *Requests {
+func NewRequests(links PaginationLinks, limit float32, offset float32) *Requests {
this := Requests{}
- this.Offset = &offset
- this.Limit = &limit
this.Links = &links
+ this.Limit = &limit
+ this.Offset = &offset
return &this
}
@@ -53,114 +53,114 @@ func NewRequestsWithDefaults() *Requests {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Requests) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *Requests) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Requests) GetIdOk() (*string, bool) {
+func (o *Requests) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *Requests) SetId(v string) {
+// SetLinks sets field value
+func (o *Requests) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Requests) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *Requests) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Requests) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Requests) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Requests) GetTypeOk() (*Type, bool) {
+func (o *Requests) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Requests) SetType(v Type) {
+// SetHref sets field value
+func (o *Requests) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Requests) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Requests) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Requests) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Requests) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Requests) GetHrefOk() (*string, bool) {
+func (o *Requests) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Requests) SetHref(v string) {
+// SetId sets field value
+func (o *Requests) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Requests) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Requests) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -168,7 +168,7 @@ func (o *Requests) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Request will be returned
+// If the value is explicit nil, nil is returned
func (o *Requests) GetItems() *[]Request {
if o == nil {
return nil
@@ -205,114 +205,114 @@ func (o *Requests) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Requests) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *Requests) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Requests) GetOffsetOk() (*float32, bool) {
+func (o *Requests) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *Requests) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *Requests) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *Requests) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *Requests) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Requests) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *Requests) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Requests) GetLimitOk() (*float32, bool) {
+func (o *Requests) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *Requests) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *Requests) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *Requests) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *Requests) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *Requests) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Requests) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Requests) GetLinksOk() (*PaginationLinks, bool) {
+func (o *Requests) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *Requests) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *Requests) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *Requests) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Requests) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -321,27 +321,34 @@ func (o *Requests) HasLinks() bool {
func (o Requests) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource.go
index 1d370ce223e..82b8f739d8f 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource.go
@@ -16,15 +16,15 @@ import (
// Resource datacenter resource representation
type Resource struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of the resource.
- Type *Type `json:"type,omitempty"`
+ Entities *ResourceEntities `json:"entities,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *ResourceProperties `json:"properties,omitempty"`
- Entities *ResourceEntities `json:"entities,omitempty"`
+ // The type of the resource.
+ Type *Type `json:"type,omitempty"`
}
// NewResource instantiates a new Resource object
@@ -45,114 +45,114 @@ func NewResourceWithDefaults() *Resource {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Resource) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *Resource) GetEntities() *ResourceEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Resource) GetIdOk() (*string, bool) {
+func (o *Resource) GetEntitiesOk() (*ResourceEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *Resource) SetId(v string) {
+// SetEntities sets field value
+func (o *Resource) SetEntities(v ResourceEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Resource) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *Resource) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Resource) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Resource) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Resource) GetTypeOk() (*Type, bool) {
+func (o *Resource) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Resource) SetType(v Type) {
+// SetHref sets field value
+func (o *Resource) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Resource) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Resource) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Resource) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Resource) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Resource) GetHrefOk() (*string, bool) {
+func (o *Resource) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Resource) SetHref(v string) {
+// SetId sets field value
+func (o *Resource) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Resource) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Resource) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -160,7 +160,7 @@ func (o *Resource) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *Resource) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
@@ -198,7 +198,7 @@ func (o *Resource) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for ResourceProperties will be returned
+// If the value is explicit nil, nil is returned
func (o *Resource) GetProperties() *ResourceProperties {
if o == nil {
return nil
@@ -235,38 +235,38 @@ func (o *Resource) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for ResourceEntities will be returned
-func (o *Resource) GetEntities() *ResourceEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Resource) GetType() *Type {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Resource) GetEntitiesOk() (*ResourceEntities, bool) {
+func (o *Resource) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *Resource) SetEntities(v ResourceEntities) {
+// SetType sets field value
+func (o *Resource) SetType(v Type) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *Resource) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Resource) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -275,24 +275,30 @@ func (o *Resource) HasEntities() bool {
func (o Resource) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_entities.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_entities.go
index cc9f26acb02..735ffe73b17 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_entities.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_entities.go
@@ -38,7 +38,7 @@ func NewResourceEntitiesWithDefaults() *ResourceEntities {
}
// GetGroups returns the Groups field value
-// If the value is explicit nil, the zero value for ResourceGroups will be returned
+// If the value is explicit nil, nil is returned
func (o *ResourceEntities) GetGroups() *ResourceGroups {
if o == nil {
return nil
@@ -80,6 +80,7 @@ func (o ResourceEntities) MarshalJSON() ([]byte, error) {
if o.Groups != nil {
toSerialize["groups"] = o.Groups
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_groups.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_groups.go
index ae8939261cf..8d0a2a1a6a0 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_groups.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_groups.go
@@ -16,14 +16,14 @@ import (
// ResourceGroups Resources assigned to this group.
type ResourceGroups struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of the resource.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Resource `json:"items,omitempty"`
+ // The type of the resource.
+ Type *Type `json:"type,omitempty"`
}
// NewResourceGroups instantiates a new ResourceGroups object
@@ -44,152 +44,152 @@ func NewResourceGroupsWithDefaults() *ResourceGroups {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ResourceGroups) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceGroups) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceGroups) GetIdOk() (*string, bool) {
+func (o *ResourceGroups) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *ResourceGroups) SetId(v string) {
+// SetHref sets field value
+func (o *ResourceGroups) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *ResourceGroups) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *ResourceGroups) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *ResourceGroups) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceGroups) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceGroups) GetTypeOk() (*Type, bool) {
+func (o *ResourceGroups) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *ResourceGroups) SetType(v Type) {
+// SetId sets field value
+func (o *ResourceGroups) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *ResourceGroups) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *ResourceGroups) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ResourceGroups) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceGroups) GetItems() *[]Resource {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceGroups) GetHrefOk() (*string, bool) {
+func (o *ResourceGroups) GetItemsOk() (*[]Resource, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *ResourceGroups) SetHref(v string) {
+// SetItems sets field value
+func (o *ResourceGroups) SetItems(v []Resource) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *ResourceGroups) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *ResourceGroups) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Resource will be returned
-func (o *ResourceGroups) GetItems() *[]Resource {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceGroups) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceGroups) GetItemsOk() (*[]Resource, bool) {
+func (o *ResourceGroups) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *ResourceGroups) SetItems(v []Resource) {
+// SetType sets field value
+func (o *ResourceGroups) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *ResourceGroups) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *ResourceGroups) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *ResourceGroups) HasItems() bool {
func (o ResourceGroups) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_limits.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_limits.go
index 8dbbe386e6b..ca9ee840057 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_limits.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_limits.go
@@ -16,81 +16,81 @@ import (
// ResourceLimits struct for ResourceLimits
type ResourceLimits struct {
- // The maximum number of CPU cores per server.
- CoresPerServer *int32 `json:"coresPerServer"`
// The maximum number of CPU cores per contract.
CoresPerContract *int32 `json:"coresPerContract"`
+ // The maximum number of CPU cores per server.
+ CoresPerServer *int32 `json:"coresPerServer"`
// The number of CPU cores provisioned.
CoresProvisioned *int32 `json:"coresProvisioned"`
- // The maximum amount of RAM (in MB) that can be provisioned for a particular server under this contract.
- RamPerServer *int32 `json:"ramPerServer"`
- // The maximum amount of RAM (in MB) that can be provisioned under this contract.
- RamPerContract *int32 `json:"ramPerContract"`
- // The amount of RAM (in MB) provisioned under this contract.
- RamProvisioned *int32 `json:"ramProvisioned"`
- // The maximum size (in MB) of an idividual hard disk volume.
- HddLimitPerVolume *int64 `json:"hddLimitPerVolume"`
+ // The amount of DAS disk space (in MB) in a Cube server that is currently provisioned.
+ DasVolumeProvisioned *int64 `json:"dasVolumeProvisioned"`
// The maximum amount of disk space (in MB) that can be provided under this contract.
HddLimitPerContract *int64 `json:"hddLimitPerContract"`
+ // The maximum size (in MB) of an idividual hard disk volume.
+ HddLimitPerVolume *int64 `json:"hddLimitPerVolume"`
// The amount of hard disk space (in MB) that is currently provisioned.
HddVolumeProvisioned *int64 `json:"hddVolumeProvisioned"`
- // The maximum size (in MB) of an individual solid state disk volume.
- SsdLimitPerVolume *int64 `json:"ssdLimitPerVolume"`
- // The maximum amount of solid state disk space (in MB) that can be provisioned under this contract.
- SsdLimitPerContract *int64 `json:"ssdLimitPerContract"`
- // The amount of solid state disk space (in MB) that is currently provisioned.
- SsdVolumeProvisioned *int64 `json:"ssdVolumeProvisioned"`
- // The amount of DAS disk space (in MB) in a Cube server that is currently provisioned.
- DasVolumeProvisioned *int64 `json:"dasVolumeProvisioned"`
- // The maximum number of static public IP addresses that can be reserved by this customer across contracts.
- ReservableIps *int32 `json:"reservableIps"`
- // The maximum number of static public IP addresses that can be reserved for this contract.
- ReservedIpsOnContract *int32 `json:"reservedIpsOnContract"`
- // The number of static public IP addresses in use.
- ReservedIpsInUse *int32 `json:"reservedIpsInUse"`
// The maximum number of Kubernetes clusters that can be created under this contract.
K8sClusterLimitTotal *int32 `json:"k8sClusterLimitTotal"`
// The amount of Kubernetes clusters that is currently provisioned.
K8sClustersProvisioned *int32 `json:"k8sClustersProvisioned"`
- // The NLB total limit.
- NlbLimitTotal *int32 `json:"nlbLimitTotal"`
- // The NLBs provisioned.
- NlbProvisioned *int32 `json:"nlbProvisioned"`
// The NAT Gateway total limit.
NatGatewayLimitTotal *int32 `json:"natGatewayLimitTotal"`
// The NAT Gateways provisioned.
NatGatewayProvisioned *int32 `json:"natGatewayProvisioned"`
+ // The NLB total limit.
+ NlbLimitTotal *int32 `json:"nlbLimitTotal"`
+ // The NLBs provisioned.
+ NlbProvisioned *int32 `json:"nlbProvisioned"`
+ // The maximum amount of RAM (in MB) that can be provisioned under this contract.
+ RamPerContract *int32 `json:"ramPerContract"`
+ // The maximum amount of RAM (in MB) that can be provisioned for a particular server under this contract.
+ RamPerServer *int32 `json:"ramPerServer"`
+ // The amount of RAM (in MB) provisioned under this contract.
+ RamProvisioned *int32 `json:"ramProvisioned"`
+ // The maximum number of static public IP addresses that can be reserved by this customer across contracts.
+ ReservableIps *int32 `json:"reservableIps"`
+ // The number of static public IP addresses in use.
+ ReservedIpsInUse *int32 `json:"reservedIpsInUse"`
+ // The maximum number of static public IP addresses that can be reserved for this contract.
+ ReservedIpsOnContract *int32 `json:"reservedIpsOnContract"`
+ // The maximum amount of solid state disk space (in MB) that can be provisioned under this contract.
+ SsdLimitPerContract *int64 `json:"ssdLimitPerContract"`
+ // The maximum size (in MB) of an individual solid state disk volume.
+ SsdLimitPerVolume *int64 `json:"ssdLimitPerVolume"`
+ // The amount of solid state disk space (in MB) that is currently provisioned.
+ SsdVolumeProvisioned *int64 `json:"ssdVolumeProvisioned"`
}
// NewResourceLimits instantiates a new ResourceLimits object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewResourceLimits(coresPerServer int32, coresPerContract int32, coresProvisioned int32, ramPerServer int32, ramPerContract int32, ramProvisioned int32, hddLimitPerVolume int64, hddLimitPerContract int64, hddVolumeProvisioned int64, ssdLimitPerVolume int64, ssdLimitPerContract int64, ssdVolumeProvisioned int64, dasVolumeProvisioned int64, reservableIps int32, reservedIpsOnContract int32, reservedIpsInUse int32, k8sClusterLimitTotal int32, k8sClustersProvisioned int32, nlbLimitTotal int32, nlbProvisioned int32, natGatewayLimitTotal int32, natGatewayProvisioned int32) *ResourceLimits {
+func NewResourceLimits(coresPerContract int32, coresPerServer int32, coresProvisioned int32, dasVolumeProvisioned int64, hddLimitPerContract int64, hddLimitPerVolume int64, hddVolumeProvisioned int64, k8sClusterLimitTotal int32, k8sClustersProvisioned int32, natGatewayLimitTotal int32, natGatewayProvisioned int32, nlbLimitTotal int32, nlbProvisioned int32, ramPerContract int32, ramPerServer int32, ramProvisioned int32, reservableIps int32, reservedIpsInUse int32, reservedIpsOnContract int32, ssdLimitPerContract int64, ssdLimitPerVolume int64, ssdVolumeProvisioned int64) *ResourceLimits {
this := ResourceLimits{}
- this.CoresPerServer = &coresPerServer
this.CoresPerContract = &coresPerContract
+ this.CoresPerServer = &coresPerServer
this.CoresProvisioned = &coresProvisioned
- this.RamPerServer = &ramPerServer
- this.RamPerContract = &ramPerContract
- this.RamProvisioned = &ramProvisioned
- this.HddLimitPerVolume = &hddLimitPerVolume
+ this.DasVolumeProvisioned = &dasVolumeProvisioned
this.HddLimitPerContract = &hddLimitPerContract
+ this.HddLimitPerVolume = &hddLimitPerVolume
this.HddVolumeProvisioned = &hddVolumeProvisioned
- this.SsdLimitPerVolume = &ssdLimitPerVolume
- this.SsdLimitPerContract = &ssdLimitPerContract
- this.SsdVolumeProvisioned = &ssdVolumeProvisioned
- this.DasVolumeProvisioned = &dasVolumeProvisioned
- this.ReservableIps = &reservableIps
- this.ReservedIpsOnContract = &reservedIpsOnContract
- this.ReservedIpsInUse = &reservedIpsInUse
this.K8sClusterLimitTotal = &k8sClusterLimitTotal
this.K8sClustersProvisioned = &k8sClustersProvisioned
- this.NlbLimitTotal = &nlbLimitTotal
- this.NlbProvisioned = &nlbProvisioned
this.NatGatewayLimitTotal = &natGatewayLimitTotal
this.NatGatewayProvisioned = &natGatewayProvisioned
+ this.NlbLimitTotal = &nlbLimitTotal
+ this.NlbProvisioned = &nlbProvisioned
+ this.RamPerContract = &ramPerContract
+ this.RamPerServer = &ramPerServer
+ this.RamProvisioned = &ramProvisioned
+ this.ReservableIps = &reservableIps
+ this.ReservedIpsInUse = &reservedIpsInUse
+ this.ReservedIpsOnContract = &reservedIpsOnContract
+ this.SsdLimitPerContract = &ssdLimitPerContract
+ this.SsdLimitPerVolume = &ssdLimitPerVolume
+ this.SsdVolumeProvisioned = &ssdVolumeProvisioned
return &this
}
@@ -103,76 +103,76 @@ func NewResourceLimitsWithDefaults() *ResourceLimits {
return &this
}
-// GetCoresPerServer returns the CoresPerServer field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetCoresPerServer() *int32 {
+// GetCoresPerContract returns the CoresPerContract field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetCoresPerContract() *int32 {
if o == nil {
return nil
}
- return o.CoresPerServer
+ return o.CoresPerContract
}
-// GetCoresPerServerOk returns a tuple with the CoresPerServer field value
+// GetCoresPerContractOk returns a tuple with the CoresPerContract field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetCoresPerServerOk() (*int32, bool) {
+func (o *ResourceLimits) GetCoresPerContractOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.CoresPerServer, true
+ return o.CoresPerContract, true
}
-// SetCoresPerServer sets field value
-func (o *ResourceLimits) SetCoresPerServer(v int32) {
+// SetCoresPerContract sets field value
+func (o *ResourceLimits) SetCoresPerContract(v int32) {
- o.CoresPerServer = &v
+ o.CoresPerContract = &v
}
-// HasCoresPerServer returns a boolean if a field has been set.
-func (o *ResourceLimits) HasCoresPerServer() bool {
- if o != nil && o.CoresPerServer != nil {
+// HasCoresPerContract returns a boolean if a field has been set.
+func (o *ResourceLimits) HasCoresPerContract() bool {
+ if o != nil && o.CoresPerContract != nil {
return true
}
return false
}
-// GetCoresPerContract returns the CoresPerContract field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetCoresPerContract() *int32 {
+// GetCoresPerServer returns the CoresPerServer field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetCoresPerServer() *int32 {
if o == nil {
return nil
}
- return o.CoresPerContract
+ return o.CoresPerServer
}
-// GetCoresPerContractOk returns a tuple with the CoresPerContract field value
+// GetCoresPerServerOk returns a tuple with the CoresPerServer field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetCoresPerContractOk() (*int32, bool) {
+func (o *ResourceLimits) GetCoresPerServerOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.CoresPerContract, true
+ return o.CoresPerServer, true
}
-// SetCoresPerContract sets field value
-func (o *ResourceLimits) SetCoresPerContract(v int32) {
+// SetCoresPerServer sets field value
+func (o *ResourceLimits) SetCoresPerServer(v int32) {
- o.CoresPerContract = &v
+ o.CoresPerServer = &v
}
-// HasCoresPerContract returns a boolean if a field has been set.
-func (o *ResourceLimits) HasCoresPerContract() bool {
- if o != nil && o.CoresPerContract != nil {
+// HasCoresPerServer returns a boolean if a field has been set.
+func (o *ResourceLimits) HasCoresPerServer() bool {
+ if o != nil && o.CoresPerServer != nil {
return true
}
@@ -180,7 +180,7 @@ func (o *ResourceLimits) HasCoresPerContract() bool {
}
// GetCoresProvisioned returns the CoresProvisioned field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *ResourceLimits) GetCoresProvisioned() *int32 {
if o == nil {
return nil
@@ -217,722 +217,722 @@ func (o *ResourceLimits) HasCoresProvisioned() bool {
return false
}
-// GetRamPerServer returns the RamPerServer field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetRamPerServer() *int32 {
+// GetDasVolumeProvisioned returns the DasVolumeProvisioned field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetDasVolumeProvisioned() *int64 {
if o == nil {
return nil
}
- return o.RamPerServer
+ return o.DasVolumeProvisioned
}
-// GetRamPerServerOk returns a tuple with the RamPerServer field value
+// GetDasVolumeProvisionedOk returns a tuple with the DasVolumeProvisioned field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetRamPerServerOk() (*int32, bool) {
+func (o *ResourceLimits) GetDasVolumeProvisionedOk() (*int64, bool) {
if o == nil {
return nil, false
}
- return o.RamPerServer, true
+ return o.DasVolumeProvisioned, true
}
-// SetRamPerServer sets field value
-func (o *ResourceLimits) SetRamPerServer(v int32) {
+// SetDasVolumeProvisioned sets field value
+func (o *ResourceLimits) SetDasVolumeProvisioned(v int64) {
- o.RamPerServer = &v
+ o.DasVolumeProvisioned = &v
}
-// HasRamPerServer returns a boolean if a field has been set.
-func (o *ResourceLimits) HasRamPerServer() bool {
- if o != nil && o.RamPerServer != nil {
+// HasDasVolumeProvisioned returns a boolean if a field has been set.
+func (o *ResourceLimits) HasDasVolumeProvisioned() bool {
+ if o != nil && o.DasVolumeProvisioned != nil {
return true
}
return false
}
-// GetRamPerContract returns the RamPerContract field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetRamPerContract() *int32 {
+// GetHddLimitPerContract returns the HddLimitPerContract field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetHddLimitPerContract() *int64 {
if o == nil {
return nil
}
- return o.RamPerContract
+ return o.HddLimitPerContract
}
-// GetRamPerContractOk returns a tuple with the RamPerContract field value
+// GetHddLimitPerContractOk returns a tuple with the HddLimitPerContract field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetRamPerContractOk() (*int32, bool) {
+func (o *ResourceLimits) GetHddLimitPerContractOk() (*int64, bool) {
if o == nil {
return nil, false
}
- return o.RamPerContract, true
+ return o.HddLimitPerContract, true
}
-// SetRamPerContract sets field value
-func (o *ResourceLimits) SetRamPerContract(v int32) {
+// SetHddLimitPerContract sets field value
+func (o *ResourceLimits) SetHddLimitPerContract(v int64) {
- o.RamPerContract = &v
+ o.HddLimitPerContract = &v
}
-// HasRamPerContract returns a boolean if a field has been set.
-func (o *ResourceLimits) HasRamPerContract() bool {
- if o != nil && o.RamPerContract != nil {
+// HasHddLimitPerContract returns a boolean if a field has been set.
+func (o *ResourceLimits) HasHddLimitPerContract() bool {
+ if o != nil && o.HddLimitPerContract != nil {
return true
}
return false
}
-// GetRamProvisioned returns the RamProvisioned field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetRamProvisioned() *int32 {
+// GetHddLimitPerVolume returns the HddLimitPerVolume field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetHddLimitPerVolume() *int64 {
if o == nil {
return nil
}
- return o.RamProvisioned
+ return o.HddLimitPerVolume
}
-// GetRamProvisionedOk returns a tuple with the RamProvisioned field value
+// GetHddLimitPerVolumeOk returns a tuple with the HddLimitPerVolume field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetRamProvisionedOk() (*int32, bool) {
+func (o *ResourceLimits) GetHddLimitPerVolumeOk() (*int64, bool) {
if o == nil {
return nil, false
}
- return o.RamProvisioned, true
+ return o.HddLimitPerVolume, true
}
-// SetRamProvisioned sets field value
-func (o *ResourceLimits) SetRamProvisioned(v int32) {
+// SetHddLimitPerVolume sets field value
+func (o *ResourceLimits) SetHddLimitPerVolume(v int64) {
- o.RamProvisioned = &v
+ o.HddLimitPerVolume = &v
}
-// HasRamProvisioned returns a boolean if a field has been set.
-func (o *ResourceLimits) HasRamProvisioned() bool {
- if o != nil && o.RamProvisioned != nil {
+// HasHddLimitPerVolume returns a boolean if a field has been set.
+func (o *ResourceLimits) HasHddLimitPerVolume() bool {
+ if o != nil && o.HddLimitPerVolume != nil {
return true
}
return false
}
-// GetHddLimitPerVolume returns the HddLimitPerVolume field value
-// If the value is explicit nil, the zero value for int64 will be returned
-func (o *ResourceLimits) GetHddLimitPerVolume() *int64 {
+// GetHddVolumeProvisioned returns the HddVolumeProvisioned field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetHddVolumeProvisioned() *int64 {
if o == nil {
return nil
}
- return o.HddLimitPerVolume
+ return o.HddVolumeProvisioned
}
-// GetHddLimitPerVolumeOk returns a tuple with the HddLimitPerVolume field value
+// GetHddVolumeProvisionedOk returns a tuple with the HddVolumeProvisioned field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetHddLimitPerVolumeOk() (*int64, bool) {
+func (o *ResourceLimits) GetHddVolumeProvisionedOk() (*int64, bool) {
if o == nil {
return nil, false
}
- return o.HddLimitPerVolume, true
+ return o.HddVolumeProvisioned, true
}
-// SetHddLimitPerVolume sets field value
-func (o *ResourceLimits) SetHddLimitPerVolume(v int64) {
+// SetHddVolumeProvisioned sets field value
+func (o *ResourceLimits) SetHddVolumeProvisioned(v int64) {
- o.HddLimitPerVolume = &v
+ o.HddVolumeProvisioned = &v
}
-// HasHddLimitPerVolume returns a boolean if a field has been set.
-func (o *ResourceLimits) HasHddLimitPerVolume() bool {
- if o != nil && o.HddLimitPerVolume != nil {
+// HasHddVolumeProvisioned returns a boolean if a field has been set.
+func (o *ResourceLimits) HasHddVolumeProvisioned() bool {
+ if o != nil && o.HddVolumeProvisioned != nil {
return true
}
return false
}
-// GetHddLimitPerContract returns the HddLimitPerContract field value
-// If the value is explicit nil, the zero value for int64 will be returned
-func (o *ResourceLimits) GetHddLimitPerContract() *int64 {
+// GetK8sClusterLimitTotal returns the K8sClusterLimitTotal field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetK8sClusterLimitTotal() *int32 {
if o == nil {
return nil
}
- return o.HddLimitPerContract
+ return o.K8sClusterLimitTotal
}
-// GetHddLimitPerContractOk returns a tuple with the HddLimitPerContract field value
+// GetK8sClusterLimitTotalOk returns a tuple with the K8sClusterLimitTotal field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetHddLimitPerContractOk() (*int64, bool) {
+func (o *ResourceLimits) GetK8sClusterLimitTotalOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.HddLimitPerContract, true
+ return o.K8sClusterLimitTotal, true
}
-// SetHddLimitPerContract sets field value
-func (o *ResourceLimits) SetHddLimitPerContract(v int64) {
+// SetK8sClusterLimitTotal sets field value
+func (o *ResourceLimits) SetK8sClusterLimitTotal(v int32) {
- o.HddLimitPerContract = &v
+ o.K8sClusterLimitTotal = &v
}
-// HasHddLimitPerContract returns a boolean if a field has been set.
-func (o *ResourceLimits) HasHddLimitPerContract() bool {
- if o != nil && o.HddLimitPerContract != nil {
+// HasK8sClusterLimitTotal returns a boolean if a field has been set.
+func (o *ResourceLimits) HasK8sClusterLimitTotal() bool {
+ if o != nil && o.K8sClusterLimitTotal != nil {
return true
}
return false
}
-// GetHddVolumeProvisioned returns the HddVolumeProvisioned field value
-// If the value is explicit nil, the zero value for int64 will be returned
-func (o *ResourceLimits) GetHddVolumeProvisioned() *int64 {
+// GetK8sClustersProvisioned returns the K8sClustersProvisioned field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetK8sClustersProvisioned() *int32 {
if o == nil {
return nil
}
- return o.HddVolumeProvisioned
+ return o.K8sClustersProvisioned
}
-// GetHddVolumeProvisionedOk returns a tuple with the HddVolumeProvisioned field value
+// GetK8sClustersProvisionedOk returns a tuple with the K8sClustersProvisioned field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetHddVolumeProvisionedOk() (*int64, bool) {
+func (o *ResourceLimits) GetK8sClustersProvisionedOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.HddVolumeProvisioned, true
+ return o.K8sClustersProvisioned, true
}
-// SetHddVolumeProvisioned sets field value
-func (o *ResourceLimits) SetHddVolumeProvisioned(v int64) {
+// SetK8sClustersProvisioned sets field value
+func (o *ResourceLimits) SetK8sClustersProvisioned(v int32) {
- o.HddVolumeProvisioned = &v
+ o.K8sClustersProvisioned = &v
}
-// HasHddVolumeProvisioned returns a boolean if a field has been set.
-func (o *ResourceLimits) HasHddVolumeProvisioned() bool {
- if o != nil && o.HddVolumeProvisioned != nil {
+// HasK8sClustersProvisioned returns a boolean if a field has been set.
+func (o *ResourceLimits) HasK8sClustersProvisioned() bool {
+ if o != nil && o.K8sClustersProvisioned != nil {
return true
}
return false
}
-// GetSsdLimitPerVolume returns the SsdLimitPerVolume field value
-// If the value is explicit nil, the zero value for int64 will be returned
-func (o *ResourceLimits) GetSsdLimitPerVolume() *int64 {
+// GetNatGatewayLimitTotal returns the NatGatewayLimitTotal field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetNatGatewayLimitTotal() *int32 {
if o == nil {
return nil
}
- return o.SsdLimitPerVolume
+ return o.NatGatewayLimitTotal
}
-// GetSsdLimitPerVolumeOk returns a tuple with the SsdLimitPerVolume field value
+// GetNatGatewayLimitTotalOk returns a tuple with the NatGatewayLimitTotal field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetSsdLimitPerVolumeOk() (*int64, bool) {
+func (o *ResourceLimits) GetNatGatewayLimitTotalOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.SsdLimitPerVolume, true
+ return o.NatGatewayLimitTotal, true
}
-// SetSsdLimitPerVolume sets field value
-func (o *ResourceLimits) SetSsdLimitPerVolume(v int64) {
+// SetNatGatewayLimitTotal sets field value
+func (o *ResourceLimits) SetNatGatewayLimitTotal(v int32) {
- o.SsdLimitPerVolume = &v
+ o.NatGatewayLimitTotal = &v
}
-// HasSsdLimitPerVolume returns a boolean if a field has been set.
-func (o *ResourceLimits) HasSsdLimitPerVolume() bool {
- if o != nil && o.SsdLimitPerVolume != nil {
+// HasNatGatewayLimitTotal returns a boolean if a field has been set.
+func (o *ResourceLimits) HasNatGatewayLimitTotal() bool {
+ if o != nil && o.NatGatewayLimitTotal != nil {
return true
}
return false
}
-// GetSsdLimitPerContract returns the SsdLimitPerContract field value
-// If the value is explicit nil, the zero value for int64 will be returned
-func (o *ResourceLimits) GetSsdLimitPerContract() *int64 {
+// GetNatGatewayProvisioned returns the NatGatewayProvisioned field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetNatGatewayProvisioned() *int32 {
if o == nil {
return nil
}
- return o.SsdLimitPerContract
+ return o.NatGatewayProvisioned
}
-// GetSsdLimitPerContractOk returns a tuple with the SsdLimitPerContract field value
+// GetNatGatewayProvisionedOk returns a tuple with the NatGatewayProvisioned field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetSsdLimitPerContractOk() (*int64, bool) {
+func (o *ResourceLimits) GetNatGatewayProvisionedOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.SsdLimitPerContract, true
+ return o.NatGatewayProvisioned, true
}
-// SetSsdLimitPerContract sets field value
-func (o *ResourceLimits) SetSsdLimitPerContract(v int64) {
+// SetNatGatewayProvisioned sets field value
+func (o *ResourceLimits) SetNatGatewayProvisioned(v int32) {
- o.SsdLimitPerContract = &v
+ o.NatGatewayProvisioned = &v
}
-// HasSsdLimitPerContract returns a boolean if a field has been set.
-func (o *ResourceLimits) HasSsdLimitPerContract() bool {
- if o != nil && o.SsdLimitPerContract != nil {
+// HasNatGatewayProvisioned returns a boolean if a field has been set.
+func (o *ResourceLimits) HasNatGatewayProvisioned() bool {
+ if o != nil && o.NatGatewayProvisioned != nil {
return true
}
return false
}
-// GetSsdVolumeProvisioned returns the SsdVolumeProvisioned field value
-// If the value is explicit nil, the zero value for int64 will be returned
-func (o *ResourceLimits) GetSsdVolumeProvisioned() *int64 {
+// GetNlbLimitTotal returns the NlbLimitTotal field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetNlbLimitTotal() *int32 {
if o == nil {
return nil
}
- return o.SsdVolumeProvisioned
+ return o.NlbLimitTotal
}
-// GetSsdVolumeProvisionedOk returns a tuple with the SsdVolumeProvisioned field value
+// GetNlbLimitTotalOk returns a tuple with the NlbLimitTotal field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetSsdVolumeProvisionedOk() (*int64, bool) {
+func (o *ResourceLimits) GetNlbLimitTotalOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.SsdVolumeProvisioned, true
+ return o.NlbLimitTotal, true
}
-// SetSsdVolumeProvisioned sets field value
-func (o *ResourceLimits) SetSsdVolumeProvisioned(v int64) {
+// SetNlbLimitTotal sets field value
+func (o *ResourceLimits) SetNlbLimitTotal(v int32) {
- o.SsdVolumeProvisioned = &v
+ o.NlbLimitTotal = &v
}
-// HasSsdVolumeProvisioned returns a boolean if a field has been set.
-func (o *ResourceLimits) HasSsdVolumeProvisioned() bool {
- if o != nil && o.SsdVolumeProvisioned != nil {
+// HasNlbLimitTotal returns a boolean if a field has been set.
+func (o *ResourceLimits) HasNlbLimitTotal() bool {
+ if o != nil && o.NlbLimitTotal != nil {
return true
}
return false
}
-// GetDasVolumeProvisioned returns the DasVolumeProvisioned field value
-// If the value is explicit nil, the zero value for int64 will be returned
-func (o *ResourceLimits) GetDasVolumeProvisioned() *int64 {
+// GetNlbProvisioned returns the NlbProvisioned field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetNlbProvisioned() *int32 {
if o == nil {
return nil
}
- return o.DasVolumeProvisioned
+ return o.NlbProvisioned
}
-// GetDasVolumeProvisionedOk returns a tuple with the DasVolumeProvisioned field value
+// GetNlbProvisionedOk returns a tuple with the NlbProvisioned field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetDasVolumeProvisionedOk() (*int64, bool) {
+func (o *ResourceLimits) GetNlbProvisionedOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.DasVolumeProvisioned, true
+ return o.NlbProvisioned, true
}
-// SetDasVolumeProvisioned sets field value
-func (o *ResourceLimits) SetDasVolumeProvisioned(v int64) {
+// SetNlbProvisioned sets field value
+func (o *ResourceLimits) SetNlbProvisioned(v int32) {
- o.DasVolumeProvisioned = &v
+ o.NlbProvisioned = &v
}
-// HasDasVolumeProvisioned returns a boolean if a field has been set.
-func (o *ResourceLimits) HasDasVolumeProvisioned() bool {
- if o != nil && o.DasVolumeProvisioned != nil {
+// HasNlbProvisioned returns a boolean if a field has been set.
+func (o *ResourceLimits) HasNlbProvisioned() bool {
+ if o != nil && o.NlbProvisioned != nil {
return true
}
return false
}
-// GetReservableIps returns the ReservableIps field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetReservableIps() *int32 {
+// GetRamPerContract returns the RamPerContract field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetRamPerContract() *int32 {
if o == nil {
return nil
}
- return o.ReservableIps
+ return o.RamPerContract
}
-// GetReservableIpsOk returns a tuple with the ReservableIps field value
+// GetRamPerContractOk returns a tuple with the RamPerContract field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetReservableIpsOk() (*int32, bool) {
+func (o *ResourceLimits) GetRamPerContractOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.ReservableIps, true
+ return o.RamPerContract, true
}
-// SetReservableIps sets field value
-func (o *ResourceLimits) SetReservableIps(v int32) {
+// SetRamPerContract sets field value
+func (o *ResourceLimits) SetRamPerContract(v int32) {
- o.ReservableIps = &v
+ o.RamPerContract = &v
}
-// HasReservableIps returns a boolean if a field has been set.
-func (o *ResourceLimits) HasReservableIps() bool {
- if o != nil && o.ReservableIps != nil {
+// HasRamPerContract returns a boolean if a field has been set.
+func (o *ResourceLimits) HasRamPerContract() bool {
+ if o != nil && o.RamPerContract != nil {
return true
}
return false
}
-// GetReservedIpsOnContract returns the ReservedIpsOnContract field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetReservedIpsOnContract() *int32 {
+// GetRamPerServer returns the RamPerServer field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetRamPerServer() *int32 {
if o == nil {
return nil
}
- return o.ReservedIpsOnContract
+ return o.RamPerServer
}
-// GetReservedIpsOnContractOk returns a tuple with the ReservedIpsOnContract field value
+// GetRamPerServerOk returns a tuple with the RamPerServer field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetReservedIpsOnContractOk() (*int32, bool) {
+func (o *ResourceLimits) GetRamPerServerOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.ReservedIpsOnContract, true
+ return o.RamPerServer, true
}
-// SetReservedIpsOnContract sets field value
-func (o *ResourceLimits) SetReservedIpsOnContract(v int32) {
+// SetRamPerServer sets field value
+func (o *ResourceLimits) SetRamPerServer(v int32) {
- o.ReservedIpsOnContract = &v
+ o.RamPerServer = &v
}
-// HasReservedIpsOnContract returns a boolean if a field has been set.
-func (o *ResourceLimits) HasReservedIpsOnContract() bool {
- if o != nil && o.ReservedIpsOnContract != nil {
+// HasRamPerServer returns a boolean if a field has been set.
+func (o *ResourceLimits) HasRamPerServer() bool {
+ if o != nil && o.RamPerServer != nil {
return true
}
return false
}
-// GetReservedIpsInUse returns the ReservedIpsInUse field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetReservedIpsInUse() *int32 {
+// GetRamProvisioned returns the RamProvisioned field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetRamProvisioned() *int32 {
if o == nil {
return nil
}
- return o.ReservedIpsInUse
+ return o.RamProvisioned
}
-// GetReservedIpsInUseOk returns a tuple with the ReservedIpsInUse field value
+// GetRamProvisionedOk returns a tuple with the RamProvisioned field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetReservedIpsInUseOk() (*int32, bool) {
+func (o *ResourceLimits) GetRamProvisionedOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.ReservedIpsInUse, true
+ return o.RamProvisioned, true
}
-// SetReservedIpsInUse sets field value
-func (o *ResourceLimits) SetReservedIpsInUse(v int32) {
+// SetRamProvisioned sets field value
+func (o *ResourceLimits) SetRamProvisioned(v int32) {
- o.ReservedIpsInUse = &v
+ o.RamProvisioned = &v
}
-// HasReservedIpsInUse returns a boolean if a field has been set.
-func (o *ResourceLimits) HasReservedIpsInUse() bool {
- if o != nil && o.ReservedIpsInUse != nil {
+// HasRamProvisioned returns a boolean if a field has been set.
+func (o *ResourceLimits) HasRamProvisioned() bool {
+ if o != nil && o.RamProvisioned != nil {
return true
}
return false
}
-// GetK8sClusterLimitTotal returns the K8sClusterLimitTotal field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetK8sClusterLimitTotal() *int32 {
+// GetReservableIps returns the ReservableIps field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetReservableIps() *int32 {
if o == nil {
return nil
}
- return o.K8sClusterLimitTotal
+ return o.ReservableIps
}
-// GetK8sClusterLimitTotalOk returns a tuple with the K8sClusterLimitTotal field value
+// GetReservableIpsOk returns a tuple with the ReservableIps field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetK8sClusterLimitTotalOk() (*int32, bool) {
+func (o *ResourceLimits) GetReservableIpsOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.K8sClusterLimitTotal, true
+ return o.ReservableIps, true
}
-// SetK8sClusterLimitTotal sets field value
-func (o *ResourceLimits) SetK8sClusterLimitTotal(v int32) {
+// SetReservableIps sets field value
+func (o *ResourceLimits) SetReservableIps(v int32) {
- o.K8sClusterLimitTotal = &v
+ o.ReservableIps = &v
}
-// HasK8sClusterLimitTotal returns a boolean if a field has been set.
-func (o *ResourceLimits) HasK8sClusterLimitTotal() bool {
- if o != nil && o.K8sClusterLimitTotal != nil {
+// HasReservableIps returns a boolean if a field has been set.
+func (o *ResourceLimits) HasReservableIps() bool {
+ if o != nil && o.ReservableIps != nil {
return true
}
return false
}
-// GetK8sClustersProvisioned returns the K8sClustersProvisioned field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetK8sClustersProvisioned() *int32 {
+// GetReservedIpsInUse returns the ReservedIpsInUse field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetReservedIpsInUse() *int32 {
if o == nil {
return nil
}
- return o.K8sClustersProvisioned
+ return o.ReservedIpsInUse
}
-// GetK8sClustersProvisionedOk returns a tuple with the K8sClustersProvisioned field value
+// GetReservedIpsInUseOk returns a tuple with the ReservedIpsInUse field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetK8sClustersProvisionedOk() (*int32, bool) {
+func (o *ResourceLimits) GetReservedIpsInUseOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.K8sClustersProvisioned, true
+ return o.ReservedIpsInUse, true
}
-// SetK8sClustersProvisioned sets field value
-func (o *ResourceLimits) SetK8sClustersProvisioned(v int32) {
+// SetReservedIpsInUse sets field value
+func (o *ResourceLimits) SetReservedIpsInUse(v int32) {
- o.K8sClustersProvisioned = &v
+ o.ReservedIpsInUse = &v
}
-// HasK8sClustersProvisioned returns a boolean if a field has been set.
-func (o *ResourceLimits) HasK8sClustersProvisioned() bool {
- if o != nil && o.K8sClustersProvisioned != nil {
+// HasReservedIpsInUse returns a boolean if a field has been set.
+func (o *ResourceLimits) HasReservedIpsInUse() bool {
+ if o != nil && o.ReservedIpsInUse != nil {
return true
}
return false
}
-// GetNlbLimitTotal returns the NlbLimitTotal field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetNlbLimitTotal() *int32 {
+// GetReservedIpsOnContract returns the ReservedIpsOnContract field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetReservedIpsOnContract() *int32 {
if o == nil {
return nil
}
- return o.NlbLimitTotal
+ return o.ReservedIpsOnContract
}
-// GetNlbLimitTotalOk returns a tuple with the NlbLimitTotal field value
+// GetReservedIpsOnContractOk returns a tuple with the ReservedIpsOnContract field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetNlbLimitTotalOk() (*int32, bool) {
+func (o *ResourceLimits) GetReservedIpsOnContractOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.NlbLimitTotal, true
+ return o.ReservedIpsOnContract, true
}
-// SetNlbLimitTotal sets field value
-func (o *ResourceLimits) SetNlbLimitTotal(v int32) {
+// SetReservedIpsOnContract sets field value
+func (o *ResourceLimits) SetReservedIpsOnContract(v int32) {
- o.NlbLimitTotal = &v
+ o.ReservedIpsOnContract = &v
}
-// HasNlbLimitTotal returns a boolean if a field has been set.
-func (o *ResourceLimits) HasNlbLimitTotal() bool {
- if o != nil && o.NlbLimitTotal != nil {
+// HasReservedIpsOnContract returns a boolean if a field has been set.
+func (o *ResourceLimits) HasReservedIpsOnContract() bool {
+ if o != nil && o.ReservedIpsOnContract != nil {
return true
}
return false
}
-// GetNlbProvisioned returns the NlbProvisioned field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetNlbProvisioned() *int32 {
+// GetSsdLimitPerContract returns the SsdLimitPerContract field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetSsdLimitPerContract() *int64 {
if o == nil {
return nil
}
- return o.NlbProvisioned
+ return o.SsdLimitPerContract
}
-// GetNlbProvisionedOk returns a tuple with the NlbProvisioned field value
+// GetSsdLimitPerContractOk returns a tuple with the SsdLimitPerContract field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetNlbProvisionedOk() (*int32, bool) {
+func (o *ResourceLimits) GetSsdLimitPerContractOk() (*int64, bool) {
if o == nil {
return nil, false
}
- return o.NlbProvisioned, true
+ return o.SsdLimitPerContract, true
}
-// SetNlbProvisioned sets field value
-func (o *ResourceLimits) SetNlbProvisioned(v int32) {
+// SetSsdLimitPerContract sets field value
+func (o *ResourceLimits) SetSsdLimitPerContract(v int64) {
- o.NlbProvisioned = &v
+ o.SsdLimitPerContract = &v
}
-// HasNlbProvisioned returns a boolean if a field has been set.
-func (o *ResourceLimits) HasNlbProvisioned() bool {
- if o != nil && o.NlbProvisioned != nil {
+// HasSsdLimitPerContract returns a boolean if a field has been set.
+func (o *ResourceLimits) HasSsdLimitPerContract() bool {
+ if o != nil && o.SsdLimitPerContract != nil {
return true
}
return false
}
-// GetNatGatewayLimitTotal returns the NatGatewayLimitTotal field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetNatGatewayLimitTotal() *int32 {
+// GetSsdLimitPerVolume returns the SsdLimitPerVolume field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetSsdLimitPerVolume() *int64 {
if o == nil {
return nil
}
- return o.NatGatewayLimitTotal
+ return o.SsdLimitPerVolume
}
-// GetNatGatewayLimitTotalOk returns a tuple with the NatGatewayLimitTotal field value
+// GetSsdLimitPerVolumeOk returns a tuple with the SsdLimitPerVolume field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetNatGatewayLimitTotalOk() (*int32, bool) {
+func (o *ResourceLimits) GetSsdLimitPerVolumeOk() (*int64, bool) {
if o == nil {
return nil, false
}
- return o.NatGatewayLimitTotal, true
+ return o.SsdLimitPerVolume, true
}
-// SetNatGatewayLimitTotal sets field value
-func (o *ResourceLimits) SetNatGatewayLimitTotal(v int32) {
+// SetSsdLimitPerVolume sets field value
+func (o *ResourceLimits) SetSsdLimitPerVolume(v int64) {
- o.NatGatewayLimitTotal = &v
+ o.SsdLimitPerVolume = &v
}
-// HasNatGatewayLimitTotal returns a boolean if a field has been set.
-func (o *ResourceLimits) HasNatGatewayLimitTotal() bool {
- if o != nil && o.NatGatewayLimitTotal != nil {
+// HasSsdLimitPerVolume returns a boolean if a field has been set.
+func (o *ResourceLimits) HasSsdLimitPerVolume() bool {
+ if o != nil && o.SsdLimitPerVolume != nil {
return true
}
return false
}
-// GetNatGatewayProvisioned returns the NatGatewayProvisioned field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ResourceLimits) GetNatGatewayProvisioned() *int32 {
+// GetSsdVolumeProvisioned returns the SsdVolumeProvisioned field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceLimits) GetSsdVolumeProvisioned() *int64 {
if o == nil {
return nil
}
- return o.NatGatewayProvisioned
+ return o.SsdVolumeProvisioned
}
-// GetNatGatewayProvisionedOk returns a tuple with the NatGatewayProvisioned field value
+// GetSsdVolumeProvisionedOk returns a tuple with the SsdVolumeProvisioned field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceLimits) GetNatGatewayProvisionedOk() (*int32, bool) {
+func (o *ResourceLimits) GetSsdVolumeProvisionedOk() (*int64, bool) {
if o == nil {
return nil, false
}
- return o.NatGatewayProvisioned, true
+ return o.SsdVolumeProvisioned, true
}
-// SetNatGatewayProvisioned sets field value
-func (o *ResourceLimits) SetNatGatewayProvisioned(v int32) {
+// SetSsdVolumeProvisioned sets field value
+func (o *ResourceLimits) SetSsdVolumeProvisioned(v int64) {
- o.NatGatewayProvisioned = &v
+ o.SsdVolumeProvisioned = &v
}
-// HasNatGatewayProvisioned returns a boolean if a field has been set.
-func (o *ResourceLimits) HasNatGatewayProvisioned() bool {
- if o != nil && o.NatGatewayProvisioned != nil {
+// HasSsdVolumeProvisioned returns a boolean if a field has been set.
+func (o *ResourceLimits) HasSsdVolumeProvisioned() bool {
+ if o != nil && o.SsdVolumeProvisioned != nil {
return true
}
@@ -941,72 +941,94 @@ func (o *ResourceLimits) HasNatGatewayProvisioned() bool {
func (o ResourceLimits) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.CoresPerServer != nil {
- toSerialize["coresPerServer"] = o.CoresPerServer
- }
if o.CoresPerContract != nil {
toSerialize["coresPerContract"] = o.CoresPerContract
}
+
+ if o.CoresPerServer != nil {
+ toSerialize["coresPerServer"] = o.CoresPerServer
+ }
+
if o.CoresProvisioned != nil {
toSerialize["coresProvisioned"] = o.CoresProvisioned
}
- if o.RamPerServer != nil {
- toSerialize["ramPerServer"] = o.RamPerServer
- }
- if o.RamPerContract != nil {
- toSerialize["ramPerContract"] = o.RamPerContract
+
+ if o.DasVolumeProvisioned != nil {
+ toSerialize["dasVolumeProvisioned"] = o.DasVolumeProvisioned
}
- if o.RamProvisioned != nil {
- toSerialize["ramProvisioned"] = o.RamProvisioned
+
+ if o.HddLimitPerContract != nil {
+ toSerialize["hddLimitPerContract"] = o.HddLimitPerContract
}
+
if o.HddLimitPerVolume != nil {
toSerialize["hddLimitPerVolume"] = o.HddLimitPerVolume
}
- if o.HddLimitPerContract != nil {
- toSerialize["hddLimitPerContract"] = o.HddLimitPerContract
- }
+
if o.HddVolumeProvisioned != nil {
toSerialize["hddVolumeProvisioned"] = o.HddVolumeProvisioned
}
- if o.SsdLimitPerVolume != nil {
- toSerialize["ssdLimitPerVolume"] = o.SsdLimitPerVolume
- }
- if o.SsdLimitPerContract != nil {
- toSerialize["ssdLimitPerContract"] = o.SsdLimitPerContract
- }
- if o.SsdVolumeProvisioned != nil {
- toSerialize["ssdVolumeProvisioned"] = o.SsdVolumeProvisioned
- }
- if o.DasVolumeProvisioned != nil {
- toSerialize["dasVolumeProvisioned"] = o.DasVolumeProvisioned
- }
- if o.ReservableIps != nil {
- toSerialize["reservableIps"] = o.ReservableIps
- }
- if o.ReservedIpsOnContract != nil {
- toSerialize["reservedIpsOnContract"] = o.ReservedIpsOnContract
- }
- if o.ReservedIpsInUse != nil {
- toSerialize["reservedIpsInUse"] = o.ReservedIpsInUse
- }
+
if o.K8sClusterLimitTotal != nil {
toSerialize["k8sClusterLimitTotal"] = o.K8sClusterLimitTotal
}
+
if o.K8sClustersProvisioned != nil {
toSerialize["k8sClustersProvisioned"] = o.K8sClustersProvisioned
}
+
+ if o.NatGatewayLimitTotal != nil {
+ toSerialize["natGatewayLimitTotal"] = o.NatGatewayLimitTotal
+ }
+
+ if o.NatGatewayProvisioned != nil {
+ toSerialize["natGatewayProvisioned"] = o.NatGatewayProvisioned
+ }
+
if o.NlbLimitTotal != nil {
toSerialize["nlbLimitTotal"] = o.NlbLimitTotal
}
+
if o.NlbProvisioned != nil {
toSerialize["nlbProvisioned"] = o.NlbProvisioned
}
- if o.NatGatewayLimitTotal != nil {
- toSerialize["natGatewayLimitTotal"] = o.NatGatewayLimitTotal
+
+ if o.RamPerContract != nil {
+ toSerialize["ramPerContract"] = o.RamPerContract
}
- if o.NatGatewayProvisioned != nil {
- toSerialize["natGatewayProvisioned"] = o.NatGatewayProvisioned
+
+ if o.RamPerServer != nil {
+ toSerialize["ramPerServer"] = o.RamPerServer
}
+
+ if o.RamProvisioned != nil {
+ toSerialize["ramProvisioned"] = o.RamProvisioned
+ }
+
+ if o.ReservableIps != nil {
+ toSerialize["reservableIps"] = o.ReservableIps
+ }
+
+ if o.ReservedIpsInUse != nil {
+ toSerialize["reservedIpsInUse"] = o.ReservedIpsInUse
+ }
+
+ if o.ReservedIpsOnContract != nil {
+ toSerialize["reservedIpsOnContract"] = o.ReservedIpsOnContract
+ }
+
+ if o.SsdLimitPerContract != nil {
+ toSerialize["ssdLimitPerContract"] = o.SsdLimitPerContract
+ }
+
+ if o.SsdLimitPerVolume != nil {
+ toSerialize["ssdLimitPerVolume"] = o.SsdLimitPerVolume
+ }
+
+ if o.SsdVolumeProvisioned != nil {
+ toSerialize["ssdVolumeProvisioned"] = o.SsdVolumeProvisioned
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_properties.go
index b5b274a28eb..224350ec56c 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_properties.go
@@ -41,7 +41,7 @@ func NewResourcePropertiesWithDefaults() *ResourceProperties {
}
// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *ResourceProperties) GetName() *string {
if o == nil {
return nil
@@ -79,7 +79,7 @@ func (o *ResourceProperties) HasName() bool {
}
// GetSecAuthProtection returns the SecAuthProtection field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *ResourceProperties) GetSecAuthProtection() *bool {
if o == nil {
return nil
@@ -121,9 +121,11 @@ func (o ResourceProperties) MarshalJSON() ([]byte, error) {
if o.Name != nil {
toSerialize["name"] = o.Name
}
+
if o.SecAuthProtection != nil {
toSerialize["secAuthProtection"] = o.SecAuthProtection
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_reference.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_reference.go
index 5732ab57016..6b58f76a354 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_reference.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resource_reference.go
@@ -16,12 +16,12 @@ import (
// ResourceReference struct for ResourceReference
type ResourceReference struct {
+ // URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
Id *string `json:"id"`
// The type of object that has been created.
Type *Type `json:"type,omitempty"`
- // URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
}
// NewResourceReference instantiates a new ResourceReference object
@@ -44,114 +44,114 @@ func NewResourceReferenceWithDefaults() *ResourceReference {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ResourceReference) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceReference) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceReference) GetIdOk() (*string, bool) {
+func (o *ResourceReference) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *ResourceReference) SetId(v string) {
+// SetHref sets field value
+func (o *ResourceReference) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *ResourceReference) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *ResourceReference) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *ResourceReference) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceReference) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceReference) GetTypeOk() (*Type, bool) {
+func (o *ResourceReference) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *ResourceReference) SetType(v Type) {
+// SetId sets field value
+func (o *ResourceReference) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *ResourceReference) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *ResourceReference) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ResourceReference) GetHref() *string {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *ResourceReference) GetType() *Type {
if o == nil {
return nil
}
- return o.Href
+ return o.Type
}
-// GetHrefOk returns a tuple with the Href field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourceReference) GetHrefOk() (*string, bool) {
+func (o *ResourceReference) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Type, true
}
-// SetHref sets field value
-func (o *ResourceReference) SetHref(v string) {
+// SetType sets field value
+func (o *ResourceReference) SetType(v Type) {
- o.Href = &v
+ o.Type = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *ResourceReference) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasType returns a boolean if a field has been set.
+func (o *ResourceReference) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -160,15 +160,18 @@ func (o *ResourceReference) HasHref() bool {
func (o ResourceReference) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
+ if o.Href != nil {
+ toSerialize["href"] = o.Href
+ }
+
if o.Id != nil {
toSerialize["id"] = o.Id
}
+
if o.Type != nil {
toSerialize["type"] = o.Type
}
- if o.Href != nil {
- toSerialize["href"] = o.Href
- }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resources.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resources.go
index 36b8beeabff..9db504339fb 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resources.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resources.go
@@ -16,14 +16,14 @@ import (
// Resources Collection to represent the resource.
type Resources struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of the resource.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Resource `json:"items,omitempty"`
+ // The type of the resource.
+ Type *Type `json:"type,omitempty"`
}
// NewResources instantiates a new Resources object
@@ -44,152 +44,152 @@ func NewResourcesWithDefaults() *Resources {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Resources) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Resources) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Resources) GetIdOk() (*string, bool) {
+func (o *Resources) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Resources) SetId(v string) {
+// SetHref sets field value
+func (o *Resources) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Resources) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Resources) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Resources) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Resources) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Resources) GetTypeOk() (*Type, bool) {
+func (o *Resources) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Resources) SetType(v Type) {
+// SetId sets field value
+func (o *Resources) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Resources) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Resources) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Resources) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *Resources) GetItems() *[]Resource {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Resources) GetHrefOk() (*string, bool) {
+func (o *Resources) GetItemsOk() (*[]Resource, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *Resources) SetHref(v string) {
+// SetItems sets field value
+func (o *Resources) SetItems(v []Resource) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Resources) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *Resources) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Resource will be returned
-func (o *Resources) GetItems() *[]Resource {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Resources) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Resources) GetItemsOk() (*[]Resource, bool) {
+func (o *Resources) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *Resources) SetItems(v []Resource) {
+// SetType sets field value
+func (o *Resources) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *Resources) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Resources) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *Resources) HasItems() bool {
func (o Resources) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resources_users.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resources_users.go
index 18de5cf52d4..e8772006c89 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_resources_users.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_resources_users.go
@@ -16,14 +16,14 @@ import (
// ResourcesUsers Resources owned by a user.
type ResourcesUsers struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of the resource.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Resource `json:"items,omitempty"`
+ // The type of the resource.
+ Type *Type `json:"type,omitempty"`
}
// NewResourcesUsers instantiates a new ResourcesUsers object
@@ -44,152 +44,152 @@ func NewResourcesUsersWithDefaults() *ResourcesUsers {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ResourcesUsers) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *ResourcesUsers) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourcesUsers) GetIdOk() (*string, bool) {
+func (o *ResourcesUsers) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *ResourcesUsers) SetId(v string) {
+// SetHref sets field value
+func (o *ResourcesUsers) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *ResourcesUsers) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *ResourcesUsers) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *ResourcesUsers) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *ResourcesUsers) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourcesUsers) GetTypeOk() (*Type, bool) {
+func (o *ResourcesUsers) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *ResourcesUsers) SetType(v Type) {
+// SetId sets field value
+func (o *ResourcesUsers) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *ResourcesUsers) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *ResourcesUsers) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ResourcesUsers) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *ResourcesUsers) GetItems() *[]Resource {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourcesUsers) GetHrefOk() (*string, bool) {
+func (o *ResourcesUsers) GetItemsOk() (*[]Resource, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *ResourcesUsers) SetHref(v string) {
+// SetItems sets field value
+func (o *ResourcesUsers) SetItems(v []Resource) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *ResourcesUsers) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *ResourcesUsers) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Resource will be returned
-func (o *ResourcesUsers) GetItems() *[]Resource {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *ResourcesUsers) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ResourcesUsers) GetItemsOk() (*[]Resource, bool) {
+func (o *ResourcesUsers) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *ResourcesUsers) SetItems(v []Resource) {
+// SetType sets field value
+func (o *ResourcesUsers) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *ResourcesUsers) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *ResourcesUsers) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *ResourcesUsers) HasItems() bool {
func (o ResourcesUsers) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_bucket.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_bucket.go
index bede8466735..5e263873ce6 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_bucket.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_bucket.go
@@ -41,7 +41,7 @@ func NewS3BucketWithDefaults() *S3Bucket {
}
// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *S3Bucket) GetName() *string {
if o == nil {
return nil
@@ -83,6 +83,7 @@ func (o S3Bucket) MarshalJSON() ([]byte, error) {
if o.Name != nil {
toSerialize["name"] = o.Name
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_key.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_key.go
index 5febf4192a4..ae9f00908b8 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_key.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_key.go
@@ -16,14 +16,14 @@ import (
// S3Key struct for S3Key
type S3Key struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of the resource.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *S3KeyMetadata `json:"metadata,omitempty"`
Properties *S3KeyProperties `json:"properties"`
+ // The type of the resource.
+ Type *Type `json:"type,omitempty"`
}
// NewS3Key instantiates a new S3Key object
@@ -46,190 +46,190 @@ func NewS3KeyWithDefaults() *S3Key {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *S3Key) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *S3Key) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3Key) GetIdOk() (*string, bool) {
+func (o *S3Key) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *S3Key) SetId(v string) {
+// SetHref sets field value
+func (o *S3Key) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *S3Key) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *S3Key) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *S3Key) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *S3Key) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3Key) GetTypeOk() (*Type, bool) {
+func (o *S3Key) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *S3Key) SetType(v Type) {
+// SetId sets field value
+func (o *S3Key) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *S3Key) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *S3Key) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *S3Key) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *S3Key) GetMetadata() *S3KeyMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3Key) GetHrefOk() (*string, bool) {
+func (o *S3Key) GetMetadataOk() (*S3KeyMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *S3Key) SetHref(v string) {
+// SetMetadata sets field value
+func (o *S3Key) SetMetadata(v S3KeyMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *S3Key) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *S3Key) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for S3KeyMetadata will be returned
-func (o *S3Key) GetMetadata() *S3KeyMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *S3Key) GetProperties() *S3KeyProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3Key) GetMetadataOk() (*S3KeyMetadata, bool) {
+func (o *S3Key) GetPropertiesOk() (*S3KeyProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *S3Key) SetMetadata(v S3KeyMetadata) {
+// SetProperties sets field value
+func (o *S3Key) SetProperties(v S3KeyProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *S3Key) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *S3Key) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for S3KeyProperties will be returned
-func (o *S3Key) GetProperties() *S3KeyProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *S3Key) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3Key) GetPropertiesOk() (*S3KeyProperties, bool) {
+func (o *S3Key) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *S3Key) SetProperties(v S3KeyProperties) {
+// SetType sets field value
+func (o *S3Key) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *S3Key) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *S3Key) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *S3Key) HasProperties() bool {
func (o S3Key) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_key_metadata.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_key_metadata.go
index 83ecc8b4638..f090555e7d8 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_key_metadata.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_key_metadata.go
@@ -17,10 +17,10 @@ import (
// S3KeyMetadata struct for S3KeyMetadata
type S3KeyMetadata struct {
- // Resource's Entity Tag as defined in http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.11 Entity Tag is also added as an 'ETag response header to requests which don't use 'depth' parameter.
- Etag *string `json:"etag,omitempty"`
// The time when the S3 key was created.
CreatedDate *IonosTime
+ // Resource's Entity Tag as defined in http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.11 Entity Tag is also added as an 'ETag response header to requests which don't use 'depth' parameter.
+ Etag *string `json:"etag,omitempty"`
}
// NewS3KeyMetadata instantiates a new S3KeyMetadata object
@@ -41,83 +41,83 @@ func NewS3KeyMetadataWithDefaults() *S3KeyMetadata {
return &this
}
-// GetEtag returns the Etag field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *S3KeyMetadata) GetEtag() *string {
+// GetCreatedDate returns the CreatedDate field value
+// If the value is explicit nil, nil is returned
+func (o *S3KeyMetadata) GetCreatedDate() *time.Time {
if o == nil {
return nil
}
- return o.Etag
+ if o.CreatedDate == nil {
+ return nil
+ }
+ return &o.CreatedDate.Time
}
-// GetEtagOk returns a tuple with the Etag field value
+// GetCreatedDateOk returns a tuple with the CreatedDate field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3KeyMetadata) GetEtagOk() (*string, bool) {
+func (o *S3KeyMetadata) GetCreatedDateOk() (*time.Time, bool) {
if o == nil {
return nil, false
}
- return o.Etag, true
+ if o.CreatedDate == nil {
+ return nil, false
+ }
+ return &o.CreatedDate.Time, true
+
}
-// SetEtag sets field value
-func (o *S3KeyMetadata) SetEtag(v string) {
+// SetCreatedDate sets field value
+func (o *S3KeyMetadata) SetCreatedDate(v time.Time) {
- o.Etag = &v
+ o.CreatedDate = &IonosTime{v}
}
-// HasEtag returns a boolean if a field has been set.
-func (o *S3KeyMetadata) HasEtag() bool {
- if o != nil && o.Etag != nil {
+// HasCreatedDate returns a boolean if a field has been set.
+func (o *S3KeyMetadata) HasCreatedDate() bool {
+ if o != nil && o.CreatedDate != nil {
return true
}
return false
}
-// GetCreatedDate returns the CreatedDate field value
-// If the value is explicit nil, the zero value for time.Time will be returned
-func (o *S3KeyMetadata) GetCreatedDate() *time.Time {
+// GetEtag returns the Etag field value
+// If the value is explicit nil, nil is returned
+func (o *S3KeyMetadata) GetEtag() *string {
if o == nil {
return nil
}
- if o.CreatedDate == nil {
- return nil
- }
- return &o.CreatedDate.Time
+ return o.Etag
}
-// GetCreatedDateOk returns a tuple with the CreatedDate field value
+// GetEtagOk returns a tuple with the Etag field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3KeyMetadata) GetCreatedDateOk() (*time.Time, bool) {
+func (o *S3KeyMetadata) GetEtagOk() (*string, bool) {
if o == nil {
return nil, false
}
- if o.CreatedDate == nil {
- return nil, false
- }
- return &o.CreatedDate.Time, true
-
+ return o.Etag, true
}
-// SetCreatedDate sets field value
-func (o *S3KeyMetadata) SetCreatedDate(v time.Time) {
+// SetEtag sets field value
+func (o *S3KeyMetadata) SetEtag(v string) {
- o.CreatedDate = &IonosTime{v}
+ o.Etag = &v
}
-// HasCreatedDate returns a boolean if a field has been set.
-func (o *S3KeyMetadata) HasCreatedDate() bool {
- if o != nil && o.CreatedDate != nil {
+// HasEtag returns a boolean if a field has been set.
+func (o *S3KeyMetadata) HasEtag() bool {
+ if o != nil && o.Etag != nil {
return true
}
@@ -126,12 +126,14 @@ func (o *S3KeyMetadata) HasCreatedDate() bool {
func (o S3KeyMetadata) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Etag != nil {
- toSerialize["etag"] = o.Etag
- }
if o.CreatedDate != nil {
toSerialize["createdDate"] = o.CreatedDate
}
+
+ if o.Etag != nil {
+ toSerialize["etag"] = o.Etag
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_key_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_key_properties.go
index a3204d717c3..0cf12e77116 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_key_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_key_properties.go
@@ -16,10 +16,10 @@ import (
// S3KeyProperties struct for S3KeyProperties
type S3KeyProperties struct {
- // Secret of the S3 key.
- SecretKey *string `json:"secretKey,omitempty"`
// Denotes weather the S3 key is active.
Active *bool `json:"active,omitempty"`
+ // Secret of the S3 key.
+ SecretKey *string `json:"secretKey,omitempty"`
}
// NewS3KeyProperties instantiates a new S3KeyProperties object
@@ -40,76 +40,76 @@ func NewS3KeyPropertiesWithDefaults() *S3KeyProperties {
return &this
}
-// GetSecretKey returns the SecretKey field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *S3KeyProperties) GetSecretKey() *string {
+// GetActive returns the Active field value
+// If the value is explicit nil, nil is returned
+func (o *S3KeyProperties) GetActive() *bool {
if o == nil {
return nil
}
- return o.SecretKey
+ return o.Active
}
-// GetSecretKeyOk returns a tuple with the SecretKey field value
+// GetActiveOk returns a tuple with the Active field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3KeyProperties) GetSecretKeyOk() (*string, bool) {
+func (o *S3KeyProperties) GetActiveOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.SecretKey, true
+ return o.Active, true
}
-// SetSecretKey sets field value
-func (o *S3KeyProperties) SetSecretKey(v string) {
+// SetActive sets field value
+func (o *S3KeyProperties) SetActive(v bool) {
- o.SecretKey = &v
+ o.Active = &v
}
-// HasSecretKey returns a boolean if a field has been set.
-func (o *S3KeyProperties) HasSecretKey() bool {
- if o != nil && o.SecretKey != nil {
+// HasActive returns a boolean if a field has been set.
+func (o *S3KeyProperties) HasActive() bool {
+ if o != nil && o.Active != nil {
return true
}
return false
}
-// GetActive returns the Active field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *S3KeyProperties) GetActive() *bool {
+// GetSecretKey returns the SecretKey field value
+// If the value is explicit nil, nil is returned
+func (o *S3KeyProperties) GetSecretKey() *string {
if o == nil {
return nil
}
- return o.Active
+ return o.SecretKey
}
-// GetActiveOk returns a tuple with the Active field value
+// GetSecretKeyOk returns a tuple with the SecretKey field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3KeyProperties) GetActiveOk() (*bool, bool) {
+func (o *S3KeyProperties) GetSecretKeyOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Active, true
+ return o.SecretKey, true
}
-// SetActive sets field value
-func (o *S3KeyProperties) SetActive(v bool) {
+// SetSecretKey sets field value
+func (o *S3KeyProperties) SetSecretKey(v string) {
- o.Active = &v
+ o.SecretKey = &v
}
-// HasActive returns a boolean if a field has been set.
-func (o *S3KeyProperties) HasActive() bool {
- if o != nil && o.Active != nil {
+// HasSecretKey returns a boolean if a field has been set.
+func (o *S3KeyProperties) HasSecretKey() bool {
+ if o != nil && o.SecretKey != nil {
return true
}
@@ -118,12 +118,14 @@ func (o *S3KeyProperties) HasActive() bool {
func (o S3KeyProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.SecretKey != nil {
- toSerialize["secretKey"] = o.SecretKey
- }
if o.Active != nil {
toSerialize["active"] = o.Active
}
+
+ if o.SecretKey != nil {
+ toSerialize["secretKey"] = o.SecretKey
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_keys.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_keys.go
index a87bc2f76ac..d0ed78cc64b 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_keys.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_keys.go
@@ -16,14 +16,14 @@ import (
// S3Keys struct for S3Keys
type S3Keys struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of the resource.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]S3Key `json:"items,omitempty"`
+ // The type of the resource.
+ Type *Type `json:"type,omitempty"`
}
// NewS3Keys instantiates a new S3Keys object
@@ -44,152 +44,152 @@ func NewS3KeysWithDefaults() *S3Keys {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *S3Keys) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *S3Keys) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3Keys) GetIdOk() (*string, bool) {
+func (o *S3Keys) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *S3Keys) SetId(v string) {
+// SetHref sets field value
+func (o *S3Keys) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *S3Keys) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *S3Keys) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *S3Keys) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *S3Keys) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3Keys) GetTypeOk() (*Type, bool) {
+func (o *S3Keys) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *S3Keys) SetType(v Type) {
+// SetId sets field value
+func (o *S3Keys) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *S3Keys) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *S3Keys) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *S3Keys) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *S3Keys) GetItems() *[]S3Key {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3Keys) GetHrefOk() (*string, bool) {
+func (o *S3Keys) GetItemsOk() (*[]S3Key, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *S3Keys) SetHref(v string) {
+// SetItems sets field value
+func (o *S3Keys) SetItems(v []S3Key) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *S3Keys) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *S3Keys) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []S3Key will be returned
-func (o *S3Keys) GetItems() *[]S3Key {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *S3Keys) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *S3Keys) GetItemsOk() (*[]S3Key, bool) {
+func (o *S3Keys) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *S3Keys) SetItems(v []S3Key) {
+// SetType sets field value
+func (o *S3Keys) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *S3Keys) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *S3Keys) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *S3Keys) HasItems() bool {
func (o S3Keys) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_object_storage_sso.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_object_storage_sso.go
index 48eb4b166cb..809410a0487 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_object_storage_sso.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_s3_object_storage_sso.go
@@ -39,7 +39,7 @@ func NewS3ObjectStorageSSOWithDefaults() *S3ObjectStorageSSO {
}
// GetSsoUrl returns the SsoUrl field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *S3ObjectStorageSSO) GetSsoUrl() *string {
if o == nil {
return nil
@@ -81,6 +81,7 @@ func (o S3ObjectStorageSSO) MarshalJSON() ([]byte, error) {
if o.SsoUrl != nil {
toSerialize["ssoUrl"] = o.SsoUrl
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_server.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_server.go
index ad75b98a165..4002c4bda88 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_server.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_server.go
@@ -16,15 +16,15 @@ import (
// Server struct for Server
type Server struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Entities *ServerEntities `json:"entities,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *ServerProperties `json:"properties"`
- Entities *ServerEntities `json:"entities,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewServer instantiates a new Server object
@@ -47,114 +47,114 @@ func NewServerWithDefaults() *Server {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Server) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *Server) GetEntities() *ServerEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Server) GetIdOk() (*string, bool) {
+func (o *Server) GetEntitiesOk() (*ServerEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *Server) SetId(v string) {
+// SetEntities sets field value
+func (o *Server) SetEntities(v ServerEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Server) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *Server) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Server) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Server) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Server) GetTypeOk() (*Type, bool) {
+func (o *Server) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Server) SetType(v Type) {
+// SetHref sets field value
+func (o *Server) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Server) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Server) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Server) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Server) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Server) GetHrefOk() (*string, bool) {
+func (o *Server) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Server) SetHref(v string) {
+// SetId sets field value
+func (o *Server) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Server) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Server) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -162,7 +162,7 @@ func (o *Server) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *Server) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
@@ -200,7 +200,7 @@ func (o *Server) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for ServerProperties will be returned
+// If the value is explicit nil, nil is returned
func (o *Server) GetProperties() *ServerProperties {
if o == nil {
return nil
@@ -237,38 +237,38 @@ func (o *Server) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for ServerEntities will be returned
-func (o *Server) GetEntities() *ServerEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Server) GetType() *Type {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Server) GetEntitiesOk() (*ServerEntities, bool) {
+func (o *Server) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *Server) SetEntities(v ServerEntities) {
+// SetType sets field value
+func (o *Server) SetType(v Type) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *Server) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Server) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -277,24 +277,30 @@ func (o *Server) HasEntities() bool {
func (o Server) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_server_entities.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_server_entities.go
index fcb42fdb285..a2a8b8912d3 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_server_entities.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_server_entities.go
@@ -17,8 +17,8 @@ import (
// ServerEntities struct for ServerEntities
type ServerEntities struct {
Cdroms *Cdroms `json:"cdroms,omitempty"`
- Volumes *AttachedVolumes `json:"volumes,omitempty"`
Nics *Nics `json:"nics,omitempty"`
+ Volumes *AttachedVolumes `json:"volumes,omitempty"`
}
// NewServerEntities instantiates a new ServerEntities object
@@ -40,7 +40,7 @@ func NewServerEntitiesWithDefaults() *ServerEntities {
}
// GetCdroms returns the Cdroms field value
-// If the value is explicit nil, the zero value for Cdroms will be returned
+// If the value is explicit nil, nil is returned
func (o *ServerEntities) GetCdroms() *Cdroms {
if o == nil {
return nil
@@ -77,76 +77,76 @@ func (o *ServerEntities) HasCdroms() bool {
return false
}
-// GetVolumes returns the Volumes field value
-// If the value is explicit nil, the zero value for AttachedVolumes will be returned
-func (o *ServerEntities) GetVolumes() *AttachedVolumes {
+// GetNics returns the Nics field value
+// If the value is explicit nil, nil is returned
+func (o *ServerEntities) GetNics() *Nics {
if o == nil {
return nil
}
- return o.Volumes
+ return o.Nics
}
-// GetVolumesOk returns a tuple with the Volumes field value
+// GetNicsOk returns a tuple with the Nics field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ServerEntities) GetVolumesOk() (*AttachedVolumes, bool) {
+func (o *ServerEntities) GetNicsOk() (*Nics, bool) {
if o == nil {
return nil, false
}
- return o.Volumes, true
+ return o.Nics, true
}
-// SetVolumes sets field value
-func (o *ServerEntities) SetVolumes(v AttachedVolumes) {
+// SetNics sets field value
+func (o *ServerEntities) SetNics(v Nics) {
- o.Volumes = &v
+ o.Nics = &v
}
-// HasVolumes returns a boolean if a field has been set.
-func (o *ServerEntities) HasVolumes() bool {
- if o != nil && o.Volumes != nil {
+// HasNics returns a boolean if a field has been set.
+func (o *ServerEntities) HasNics() bool {
+ if o != nil && o.Nics != nil {
return true
}
return false
}
-// GetNics returns the Nics field value
-// If the value is explicit nil, the zero value for Nics will be returned
-func (o *ServerEntities) GetNics() *Nics {
+// GetVolumes returns the Volumes field value
+// If the value is explicit nil, nil is returned
+func (o *ServerEntities) GetVolumes() *AttachedVolumes {
if o == nil {
return nil
}
- return o.Nics
+ return o.Volumes
}
-// GetNicsOk returns a tuple with the Nics field value
+// GetVolumesOk returns a tuple with the Volumes field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ServerEntities) GetNicsOk() (*Nics, bool) {
+func (o *ServerEntities) GetVolumesOk() (*AttachedVolumes, bool) {
if o == nil {
return nil, false
}
- return o.Nics, true
+ return o.Volumes, true
}
-// SetNics sets field value
-func (o *ServerEntities) SetNics(v Nics) {
+// SetVolumes sets field value
+func (o *ServerEntities) SetVolumes(v AttachedVolumes) {
- o.Nics = &v
+ o.Volumes = &v
}
-// HasNics returns a boolean if a field has been set.
-func (o *ServerEntities) HasNics() bool {
- if o != nil && o.Nics != nil {
+// HasVolumes returns a boolean if a field has been set.
+func (o *ServerEntities) HasVolumes() bool {
+ if o != nil && o.Volumes != nil {
return true
}
@@ -158,12 +158,15 @@ func (o ServerEntities) MarshalJSON() ([]byte, error) {
if o.Cdroms != nil {
toSerialize["cdroms"] = o.Cdroms
}
- if o.Volumes != nil {
- toSerialize["volumes"] = o.Volumes
- }
+
if o.Nics != nil {
toSerialize["nics"] = o.Nics
}
+
+ if o.Volumes != nil {
+ toSerialize["volumes"] = o.Volumes
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_server_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_server_properties.go
index 4f292cde92e..5b81d95518d 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_server_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_server_properties.go
@@ -16,24 +16,26 @@ import (
// ServerProperties struct for ServerProperties
type ServerProperties struct {
- // The ID of the template for creating a CUBE server; the available templates for CUBE servers can be found on the templates resource.
- TemplateUuid *string `json:"templateUuid,omitempty"`
- // The name of the resource.
- Name *string `json:"name,omitempty"`
+ // The availability zone in which the server should be provisioned.
+ AvailabilityZone *string `json:"availabilityZone,omitempty"`
+ BootCdrom *ResourceReference `json:"bootCdrom,omitempty"`
+ BootVolume *ResourceReference `json:"bootVolume,omitempty"`
// The total number of cores for the enterprise server.
Cores *int32 `json:"cores,omitempty"`
- // The memory size for the enterprise server in MB, such as 2048. Size must be specified in multiples of 256 MB with a minimum of 256 MB; however, if you set ramHotPlug to TRUE then you must use a minimum of 1024 MB. If you set the RAM size more than 240GB, then ramHotPlug will be set to FALSE and can not be set to TRUE unless RAM size not set to less than 240GB.
- Ram *int32 `json:"ram,omitempty"`
- // The availability zone in which the server should be provisioned.
- AvailabilityZone *string `json:"availabilityZone,omitempty"`
- // Status of the virtual machine.
- VmState *string `json:"vmState,omitempty"`
- BootCdrom *ResourceReference `json:"bootCdrom,omitempty"`
- BootVolume *ResourceReference `json:"bootVolume,omitempty"`
// CPU architecture on which server gets provisioned; not all CPU architectures are available in all datacenter regions; available CPU architectures can be retrieved from the datacenter resource; must not be provided for CUBE servers.
CpuFamily *string `json:"cpuFamily,omitempty"`
- // Server type.
+ // The name of the resource.
+ Name *string `json:"name,omitempty"`
+ // The placement group ID that belongs to this server; Requires system privileges
+ PlacementGroupId *string `json:"placementGroupId,omitempty"`
+ // The memory size for the enterprise server in MB, such as 2048. Size must be specified in multiples of 256 MB with a minimum of 256 MB; however, if you set ramHotPlug to TRUE then you must use a minimum of 1024 MB. If you set the RAM size more than 240GB, then ramHotPlug will be set to FALSE and can not be set to TRUE unless RAM size not set to less than 240GB.
+ Ram *int32 `json:"ram,omitempty"`
+ // The ID of the template for creating a CUBE server; the available templates for CUBE servers can be found on the templates resource.
+ TemplateUuid *string `json:"templateUuid,omitempty"`
+ // Server type: CUBE or ENTERPRISE.
Type *string `json:"type,omitempty"`
+ // Status of the virtual machine.
+ VmState *string `json:"vmState,omitempty"`
}
// NewServerProperties instantiates a new ServerProperties object
@@ -54,342 +56,342 @@ func NewServerPropertiesWithDefaults() *ServerProperties {
return &this
}
-// GetTemplateUuid returns the TemplateUuid field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ServerProperties) GetTemplateUuid() *string {
+// GetAvailabilityZone returns the AvailabilityZone field value
+// If the value is explicit nil, nil is returned
+func (o *ServerProperties) GetAvailabilityZone() *string {
if o == nil {
return nil
}
- return o.TemplateUuid
+ return o.AvailabilityZone
}
-// GetTemplateUuidOk returns a tuple with the TemplateUuid field value
+// GetAvailabilityZoneOk returns a tuple with the AvailabilityZone field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ServerProperties) GetTemplateUuidOk() (*string, bool) {
+func (o *ServerProperties) GetAvailabilityZoneOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.TemplateUuid, true
+ return o.AvailabilityZone, true
}
-// SetTemplateUuid sets field value
-func (o *ServerProperties) SetTemplateUuid(v string) {
+// SetAvailabilityZone sets field value
+func (o *ServerProperties) SetAvailabilityZone(v string) {
- o.TemplateUuid = &v
+ o.AvailabilityZone = &v
}
-// HasTemplateUuid returns a boolean if a field has been set.
-func (o *ServerProperties) HasTemplateUuid() bool {
- if o != nil && o.TemplateUuid != nil {
+// HasAvailabilityZone returns a boolean if a field has been set.
+func (o *ServerProperties) HasAvailabilityZone() bool {
+ if o != nil && o.AvailabilityZone != nil {
return true
}
return false
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ServerProperties) GetName() *string {
+// GetBootCdrom returns the BootCdrom field value
+// If the value is explicit nil, nil is returned
+func (o *ServerProperties) GetBootCdrom() *ResourceReference {
if o == nil {
return nil
}
- return o.Name
+ return o.BootCdrom
}
-// GetNameOk returns a tuple with the Name field value
+// GetBootCdromOk returns a tuple with the BootCdrom field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ServerProperties) GetNameOk() (*string, bool) {
+func (o *ServerProperties) GetBootCdromOk() (*ResourceReference, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.BootCdrom, true
}
-// SetName sets field value
-func (o *ServerProperties) SetName(v string) {
+// SetBootCdrom sets field value
+func (o *ServerProperties) SetBootCdrom(v ResourceReference) {
- o.Name = &v
+ o.BootCdrom = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *ServerProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasBootCdrom returns a boolean if a field has been set.
+func (o *ServerProperties) HasBootCdrom() bool {
+ if o != nil && o.BootCdrom != nil {
return true
}
return false
}
-// GetCores returns the Cores field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ServerProperties) GetCores() *int32 {
+// GetBootVolume returns the BootVolume field value
+// If the value is explicit nil, nil is returned
+func (o *ServerProperties) GetBootVolume() *ResourceReference {
if o == nil {
return nil
}
- return o.Cores
+ return o.BootVolume
}
-// GetCoresOk returns a tuple with the Cores field value
+// GetBootVolumeOk returns a tuple with the BootVolume field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ServerProperties) GetCoresOk() (*int32, bool) {
+func (o *ServerProperties) GetBootVolumeOk() (*ResourceReference, bool) {
if o == nil {
return nil, false
}
- return o.Cores, true
+ return o.BootVolume, true
}
-// SetCores sets field value
-func (o *ServerProperties) SetCores(v int32) {
+// SetBootVolume sets field value
+func (o *ServerProperties) SetBootVolume(v ResourceReference) {
- o.Cores = &v
+ o.BootVolume = &v
}
-// HasCores returns a boolean if a field has been set.
-func (o *ServerProperties) HasCores() bool {
- if o != nil && o.Cores != nil {
+// HasBootVolume returns a boolean if a field has been set.
+func (o *ServerProperties) HasBootVolume() bool {
+ if o != nil && o.BootVolume != nil {
return true
}
return false
}
-// GetRam returns the Ram field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *ServerProperties) GetRam() *int32 {
+// GetCores returns the Cores field value
+// If the value is explicit nil, nil is returned
+func (o *ServerProperties) GetCores() *int32 {
if o == nil {
return nil
}
- return o.Ram
+ return o.Cores
}
-// GetRamOk returns a tuple with the Ram field value
+// GetCoresOk returns a tuple with the Cores field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ServerProperties) GetRamOk() (*int32, bool) {
+func (o *ServerProperties) GetCoresOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Ram, true
+ return o.Cores, true
}
-// SetRam sets field value
-func (o *ServerProperties) SetRam(v int32) {
+// SetCores sets field value
+func (o *ServerProperties) SetCores(v int32) {
- o.Ram = &v
+ o.Cores = &v
}
-// HasRam returns a boolean if a field has been set.
-func (o *ServerProperties) HasRam() bool {
- if o != nil && o.Ram != nil {
+// HasCores returns a boolean if a field has been set.
+func (o *ServerProperties) HasCores() bool {
+ if o != nil && o.Cores != nil {
return true
}
return false
}
-// GetAvailabilityZone returns the AvailabilityZone field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ServerProperties) GetAvailabilityZone() *string {
+// GetCpuFamily returns the CpuFamily field value
+// If the value is explicit nil, nil is returned
+func (o *ServerProperties) GetCpuFamily() *string {
if o == nil {
return nil
}
- return o.AvailabilityZone
+ return o.CpuFamily
}
-// GetAvailabilityZoneOk returns a tuple with the AvailabilityZone field value
+// GetCpuFamilyOk returns a tuple with the CpuFamily field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ServerProperties) GetAvailabilityZoneOk() (*string, bool) {
+func (o *ServerProperties) GetCpuFamilyOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.AvailabilityZone, true
+ return o.CpuFamily, true
}
-// SetAvailabilityZone sets field value
-func (o *ServerProperties) SetAvailabilityZone(v string) {
+// SetCpuFamily sets field value
+func (o *ServerProperties) SetCpuFamily(v string) {
- o.AvailabilityZone = &v
+ o.CpuFamily = &v
}
-// HasAvailabilityZone returns a boolean if a field has been set.
-func (o *ServerProperties) HasAvailabilityZone() bool {
- if o != nil && o.AvailabilityZone != nil {
+// HasCpuFamily returns a boolean if a field has been set.
+func (o *ServerProperties) HasCpuFamily() bool {
+ if o != nil && o.CpuFamily != nil {
return true
}
return false
}
-// GetVmState returns the VmState field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ServerProperties) GetVmState() *string {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *ServerProperties) GetName() *string {
if o == nil {
return nil
}
- return o.VmState
+ return o.Name
}
-// GetVmStateOk returns a tuple with the VmState field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ServerProperties) GetVmStateOk() (*string, bool) {
+func (o *ServerProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.VmState, true
+ return o.Name, true
}
-// SetVmState sets field value
-func (o *ServerProperties) SetVmState(v string) {
+// SetName sets field value
+func (o *ServerProperties) SetName(v string) {
- o.VmState = &v
+ o.Name = &v
}
-// HasVmState returns a boolean if a field has been set.
-func (o *ServerProperties) HasVmState() bool {
- if o != nil && o.VmState != nil {
+// HasName returns a boolean if a field has been set.
+func (o *ServerProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetBootCdrom returns the BootCdrom field value
-// If the value is explicit nil, the zero value for ResourceReference will be returned
-func (o *ServerProperties) GetBootCdrom() *ResourceReference {
+// GetPlacementGroupId returns the PlacementGroupId field value
+// If the value is explicit nil, nil is returned
+func (o *ServerProperties) GetPlacementGroupId() *string {
if o == nil {
return nil
}
- return o.BootCdrom
+ return o.PlacementGroupId
}
-// GetBootCdromOk returns a tuple with the BootCdrom field value
+// GetPlacementGroupIdOk returns a tuple with the PlacementGroupId field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ServerProperties) GetBootCdromOk() (*ResourceReference, bool) {
+func (o *ServerProperties) GetPlacementGroupIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.BootCdrom, true
+ return o.PlacementGroupId, true
}
-// SetBootCdrom sets field value
-func (o *ServerProperties) SetBootCdrom(v ResourceReference) {
+// SetPlacementGroupId sets field value
+func (o *ServerProperties) SetPlacementGroupId(v string) {
- o.BootCdrom = &v
+ o.PlacementGroupId = &v
}
-// HasBootCdrom returns a boolean if a field has been set.
-func (o *ServerProperties) HasBootCdrom() bool {
- if o != nil && o.BootCdrom != nil {
+// HasPlacementGroupId returns a boolean if a field has been set.
+func (o *ServerProperties) HasPlacementGroupId() bool {
+ if o != nil && o.PlacementGroupId != nil {
return true
}
return false
}
-// GetBootVolume returns the BootVolume field value
-// If the value is explicit nil, the zero value for ResourceReference will be returned
-func (o *ServerProperties) GetBootVolume() *ResourceReference {
+// GetRam returns the Ram field value
+// If the value is explicit nil, nil is returned
+func (o *ServerProperties) GetRam() *int32 {
if o == nil {
return nil
}
- return o.BootVolume
+ return o.Ram
}
-// GetBootVolumeOk returns a tuple with the BootVolume field value
+// GetRamOk returns a tuple with the Ram field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ServerProperties) GetBootVolumeOk() (*ResourceReference, bool) {
+func (o *ServerProperties) GetRamOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.BootVolume, true
+ return o.Ram, true
}
-// SetBootVolume sets field value
-func (o *ServerProperties) SetBootVolume(v ResourceReference) {
+// SetRam sets field value
+func (o *ServerProperties) SetRam(v int32) {
- o.BootVolume = &v
+ o.Ram = &v
}
-// HasBootVolume returns a boolean if a field has been set.
-func (o *ServerProperties) HasBootVolume() bool {
- if o != nil && o.BootVolume != nil {
+// HasRam returns a boolean if a field has been set.
+func (o *ServerProperties) HasRam() bool {
+ if o != nil && o.Ram != nil {
return true
}
return false
}
-// GetCpuFamily returns the CpuFamily field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *ServerProperties) GetCpuFamily() *string {
+// GetTemplateUuid returns the TemplateUuid field value
+// If the value is explicit nil, nil is returned
+func (o *ServerProperties) GetTemplateUuid() *string {
if o == nil {
return nil
}
- return o.CpuFamily
+ return o.TemplateUuid
}
-// GetCpuFamilyOk returns a tuple with the CpuFamily field value
+// GetTemplateUuidOk returns a tuple with the TemplateUuid field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *ServerProperties) GetCpuFamilyOk() (*string, bool) {
+func (o *ServerProperties) GetTemplateUuidOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.CpuFamily, true
+ return o.TemplateUuid, true
}
-// SetCpuFamily sets field value
-func (o *ServerProperties) SetCpuFamily(v string) {
+// SetTemplateUuid sets field value
+func (o *ServerProperties) SetTemplateUuid(v string) {
- o.CpuFamily = &v
+ o.TemplateUuid = &v
}
-// HasCpuFamily returns a boolean if a field has been set.
-func (o *ServerProperties) HasCpuFamily() bool {
- if o != nil && o.CpuFamily != nil {
+// HasTemplateUuid returns a boolean if a field has been set.
+func (o *ServerProperties) HasTemplateUuid() bool {
+ if o != nil && o.TemplateUuid != nil {
return true
}
@@ -397,7 +399,7 @@ func (o *ServerProperties) HasCpuFamily() bool {
}
// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *ServerProperties) GetType() *string {
if o == nil {
return nil
@@ -434,38 +436,90 @@ func (o *ServerProperties) HasType() bool {
return false
}
-func (o ServerProperties) MarshalJSON() ([]byte, error) {
- toSerialize := map[string]interface{}{}
- if o.TemplateUuid != nil {
- toSerialize["templateUuid"] = o.TemplateUuid
- }
- if o.Name != nil {
- toSerialize["name"] = o.Name
+// GetVmState returns the VmState field value
+// If the value is explicit nil, nil is returned
+func (o *ServerProperties) GetVmState() *string {
+ if o == nil {
+ return nil
}
- if o.Cores != nil {
- toSerialize["cores"] = o.Cores
+
+ return o.VmState
+
+}
+
+// GetVmStateOk returns a tuple with the VmState field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *ServerProperties) GetVmStateOk() (*string, bool) {
+ if o == nil {
+ return nil, false
}
- if o.Ram != nil {
- toSerialize["ram"] = o.Ram
+
+ return o.VmState, true
+}
+
+// SetVmState sets field value
+func (o *ServerProperties) SetVmState(v string) {
+
+ o.VmState = &v
+
+}
+
+// HasVmState returns a boolean if a field has been set.
+func (o *ServerProperties) HasVmState() bool {
+ if o != nil && o.VmState != nil {
+ return true
}
+
+ return false
+}
+
+func (o ServerProperties) MarshalJSON() ([]byte, error) {
+ toSerialize := map[string]interface{}{}
if o.AvailabilityZone != nil {
toSerialize["availabilityZone"] = o.AvailabilityZone
}
- if o.VmState != nil {
- toSerialize["vmState"] = o.VmState
- }
+
if o.BootCdrom != nil {
toSerialize["bootCdrom"] = o.BootCdrom
}
+
if o.BootVolume != nil {
toSerialize["bootVolume"] = o.BootVolume
}
+
+ if o.Cores != nil {
+ toSerialize["cores"] = o.Cores
+ }
+
if o.CpuFamily != nil {
toSerialize["cpuFamily"] = o.CpuFamily
}
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
+ if o.PlacementGroupId != nil {
+ toSerialize["placementGroupId"] = o.PlacementGroupId
+ }
+
+ if o.Ram != nil {
+ toSerialize["ram"] = o.Ram
+ }
+
+ if o.TemplateUuid != nil {
+ toSerialize["templateUuid"] = o.TemplateUuid
+ }
+
if o.Type != nil {
toSerialize["type"] = o.Type
}
+
+ if o.VmState != nil {
+ toSerialize["vmState"] = o.VmState
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_servers.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_servers.go
index 86fe0d2deea..789aeaeb575 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_servers.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_servers.go
@@ -16,19 +16,19 @@ import (
// Servers struct for Servers
type Servers struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Server `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewServers instantiates a new Servers object
@@ -49,114 +49,114 @@ func NewServersWithDefaults() *Servers {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Servers) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *Servers) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Servers) GetIdOk() (*string, bool) {
+func (o *Servers) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *Servers) SetId(v string) {
+// SetLinks sets field value
+func (o *Servers) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Servers) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *Servers) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Servers) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Servers) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Servers) GetTypeOk() (*Type, bool) {
+func (o *Servers) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Servers) SetType(v Type) {
+// SetHref sets field value
+func (o *Servers) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Servers) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Servers) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Servers) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Servers) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Servers) GetHrefOk() (*string, bool) {
+func (o *Servers) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Servers) SetHref(v string) {
+// SetId sets field value
+func (o *Servers) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Servers) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Servers) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *Servers) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Server will be returned
+// If the value is explicit nil, nil is returned
func (o *Servers) GetItems() *[]Server {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *Servers) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Servers) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *Servers) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Servers) GetOffsetOk() (*float32, bool) {
+func (o *Servers) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *Servers) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *Servers) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *Servers) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *Servers) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Servers) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *Servers) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Servers) GetLimitOk() (*float32, bool) {
+func (o *Servers) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *Servers) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *Servers) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *Servers) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *Servers) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *Servers) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Servers) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Servers) GetLinksOk() (*PaginationLinks, bool) {
+func (o *Servers) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *Servers) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *Servers) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *Servers) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Servers) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *Servers) HasLinks() bool {
func (o Servers) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_snapshot.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_snapshot.go
index 56ebb960da8..c42cc05467e 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_snapshot.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_snapshot.go
@@ -16,14 +16,14 @@ import (
// Snapshot struct for Snapshot
type Snapshot struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *SnapshotProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewSnapshot instantiates a new Snapshot object
@@ -46,190 +46,190 @@ func NewSnapshotWithDefaults() *Snapshot {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Snapshot) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Snapshot) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Snapshot) GetIdOk() (*string, bool) {
+func (o *Snapshot) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Snapshot) SetId(v string) {
+// SetHref sets field value
+func (o *Snapshot) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Snapshot) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Snapshot) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Snapshot) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Snapshot) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Snapshot) GetTypeOk() (*Type, bool) {
+func (o *Snapshot) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Snapshot) SetType(v Type) {
+// SetId sets field value
+func (o *Snapshot) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Snapshot) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Snapshot) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Snapshot) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *Snapshot) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Snapshot) GetHrefOk() (*string, bool) {
+func (o *Snapshot) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *Snapshot) SetHref(v string) {
+// SetMetadata sets field value
+func (o *Snapshot) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Snapshot) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *Snapshot) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *Snapshot) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *Snapshot) GetProperties() *SnapshotProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Snapshot) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *Snapshot) GetPropertiesOk() (*SnapshotProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *Snapshot) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *Snapshot) SetProperties(v SnapshotProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *Snapshot) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *Snapshot) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for SnapshotProperties will be returned
-func (o *Snapshot) GetProperties() *SnapshotProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Snapshot) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Snapshot) GetPropertiesOk() (*SnapshotProperties, bool) {
+func (o *Snapshot) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *Snapshot) SetProperties(v SnapshotProperties) {
+// SetType sets field value
+func (o *Snapshot) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *Snapshot) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Snapshot) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *Snapshot) HasProperties() bool {
func (o Snapshot) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_snapshot_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_snapshot_properties.go
index b42dca20cd5..5eb8cea6e68 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_snapshot_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_snapshot_properties.go
@@ -16,38 +16,38 @@ import (
// SnapshotProperties struct for SnapshotProperties
type SnapshotProperties struct {
- // The name of the resource.
- Name *string `json:"name,omitempty"`
- // Human-readable description.
- Description *string `json:"description,omitempty"`
- // Location of that image/snapshot.
- Location *string `json:"location,omitempty"`
- // The size of the image in GB.
- Size *float32 `json:"size,omitempty"`
- // Boolean value representing if the snapshot requires extra protection, such as two-step verification.
- SecAuthProtection *bool `json:"secAuthProtection,omitempty"`
// Hot-plug capable CPU (no reboot required).
CpuHotPlug *bool `json:"cpuHotPlug,omitempty"`
// Hot-unplug capable CPU (no reboot required).
CpuHotUnplug *bool `json:"cpuHotUnplug,omitempty"`
- // Hot-plug capable RAM (no reboot required).
- RamHotPlug *bool `json:"ramHotPlug,omitempty"`
- // Hot-unplug capable RAM (no reboot required).
- RamHotUnplug *bool `json:"ramHotUnplug,omitempty"`
- // Hot-plug capable NIC (no reboot required).
- NicHotPlug *bool `json:"nicHotPlug,omitempty"`
- // Hot-unplug capable NIC (no reboot required).
- NicHotUnplug *bool `json:"nicHotUnplug,omitempty"`
- // Hot-plug capable Virt-IO drive (no reboot required).
- DiscVirtioHotPlug *bool `json:"discVirtioHotPlug,omitempty"`
- // Hot-unplug capable Virt-IO drive (no reboot required). Not supported with Windows VMs.
- DiscVirtioHotUnplug *bool `json:"discVirtioHotUnplug,omitempty"`
+ // Human-readable description.
+ Description *string `json:"description,omitempty"`
// Hot-plug capable SCSI drive (no reboot required).
DiscScsiHotPlug *bool `json:"discScsiHotPlug,omitempty"`
// Is capable of SCSI drive hot unplug (no reboot required). This works only for non-Windows virtual Machines.
DiscScsiHotUnplug *bool `json:"discScsiHotUnplug,omitempty"`
+ // Hot-plug capable Virt-IO drive (no reboot required).
+ DiscVirtioHotPlug *bool `json:"discVirtioHotPlug,omitempty"`
+ // Hot-unplug capable Virt-IO drive (no reboot required). Not supported with Windows VMs.
+ DiscVirtioHotUnplug *bool `json:"discVirtioHotUnplug,omitempty"`
// OS type of this snapshot
LicenceType *string `json:"licenceType,omitempty"`
+ // Location of that image/snapshot.
+ Location *string `json:"location,omitempty"`
+ // The name of the resource.
+ Name *string `json:"name,omitempty"`
+ // Hot-plug capable NIC (no reboot required).
+ NicHotPlug *bool `json:"nicHotPlug,omitempty"`
+ // Hot-unplug capable NIC (no reboot required).
+ NicHotUnplug *bool `json:"nicHotUnplug,omitempty"`
+ // Hot-plug capable RAM (no reboot required).
+ RamHotPlug *bool `json:"ramHotPlug,omitempty"`
+ // Hot-unplug capable RAM (no reboot required).
+ RamHotUnplug *bool `json:"ramHotUnplug,omitempty"`
+ // Boolean value representing if the snapshot requires extra protection, such as two-step verification.
+ SecAuthProtection *bool `json:"secAuthProtection,omitempty"`
+ // The size of the image in GB.
+ Size *float32 `json:"size,omitempty"`
}
// NewSnapshotProperties instantiates a new SnapshotProperties object
@@ -68,38 +68,76 @@ func NewSnapshotPropertiesWithDefaults() *SnapshotProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *SnapshotProperties) GetName() *string {
+// GetCpuHotPlug returns the CpuHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetCpuHotPlug() *bool {
if o == nil {
return nil
}
- return o.Name
+ return o.CpuHotPlug
}
-// GetNameOk returns a tuple with the Name field value
+// GetCpuHotPlugOk returns a tuple with the CpuHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetNameOk() (*string, bool) {
+func (o *SnapshotProperties) GetCpuHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.CpuHotPlug, true
}
-// SetName sets field value
-func (o *SnapshotProperties) SetName(v string) {
+// SetCpuHotPlug sets field value
+func (o *SnapshotProperties) SetCpuHotPlug(v bool) {
- o.Name = &v
+ o.CpuHotPlug = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasCpuHotPlug returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasCpuHotPlug() bool {
+ if o != nil && o.CpuHotPlug != nil {
+ return true
+ }
+
+ return false
+}
+
+// GetCpuHotUnplug returns the CpuHotUnplug field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetCpuHotUnplug() *bool {
+ if o == nil {
+ return nil
+ }
+
+ return o.CpuHotUnplug
+
+}
+
+// GetCpuHotUnplugOk returns a tuple with the CpuHotUnplug field value
+// and a boolean to check if the value has been set.
+// NOTE: If the value is an explicit nil, `nil, true` will be returned
+func (o *SnapshotProperties) GetCpuHotUnplugOk() (*bool, bool) {
+ if o == nil {
+ return nil, false
+ }
+
+ return o.CpuHotUnplug, true
+}
+
+// SetCpuHotUnplug sets field value
+func (o *SnapshotProperties) SetCpuHotUnplug(v bool) {
+
+ o.CpuHotUnplug = &v
+
+}
+
+// HasCpuHotUnplug returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasCpuHotUnplug() bool {
+ if o != nil && o.CpuHotUnplug != nil {
return true
}
@@ -107,7 +145,7 @@ func (o *SnapshotProperties) HasName() bool {
}
// GetDescription returns the Description field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *SnapshotProperties) GetDescription() *string {
if o == nil {
return nil
@@ -144,266 +182,266 @@ func (o *SnapshotProperties) HasDescription() bool {
return false
}
-// GetLocation returns the Location field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *SnapshotProperties) GetLocation() *string {
+// GetDiscScsiHotPlug returns the DiscScsiHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetDiscScsiHotPlug() *bool {
if o == nil {
return nil
}
- return o.Location
+ return o.DiscScsiHotPlug
}
-// GetLocationOk returns a tuple with the Location field value
+// GetDiscScsiHotPlugOk returns a tuple with the DiscScsiHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetLocationOk() (*string, bool) {
+func (o *SnapshotProperties) GetDiscScsiHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Location, true
+ return o.DiscScsiHotPlug, true
}
-// SetLocation sets field value
-func (o *SnapshotProperties) SetLocation(v string) {
+// SetDiscScsiHotPlug sets field value
+func (o *SnapshotProperties) SetDiscScsiHotPlug(v bool) {
- o.Location = &v
+ o.DiscScsiHotPlug = &v
}
-// HasLocation returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasLocation() bool {
- if o != nil && o.Location != nil {
+// HasDiscScsiHotPlug returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasDiscScsiHotPlug() bool {
+ if o != nil && o.DiscScsiHotPlug != nil {
return true
}
return false
}
-// GetSize returns the Size field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *SnapshotProperties) GetSize() *float32 {
+// GetDiscScsiHotUnplug returns the DiscScsiHotUnplug field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetDiscScsiHotUnplug() *bool {
if o == nil {
return nil
}
- return o.Size
+ return o.DiscScsiHotUnplug
}
-// GetSizeOk returns a tuple with the Size field value
+// GetDiscScsiHotUnplugOk returns a tuple with the DiscScsiHotUnplug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetSizeOk() (*float32, bool) {
+func (o *SnapshotProperties) GetDiscScsiHotUnplugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Size, true
+ return o.DiscScsiHotUnplug, true
}
-// SetSize sets field value
-func (o *SnapshotProperties) SetSize(v float32) {
+// SetDiscScsiHotUnplug sets field value
+func (o *SnapshotProperties) SetDiscScsiHotUnplug(v bool) {
- o.Size = &v
+ o.DiscScsiHotUnplug = &v
}
-// HasSize returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasSize() bool {
- if o != nil && o.Size != nil {
+// HasDiscScsiHotUnplug returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasDiscScsiHotUnplug() bool {
+ if o != nil && o.DiscScsiHotUnplug != nil {
return true
}
return false
}
-// GetSecAuthProtection returns the SecAuthProtection field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *SnapshotProperties) GetSecAuthProtection() *bool {
+// GetDiscVirtioHotPlug returns the DiscVirtioHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetDiscVirtioHotPlug() *bool {
if o == nil {
return nil
}
- return o.SecAuthProtection
+ return o.DiscVirtioHotPlug
}
-// GetSecAuthProtectionOk returns a tuple with the SecAuthProtection field value
+// GetDiscVirtioHotPlugOk returns a tuple with the DiscVirtioHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetSecAuthProtectionOk() (*bool, bool) {
+func (o *SnapshotProperties) GetDiscVirtioHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.SecAuthProtection, true
+ return o.DiscVirtioHotPlug, true
}
-// SetSecAuthProtection sets field value
-func (o *SnapshotProperties) SetSecAuthProtection(v bool) {
+// SetDiscVirtioHotPlug sets field value
+func (o *SnapshotProperties) SetDiscVirtioHotPlug(v bool) {
- o.SecAuthProtection = &v
+ o.DiscVirtioHotPlug = &v
}
-// HasSecAuthProtection returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasSecAuthProtection() bool {
- if o != nil && o.SecAuthProtection != nil {
+// HasDiscVirtioHotPlug returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasDiscVirtioHotPlug() bool {
+ if o != nil && o.DiscVirtioHotPlug != nil {
return true
}
return false
}
-// GetCpuHotPlug returns the CpuHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *SnapshotProperties) GetCpuHotPlug() *bool {
+// GetDiscVirtioHotUnplug returns the DiscVirtioHotUnplug field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetDiscVirtioHotUnplug() *bool {
if o == nil {
return nil
}
- return o.CpuHotPlug
+ return o.DiscVirtioHotUnplug
}
-// GetCpuHotPlugOk returns a tuple with the CpuHotPlug field value
+// GetDiscVirtioHotUnplugOk returns a tuple with the DiscVirtioHotUnplug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetCpuHotPlugOk() (*bool, bool) {
+func (o *SnapshotProperties) GetDiscVirtioHotUnplugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.CpuHotPlug, true
+ return o.DiscVirtioHotUnplug, true
}
-// SetCpuHotPlug sets field value
-func (o *SnapshotProperties) SetCpuHotPlug(v bool) {
+// SetDiscVirtioHotUnplug sets field value
+func (o *SnapshotProperties) SetDiscVirtioHotUnplug(v bool) {
- o.CpuHotPlug = &v
+ o.DiscVirtioHotUnplug = &v
}
-// HasCpuHotPlug returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasCpuHotPlug() bool {
- if o != nil && o.CpuHotPlug != nil {
+// HasDiscVirtioHotUnplug returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasDiscVirtioHotUnplug() bool {
+ if o != nil && o.DiscVirtioHotUnplug != nil {
return true
}
return false
}
-// GetCpuHotUnplug returns the CpuHotUnplug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *SnapshotProperties) GetCpuHotUnplug() *bool {
+// GetLicenceType returns the LicenceType field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetLicenceType() *string {
if o == nil {
return nil
}
- return o.CpuHotUnplug
+ return o.LicenceType
}
-// GetCpuHotUnplugOk returns a tuple with the CpuHotUnplug field value
+// GetLicenceTypeOk returns a tuple with the LicenceType field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetCpuHotUnplugOk() (*bool, bool) {
+func (o *SnapshotProperties) GetLicenceTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.CpuHotUnplug, true
+ return o.LicenceType, true
}
-// SetCpuHotUnplug sets field value
-func (o *SnapshotProperties) SetCpuHotUnplug(v bool) {
+// SetLicenceType sets field value
+func (o *SnapshotProperties) SetLicenceType(v string) {
- o.CpuHotUnplug = &v
+ o.LicenceType = &v
}
-// HasCpuHotUnplug returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasCpuHotUnplug() bool {
- if o != nil && o.CpuHotUnplug != nil {
+// HasLicenceType returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasLicenceType() bool {
+ if o != nil && o.LicenceType != nil {
return true
}
return false
}
-// GetRamHotPlug returns the RamHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *SnapshotProperties) GetRamHotPlug() *bool {
+// GetLocation returns the Location field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetLocation() *string {
if o == nil {
return nil
}
- return o.RamHotPlug
+ return o.Location
}
-// GetRamHotPlugOk returns a tuple with the RamHotPlug field value
+// GetLocationOk returns a tuple with the Location field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetRamHotPlugOk() (*bool, bool) {
+func (o *SnapshotProperties) GetLocationOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.RamHotPlug, true
+ return o.Location, true
}
-// SetRamHotPlug sets field value
-func (o *SnapshotProperties) SetRamHotPlug(v bool) {
+// SetLocation sets field value
+func (o *SnapshotProperties) SetLocation(v string) {
- o.RamHotPlug = &v
+ o.Location = &v
}
-// HasRamHotPlug returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasRamHotPlug() bool {
- if o != nil && o.RamHotPlug != nil {
+// HasLocation returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasLocation() bool {
+ if o != nil && o.Location != nil {
return true
}
return false
}
-// GetRamHotUnplug returns the RamHotUnplug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *SnapshotProperties) GetRamHotUnplug() *bool {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetName() *string {
if o == nil {
return nil
}
- return o.RamHotUnplug
+ return o.Name
}
-// GetRamHotUnplugOk returns a tuple with the RamHotUnplug field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetRamHotUnplugOk() (*bool, bool) {
+func (o *SnapshotProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.RamHotUnplug, true
+ return o.Name, true
}
-// SetRamHotUnplug sets field value
-func (o *SnapshotProperties) SetRamHotUnplug(v bool) {
+// SetName sets field value
+func (o *SnapshotProperties) SetName(v string) {
- o.RamHotUnplug = &v
+ o.Name = &v
}
-// HasRamHotUnplug returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasRamHotUnplug() bool {
- if o != nil && o.RamHotUnplug != nil {
+// HasName returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -411,7 +449,7 @@ func (o *SnapshotProperties) HasRamHotUnplug() bool {
}
// GetNicHotPlug returns the NicHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *SnapshotProperties) GetNicHotPlug() *bool {
if o == nil {
return nil
@@ -449,7 +487,7 @@ func (o *SnapshotProperties) HasNicHotPlug() bool {
}
// GetNicHotUnplug returns the NicHotUnplug field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *SnapshotProperties) GetNicHotUnplug() *bool {
if o == nil {
return nil
@@ -486,246 +524,224 @@ func (o *SnapshotProperties) HasNicHotUnplug() bool {
return false
}
-// GetDiscVirtioHotPlug returns the DiscVirtioHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *SnapshotProperties) GetDiscVirtioHotPlug() *bool {
+// GetRamHotPlug returns the RamHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetRamHotPlug() *bool {
if o == nil {
return nil
}
- return o.DiscVirtioHotPlug
+ return o.RamHotPlug
}
-// GetDiscVirtioHotPlugOk returns a tuple with the DiscVirtioHotPlug field value
+// GetRamHotPlugOk returns a tuple with the RamHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetDiscVirtioHotPlugOk() (*bool, bool) {
+func (o *SnapshotProperties) GetRamHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.DiscVirtioHotPlug, true
+ return o.RamHotPlug, true
}
-// SetDiscVirtioHotPlug sets field value
-func (o *SnapshotProperties) SetDiscVirtioHotPlug(v bool) {
+// SetRamHotPlug sets field value
+func (o *SnapshotProperties) SetRamHotPlug(v bool) {
- o.DiscVirtioHotPlug = &v
+ o.RamHotPlug = &v
}
-// HasDiscVirtioHotPlug returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasDiscVirtioHotPlug() bool {
- if o != nil && o.DiscVirtioHotPlug != nil {
+// HasRamHotPlug returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasRamHotPlug() bool {
+ if o != nil && o.RamHotPlug != nil {
return true
}
return false
}
-// GetDiscVirtioHotUnplug returns the DiscVirtioHotUnplug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *SnapshotProperties) GetDiscVirtioHotUnplug() *bool {
+// GetRamHotUnplug returns the RamHotUnplug field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetRamHotUnplug() *bool {
if o == nil {
return nil
}
- return o.DiscVirtioHotUnplug
+ return o.RamHotUnplug
}
-// GetDiscVirtioHotUnplugOk returns a tuple with the DiscVirtioHotUnplug field value
+// GetRamHotUnplugOk returns a tuple with the RamHotUnplug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetDiscVirtioHotUnplugOk() (*bool, bool) {
+func (o *SnapshotProperties) GetRamHotUnplugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.DiscVirtioHotUnplug, true
+ return o.RamHotUnplug, true
}
-// SetDiscVirtioHotUnplug sets field value
-func (o *SnapshotProperties) SetDiscVirtioHotUnplug(v bool) {
+// SetRamHotUnplug sets field value
+func (o *SnapshotProperties) SetRamHotUnplug(v bool) {
- o.DiscVirtioHotUnplug = &v
+ o.RamHotUnplug = &v
}
-// HasDiscVirtioHotUnplug returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasDiscVirtioHotUnplug() bool {
- if o != nil && o.DiscVirtioHotUnplug != nil {
+// HasRamHotUnplug returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasRamHotUnplug() bool {
+ if o != nil && o.RamHotUnplug != nil {
return true
}
return false
}
-// GetDiscScsiHotPlug returns the DiscScsiHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *SnapshotProperties) GetDiscScsiHotPlug() *bool {
+// GetSecAuthProtection returns the SecAuthProtection field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetSecAuthProtection() *bool {
if o == nil {
return nil
}
- return o.DiscScsiHotPlug
+ return o.SecAuthProtection
}
-// GetDiscScsiHotPlugOk returns a tuple with the DiscScsiHotPlug field value
+// GetSecAuthProtectionOk returns a tuple with the SecAuthProtection field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetDiscScsiHotPlugOk() (*bool, bool) {
+func (o *SnapshotProperties) GetSecAuthProtectionOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.DiscScsiHotPlug, true
+ return o.SecAuthProtection, true
}
-// SetDiscScsiHotPlug sets field value
-func (o *SnapshotProperties) SetDiscScsiHotPlug(v bool) {
+// SetSecAuthProtection sets field value
+func (o *SnapshotProperties) SetSecAuthProtection(v bool) {
- o.DiscScsiHotPlug = &v
+ o.SecAuthProtection = &v
}
-// HasDiscScsiHotPlug returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasDiscScsiHotPlug() bool {
- if o != nil && o.DiscScsiHotPlug != nil {
+// HasSecAuthProtection returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasSecAuthProtection() bool {
+ if o != nil && o.SecAuthProtection != nil {
return true
}
return false
}
-// GetDiscScsiHotUnplug returns the DiscScsiHotUnplug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *SnapshotProperties) GetDiscScsiHotUnplug() *bool {
+// GetSize returns the Size field value
+// If the value is explicit nil, nil is returned
+func (o *SnapshotProperties) GetSize() *float32 {
if o == nil {
return nil
}
- return o.DiscScsiHotUnplug
+ return o.Size
}
-// GetDiscScsiHotUnplugOk returns a tuple with the DiscScsiHotUnplug field value
+// GetSizeOk returns a tuple with the Size field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetDiscScsiHotUnplugOk() (*bool, bool) {
+func (o *SnapshotProperties) GetSizeOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.DiscScsiHotUnplug, true
+ return o.Size, true
}
-// SetDiscScsiHotUnplug sets field value
-func (o *SnapshotProperties) SetDiscScsiHotUnplug(v bool) {
+// SetSize sets field value
+func (o *SnapshotProperties) SetSize(v float32) {
- o.DiscScsiHotUnplug = &v
+ o.Size = &v
}
-// HasDiscScsiHotUnplug returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasDiscScsiHotUnplug() bool {
- if o != nil && o.DiscScsiHotUnplug != nil {
+// HasSize returns a boolean if a field has been set.
+func (o *SnapshotProperties) HasSize() bool {
+ if o != nil && o.Size != nil {
return true
}
return false
}
-// GetLicenceType returns the LicenceType field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *SnapshotProperties) GetLicenceType() *string {
- if o == nil {
- return nil
+func (o SnapshotProperties) MarshalJSON() ([]byte, error) {
+ toSerialize := map[string]interface{}{}
+ if o.CpuHotPlug != nil {
+ toSerialize["cpuHotPlug"] = o.CpuHotPlug
}
- return o.LicenceType
-
-}
-
-// GetLicenceTypeOk returns a tuple with the LicenceType field value
-// and a boolean to check if the value has been set.
-// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *SnapshotProperties) GetLicenceTypeOk() (*string, bool) {
- if o == nil {
- return nil, false
+ if o.CpuHotUnplug != nil {
+ toSerialize["cpuHotUnplug"] = o.CpuHotUnplug
}
- return o.LicenceType, true
-}
-
-// SetLicenceType sets field value
-func (o *SnapshotProperties) SetLicenceType(v string) {
-
- o.LicenceType = &v
+ if o.Description != nil {
+ toSerialize["description"] = o.Description
+ }
-}
+ if o.DiscScsiHotPlug != nil {
+ toSerialize["discScsiHotPlug"] = o.DiscScsiHotPlug
+ }
-// HasLicenceType returns a boolean if a field has been set.
-func (o *SnapshotProperties) HasLicenceType() bool {
- if o != nil && o.LicenceType != nil {
- return true
+ if o.DiscScsiHotUnplug != nil {
+ toSerialize["discScsiHotUnplug"] = o.DiscScsiHotUnplug
}
- return false
-}
+ if o.DiscVirtioHotPlug != nil {
+ toSerialize["discVirtioHotPlug"] = o.DiscVirtioHotPlug
+ }
-func (o SnapshotProperties) MarshalJSON() ([]byte, error) {
- toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
+ if o.DiscVirtioHotUnplug != nil {
+ toSerialize["discVirtioHotUnplug"] = o.DiscVirtioHotUnplug
}
- if o.Description != nil {
- toSerialize["description"] = o.Description
+
+ if o.LicenceType != nil {
+ toSerialize["licenceType"] = o.LicenceType
}
+
if o.Location != nil {
toSerialize["location"] = o.Location
}
- if o.Size != nil {
- toSerialize["size"] = o.Size
- }
- if o.SecAuthProtection != nil {
- toSerialize["secAuthProtection"] = o.SecAuthProtection
- }
- if o.CpuHotPlug != nil {
- toSerialize["cpuHotPlug"] = o.CpuHotPlug
- }
- if o.CpuHotUnplug != nil {
- toSerialize["cpuHotUnplug"] = o.CpuHotUnplug
- }
- if o.RamHotPlug != nil {
- toSerialize["ramHotPlug"] = o.RamHotPlug
- }
- if o.RamHotUnplug != nil {
- toSerialize["ramHotUnplug"] = o.RamHotUnplug
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
}
+
if o.NicHotPlug != nil {
toSerialize["nicHotPlug"] = o.NicHotPlug
}
+
if o.NicHotUnplug != nil {
toSerialize["nicHotUnplug"] = o.NicHotUnplug
}
- if o.DiscVirtioHotPlug != nil {
- toSerialize["discVirtioHotPlug"] = o.DiscVirtioHotPlug
- }
- if o.DiscVirtioHotUnplug != nil {
- toSerialize["discVirtioHotUnplug"] = o.DiscVirtioHotUnplug
+
+ if o.RamHotPlug != nil {
+ toSerialize["ramHotPlug"] = o.RamHotPlug
}
- if o.DiscScsiHotPlug != nil {
- toSerialize["discScsiHotPlug"] = o.DiscScsiHotPlug
+
+ if o.RamHotUnplug != nil {
+ toSerialize["ramHotUnplug"] = o.RamHotUnplug
}
- if o.DiscScsiHotUnplug != nil {
- toSerialize["discScsiHotUnplug"] = o.DiscScsiHotUnplug
+
+ if o.SecAuthProtection != nil {
+ toSerialize["secAuthProtection"] = o.SecAuthProtection
}
- if o.LicenceType != nil {
- toSerialize["licenceType"] = o.LicenceType
+
+ if o.Size != nil {
+ toSerialize["size"] = o.Size
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_snapshots.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_snapshots.go
index 8578d03ddaa..313d03e0927 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_snapshots.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_snapshots.go
@@ -16,14 +16,14 @@ import (
// Snapshots struct for Snapshots
type Snapshots struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Snapshot `json:"items,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewSnapshots instantiates a new Snapshots object
@@ -44,152 +44,152 @@ func NewSnapshotsWithDefaults() *Snapshots {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Snapshots) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Snapshots) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Snapshots) GetIdOk() (*string, bool) {
+func (o *Snapshots) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Snapshots) SetId(v string) {
+// SetHref sets field value
+func (o *Snapshots) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Snapshots) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Snapshots) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Snapshots) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Snapshots) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Snapshots) GetTypeOk() (*Type, bool) {
+func (o *Snapshots) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Snapshots) SetType(v Type) {
+// SetId sets field value
+func (o *Snapshots) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Snapshots) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Snapshots) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Snapshots) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *Snapshots) GetItems() *[]Snapshot {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Snapshots) GetHrefOk() (*string, bool) {
+func (o *Snapshots) GetItemsOk() (*[]Snapshot, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *Snapshots) SetHref(v string) {
+// SetItems sets field value
+func (o *Snapshots) SetItems(v []Snapshot) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Snapshots) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *Snapshots) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Snapshot will be returned
-func (o *Snapshots) GetItems() *[]Snapshot {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Snapshots) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Snapshots) GetItemsOk() (*[]Snapshot, bool) {
+func (o *Snapshots) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *Snapshots) SetItems(v []Snapshot) {
+// SetType sets field value
+func (o *Snapshots) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *Snapshots) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Snapshots) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *Snapshots) HasItems() bool {
func (o Snapshots) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group.go
index 95d71efeae1..cbfb0271f45 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group.go
@@ -16,14 +16,14 @@ import (
// TargetGroup struct for TargetGroup
type TargetGroup struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *TargetGroupProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewTargetGroup instantiates a new TargetGroup object
@@ -46,190 +46,190 @@ func NewTargetGroupWithDefaults() *TargetGroup {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroup) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroup) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroup) GetIdOk() (*string, bool) {
+func (o *TargetGroup) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *TargetGroup) SetId(v string) {
+// SetHref sets field value
+func (o *TargetGroup) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *TargetGroup) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *TargetGroup) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *TargetGroup) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroup) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroup) GetTypeOk() (*Type, bool) {
+func (o *TargetGroup) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *TargetGroup) SetType(v Type) {
+// SetId sets field value
+func (o *TargetGroup) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *TargetGroup) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *TargetGroup) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroup) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroup) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroup) GetHrefOk() (*string, bool) {
+func (o *TargetGroup) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *TargetGroup) SetHref(v string) {
+// SetMetadata sets field value
+func (o *TargetGroup) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *TargetGroup) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *TargetGroup) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *TargetGroup) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroup) GetProperties() *TargetGroupProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroup) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *TargetGroup) GetPropertiesOk() (*TargetGroupProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *TargetGroup) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *TargetGroup) SetProperties(v TargetGroupProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *TargetGroup) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *TargetGroup) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for TargetGroupProperties will be returned
-func (o *TargetGroup) GetProperties() *TargetGroupProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroup) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroup) GetPropertiesOk() (*TargetGroupProperties, bool) {
+func (o *TargetGroup) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *TargetGroup) SetProperties(v TargetGroupProperties) {
+// SetType sets field value
+func (o *TargetGroup) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *TargetGroup) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *TargetGroup) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *TargetGroup) HasProperties() bool {
func (o TargetGroup) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_health_check.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_health_check.go
index 5c8dfdfc6d3..70ca3dc637c 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_health_check.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_health_check.go
@@ -16,10 +16,10 @@ import (
// TargetGroupHealthCheck struct for TargetGroupHealthCheck
type TargetGroupHealthCheck struct {
- // The maximum time in milliseconds is to wait for a target to respond to a check. For target VMs with a 'Check Interval' set, the smaller of the two values is used once the TCP connection is established.
- CheckTimeout *int32 `json:"checkTimeout,omitempty"`
// The interval in milliseconds between consecutive health checks; the default value is '2000'.
CheckInterval *int32 `json:"checkInterval,omitempty"`
+ // The maximum time in milliseconds is to wait for a target to respond to a check. For target VMs with a 'Check Interval' set, the smaller of the two values is used once the TCP connection is established.
+ CheckTimeout *int32 `json:"checkTimeout,omitempty"`
// The maximum number of attempts to reconnect to a target after a connection failure. The valid range is '0 to 65535'; the default value is '3'.
Retries *int32 `json:"retries,omitempty"`
}
@@ -42,76 +42,76 @@ func NewTargetGroupHealthCheckWithDefaults() *TargetGroupHealthCheck {
return &this
}
-// GetCheckTimeout returns the CheckTimeout field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *TargetGroupHealthCheck) GetCheckTimeout() *int32 {
+// GetCheckInterval returns the CheckInterval field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupHealthCheck) GetCheckInterval() *int32 {
if o == nil {
return nil
}
- return o.CheckTimeout
+ return o.CheckInterval
}
-// GetCheckTimeoutOk returns a tuple with the CheckTimeout field value
+// GetCheckIntervalOk returns a tuple with the CheckInterval field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupHealthCheck) GetCheckTimeoutOk() (*int32, bool) {
+func (o *TargetGroupHealthCheck) GetCheckIntervalOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.CheckTimeout, true
+ return o.CheckInterval, true
}
-// SetCheckTimeout sets field value
-func (o *TargetGroupHealthCheck) SetCheckTimeout(v int32) {
+// SetCheckInterval sets field value
+func (o *TargetGroupHealthCheck) SetCheckInterval(v int32) {
- o.CheckTimeout = &v
+ o.CheckInterval = &v
}
-// HasCheckTimeout returns a boolean if a field has been set.
-func (o *TargetGroupHealthCheck) HasCheckTimeout() bool {
- if o != nil && o.CheckTimeout != nil {
+// HasCheckInterval returns a boolean if a field has been set.
+func (o *TargetGroupHealthCheck) HasCheckInterval() bool {
+ if o != nil && o.CheckInterval != nil {
return true
}
return false
}
-// GetCheckInterval returns the CheckInterval field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *TargetGroupHealthCheck) GetCheckInterval() *int32 {
+// GetCheckTimeout returns the CheckTimeout field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupHealthCheck) GetCheckTimeout() *int32 {
if o == nil {
return nil
}
- return o.CheckInterval
+ return o.CheckTimeout
}
-// GetCheckIntervalOk returns a tuple with the CheckInterval field value
+// GetCheckTimeoutOk returns a tuple with the CheckTimeout field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupHealthCheck) GetCheckIntervalOk() (*int32, bool) {
+func (o *TargetGroupHealthCheck) GetCheckTimeoutOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.CheckInterval, true
+ return o.CheckTimeout, true
}
-// SetCheckInterval sets field value
-func (o *TargetGroupHealthCheck) SetCheckInterval(v int32) {
+// SetCheckTimeout sets field value
+func (o *TargetGroupHealthCheck) SetCheckTimeout(v int32) {
- o.CheckInterval = &v
+ o.CheckTimeout = &v
}
-// HasCheckInterval returns a boolean if a field has been set.
-func (o *TargetGroupHealthCheck) HasCheckInterval() bool {
- if o != nil && o.CheckInterval != nil {
+// HasCheckTimeout returns a boolean if a field has been set.
+func (o *TargetGroupHealthCheck) HasCheckTimeout() bool {
+ if o != nil && o.CheckTimeout != nil {
return true
}
@@ -119,7 +119,7 @@ func (o *TargetGroupHealthCheck) HasCheckInterval() bool {
}
// GetRetries returns the Retries field value
-// If the value is explicit nil, the zero value for int32 will be returned
+// If the value is explicit nil, nil is returned
func (o *TargetGroupHealthCheck) GetRetries() *int32 {
if o == nil {
return nil
@@ -158,15 +158,18 @@ func (o *TargetGroupHealthCheck) HasRetries() bool {
func (o TargetGroupHealthCheck) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.CheckTimeout != nil {
- toSerialize["checkTimeout"] = o.CheckTimeout
- }
if o.CheckInterval != nil {
toSerialize["checkInterval"] = o.CheckInterval
}
+
+ if o.CheckTimeout != nil {
+ toSerialize["checkTimeout"] = o.CheckTimeout
+ }
+
if o.Retries != nil {
toSerialize["retries"] = o.Retries
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_http_health_check.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_http_health_check.go
index 274f7b91126..dc31f49508a 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_http_health_check.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_http_health_check.go
@@ -16,18 +16,18 @@ import (
// TargetGroupHttpHealthCheck struct for TargetGroupHttpHealthCheck
type TargetGroupHttpHealthCheck struct {
- // The destination URL for HTTP the health check; the default is '/'.
- Path *string `json:"path,omitempty"`
- // The method used for the health check request.
- Method *string `json:"method,omitempty"`
// Specify the target's response type to match ALB's request.
MatchType *string `json:"matchType"`
- // The response returned by the request. It can be a status code or a response body depending on the definition of 'matchType'.
- Response *string `json:"response"`
- // Specifies whether to use a regular expression to parse the response body; the default value is 'FALSE'. By using regular expressions, you can flexibly customize the expected response from a healthy server.
- Regex *bool `json:"regex,omitempty"`
+ // The method used for the health check request.
+ Method *string `json:"method,omitempty"`
// Specifies whether to negate an individual entry; the default value is 'FALSE'.
Negate *bool `json:"negate,omitempty"`
+ // The destination URL for HTTP the health check; the default is '/'.
+ Path *string `json:"path,omitempty"`
+ // Specifies whether to use a regular expression to parse the response body; the default value is 'FALSE'. By using regular expressions, you can flexibly customize the expected response from a healthy server.
+ Regex *bool `json:"regex,omitempty"`
+ // The response returned by the request. It can be a status code or a response body depending on the definition of 'matchType'.
+ Response *string `json:"response"`
}
// NewTargetGroupHttpHealthCheck instantiates a new TargetGroupHttpHealthCheck object
@@ -51,38 +51,38 @@ func NewTargetGroupHttpHealthCheckWithDefaults() *TargetGroupHttpHealthCheck {
return &this
}
-// GetPath returns the Path field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroupHttpHealthCheck) GetPath() *string {
+// GetMatchType returns the MatchType field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupHttpHealthCheck) GetMatchType() *string {
if o == nil {
return nil
}
- return o.Path
+ return o.MatchType
}
-// GetPathOk returns a tuple with the Path field value
+// GetMatchTypeOk returns a tuple with the MatchType field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupHttpHealthCheck) GetPathOk() (*string, bool) {
+func (o *TargetGroupHttpHealthCheck) GetMatchTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Path, true
+ return o.MatchType, true
}
-// SetPath sets field value
-func (o *TargetGroupHttpHealthCheck) SetPath(v string) {
+// SetMatchType sets field value
+func (o *TargetGroupHttpHealthCheck) SetMatchType(v string) {
- o.Path = &v
+ o.MatchType = &v
}
-// HasPath returns a boolean if a field has been set.
-func (o *TargetGroupHttpHealthCheck) HasPath() bool {
- if o != nil && o.Path != nil {
+// HasMatchType returns a boolean if a field has been set.
+func (o *TargetGroupHttpHealthCheck) HasMatchType() bool {
+ if o != nil && o.MatchType != nil {
return true
}
@@ -90,7 +90,7 @@ func (o *TargetGroupHttpHealthCheck) HasPath() bool {
}
// GetMethod returns the Method field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *TargetGroupHttpHealthCheck) GetMethod() *string {
if o == nil {
return nil
@@ -127,76 +127,76 @@ func (o *TargetGroupHttpHealthCheck) HasMethod() bool {
return false
}
-// GetMatchType returns the MatchType field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroupHttpHealthCheck) GetMatchType() *string {
+// GetNegate returns the Negate field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupHttpHealthCheck) GetNegate() *bool {
if o == nil {
return nil
}
- return o.MatchType
+ return o.Negate
}
-// GetMatchTypeOk returns a tuple with the MatchType field value
+// GetNegateOk returns a tuple with the Negate field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupHttpHealthCheck) GetMatchTypeOk() (*string, bool) {
+func (o *TargetGroupHttpHealthCheck) GetNegateOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.MatchType, true
+ return o.Negate, true
}
-// SetMatchType sets field value
-func (o *TargetGroupHttpHealthCheck) SetMatchType(v string) {
+// SetNegate sets field value
+func (o *TargetGroupHttpHealthCheck) SetNegate(v bool) {
- o.MatchType = &v
+ o.Negate = &v
}
-// HasMatchType returns a boolean if a field has been set.
-func (o *TargetGroupHttpHealthCheck) HasMatchType() bool {
- if o != nil && o.MatchType != nil {
+// HasNegate returns a boolean if a field has been set.
+func (o *TargetGroupHttpHealthCheck) HasNegate() bool {
+ if o != nil && o.Negate != nil {
return true
}
return false
}
-// GetResponse returns the Response field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroupHttpHealthCheck) GetResponse() *string {
+// GetPath returns the Path field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupHttpHealthCheck) GetPath() *string {
if o == nil {
return nil
}
- return o.Response
+ return o.Path
}
-// GetResponseOk returns a tuple with the Response field value
+// GetPathOk returns a tuple with the Path field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupHttpHealthCheck) GetResponseOk() (*string, bool) {
+func (o *TargetGroupHttpHealthCheck) GetPathOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Response, true
+ return o.Path, true
}
-// SetResponse sets field value
-func (o *TargetGroupHttpHealthCheck) SetResponse(v string) {
+// SetPath sets field value
+func (o *TargetGroupHttpHealthCheck) SetPath(v string) {
- o.Response = &v
+ o.Path = &v
}
-// HasResponse returns a boolean if a field has been set.
-func (o *TargetGroupHttpHealthCheck) HasResponse() bool {
- if o != nil && o.Response != nil {
+// HasPath returns a boolean if a field has been set.
+func (o *TargetGroupHttpHealthCheck) HasPath() bool {
+ if o != nil && o.Path != nil {
return true
}
@@ -204,7 +204,7 @@ func (o *TargetGroupHttpHealthCheck) HasResponse() bool {
}
// GetRegex returns the Regex field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *TargetGroupHttpHealthCheck) GetRegex() *bool {
if o == nil {
return nil
@@ -241,38 +241,38 @@ func (o *TargetGroupHttpHealthCheck) HasRegex() bool {
return false
}
-// GetNegate returns the Negate field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *TargetGroupHttpHealthCheck) GetNegate() *bool {
+// GetResponse returns the Response field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupHttpHealthCheck) GetResponse() *string {
if o == nil {
return nil
}
- return o.Negate
+ return o.Response
}
-// GetNegateOk returns a tuple with the Negate field value
+// GetResponseOk returns a tuple with the Response field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupHttpHealthCheck) GetNegateOk() (*bool, bool) {
+func (o *TargetGroupHttpHealthCheck) GetResponseOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Negate, true
+ return o.Response, true
}
-// SetNegate sets field value
-func (o *TargetGroupHttpHealthCheck) SetNegate(v bool) {
+// SetResponse sets field value
+func (o *TargetGroupHttpHealthCheck) SetResponse(v string) {
- o.Negate = &v
+ o.Response = &v
}
-// HasNegate returns a boolean if a field has been set.
-func (o *TargetGroupHttpHealthCheck) HasNegate() bool {
- if o != nil && o.Negate != nil {
+// HasResponse returns a boolean if a field has been set.
+func (o *TargetGroupHttpHealthCheck) HasResponse() bool {
+ if o != nil && o.Response != nil {
return true
}
@@ -281,24 +281,30 @@ func (o *TargetGroupHttpHealthCheck) HasNegate() bool {
func (o TargetGroupHttpHealthCheck) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Path != nil {
- toSerialize["path"] = o.Path
+ if o.MatchType != nil {
+ toSerialize["matchType"] = o.MatchType
}
+
if o.Method != nil {
toSerialize["method"] = o.Method
}
- if o.MatchType != nil {
- toSerialize["matchType"] = o.MatchType
+
+ if o.Negate != nil {
+ toSerialize["negate"] = o.Negate
}
- if o.Response != nil {
- toSerialize["response"] = o.Response
+
+ if o.Path != nil {
+ toSerialize["path"] = o.Path
}
+
if o.Regex != nil {
toSerialize["regex"] = o.Regex
}
- if o.Negate != nil {
- toSerialize["negate"] = o.Negate
+
+ if o.Response != nil {
+ toSerialize["response"] = o.Response
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_properties.go
index 3a79b8bc784..f14f3486fb5 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_properties.go
@@ -16,27 +16,27 @@ import (
// TargetGroupProperties struct for TargetGroupProperties
type TargetGroupProperties struct {
+ // The balancing algorithm. A balancing algorithm consists of predefined rules with the logic that a load balancer uses to distribute network traffic between servers. - **Round Robin**: Targets are served alternately according to their weighting. - **Least Connection**: The target with the least active connection is served. - **Random**: The targets are served based on a consistent pseudorandom algorithm. - **Source IP**: It is ensured that the same client IP address reaches the same target.
+ Algorithm *string `json:"algorithm"`
+ HealthCheck *TargetGroupHealthCheck `json:"healthCheck,omitempty"`
+ HttpHealthCheck *TargetGroupHttpHealthCheck `json:"httpHealthCheck,omitempty"`
// The target group name.
Name *string `json:"name"`
- // The balancing algorithm. A balancing algorithm consists of predefined rules with the logic that a load balancer uses to distribute network traffic between servers. - **Round Robin**: Targets are served alternately according to their weighting. - **Least Connection**: The target with the least active connection is served. - **Random**: The targets are served based on a consistent pseudorandom algorithm. - **Source IP**: It is ensured that the same client IP address reaches the same target.
- Algorithm *string `json:"algorithm"`
// The forwarding protocol. Only the value 'HTTP' is allowed.
Protocol *string `json:"protocol"`
// Array of items in the collection.
- Targets *[]TargetGroupTarget `json:"targets,omitempty"`
- HealthCheck *TargetGroupHealthCheck `json:"healthCheck,omitempty"`
- HttpHealthCheck *TargetGroupHttpHealthCheck `json:"httpHealthCheck,omitempty"`
+ Targets *[]TargetGroupTarget `json:"targets,omitempty"`
}
// NewTargetGroupProperties instantiates a new TargetGroupProperties object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewTargetGroupProperties(name string, algorithm string, protocol string) *TargetGroupProperties {
+func NewTargetGroupProperties(algorithm string, name string, protocol string) *TargetGroupProperties {
this := TargetGroupProperties{}
- this.Name = &name
this.Algorithm = &algorithm
+ this.Name = &name
this.Protocol = &protocol
return &this
@@ -50,228 +50,228 @@ func NewTargetGroupPropertiesWithDefaults() *TargetGroupProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroupProperties) GetName() *string {
+// GetAlgorithm returns the Algorithm field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupProperties) GetAlgorithm() *string {
if o == nil {
return nil
}
- return o.Name
+ return o.Algorithm
}
-// GetNameOk returns a tuple with the Name field value
+// GetAlgorithmOk returns a tuple with the Algorithm field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupProperties) GetNameOk() (*string, bool) {
+func (o *TargetGroupProperties) GetAlgorithmOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.Algorithm, true
}
-// SetName sets field value
-func (o *TargetGroupProperties) SetName(v string) {
+// SetAlgorithm sets field value
+func (o *TargetGroupProperties) SetAlgorithm(v string) {
- o.Name = &v
+ o.Algorithm = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *TargetGroupProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasAlgorithm returns a boolean if a field has been set.
+func (o *TargetGroupProperties) HasAlgorithm() bool {
+ if o != nil && o.Algorithm != nil {
return true
}
return false
}
-// GetAlgorithm returns the Algorithm field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroupProperties) GetAlgorithm() *string {
+// GetHealthCheck returns the HealthCheck field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupProperties) GetHealthCheck() *TargetGroupHealthCheck {
if o == nil {
return nil
}
- return o.Algorithm
+ return o.HealthCheck
}
-// GetAlgorithmOk returns a tuple with the Algorithm field value
+// GetHealthCheckOk returns a tuple with the HealthCheck field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupProperties) GetAlgorithmOk() (*string, bool) {
+func (o *TargetGroupProperties) GetHealthCheckOk() (*TargetGroupHealthCheck, bool) {
if o == nil {
return nil, false
}
- return o.Algorithm, true
+ return o.HealthCheck, true
}
-// SetAlgorithm sets field value
-func (o *TargetGroupProperties) SetAlgorithm(v string) {
+// SetHealthCheck sets field value
+func (o *TargetGroupProperties) SetHealthCheck(v TargetGroupHealthCheck) {
- o.Algorithm = &v
+ o.HealthCheck = &v
}
-// HasAlgorithm returns a boolean if a field has been set.
-func (o *TargetGroupProperties) HasAlgorithm() bool {
- if o != nil && o.Algorithm != nil {
+// HasHealthCheck returns a boolean if a field has been set.
+func (o *TargetGroupProperties) HasHealthCheck() bool {
+ if o != nil && o.HealthCheck != nil {
return true
}
return false
}
-// GetProtocol returns the Protocol field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroupProperties) GetProtocol() *string {
+// GetHttpHealthCheck returns the HttpHealthCheck field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupProperties) GetHttpHealthCheck() *TargetGroupHttpHealthCheck {
if o == nil {
return nil
}
- return o.Protocol
+ return o.HttpHealthCheck
}
-// GetProtocolOk returns a tuple with the Protocol field value
+// GetHttpHealthCheckOk returns a tuple with the HttpHealthCheck field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupProperties) GetProtocolOk() (*string, bool) {
+func (o *TargetGroupProperties) GetHttpHealthCheckOk() (*TargetGroupHttpHealthCheck, bool) {
if o == nil {
return nil, false
}
- return o.Protocol, true
+ return o.HttpHealthCheck, true
}
-// SetProtocol sets field value
-func (o *TargetGroupProperties) SetProtocol(v string) {
+// SetHttpHealthCheck sets field value
+func (o *TargetGroupProperties) SetHttpHealthCheck(v TargetGroupHttpHealthCheck) {
- o.Protocol = &v
+ o.HttpHealthCheck = &v
}
-// HasProtocol returns a boolean if a field has been set.
-func (o *TargetGroupProperties) HasProtocol() bool {
- if o != nil && o.Protocol != nil {
+// HasHttpHealthCheck returns a boolean if a field has been set.
+func (o *TargetGroupProperties) HasHttpHealthCheck() bool {
+ if o != nil && o.HttpHealthCheck != nil {
return true
}
return false
}
-// GetTargets returns the Targets field value
-// If the value is explicit nil, the zero value for []TargetGroupTarget will be returned
-func (o *TargetGroupProperties) GetTargets() *[]TargetGroupTarget {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupProperties) GetName() *string {
if o == nil {
return nil
}
- return o.Targets
+ return o.Name
}
-// GetTargetsOk returns a tuple with the Targets field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupProperties) GetTargetsOk() (*[]TargetGroupTarget, bool) {
+func (o *TargetGroupProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Targets, true
+ return o.Name, true
}
-// SetTargets sets field value
-func (o *TargetGroupProperties) SetTargets(v []TargetGroupTarget) {
+// SetName sets field value
+func (o *TargetGroupProperties) SetName(v string) {
- o.Targets = &v
+ o.Name = &v
}
-// HasTargets returns a boolean if a field has been set.
-func (o *TargetGroupProperties) HasTargets() bool {
- if o != nil && o.Targets != nil {
+// HasName returns a boolean if a field has been set.
+func (o *TargetGroupProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetHealthCheck returns the HealthCheck field value
-// If the value is explicit nil, the zero value for TargetGroupHealthCheck will be returned
-func (o *TargetGroupProperties) GetHealthCheck() *TargetGroupHealthCheck {
+// GetProtocol returns the Protocol field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupProperties) GetProtocol() *string {
if o == nil {
return nil
}
- return o.HealthCheck
+ return o.Protocol
}
-// GetHealthCheckOk returns a tuple with the HealthCheck field value
+// GetProtocolOk returns a tuple with the Protocol field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupProperties) GetHealthCheckOk() (*TargetGroupHealthCheck, bool) {
+func (o *TargetGroupProperties) GetProtocolOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.HealthCheck, true
+ return o.Protocol, true
}
-// SetHealthCheck sets field value
-func (o *TargetGroupProperties) SetHealthCheck(v TargetGroupHealthCheck) {
+// SetProtocol sets field value
+func (o *TargetGroupProperties) SetProtocol(v string) {
- o.HealthCheck = &v
+ o.Protocol = &v
}
-// HasHealthCheck returns a boolean if a field has been set.
-func (o *TargetGroupProperties) HasHealthCheck() bool {
- if o != nil && o.HealthCheck != nil {
+// HasProtocol returns a boolean if a field has been set.
+func (o *TargetGroupProperties) HasProtocol() bool {
+ if o != nil && o.Protocol != nil {
return true
}
return false
}
-// GetHttpHealthCheck returns the HttpHealthCheck field value
-// If the value is explicit nil, the zero value for TargetGroupHttpHealthCheck will be returned
-func (o *TargetGroupProperties) GetHttpHealthCheck() *TargetGroupHttpHealthCheck {
+// GetTargets returns the Targets field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupProperties) GetTargets() *[]TargetGroupTarget {
if o == nil {
return nil
}
- return o.HttpHealthCheck
+ return o.Targets
}
-// GetHttpHealthCheckOk returns a tuple with the HttpHealthCheck field value
+// GetTargetsOk returns a tuple with the Targets field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupProperties) GetHttpHealthCheckOk() (*TargetGroupHttpHealthCheck, bool) {
+func (o *TargetGroupProperties) GetTargetsOk() (*[]TargetGroupTarget, bool) {
if o == nil {
return nil, false
}
- return o.HttpHealthCheck, true
+ return o.Targets, true
}
-// SetHttpHealthCheck sets field value
-func (o *TargetGroupProperties) SetHttpHealthCheck(v TargetGroupHttpHealthCheck) {
+// SetTargets sets field value
+func (o *TargetGroupProperties) SetTargets(v []TargetGroupTarget) {
- o.HttpHealthCheck = &v
+ o.Targets = &v
}
-// HasHttpHealthCheck returns a boolean if a field has been set.
-func (o *TargetGroupProperties) HasHttpHealthCheck() bool {
- if o != nil && o.HttpHealthCheck != nil {
+// HasTargets returns a boolean if a field has been set.
+func (o *TargetGroupProperties) HasTargets() bool {
+ if o != nil && o.Targets != nil {
return true
}
@@ -280,24 +280,30 @@ func (o *TargetGroupProperties) HasHttpHealthCheck() bool {
func (o TargetGroupProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
- }
if o.Algorithm != nil {
toSerialize["algorithm"] = o.Algorithm
}
- if o.Protocol != nil {
- toSerialize["protocol"] = o.Protocol
- }
- if o.Targets != nil {
- toSerialize["targets"] = o.Targets
- }
+
if o.HealthCheck != nil {
toSerialize["healthCheck"] = o.HealthCheck
}
+
if o.HttpHealthCheck != nil {
toSerialize["httpHealthCheck"] = o.HttpHealthCheck
}
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
+ if o.Protocol != nil {
+ toSerialize["protocol"] = o.Protocol
+ }
+
+ if o.Targets != nil {
+ toSerialize["targets"] = o.Targets
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_put.go
index e5f5afd5624..b5f93b5652f 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_put.go
@@ -16,13 +16,13 @@ import (
// TargetGroupPut struct for TargetGroupPut
type TargetGroupPut struct {
+ // The URL to the object representation (absolute path).
+ Href *string `json:"href,omitempty"`
// The resource's unique identifier.
- Id *string `json:"id,omitempty"`
+ Id *string `json:"id,omitempty"`
+ Properties *TargetGroupProperties `json:"properties"`
// The type of object that has been created.
Type *Type `json:"type,omitempty"`
- // The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
- Properties *TargetGroupProperties `json:"properties"`
}
// NewTargetGroupPut instantiates a new TargetGroupPut object
@@ -45,152 +45,152 @@ func NewTargetGroupPutWithDefaults() *TargetGroupPut {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroupPut) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupPut) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupPut) GetIdOk() (*string, bool) {
+func (o *TargetGroupPut) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *TargetGroupPut) SetId(v string) {
+// SetHref sets field value
+func (o *TargetGroupPut) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *TargetGroupPut) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *TargetGroupPut) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *TargetGroupPut) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupPut) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupPut) GetTypeOk() (*Type, bool) {
+func (o *TargetGroupPut) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *TargetGroupPut) SetType(v Type) {
+// SetId sets field value
+func (o *TargetGroupPut) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *TargetGroupPut) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *TargetGroupPut) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroupPut) GetHref() *string {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupPut) GetProperties() *TargetGroupProperties {
if o == nil {
return nil
}
- return o.Href
+ return o.Properties
}
-// GetHrefOk returns a tuple with the Href field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupPut) GetHrefOk() (*string, bool) {
+func (o *TargetGroupPut) GetPropertiesOk() (*TargetGroupProperties, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Properties, true
}
-// SetHref sets field value
-func (o *TargetGroupPut) SetHref(v string) {
+// SetProperties sets field value
+func (o *TargetGroupPut) SetProperties(v TargetGroupProperties) {
- o.Href = &v
+ o.Properties = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *TargetGroupPut) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *TargetGroupPut) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for TargetGroupProperties will be returned
-func (o *TargetGroupPut) GetProperties() *TargetGroupProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupPut) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupPut) GetPropertiesOk() (*TargetGroupProperties, bool) {
+func (o *TargetGroupPut) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *TargetGroupPut) SetProperties(v TargetGroupProperties) {
+// SetType sets field value
+func (o *TargetGroupPut) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *TargetGroupPut) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *TargetGroupPut) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -199,18 +199,22 @@ func (o *TargetGroupPut) HasProperties() bool {
func (o TargetGroupPut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_target.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_target.go
index bad8c42d575..a9c9e2d9e4e 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_target.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_group_target.go
@@ -16,16 +16,16 @@ import (
// TargetGroupTarget struct for TargetGroupTarget
type TargetGroupTarget struct {
+ // When the health check is enabled, the target is available only when it accepts regular TCP or HTTP connection attempts for state checking. The state check consists of one connection attempt with the target's address and port. The default value is 'TRUE'.
+ HealthCheckEnabled *bool `json:"healthCheckEnabled,omitempty"`
// The IP address of the balanced target.
Ip *string `json:"ip"`
+ // When the maintenance mode is enabled, the target is prevented from receiving traffic; the default value is 'FALSE'.
+ MaintenanceEnabled *bool `json:"maintenanceEnabled,omitempty"`
// The port of the balanced target service; the valid range is 1 to 65535.
Port *int32 `json:"port"`
// The traffic is distributed proportionally to target weight, which is the ratio of the total weight of all targets. A target with higher weight receives a larger share of traffic. The valid range is from 0 to 256; the default value is '1'. Targets with a weight of '0' do not participate in load balancing but still accept persistent connections. We recommend using values in the middle range to leave room for later adjustments.
Weight *int32 `json:"weight"`
- // When the health check is enabled, the target is available only when it accepts regular TCP or HTTP connection attempts for state checking. The state check consists of one connection attempt with the target's address and port. The default value is 'TRUE'.
- HealthCheckEnabled *bool `json:"healthCheckEnabled,omitempty"`
- // When the maintenance mode is enabled, the target is prevented from receiving traffic; the default value is 'FALSE'.
- MaintenanceEnabled *bool `json:"maintenanceEnabled,omitempty"`
}
// NewTargetGroupTarget instantiates a new TargetGroupTarget object
@@ -50,190 +50,190 @@ func NewTargetGroupTargetWithDefaults() *TargetGroupTarget {
return &this
}
-// GetIp returns the Ip field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroupTarget) GetIp() *string {
+// GetHealthCheckEnabled returns the HealthCheckEnabled field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupTarget) GetHealthCheckEnabled() *bool {
if o == nil {
return nil
}
- return o.Ip
+ return o.HealthCheckEnabled
}
-// GetIpOk returns a tuple with the Ip field value
+// GetHealthCheckEnabledOk returns a tuple with the HealthCheckEnabled field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupTarget) GetIpOk() (*string, bool) {
+func (o *TargetGroupTarget) GetHealthCheckEnabledOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Ip, true
+ return o.HealthCheckEnabled, true
}
-// SetIp sets field value
-func (o *TargetGroupTarget) SetIp(v string) {
+// SetHealthCheckEnabled sets field value
+func (o *TargetGroupTarget) SetHealthCheckEnabled(v bool) {
- o.Ip = &v
+ o.HealthCheckEnabled = &v
}
-// HasIp returns a boolean if a field has been set.
-func (o *TargetGroupTarget) HasIp() bool {
- if o != nil && o.Ip != nil {
+// HasHealthCheckEnabled returns a boolean if a field has been set.
+func (o *TargetGroupTarget) HasHealthCheckEnabled() bool {
+ if o != nil && o.HealthCheckEnabled != nil {
return true
}
return false
}
-// GetPort returns the Port field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *TargetGroupTarget) GetPort() *int32 {
+// GetIp returns the Ip field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupTarget) GetIp() *string {
if o == nil {
return nil
}
- return o.Port
+ return o.Ip
}
-// GetPortOk returns a tuple with the Port field value
+// GetIpOk returns a tuple with the Ip field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupTarget) GetPortOk() (*int32, bool) {
+func (o *TargetGroupTarget) GetIpOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Port, true
+ return o.Ip, true
}
-// SetPort sets field value
-func (o *TargetGroupTarget) SetPort(v int32) {
+// SetIp sets field value
+func (o *TargetGroupTarget) SetIp(v string) {
- o.Port = &v
+ o.Ip = &v
}
-// HasPort returns a boolean if a field has been set.
-func (o *TargetGroupTarget) HasPort() bool {
- if o != nil && o.Port != nil {
+// HasIp returns a boolean if a field has been set.
+func (o *TargetGroupTarget) HasIp() bool {
+ if o != nil && o.Ip != nil {
return true
}
return false
}
-// GetWeight returns the Weight field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *TargetGroupTarget) GetWeight() *int32 {
+// GetMaintenanceEnabled returns the MaintenanceEnabled field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupTarget) GetMaintenanceEnabled() *bool {
if o == nil {
return nil
}
- return o.Weight
+ return o.MaintenanceEnabled
}
-// GetWeightOk returns a tuple with the Weight field value
+// GetMaintenanceEnabledOk returns a tuple with the MaintenanceEnabled field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupTarget) GetWeightOk() (*int32, bool) {
+func (o *TargetGroupTarget) GetMaintenanceEnabledOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Weight, true
+ return o.MaintenanceEnabled, true
}
-// SetWeight sets field value
-func (o *TargetGroupTarget) SetWeight(v int32) {
+// SetMaintenanceEnabled sets field value
+func (o *TargetGroupTarget) SetMaintenanceEnabled(v bool) {
- o.Weight = &v
+ o.MaintenanceEnabled = &v
}
-// HasWeight returns a boolean if a field has been set.
-func (o *TargetGroupTarget) HasWeight() bool {
- if o != nil && o.Weight != nil {
+// HasMaintenanceEnabled returns a boolean if a field has been set.
+func (o *TargetGroupTarget) HasMaintenanceEnabled() bool {
+ if o != nil && o.MaintenanceEnabled != nil {
return true
}
return false
}
-// GetHealthCheckEnabled returns the HealthCheckEnabled field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *TargetGroupTarget) GetHealthCheckEnabled() *bool {
+// GetPort returns the Port field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupTarget) GetPort() *int32 {
if o == nil {
return nil
}
- return o.HealthCheckEnabled
+ return o.Port
}
-// GetHealthCheckEnabledOk returns a tuple with the HealthCheckEnabled field value
+// GetPortOk returns a tuple with the Port field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupTarget) GetHealthCheckEnabledOk() (*bool, bool) {
+func (o *TargetGroupTarget) GetPortOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.HealthCheckEnabled, true
+ return o.Port, true
}
-// SetHealthCheckEnabled sets field value
-func (o *TargetGroupTarget) SetHealthCheckEnabled(v bool) {
+// SetPort sets field value
+func (o *TargetGroupTarget) SetPort(v int32) {
- o.HealthCheckEnabled = &v
+ o.Port = &v
}
-// HasHealthCheckEnabled returns a boolean if a field has been set.
-func (o *TargetGroupTarget) HasHealthCheckEnabled() bool {
- if o != nil && o.HealthCheckEnabled != nil {
+// HasPort returns a boolean if a field has been set.
+func (o *TargetGroupTarget) HasPort() bool {
+ if o != nil && o.Port != nil {
return true
}
return false
}
-// GetMaintenanceEnabled returns the MaintenanceEnabled field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *TargetGroupTarget) GetMaintenanceEnabled() *bool {
+// GetWeight returns the Weight field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroupTarget) GetWeight() *int32 {
if o == nil {
return nil
}
- return o.MaintenanceEnabled
+ return o.Weight
}
-// GetMaintenanceEnabledOk returns a tuple with the MaintenanceEnabled field value
+// GetWeightOk returns a tuple with the Weight field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroupTarget) GetMaintenanceEnabledOk() (*bool, bool) {
+func (o *TargetGroupTarget) GetWeightOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.MaintenanceEnabled, true
+ return o.Weight, true
}
-// SetMaintenanceEnabled sets field value
-func (o *TargetGroupTarget) SetMaintenanceEnabled(v bool) {
+// SetWeight sets field value
+func (o *TargetGroupTarget) SetWeight(v int32) {
- o.MaintenanceEnabled = &v
+ o.Weight = &v
}
-// HasMaintenanceEnabled returns a boolean if a field has been set.
-func (o *TargetGroupTarget) HasMaintenanceEnabled() bool {
- if o != nil && o.MaintenanceEnabled != nil {
+// HasWeight returns a boolean if a field has been set.
+func (o *TargetGroupTarget) HasWeight() bool {
+ if o != nil && o.Weight != nil {
return true
}
@@ -242,21 +242,26 @@ func (o *TargetGroupTarget) HasMaintenanceEnabled() bool {
func (o TargetGroupTarget) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
+ if o.HealthCheckEnabled != nil {
+ toSerialize["healthCheckEnabled"] = o.HealthCheckEnabled
+ }
+
if o.Ip != nil {
toSerialize["ip"] = o.Ip
}
+
+ if o.MaintenanceEnabled != nil {
+ toSerialize["maintenanceEnabled"] = o.MaintenanceEnabled
+ }
+
if o.Port != nil {
toSerialize["port"] = o.Port
}
+
if o.Weight != nil {
toSerialize["weight"] = o.Weight
}
- if o.HealthCheckEnabled != nil {
- toSerialize["healthCheckEnabled"] = o.HealthCheckEnabled
- }
- if o.MaintenanceEnabled != nil {
- toSerialize["maintenanceEnabled"] = o.MaintenanceEnabled
- }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_groups.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_groups.go
index ca5778f545b..521ca7b3fa3 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_groups.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_groups.go
@@ -16,19 +16,19 @@ import (
// TargetGroups struct for TargetGroups
type TargetGroups struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// The URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]TargetGroup `json:"items,omitempty"`
+ // The limit, specified in the request (if not specified, the endpoint's default pagination limit is used).
+ Limit *float32 `json:"limit,omitempty"`
// The offset, specified in the request (if not is specified, 0 is used by default).
Offset *float32 `json:"offset,omitempty"`
- // The limit, specified in the request (if not specified, the endpoint's default pagination limit is used).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewTargetGroups instantiates a new TargetGroups object
@@ -49,114 +49,114 @@ func NewTargetGroupsWithDefaults() *TargetGroups {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroups) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroups) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroups) GetIdOk() (*string, bool) {
+func (o *TargetGroups) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *TargetGroups) SetId(v string) {
+// SetLinks sets field value
+func (o *TargetGroups) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *TargetGroups) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *TargetGroups) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *TargetGroups) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroups) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroups) GetTypeOk() (*Type, bool) {
+func (o *TargetGroups) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *TargetGroups) SetType(v Type) {
+// SetHref sets field value
+func (o *TargetGroups) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *TargetGroups) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *TargetGroups) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TargetGroups) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroups) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroups) GetHrefOk() (*string, bool) {
+func (o *TargetGroups) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *TargetGroups) SetHref(v string) {
+// SetId sets field value
+func (o *TargetGroups) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *TargetGroups) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *TargetGroups) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *TargetGroups) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []TargetGroup will be returned
+// If the value is explicit nil, nil is returned
func (o *TargetGroups) GetItems() *[]TargetGroup {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *TargetGroups) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *TargetGroups) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroups) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroups) GetOffsetOk() (*float32, bool) {
+func (o *TargetGroups) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *TargetGroups) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *TargetGroups) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *TargetGroups) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *TargetGroups) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *TargetGroups) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroups) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroups) GetLimitOk() (*float32, bool) {
+func (o *TargetGroups) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *TargetGroups) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *TargetGroups) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *TargetGroups) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *TargetGroups) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *TargetGroups) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *TargetGroups) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetGroups) GetLinksOk() (*PaginationLinks, bool) {
+func (o *TargetGroups) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *TargetGroups) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *TargetGroups) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *TargetGroups) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *TargetGroups) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *TargetGroups) HasLinks() bool {
func (o TargetGroups) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_port_range.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_port_range.go
index 9a1c39ea528..8c5281ed8a9 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_port_range.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_target_port_range.go
@@ -16,10 +16,10 @@ import (
// TargetPortRange struct for TargetPortRange
type TargetPortRange struct {
- // Target port range start associated with the NAT Gateway rule.
- Start *int32 `json:"start,omitempty"`
// Target port range end associated with the NAT Gateway rule.
End *int32 `json:"end,omitempty"`
+ // Target port range start associated with the NAT Gateway rule.
+ Start *int32 `json:"start,omitempty"`
}
// NewTargetPortRange instantiates a new TargetPortRange object
@@ -40,76 +40,76 @@ func NewTargetPortRangeWithDefaults() *TargetPortRange {
return &this
}
-// GetStart returns the Start field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *TargetPortRange) GetStart() *int32 {
+// GetEnd returns the End field value
+// If the value is explicit nil, nil is returned
+func (o *TargetPortRange) GetEnd() *int32 {
if o == nil {
return nil
}
- return o.Start
+ return o.End
}
-// GetStartOk returns a tuple with the Start field value
+// GetEndOk returns a tuple with the End field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetPortRange) GetStartOk() (*int32, bool) {
+func (o *TargetPortRange) GetEndOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.Start, true
+ return o.End, true
}
-// SetStart sets field value
-func (o *TargetPortRange) SetStart(v int32) {
+// SetEnd sets field value
+func (o *TargetPortRange) SetEnd(v int32) {
- o.Start = &v
+ o.End = &v
}
-// HasStart returns a boolean if a field has been set.
-func (o *TargetPortRange) HasStart() bool {
- if o != nil && o.Start != nil {
+// HasEnd returns a boolean if a field has been set.
+func (o *TargetPortRange) HasEnd() bool {
+ if o != nil && o.End != nil {
return true
}
return false
}
-// GetEnd returns the End field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *TargetPortRange) GetEnd() *int32 {
+// GetStart returns the Start field value
+// If the value is explicit nil, nil is returned
+func (o *TargetPortRange) GetStart() *int32 {
if o == nil {
return nil
}
- return o.End
+ return o.Start
}
-// GetEndOk returns a tuple with the End field value
+// GetStartOk returns a tuple with the Start field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TargetPortRange) GetEndOk() (*int32, bool) {
+func (o *TargetPortRange) GetStartOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.End, true
+ return o.Start, true
}
-// SetEnd sets field value
-func (o *TargetPortRange) SetEnd(v int32) {
+// SetStart sets field value
+func (o *TargetPortRange) SetStart(v int32) {
- o.End = &v
+ o.Start = &v
}
-// HasEnd returns a boolean if a field has been set.
-func (o *TargetPortRange) HasEnd() bool {
- if o != nil && o.End != nil {
+// HasStart returns a boolean if a field has been set.
+func (o *TargetPortRange) HasStart() bool {
+ if o != nil && o.Start != nil {
return true
}
@@ -118,12 +118,14 @@ func (o *TargetPortRange) HasEnd() bool {
func (o TargetPortRange) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Start != nil {
- toSerialize["start"] = o.Start
- }
if o.End != nil {
toSerialize["end"] = o.End
}
+
+ if o.Start != nil {
+ toSerialize["start"] = o.Start
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_template.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_template.go
index 48156f1066b..ad290d4090b 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_template.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_template.go
@@ -16,14 +16,14 @@ import (
// Template struct for Template
type Template struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *TemplateProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewTemplate instantiates a new Template object
@@ -46,190 +46,190 @@ func NewTemplateWithDefaults() *Template {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Template) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Template) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Template) GetIdOk() (*string, bool) {
+func (o *Template) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Template) SetId(v string) {
+// SetHref sets field value
+func (o *Template) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Template) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Template) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Template) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Template) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Template) GetTypeOk() (*Type, bool) {
+func (o *Template) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Template) SetType(v Type) {
+// SetId sets field value
+func (o *Template) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Template) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Template) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Template) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *Template) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Template) GetHrefOk() (*string, bool) {
+func (o *Template) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *Template) SetHref(v string) {
+// SetMetadata sets field value
+func (o *Template) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Template) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *Template) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *Template) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *Template) GetProperties() *TemplateProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Template) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *Template) GetPropertiesOk() (*TemplateProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *Template) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *Template) SetProperties(v TemplateProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *Template) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *Template) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for TemplateProperties will be returned
-func (o *Template) GetProperties() *TemplateProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Template) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Template) GetPropertiesOk() (*TemplateProperties, bool) {
+func (o *Template) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *Template) SetProperties(v TemplateProperties) {
+// SetType sets field value
+func (o *Template) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *Template) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Template) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *Template) HasProperties() bool {
func (o Template) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_template_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_template_properties.go
index 5d661eee257..98d1150116a 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_template_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_template_properties.go
@@ -16,10 +16,10 @@ import (
// TemplateProperties struct for TemplateProperties
type TemplateProperties struct {
- // The resource name.
- Name *string `json:"name"`
// The CPU cores count.
Cores *float32 `json:"cores"`
+ // The resource name.
+ Name *string `json:"name"`
// The RAM size in MB.
Ram *float32 `json:"ram"`
// The storage size in GB.
@@ -30,11 +30,11 @@ type TemplateProperties struct {
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
-func NewTemplateProperties(name string, cores float32, ram float32, storageSize float32) *TemplateProperties {
+func NewTemplateProperties(cores float32, name string, ram float32, storageSize float32) *TemplateProperties {
this := TemplateProperties{}
- this.Name = &name
this.Cores = &cores
+ this.Name = &name
this.Ram = &ram
this.StorageSize = &storageSize
@@ -49,76 +49,76 @@ func NewTemplatePropertiesWithDefaults() *TemplateProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *TemplateProperties) GetName() *string {
+// GetCores returns the Cores field value
+// If the value is explicit nil, nil is returned
+func (o *TemplateProperties) GetCores() *float32 {
if o == nil {
return nil
}
- return o.Name
+ return o.Cores
}
-// GetNameOk returns a tuple with the Name field value
+// GetCoresOk returns a tuple with the Cores field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TemplateProperties) GetNameOk() (*string, bool) {
+func (o *TemplateProperties) GetCoresOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.Cores, true
}
-// SetName sets field value
-func (o *TemplateProperties) SetName(v string) {
+// SetCores sets field value
+func (o *TemplateProperties) SetCores(v float32) {
- o.Name = &v
+ o.Cores = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *TemplateProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasCores returns a boolean if a field has been set.
+func (o *TemplateProperties) HasCores() bool {
+ if o != nil && o.Cores != nil {
return true
}
return false
}
-// GetCores returns the Cores field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *TemplateProperties) GetCores() *float32 {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *TemplateProperties) GetName() *string {
if o == nil {
return nil
}
- return o.Cores
+ return o.Name
}
-// GetCoresOk returns a tuple with the Cores field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *TemplateProperties) GetCoresOk() (*float32, bool) {
+func (o *TemplateProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Cores, true
+ return o.Name, true
}
-// SetCores sets field value
-func (o *TemplateProperties) SetCores(v float32) {
+// SetName sets field value
+func (o *TemplateProperties) SetName(v string) {
- o.Cores = &v
+ o.Name = &v
}
-// HasCores returns a boolean if a field has been set.
-func (o *TemplateProperties) HasCores() bool {
- if o != nil && o.Cores != nil {
+// HasName returns a boolean if a field has been set.
+func (o *TemplateProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
@@ -126,7 +126,7 @@ func (o *TemplateProperties) HasCores() bool {
}
// GetRam returns the Ram field value
-// If the value is explicit nil, the zero value for float32 will be returned
+// If the value is explicit nil, nil is returned
func (o *TemplateProperties) GetRam() *float32 {
if o == nil {
return nil
@@ -164,7 +164,7 @@ func (o *TemplateProperties) HasRam() bool {
}
// GetStorageSize returns the StorageSize field value
-// If the value is explicit nil, the zero value for float32 will be returned
+// If the value is explicit nil, nil is returned
func (o *TemplateProperties) GetStorageSize() *float32 {
if o == nil {
return nil
@@ -203,18 +203,22 @@ func (o *TemplateProperties) HasStorageSize() bool {
func (o TemplateProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
- }
if o.Cores != nil {
toSerialize["cores"] = o.Cores
}
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
+ }
+
if o.Ram != nil {
toSerialize["ram"] = o.Ram
}
+
if o.StorageSize != nil {
toSerialize["storageSize"] = o.StorageSize
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_templates.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_templates.go
index 1d6e9640ca7..c66eac10cc6 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_templates.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_templates.go
@@ -16,14 +16,14 @@ import (
// Templates struct for Templates
type Templates struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// The URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Template `json:"items,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewTemplates instantiates a new Templates object
@@ -44,152 +44,152 @@ func NewTemplatesWithDefaults() *Templates {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Templates) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Templates) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Templates) GetIdOk() (*string, bool) {
+func (o *Templates) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Templates) SetId(v string) {
+// SetHref sets field value
+func (o *Templates) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Templates) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Templates) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Templates) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Templates) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Templates) GetTypeOk() (*Type, bool) {
+func (o *Templates) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Templates) SetType(v Type) {
+// SetId sets field value
+func (o *Templates) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Templates) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Templates) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Templates) GetHref() *string {
+// GetItems returns the Items field value
+// If the value is explicit nil, nil is returned
+func (o *Templates) GetItems() *[]Template {
if o == nil {
return nil
}
- return o.Href
+ return o.Items
}
-// GetHrefOk returns a tuple with the Href field value
+// GetItemsOk returns a tuple with the Items field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Templates) GetHrefOk() (*string, bool) {
+func (o *Templates) GetItemsOk() (*[]Template, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Items, true
}
-// SetHref sets field value
-func (o *Templates) SetHref(v string) {
+// SetItems sets field value
+func (o *Templates) SetItems(v []Template) {
- o.Href = &v
+ o.Items = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Templates) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasItems returns a boolean if a field has been set.
+func (o *Templates) HasItems() bool {
+ if o != nil && o.Items != nil {
return true
}
return false
}
-// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Template will be returned
-func (o *Templates) GetItems() *[]Template {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Templates) GetType() *Type {
if o == nil {
return nil
}
- return o.Items
+ return o.Type
}
-// GetItemsOk returns a tuple with the Items field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Templates) GetItemsOk() (*[]Template, bool) {
+func (o *Templates) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Items, true
+ return o.Type, true
}
-// SetItems sets field value
-func (o *Templates) SetItems(v []Template) {
+// SetType sets field value
+func (o *Templates) SetType(v Type) {
- o.Items = &v
+ o.Type = &v
}
-// HasItems returns a boolean if a field has been set.
-func (o *Templates) HasItems() bool {
- if o != nil && o.Items != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Templates) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -198,18 +198,22 @@ func (o *Templates) HasItems() bool {
func (o Templates) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_token.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_token.go
index 074e07ad673..c886b268073 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_token.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_token.go
@@ -39,7 +39,7 @@ func NewTokenWithDefaults() *Token {
}
// GetToken returns the Token field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *Token) GetToken() *string {
if o == nil {
return nil
@@ -81,6 +81,7 @@ func (o Token) MarshalJSON() ([]byte, error) {
if o.Token != nil {
toSerialize["token"] = o.Token
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user.go
index 14864be690f..38d1a9b063d 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user.go
@@ -16,15 +16,15 @@ import (
// User struct for User
type User struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Entities *UsersEntities `json:"entities,omitempty"`
// URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *UserMetadata `json:"metadata,omitempty"`
Properties *UserProperties `json:"properties"`
- Entities *UsersEntities `json:"entities,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewUser instantiates a new User object
@@ -47,114 +47,114 @@ func NewUserWithDefaults() *User {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *User) GetId() *string {
+// GetEntities returns the Entities field value
+// If the value is explicit nil, nil is returned
+func (o *User) GetEntities() *UsersEntities {
if o == nil {
return nil
}
- return o.Id
+ return o.Entities
}
-// GetIdOk returns a tuple with the Id field value
+// GetEntitiesOk returns a tuple with the Entities field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *User) GetIdOk() (*string, bool) {
+func (o *User) GetEntitiesOk() (*UsersEntities, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Entities, true
}
-// SetId sets field value
-func (o *User) SetId(v string) {
+// SetEntities sets field value
+func (o *User) SetEntities(v UsersEntities) {
- o.Id = &v
+ o.Entities = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *User) HasId() bool {
- if o != nil && o.Id != nil {
+// HasEntities returns a boolean if a field has been set.
+func (o *User) HasEntities() bool {
+ if o != nil && o.Entities != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *User) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *User) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *User) GetTypeOk() (*Type, bool) {
+func (o *User) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *User) SetType(v Type) {
+// SetHref sets field value
+func (o *User) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *User) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *User) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *User) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *User) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *User) GetHrefOk() (*string, bool) {
+func (o *User) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *User) SetHref(v string) {
+// SetId sets field value
+func (o *User) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *User) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *User) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -162,7 +162,7 @@ func (o *User) HasHref() bool {
}
// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for UserMetadata will be returned
+// If the value is explicit nil, nil is returned
func (o *User) GetMetadata() *UserMetadata {
if o == nil {
return nil
@@ -200,7 +200,7 @@ func (o *User) HasMetadata() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for UserProperties will be returned
+// If the value is explicit nil, nil is returned
func (o *User) GetProperties() *UserProperties {
if o == nil {
return nil
@@ -237,38 +237,38 @@ func (o *User) HasProperties() bool {
return false
}
-// GetEntities returns the Entities field value
-// If the value is explicit nil, the zero value for UsersEntities will be returned
-func (o *User) GetEntities() *UsersEntities {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *User) GetType() *Type {
if o == nil {
return nil
}
- return o.Entities
+ return o.Type
}
-// GetEntitiesOk returns a tuple with the Entities field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *User) GetEntitiesOk() (*UsersEntities, bool) {
+func (o *User) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Entities, true
+ return o.Type, true
}
-// SetEntities sets field value
-func (o *User) SetEntities(v UsersEntities) {
+// SetType sets field value
+func (o *User) SetType(v Type) {
- o.Entities = &v
+ o.Type = &v
}
-// HasEntities returns a boolean if a field has been set.
-func (o *User) HasEntities() bool {
- if o != nil && o.Entities != nil {
+// HasType returns a boolean if a field has been set.
+func (o *User) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -277,24 +277,30 @@ func (o *User) HasEntities() bool {
func (o User) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Entities != nil {
+ toSerialize["entities"] = o.Entities
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
- if o.Entities != nil {
- toSerialize["entities"] = o.Entities
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_metadata.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_metadata.go
index da90dc00b89..de6738d715f 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_metadata.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_metadata.go
@@ -17,10 +17,10 @@ import (
// UserMetadata struct for UserMetadata
type UserMetadata struct {
- // Resource's Entity Tag as defined in http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.11 Entity Tag is also added as an 'ETag response header to requests which don't use 'depth' parameter.
- Etag *string `json:"etag,omitempty"`
// The time the user was created.
CreatedDate *IonosTime
+ // Resource's Entity Tag as defined in http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.11 Entity Tag is also added as an 'ETag response header to requests which don't use 'depth' parameter.
+ Etag *string `json:"etag,omitempty"`
// The time of the last login by the user.
LastLogin *IonosTime
}
@@ -43,83 +43,83 @@ func NewUserMetadataWithDefaults() *UserMetadata {
return &this
}
-// GetEtag returns the Etag field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *UserMetadata) GetEtag() *string {
+// GetCreatedDate returns the CreatedDate field value
+// If the value is explicit nil, nil is returned
+func (o *UserMetadata) GetCreatedDate() *time.Time {
if o == nil {
return nil
}
- return o.Etag
+ if o.CreatedDate == nil {
+ return nil
+ }
+ return &o.CreatedDate.Time
}
-// GetEtagOk returns a tuple with the Etag field value
+// GetCreatedDateOk returns a tuple with the CreatedDate field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserMetadata) GetEtagOk() (*string, bool) {
+func (o *UserMetadata) GetCreatedDateOk() (*time.Time, bool) {
if o == nil {
return nil, false
}
- return o.Etag, true
+ if o.CreatedDate == nil {
+ return nil, false
+ }
+ return &o.CreatedDate.Time, true
+
}
-// SetEtag sets field value
-func (o *UserMetadata) SetEtag(v string) {
+// SetCreatedDate sets field value
+func (o *UserMetadata) SetCreatedDate(v time.Time) {
- o.Etag = &v
+ o.CreatedDate = &IonosTime{v}
}
-// HasEtag returns a boolean if a field has been set.
-func (o *UserMetadata) HasEtag() bool {
- if o != nil && o.Etag != nil {
+// HasCreatedDate returns a boolean if a field has been set.
+func (o *UserMetadata) HasCreatedDate() bool {
+ if o != nil && o.CreatedDate != nil {
return true
}
return false
}
-// GetCreatedDate returns the CreatedDate field value
-// If the value is explicit nil, the zero value for time.Time will be returned
-func (o *UserMetadata) GetCreatedDate() *time.Time {
+// GetEtag returns the Etag field value
+// If the value is explicit nil, nil is returned
+func (o *UserMetadata) GetEtag() *string {
if o == nil {
return nil
}
- if o.CreatedDate == nil {
- return nil
- }
- return &o.CreatedDate.Time
+ return o.Etag
}
-// GetCreatedDateOk returns a tuple with the CreatedDate field value
+// GetEtagOk returns a tuple with the Etag field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserMetadata) GetCreatedDateOk() (*time.Time, bool) {
+func (o *UserMetadata) GetEtagOk() (*string, bool) {
if o == nil {
return nil, false
}
- if o.CreatedDate == nil {
- return nil, false
- }
- return &o.CreatedDate.Time, true
-
+ return o.Etag, true
}
-// SetCreatedDate sets field value
-func (o *UserMetadata) SetCreatedDate(v time.Time) {
+// SetEtag sets field value
+func (o *UserMetadata) SetEtag(v string) {
- o.CreatedDate = &IonosTime{v}
+ o.Etag = &v
}
-// HasCreatedDate returns a boolean if a field has been set.
-func (o *UserMetadata) HasCreatedDate() bool {
- if o != nil && o.CreatedDate != nil {
+// HasEtag returns a boolean if a field has been set.
+func (o *UserMetadata) HasEtag() bool {
+ if o != nil && o.Etag != nil {
return true
}
@@ -127,7 +127,7 @@ func (o *UserMetadata) HasCreatedDate() bool {
}
// GetLastLogin returns the LastLogin field value
-// If the value is explicit nil, the zero value for time.Time will be returned
+// If the value is explicit nil, nil is returned
func (o *UserMetadata) GetLastLogin() *time.Time {
if o == nil {
return nil
@@ -173,15 +173,18 @@ func (o *UserMetadata) HasLastLogin() bool {
func (o UserMetadata) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Etag != nil {
- toSerialize["etag"] = o.Etag
- }
if o.CreatedDate != nil {
toSerialize["createdDate"] = o.CreatedDate
}
+
+ if o.Etag != nil {
+ toSerialize["etag"] = o.Etag
+ }
+
if o.LastLogin != nil {
toSerialize["lastLogin"] = o.LastLogin
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_post.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_post.go
index 912dc339199..cfbe91439f2 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_post.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_post.go
@@ -40,7 +40,7 @@ func NewUserPostWithDefaults() *UserPost {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for UserPropertiesPost will be returned
+// If the value is explicit nil, nil is returned
func (o *UserPost) GetProperties() *UserPropertiesPost {
if o == nil {
return nil
@@ -82,6 +82,7 @@ func (o UserPost) MarshalJSON() ([]byte, error) {
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_properties.go
index 6ff0ff0f00c..7fadd2b431f 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_properties.go
@@ -16,22 +16,22 @@ import (
// UserProperties struct for UserProperties
type UserProperties struct {
- // The first name of the user.
- Firstname *string `json:"firstname,omitempty"`
- // The last name of the user.
- Lastname *string `json:"lastname,omitempty"`
- // The email address of the user.
- Email *string `json:"email,omitempty"`
+ // Indicates if the user is active.
+ Active *bool `json:"active,omitempty"`
// Indicates if the user has admin rights.
Administrator *bool `json:"administrator,omitempty"`
+ // The email address of the user.
+ Email *string `json:"email,omitempty"`
+ // The first name of the user.
+ Firstname *string `json:"firstname,omitempty"`
// Indicates if secure authentication should be forced on the user.
ForceSecAuth *bool `json:"forceSecAuth,omitempty"`
- // Indicates if secure authentication is active for the user.
- SecAuthActive *bool `json:"secAuthActive,omitempty"`
+ // The last name of the user.
+ Lastname *string `json:"lastname,omitempty"`
// Canonical (S3) ID of the user for a given identity.
S3CanonicalUserId *string `json:"s3CanonicalUserId,omitempty"`
- // Indicates if the user is active.
- Active *bool `json:"active,omitempty"`
+ // Indicates if secure authentication is active for the user.
+ SecAuthActive *bool `json:"secAuthActive,omitempty"`
}
// NewUserProperties instantiates a new UserProperties object
@@ -52,76 +52,76 @@ func NewUserPropertiesWithDefaults() *UserProperties {
return &this
}
-// GetFirstname returns the Firstname field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *UserProperties) GetFirstname() *string {
+// GetActive returns the Active field value
+// If the value is explicit nil, nil is returned
+func (o *UserProperties) GetActive() *bool {
if o == nil {
return nil
}
- return o.Firstname
+ return o.Active
}
-// GetFirstnameOk returns a tuple with the Firstname field value
+// GetActiveOk returns a tuple with the Active field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserProperties) GetFirstnameOk() (*string, bool) {
+func (o *UserProperties) GetActiveOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Firstname, true
+ return o.Active, true
}
-// SetFirstname sets field value
-func (o *UserProperties) SetFirstname(v string) {
+// SetActive sets field value
+func (o *UserProperties) SetActive(v bool) {
- o.Firstname = &v
+ o.Active = &v
}
-// HasFirstname returns a boolean if a field has been set.
-func (o *UserProperties) HasFirstname() bool {
- if o != nil && o.Firstname != nil {
+// HasActive returns a boolean if a field has been set.
+func (o *UserProperties) HasActive() bool {
+ if o != nil && o.Active != nil {
return true
}
return false
}
-// GetLastname returns the Lastname field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *UserProperties) GetLastname() *string {
+// GetAdministrator returns the Administrator field value
+// If the value is explicit nil, nil is returned
+func (o *UserProperties) GetAdministrator() *bool {
if o == nil {
return nil
}
- return o.Lastname
+ return o.Administrator
}
-// GetLastnameOk returns a tuple with the Lastname field value
+// GetAdministratorOk returns a tuple with the Administrator field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserProperties) GetLastnameOk() (*string, bool) {
+func (o *UserProperties) GetAdministratorOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Lastname, true
+ return o.Administrator, true
}
-// SetLastname sets field value
-func (o *UserProperties) SetLastname(v string) {
+// SetAdministrator sets field value
+func (o *UserProperties) SetAdministrator(v bool) {
- o.Lastname = &v
+ o.Administrator = &v
}
-// HasLastname returns a boolean if a field has been set.
-func (o *UserProperties) HasLastname() bool {
- if o != nil && o.Lastname != nil {
+// HasAdministrator returns a boolean if a field has been set.
+func (o *UserProperties) HasAdministrator() bool {
+ if o != nil && o.Administrator != nil {
return true
}
@@ -129,7 +129,7 @@ func (o *UserProperties) HasLastname() bool {
}
// GetEmail returns the Email field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *UserProperties) GetEmail() *string {
if o == nil {
return nil
@@ -166,38 +166,38 @@ func (o *UserProperties) HasEmail() bool {
return false
}
-// GetAdministrator returns the Administrator field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *UserProperties) GetAdministrator() *bool {
+// GetFirstname returns the Firstname field value
+// If the value is explicit nil, nil is returned
+func (o *UserProperties) GetFirstname() *string {
if o == nil {
return nil
}
- return o.Administrator
+ return o.Firstname
}
-// GetAdministratorOk returns a tuple with the Administrator field value
+// GetFirstnameOk returns a tuple with the Firstname field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserProperties) GetAdministratorOk() (*bool, bool) {
+func (o *UserProperties) GetFirstnameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Administrator, true
+ return o.Firstname, true
}
-// SetAdministrator sets field value
-func (o *UserProperties) SetAdministrator(v bool) {
+// SetFirstname sets field value
+func (o *UserProperties) SetFirstname(v string) {
- o.Administrator = &v
+ o.Firstname = &v
}
-// HasAdministrator returns a boolean if a field has been set.
-func (o *UserProperties) HasAdministrator() bool {
- if o != nil && o.Administrator != nil {
+// HasFirstname returns a boolean if a field has been set.
+func (o *UserProperties) HasFirstname() bool {
+ if o != nil && o.Firstname != nil {
return true
}
@@ -205,7 +205,7 @@ func (o *UserProperties) HasAdministrator() bool {
}
// GetForceSecAuth returns the ForceSecAuth field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *UserProperties) GetForceSecAuth() *bool {
if o == nil {
return nil
@@ -242,38 +242,38 @@ func (o *UserProperties) HasForceSecAuth() bool {
return false
}
-// GetSecAuthActive returns the SecAuthActive field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *UserProperties) GetSecAuthActive() *bool {
+// GetLastname returns the Lastname field value
+// If the value is explicit nil, nil is returned
+func (o *UserProperties) GetLastname() *string {
if o == nil {
return nil
}
- return o.SecAuthActive
+ return o.Lastname
}
-// GetSecAuthActiveOk returns a tuple with the SecAuthActive field value
+// GetLastnameOk returns a tuple with the Lastname field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserProperties) GetSecAuthActiveOk() (*bool, bool) {
+func (o *UserProperties) GetLastnameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.SecAuthActive, true
+ return o.Lastname, true
}
-// SetSecAuthActive sets field value
-func (o *UserProperties) SetSecAuthActive(v bool) {
+// SetLastname sets field value
+func (o *UserProperties) SetLastname(v string) {
- o.SecAuthActive = &v
+ o.Lastname = &v
}
-// HasSecAuthActive returns a boolean if a field has been set.
-func (o *UserProperties) HasSecAuthActive() bool {
- if o != nil && o.SecAuthActive != nil {
+// HasLastname returns a boolean if a field has been set.
+func (o *UserProperties) HasLastname() bool {
+ if o != nil && o.Lastname != nil {
return true
}
@@ -281,7 +281,7 @@ func (o *UserProperties) HasSecAuthActive() bool {
}
// GetS3CanonicalUserId returns the S3CanonicalUserId field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *UserProperties) GetS3CanonicalUserId() *string {
if o == nil {
return nil
@@ -318,38 +318,38 @@ func (o *UserProperties) HasS3CanonicalUserId() bool {
return false
}
-// GetActive returns the Active field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *UserProperties) GetActive() *bool {
+// GetSecAuthActive returns the SecAuthActive field value
+// If the value is explicit nil, nil is returned
+func (o *UserProperties) GetSecAuthActive() *bool {
if o == nil {
return nil
}
- return o.Active
+ return o.SecAuthActive
}
-// GetActiveOk returns a tuple with the Active field value
+// GetSecAuthActiveOk returns a tuple with the SecAuthActive field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserProperties) GetActiveOk() (*bool, bool) {
+func (o *UserProperties) GetSecAuthActiveOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Active, true
+ return o.SecAuthActive, true
}
-// SetActive sets field value
-func (o *UserProperties) SetActive(v bool) {
+// SetSecAuthActive sets field value
+func (o *UserProperties) SetSecAuthActive(v bool) {
- o.Active = &v
+ o.SecAuthActive = &v
}
-// HasActive returns a boolean if a field has been set.
-func (o *UserProperties) HasActive() bool {
- if o != nil && o.Active != nil {
+// HasSecAuthActive returns a boolean if a field has been set.
+func (o *UserProperties) HasSecAuthActive() bool {
+ if o != nil && o.SecAuthActive != nil {
return true
}
@@ -358,30 +358,38 @@ func (o *UserProperties) HasActive() bool {
func (o UserProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Firstname != nil {
- toSerialize["firstname"] = o.Firstname
+ if o.Active != nil {
+ toSerialize["active"] = o.Active
}
- if o.Lastname != nil {
- toSerialize["lastname"] = o.Lastname
+
+ if o.Administrator != nil {
+ toSerialize["administrator"] = o.Administrator
}
+
if o.Email != nil {
toSerialize["email"] = o.Email
}
- if o.Administrator != nil {
- toSerialize["administrator"] = o.Administrator
+
+ if o.Firstname != nil {
+ toSerialize["firstname"] = o.Firstname
}
+
if o.ForceSecAuth != nil {
toSerialize["forceSecAuth"] = o.ForceSecAuth
}
- if o.SecAuthActive != nil {
- toSerialize["secAuthActive"] = o.SecAuthActive
+
+ if o.Lastname != nil {
+ toSerialize["lastname"] = o.Lastname
}
+
if o.S3CanonicalUserId != nil {
toSerialize["s3CanonicalUserId"] = o.S3CanonicalUserId
}
- if o.Active != nil {
- toSerialize["active"] = o.Active
+
+ if o.SecAuthActive != nil {
+ toSerialize["secAuthActive"] = o.SecAuthActive
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_properties_post.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_properties_post.go
index 463eb6dc3a3..fb4e9026f5b 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_properties_post.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_properties_post.go
@@ -16,22 +16,22 @@ import (
// UserPropertiesPost struct for UserPropertiesPost
type UserPropertiesPost struct {
- // The first name of the user.
- Firstname *string `json:"firstname,omitempty"`
- // The last name of the user.
- Lastname *string `json:"lastname,omitempty"`
- // The email address of the user.
- Email *string `json:"email,omitempty"`
+ // Indicates if the user is active.
+ Active *bool `json:"active,omitempty"`
// Indicates if the user has admin rights.
Administrator *bool `json:"administrator,omitempty"`
+ // The email address of the user.
+ Email *string `json:"email,omitempty"`
+ // The first name of the user.
+ Firstname *string `json:"firstname,omitempty"`
// Indicates if secure authentication should be forced on the user.
ForceSecAuth *bool `json:"forceSecAuth,omitempty"`
- // Indicates if secure authentication is active for the user.
- SecAuthActive *bool `json:"secAuthActive,omitempty"`
+ // The last name of the user.
+ Lastname *string `json:"lastname,omitempty"`
// User password.
Password *string `json:"password,omitempty"`
- // Indicates if the user is active.
- Active *bool `json:"active,omitempty"`
+ // Indicates if secure authentication is active for the user.
+ SecAuthActive *bool `json:"secAuthActive,omitempty"`
}
// NewUserPropertiesPost instantiates a new UserPropertiesPost object
@@ -52,76 +52,76 @@ func NewUserPropertiesPostWithDefaults() *UserPropertiesPost {
return &this
}
-// GetFirstname returns the Firstname field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *UserPropertiesPost) GetFirstname() *string {
+// GetActive returns the Active field value
+// If the value is explicit nil, nil is returned
+func (o *UserPropertiesPost) GetActive() *bool {
if o == nil {
return nil
}
- return o.Firstname
+ return o.Active
}
-// GetFirstnameOk returns a tuple with the Firstname field value
+// GetActiveOk returns a tuple with the Active field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserPropertiesPost) GetFirstnameOk() (*string, bool) {
+func (o *UserPropertiesPost) GetActiveOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Firstname, true
+ return o.Active, true
}
-// SetFirstname sets field value
-func (o *UserPropertiesPost) SetFirstname(v string) {
+// SetActive sets field value
+func (o *UserPropertiesPost) SetActive(v bool) {
- o.Firstname = &v
+ o.Active = &v
}
-// HasFirstname returns a boolean if a field has been set.
-func (o *UserPropertiesPost) HasFirstname() bool {
- if o != nil && o.Firstname != nil {
+// HasActive returns a boolean if a field has been set.
+func (o *UserPropertiesPost) HasActive() bool {
+ if o != nil && o.Active != nil {
return true
}
return false
}
-// GetLastname returns the Lastname field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *UserPropertiesPost) GetLastname() *string {
+// GetAdministrator returns the Administrator field value
+// If the value is explicit nil, nil is returned
+func (o *UserPropertiesPost) GetAdministrator() *bool {
if o == nil {
return nil
}
- return o.Lastname
+ return o.Administrator
}
-// GetLastnameOk returns a tuple with the Lastname field value
+// GetAdministratorOk returns a tuple with the Administrator field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserPropertiesPost) GetLastnameOk() (*string, bool) {
+func (o *UserPropertiesPost) GetAdministratorOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Lastname, true
+ return o.Administrator, true
}
-// SetLastname sets field value
-func (o *UserPropertiesPost) SetLastname(v string) {
+// SetAdministrator sets field value
+func (o *UserPropertiesPost) SetAdministrator(v bool) {
- o.Lastname = &v
+ o.Administrator = &v
}
-// HasLastname returns a boolean if a field has been set.
-func (o *UserPropertiesPost) HasLastname() bool {
- if o != nil && o.Lastname != nil {
+// HasAdministrator returns a boolean if a field has been set.
+func (o *UserPropertiesPost) HasAdministrator() bool {
+ if o != nil && o.Administrator != nil {
return true
}
@@ -129,7 +129,7 @@ func (o *UserPropertiesPost) HasLastname() bool {
}
// GetEmail returns the Email field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *UserPropertiesPost) GetEmail() *string {
if o == nil {
return nil
@@ -166,38 +166,38 @@ func (o *UserPropertiesPost) HasEmail() bool {
return false
}
-// GetAdministrator returns the Administrator field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *UserPropertiesPost) GetAdministrator() *bool {
+// GetFirstname returns the Firstname field value
+// If the value is explicit nil, nil is returned
+func (o *UserPropertiesPost) GetFirstname() *string {
if o == nil {
return nil
}
- return o.Administrator
+ return o.Firstname
}
-// GetAdministratorOk returns a tuple with the Administrator field value
+// GetFirstnameOk returns a tuple with the Firstname field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserPropertiesPost) GetAdministratorOk() (*bool, bool) {
+func (o *UserPropertiesPost) GetFirstnameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Administrator, true
+ return o.Firstname, true
}
-// SetAdministrator sets field value
-func (o *UserPropertiesPost) SetAdministrator(v bool) {
+// SetFirstname sets field value
+func (o *UserPropertiesPost) SetFirstname(v string) {
- o.Administrator = &v
+ o.Firstname = &v
}
-// HasAdministrator returns a boolean if a field has been set.
-func (o *UserPropertiesPost) HasAdministrator() bool {
- if o != nil && o.Administrator != nil {
+// HasFirstname returns a boolean if a field has been set.
+func (o *UserPropertiesPost) HasFirstname() bool {
+ if o != nil && o.Firstname != nil {
return true
}
@@ -205,7 +205,7 @@ func (o *UserPropertiesPost) HasAdministrator() bool {
}
// GetForceSecAuth returns the ForceSecAuth field value
-// If the value is explicit nil, the zero value for bool will be returned
+// If the value is explicit nil, nil is returned
func (o *UserPropertiesPost) GetForceSecAuth() *bool {
if o == nil {
return nil
@@ -242,38 +242,38 @@ func (o *UserPropertiesPost) HasForceSecAuth() bool {
return false
}
-// GetSecAuthActive returns the SecAuthActive field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *UserPropertiesPost) GetSecAuthActive() *bool {
+// GetLastname returns the Lastname field value
+// If the value is explicit nil, nil is returned
+func (o *UserPropertiesPost) GetLastname() *string {
if o == nil {
return nil
}
- return o.SecAuthActive
+ return o.Lastname
}
-// GetSecAuthActiveOk returns a tuple with the SecAuthActive field value
+// GetLastnameOk returns a tuple with the Lastname field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserPropertiesPost) GetSecAuthActiveOk() (*bool, bool) {
+func (o *UserPropertiesPost) GetLastnameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.SecAuthActive, true
+ return o.Lastname, true
}
-// SetSecAuthActive sets field value
-func (o *UserPropertiesPost) SetSecAuthActive(v bool) {
+// SetLastname sets field value
+func (o *UserPropertiesPost) SetLastname(v string) {
- o.SecAuthActive = &v
+ o.Lastname = &v
}
-// HasSecAuthActive returns a boolean if a field has been set.
-func (o *UserPropertiesPost) HasSecAuthActive() bool {
- if o != nil && o.SecAuthActive != nil {
+// HasLastname returns a boolean if a field has been set.
+func (o *UserPropertiesPost) HasLastname() bool {
+ if o != nil && o.Lastname != nil {
return true
}
@@ -281,7 +281,7 @@ func (o *UserPropertiesPost) HasSecAuthActive() bool {
}
// GetPassword returns the Password field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *UserPropertiesPost) GetPassword() *string {
if o == nil {
return nil
@@ -318,38 +318,38 @@ func (o *UserPropertiesPost) HasPassword() bool {
return false
}
-// GetActive returns the Active field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *UserPropertiesPost) GetActive() *bool {
+// GetSecAuthActive returns the SecAuthActive field value
+// If the value is explicit nil, nil is returned
+func (o *UserPropertiesPost) GetSecAuthActive() *bool {
if o == nil {
return nil
}
- return o.Active
+ return o.SecAuthActive
}
-// GetActiveOk returns a tuple with the Active field value
+// GetSecAuthActiveOk returns a tuple with the SecAuthActive field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserPropertiesPost) GetActiveOk() (*bool, bool) {
+func (o *UserPropertiesPost) GetSecAuthActiveOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Active, true
+ return o.SecAuthActive, true
}
-// SetActive sets field value
-func (o *UserPropertiesPost) SetActive(v bool) {
+// SetSecAuthActive sets field value
+func (o *UserPropertiesPost) SetSecAuthActive(v bool) {
- o.Active = &v
+ o.SecAuthActive = &v
}
-// HasActive returns a boolean if a field has been set.
-func (o *UserPropertiesPost) HasActive() bool {
- if o != nil && o.Active != nil {
+// HasSecAuthActive returns a boolean if a field has been set.
+func (o *UserPropertiesPost) HasSecAuthActive() bool {
+ if o != nil && o.SecAuthActive != nil {
return true
}
@@ -358,30 +358,38 @@ func (o *UserPropertiesPost) HasActive() bool {
func (o UserPropertiesPost) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Firstname != nil {
- toSerialize["firstname"] = o.Firstname
+ if o.Active != nil {
+ toSerialize["active"] = o.Active
}
- if o.Lastname != nil {
- toSerialize["lastname"] = o.Lastname
+
+ if o.Administrator != nil {
+ toSerialize["administrator"] = o.Administrator
}
+
if o.Email != nil {
toSerialize["email"] = o.Email
}
- if o.Administrator != nil {
- toSerialize["administrator"] = o.Administrator
+
+ if o.Firstname != nil {
+ toSerialize["firstname"] = o.Firstname
}
+
if o.ForceSecAuth != nil {
toSerialize["forceSecAuth"] = o.ForceSecAuth
}
- if o.SecAuthActive != nil {
- toSerialize["secAuthActive"] = o.SecAuthActive
+
+ if o.Lastname != nil {
+ toSerialize["lastname"] = o.Lastname
}
+
if o.Password != nil {
toSerialize["password"] = o.Password
}
- if o.Active != nil {
- toSerialize["active"] = o.Active
+
+ if o.SecAuthActive != nil {
+ toSerialize["secAuthActive"] = o.SecAuthActive
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_properties_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_properties_put.go
index 778c3b0cfc5..d0ad92946ec 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_properties_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_properties_put.go
@@ -16,22 +16,22 @@ import (
// UserPropertiesPut struct for UserPropertiesPut
type UserPropertiesPut struct {
+ // Indicates if the user is active.
+ Active *bool `json:"active,omitempty"`
+ // Indicates if the user has admin rights.
+ Administrator *bool `json:"administrator,omitempty"`
+ // The email address of the user.
+ Email *string `json:"email,omitempty"`
// The first name of the user.
Firstname *string `json:"firstname,omitempty"`
+ // Indicates if secure authentication should be forced on the user.
+ ForceSecAuth *bool `json:"forceSecAuth,omitempty"`
// The last name of the user.
Lastname *string `json:"lastname,omitempty"`
- // The email address of the user.
- Email *string `json:"email,omitempty"`
// password of the user
Password *string `json:"password,omitempty"`
- // Indicates if the user has admin rights.
- Administrator *bool `json:"administrator,omitempty"`
- // Indicates if secure authentication should be forced on the user.
- ForceSecAuth *bool `json:"forceSecAuth,omitempty"`
// Indicates if secure authentication is active for the user.
SecAuthActive *bool `json:"secAuthActive,omitempty"`
- // Indicates if the user is active.
- Active *bool `json:"active,omitempty"`
}
// NewUserPropertiesPut instantiates a new UserPropertiesPut object
@@ -52,76 +52,76 @@ func NewUserPropertiesPutWithDefaults() *UserPropertiesPut {
return &this
}
-// GetFirstname returns the Firstname field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *UserPropertiesPut) GetFirstname() *string {
+// GetActive returns the Active field value
+// If the value is explicit nil, nil is returned
+func (o *UserPropertiesPut) GetActive() *bool {
if o == nil {
return nil
}
- return o.Firstname
+ return o.Active
}
-// GetFirstnameOk returns a tuple with the Firstname field value
+// GetActiveOk returns a tuple with the Active field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserPropertiesPut) GetFirstnameOk() (*string, bool) {
+func (o *UserPropertiesPut) GetActiveOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Firstname, true
+ return o.Active, true
}
-// SetFirstname sets field value
-func (o *UserPropertiesPut) SetFirstname(v string) {
+// SetActive sets field value
+func (o *UserPropertiesPut) SetActive(v bool) {
- o.Firstname = &v
+ o.Active = &v
}
-// HasFirstname returns a boolean if a field has been set.
-func (o *UserPropertiesPut) HasFirstname() bool {
- if o != nil && o.Firstname != nil {
+// HasActive returns a boolean if a field has been set.
+func (o *UserPropertiesPut) HasActive() bool {
+ if o != nil && o.Active != nil {
return true
}
return false
}
-// GetLastname returns the Lastname field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *UserPropertiesPut) GetLastname() *string {
+// GetAdministrator returns the Administrator field value
+// If the value is explicit nil, nil is returned
+func (o *UserPropertiesPut) GetAdministrator() *bool {
if o == nil {
return nil
}
- return o.Lastname
+ return o.Administrator
}
-// GetLastnameOk returns a tuple with the Lastname field value
+// GetAdministratorOk returns a tuple with the Administrator field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserPropertiesPut) GetLastnameOk() (*string, bool) {
+func (o *UserPropertiesPut) GetAdministratorOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Lastname, true
+ return o.Administrator, true
}
-// SetLastname sets field value
-func (o *UserPropertiesPut) SetLastname(v string) {
+// SetAdministrator sets field value
+func (o *UserPropertiesPut) SetAdministrator(v bool) {
- o.Lastname = &v
+ o.Administrator = &v
}
-// HasLastname returns a boolean if a field has been set.
-func (o *UserPropertiesPut) HasLastname() bool {
- if o != nil && o.Lastname != nil {
+// HasAdministrator returns a boolean if a field has been set.
+func (o *UserPropertiesPut) HasAdministrator() bool {
+ if o != nil && o.Administrator != nil {
return true
}
@@ -129,7 +129,7 @@ func (o *UserPropertiesPut) HasLastname() bool {
}
// GetEmail returns the Email field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *UserPropertiesPut) GetEmail() *string {
if o == nil {
return nil
@@ -166,190 +166,190 @@ func (o *UserPropertiesPut) HasEmail() bool {
return false
}
-// GetPassword returns the Password field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *UserPropertiesPut) GetPassword() *string {
+// GetFirstname returns the Firstname field value
+// If the value is explicit nil, nil is returned
+func (o *UserPropertiesPut) GetFirstname() *string {
if o == nil {
return nil
}
- return o.Password
+ return o.Firstname
}
-// GetPasswordOk returns a tuple with the Password field value
+// GetFirstnameOk returns a tuple with the Firstname field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserPropertiesPut) GetPasswordOk() (*string, bool) {
+func (o *UserPropertiesPut) GetFirstnameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Password, true
+ return o.Firstname, true
}
-// SetPassword sets field value
-func (o *UserPropertiesPut) SetPassword(v string) {
+// SetFirstname sets field value
+func (o *UserPropertiesPut) SetFirstname(v string) {
- o.Password = &v
+ o.Firstname = &v
}
-// HasPassword returns a boolean if a field has been set.
-func (o *UserPropertiesPut) HasPassword() bool {
- if o != nil && o.Password != nil {
+// HasFirstname returns a boolean if a field has been set.
+func (o *UserPropertiesPut) HasFirstname() bool {
+ if o != nil && o.Firstname != nil {
return true
}
return false
}
-// GetAdministrator returns the Administrator field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *UserPropertiesPut) GetAdministrator() *bool {
+// GetForceSecAuth returns the ForceSecAuth field value
+// If the value is explicit nil, nil is returned
+func (o *UserPropertiesPut) GetForceSecAuth() *bool {
if o == nil {
return nil
}
- return o.Administrator
+ return o.ForceSecAuth
}
-// GetAdministratorOk returns a tuple with the Administrator field value
+// GetForceSecAuthOk returns a tuple with the ForceSecAuth field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserPropertiesPut) GetAdministratorOk() (*bool, bool) {
+func (o *UserPropertiesPut) GetForceSecAuthOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Administrator, true
+ return o.ForceSecAuth, true
}
-// SetAdministrator sets field value
-func (o *UserPropertiesPut) SetAdministrator(v bool) {
+// SetForceSecAuth sets field value
+func (o *UserPropertiesPut) SetForceSecAuth(v bool) {
- o.Administrator = &v
+ o.ForceSecAuth = &v
}
-// HasAdministrator returns a boolean if a field has been set.
-func (o *UserPropertiesPut) HasAdministrator() bool {
- if o != nil && o.Administrator != nil {
+// HasForceSecAuth returns a boolean if a field has been set.
+func (o *UserPropertiesPut) HasForceSecAuth() bool {
+ if o != nil && o.ForceSecAuth != nil {
return true
}
return false
}
-// GetForceSecAuth returns the ForceSecAuth field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *UserPropertiesPut) GetForceSecAuth() *bool {
+// GetLastname returns the Lastname field value
+// If the value is explicit nil, nil is returned
+func (o *UserPropertiesPut) GetLastname() *string {
if o == nil {
return nil
}
- return o.ForceSecAuth
+ return o.Lastname
}
-// GetForceSecAuthOk returns a tuple with the ForceSecAuth field value
+// GetLastnameOk returns a tuple with the Lastname field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserPropertiesPut) GetForceSecAuthOk() (*bool, bool) {
+func (o *UserPropertiesPut) GetLastnameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.ForceSecAuth, true
+ return o.Lastname, true
}
-// SetForceSecAuth sets field value
-func (o *UserPropertiesPut) SetForceSecAuth(v bool) {
+// SetLastname sets field value
+func (o *UserPropertiesPut) SetLastname(v string) {
- o.ForceSecAuth = &v
+ o.Lastname = &v
}
-// HasForceSecAuth returns a boolean if a field has been set.
-func (o *UserPropertiesPut) HasForceSecAuth() bool {
- if o != nil && o.ForceSecAuth != nil {
+// HasLastname returns a boolean if a field has been set.
+func (o *UserPropertiesPut) HasLastname() bool {
+ if o != nil && o.Lastname != nil {
return true
}
return false
}
-// GetSecAuthActive returns the SecAuthActive field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *UserPropertiesPut) GetSecAuthActive() *bool {
+// GetPassword returns the Password field value
+// If the value is explicit nil, nil is returned
+func (o *UserPropertiesPut) GetPassword() *string {
if o == nil {
return nil
}
- return o.SecAuthActive
+ return o.Password
}
-// GetSecAuthActiveOk returns a tuple with the SecAuthActive field value
+// GetPasswordOk returns a tuple with the Password field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserPropertiesPut) GetSecAuthActiveOk() (*bool, bool) {
+func (o *UserPropertiesPut) GetPasswordOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.SecAuthActive, true
+ return o.Password, true
}
-// SetSecAuthActive sets field value
-func (o *UserPropertiesPut) SetSecAuthActive(v bool) {
+// SetPassword sets field value
+func (o *UserPropertiesPut) SetPassword(v string) {
- o.SecAuthActive = &v
+ o.Password = &v
}
-// HasSecAuthActive returns a boolean if a field has been set.
-func (o *UserPropertiesPut) HasSecAuthActive() bool {
- if o != nil && o.SecAuthActive != nil {
+// HasPassword returns a boolean if a field has been set.
+func (o *UserPropertiesPut) HasPassword() bool {
+ if o != nil && o.Password != nil {
return true
}
return false
}
-// GetActive returns the Active field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *UserPropertiesPut) GetActive() *bool {
+// GetSecAuthActive returns the SecAuthActive field value
+// If the value is explicit nil, nil is returned
+func (o *UserPropertiesPut) GetSecAuthActive() *bool {
if o == nil {
return nil
}
- return o.Active
+ return o.SecAuthActive
}
-// GetActiveOk returns a tuple with the Active field value
+// GetSecAuthActiveOk returns a tuple with the SecAuthActive field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UserPropertiesPut) GetActiveOk() (*bool, bool) {
+func (o *UserPropertiesPut) GetSecAuthActiveOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Active, true
+ return o.SecAuthActive, true
}
-// SetActive sets field value
-func (o *UserPropertiesPut) SetActive(v bool) {
+// SetSecAuthActive sets field value
+func (o *UserPropertiesPut) SetSecAuthActive(v bool) {
- o.Active = &v
+ o.SecAuthActive = &v
}
-// HasActive returns a boolean if a field has been set.
-func (o *UserPropertiesPut) HasActive() bool {
- if o != nil && o.Active != nil {
+// HasSecAuthActive returns a boolean if a field has been set.
+func (o *UserPropertiesPut) HasSecAuthActive() bool {
+ if o != nil && o.SecAuthActive != nil {
return true
}
@@ -358,30 +358,38 @@ func (o *UserPropertiesPut) HasActive() bool {
func (o UserPropertiesPut) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Firstname != nil {
- toSerialize["firstname"] = o.Firstname
+ if o.Active != nil {
+ toSerialize["active"] = o.Active
}
- if o.Lastname != nil {
- toSerialize["lastname"] = o.Lastname
+
+ if o.Administrator != nil {
+ toSerialize["administrator"] = o.Administrator
}
+
if o.Email != nil {
toSerialize["email"] = o.Email
}
- if o.Password != nil {
- toSerialize["password"] = o.Password
- }
- if o.Administrator != nil {
- toSerialize["administrator"] = o.Administrator
+
+ if o.Firstname != nil {
+ toSerialize["firstname"] = o.Firstname
}
+
if o.ForceSecAuth != nil {
toSerialize["forceSecAuth"] = o.ForceSecAuth
}
+
+ if o.Lastname != nil {
+ toSerialize["lastname"] = o.Lastname
+ }
+
+ if o.Password != nil {
+ toSerialize["password"] = o.Password
+ }
+
if o.SecAuthActive != nil {
toSerialize["secAuthActive"] = o.SecAuthActive
}
- if o.Active != nil {
- toSerialize["active"] = o.Active
- }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_put.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_put.go
index b45261f2f44..9e0c992c990 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_put.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_user_put.go
@@ -42,7 +42,7 @@ func NewUserPutWithDefaults() *UserPut {
}
// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
+// If the value is explicit nil, nil is returned
func (o *UserPut) GetId() *string {
if o == nil {
return nil
@@ -80,7 +80,7 @@ func (o *UserPut) HasId() bool {
}
// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for UserPropertiesPut will be returned
+// If the value is explicit nil, nil is returned
func (o *UserPut) GetProperties() *UserPropertiesPut {
if o == nil {
return nil
@@ -122,9 +122,11 @@ func (o UserPut) MarshalJSON() ([]byte, error) {
if o.Id != nil {
toSerialize["id"] = o.Id
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_users.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_users.go
index 0107d029b32..e67610e195f 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_users.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_users.go
@@ -16,19 +16,19 @@ import (
// Users struct for Users
type Users struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]User `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewUsers instantiates a new Users object
@@ -49,114 +49,114 @@ func NewUsersWithDefaults() *Users {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Users) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *Users) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Users) GetIdOk() (*string, bool) {
+func (o *Users) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *Users) SetId(v string) {
+// SetLinks sets field value
+func (o *Users) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Users) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *Users) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Users) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Users) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Users) GetTypeOk() (*Type, bool) {
+func (o *Users) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Users) SetType(v Type) {
+// SetHref sets field value
+func (o *Users) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Users) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Users) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Users) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Users) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Users) GetHrefOk() (*string, bool) {
+func (o *Users) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Users) SetHref(v string) {
+// SetId sets field value
+func (o *Users) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Users) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Users) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *Users) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []User will be returned
+// If the value is explicit nil, nil is returned
func (o *Users) GetItems() *[]User {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *Users) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Users) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *Users) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Users) GetOffsetOk() (*float32, bool) {
+func (o *Users) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *Users) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *Users) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *Users) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *Users) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Users) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *Users) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Users) GetLimitOk() (*float32, bool) {
+func (o *Users) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *Users) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *Users) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *Users) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *Users) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *Users) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Users) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Users) GetLinksOk() (*PaginationLinks, bool) {
+func (o *Users) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *Users) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *Users) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *Users) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Users) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *Users) HasLinks() bool {
func (o Users) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_users_entities.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_users_entities.go
index 6c10d5a04b1..7619f661192 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_users_entities.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_users_entities.go
@@ -16,8 +16,8 @@ import (
// UsersEntities struct for UsersEntities
type UsersEntities struct {
- Owns *ResourcesUsers `json:"owns,omitempty"`
Groups *GroupUsers `json:"groups,omitempty"`
+ Owns *ResourcesUsers `json:"owns,omitempty"`
}
// NewUsersEntities instantiates a new UsersEntities object
@@ -38,76 +38,76 @@ func NewUsersEntitiesWithDefaults() *UsersEntities {
return &this
}
-// GetOwns returns the Owns field value
-// If the value is explicit nil, the zero value for ResourcesUsers will be returned
-func (o *UsersEntities) GetOwns() *ResourcesUsers {
+// GetGroups returns the Groups field value
+// If the value is explicit nil, nil is returned
+func (o *UsersEntities) GetGroups() *GroupUsers {
if o == nil {
return nil
}
- return o.Owns
+ return o.Groups
}
-// GetOwnsOk returns a tuple with the Owns field value
+// GetGroupsOk returns a tuple with the Groups field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UsersEntities) GetOwnsOk() (*ResourcesUsers, bool) {
+func (o *UsersEntities) GetGroupsOk() (*GroupUsers, bool) {
if o == nil {
return nil, false
}
- return o.Owns, true
+ return o.Groups, true
}
-// SetOwns sets field value
-func (o *UsersEntities) SetOwns(v ResourcesUsers) {
+// SetGroups sets field value
+func (o *UsersEntities) SetGroups(v GroupUsers) {
- o.Owns = &v
+ o.Groups = &v
}
-// HasOwns returns a boolean if a field has been set.
-func (o *UsersEntities) HasOwns() bool {
- if o != nil && o.Owns != nil {
+// HasGroups returns a boolean if a field has been set.
+func (o *UsersEntities) HasGroups() bool {
+ if o != nil && o.Groups != nil {
return true
}
return false
}
-// GetGroups returns the Groups field value
-// If the value is explicit nil, the zero value for GroupUsers will be returned
-func (o *UsersEntities) GetGroups() *GroupUsers {
+// GetOwns returns the Owns field value
+// If the value is explicit nil, nil is returned
+func (o *UsersEntities) GetOwns() *ResourcesUsers {
if o == nil {
return nil
}
- return o.Groups
+ return o.Owns
}
-// GetGroupsOk returns a tuple with the Groups field value
+// GetOwnsOk returns a tuple with the Owns field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *UsersEntities) GetGroupsOk() (*GroupUsers, bool) {
+func (o *UsersEntities) GetOwnsOk() (*ResourcesUsers, bool) {
if o == nil {
return nil, false
}
- return o.Groups, true
+ return o.Owns, true
}
-// SetGroups sets field value
-func (o *UsersEntities) SetGroups(v GroupUsers) {
+// SetOwns sets field value
+func (o *UsersEntities) SetOwns(v ResourcesUsers) {
- o.Groups = &v
+ o.Owns = &v
}
-// HasGroups returns a boolean if a field has been set.
-func (o *UsersEntities) HasGroups() bool {
- if o != nil && o.Groups != nil {
+// HasOwns returns a boolean if a field has been set.
+func (o *UsersEntities) HasOwns() bool {
+ if o != nil && o.Owns != nil {
return true
}
@@ -116,12 +116,14 @@ func (o *UsersEntities) HasGroups() bool {
func (o UsersEntities) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Owns != nil {
- toSerialize["owns"] = o.Owns
- }
if o.Groups != nil {
toSerialize["groups"] = o.Groups
}
+
+ if o.Owns != nil {
+ toSerialize["owns"] = o.Owns
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_volume.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_volume.go
index d0b7b862ede..59bf03f024d 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_volume.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_volume.go
@@ -16,14 +16,14 @@ import (
// Volume struct for Volume
type Volume struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
// The URL to the object representation (absolute path).
- Href *string `json:"href,omitempty"`
+ Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
Metadata *DatacenterElementMetadata `json:"metadata,omitempty"`
Properties *VolumeProperties `json:"properties"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewVolume instantiates a new Volume object
@@ -46,190 +46,190 @@ func NewVolumeWithDefaults() *Volume {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Volume) GetId() *string {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Volume) GetHref() *string {
if o == nil {
return nil
}
- return o.Id
+ return o.Href
}
-// GetIdOk returns a tuple with the Id field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Volume) GetIdOk() (*string, bool) {
+func (o *Volume) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Href, true
}
-// SetId sets field value
-func (o *Volume) SetId(v string) {
+// SetHref sets field value
+func (o *Volume) SetHref(v string) {
- o.Id = &v
+ o.Href = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Volume) HasId() bool {
- if o != nil && o.Id != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Volume) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Volume) GetType() *Type {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Volume) GetId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Id
}
-// GetTypeOk returns a tuple with the Type field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Volume) GetTypeOk() (*Type, bool) {
+func (o *Volume) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Id, true
}
-// SetType sets field value
-func (o *Volume) SetType(v Type) {
+// SetId sets field value
+func (o *Volume) SetId(v string) {
- o.Type = &v
+ o.Id = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Volume) HasType() bool {
- if o != nil && o.Type != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Volume) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Volume) GetHref() *string {
+// GetMetadata returns the Metadata field value
+// If the value is explicit nil, nil is returned
+func (o *Volume) GetMetadata() *DatacenterElementMetadata {
if o == nil {
return nil
}
- return o.Href
+ return o.Metadata
}
-// GetHrefOk returns a tuple with the Href field value
+// GetMetadataOk returns a tuple with the Metadata field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Volume) GetHrefOk() (*string, bool) {
+func (o *Volume) GetMetadataOk() (*DatacenterElementMetadata, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Metadata, true
}
-// SetHref sets field value
-func (o *Volume) SetHref(v string) {
+// SetMetadata sets field value
+func (o *Volume) SetMetadata(v DatacenterElementMetadata) {
- o.Href = &v
+ o.Metadata = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Volume) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasMetadata returns a boolean if a field has been set.
+func (o *Volume) HasMetadata() bool {
+ if o != nil && o.Metadata != nil {
return true
}
return false
}
-// GetMetadata returns the Metadata field value
-// If the value is explicit nil, the zero value for DatacenterElementMetadata will be returned
-func (o *Volume) GetMetadata() *DatacenterElementMetadata {
+// GetProperties returns the Properties field value
+// If the value is explicit nil, nil is returned
+func (o *Volume) GetProperties() *VolumeProperties {
if o == nil {
return nil
}
- return o.Metadata
+ return o.Properties
}
-// GetMetadataOk returns a tuple with the Metadata field value
+// GetPropertiesOk returns a tuple with the Properties field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Volume) GetMetadataOk() (*DatacenterElementMetadata, bool) {
+func (o *Volume) GetPropertiesOk() (*VolumeProperties, bool) {
if o == nil {
return nil, false
}
- return o.Metadata, true
+ return o.Properties, true
}
-// SetMetadata sets field value
-func (o *Volume) SetMetadata(v DatacenterElementMetadata) {
+// SetProperties sets field value
+func (o *Volume) SetProperties(v VolumeProperties) {
- o.Metadata = &v
+ o.Properties = &v
}
-// HasMetadata returns a boolean if a field has been set.
-func (o *Volume) HasMetadata() bool {
- if o != nil && o.Metadata != nil {
+// HasProperties returns a boolean if a field has been set.
+func (o *Volume) HasProperties() bool {
+ if o != nil && o.Properties != nil {
return true
}
return false
}
-// GetProperties returns the Properties field value
-// If the value is explicit nil, the zero value for VolumeProperties will be returned
-func (o *Volume) GetProperties() *VolumeProperties {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Volume) GetType() *Type {
if o == nil {
return nil
}
- return o.Properties
+ return o.Type
}
-// GetPropertiesOk returns a tuple with the Properties field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Volume) GetPropertiesOk() (*VolumeProperties, bool) {
+func (o *Volume) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Properties, true
+ return o.Type, true
}
-// SetProperties sets field value
-func (o *Volume) SetProperties(v VolumeProperties) {
+// SetType sets field value
+func (o *Volume) SetType(v Type) {
- o.Properties = &v
+ o.Type = &v
}
-// HasProperties returns a boolean if a field has been set.
-func (o *Volume) HasProperties() bool {
- if o != nil && o.Properties != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Volume) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -238,21 +238,26 @@ func (o *Volume) HasProperties() bool {
func (o Volume) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
- }
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Metadata != nil {
toSerialize["metadata"] = o.Metadata
}
+
if o.Properties != nil {
toSerialize["properties"] = o.Properties
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_volume_properties.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_volume_properties.go
index 15ed6a14860..6f6bc6b963e 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_volume_properties.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_volume_properties.go
@@ -16,49 +16,50 @@ import (
// VolumeProperties struct for VolumeProperties
type VolumeProperties struct {
- // The name of the resource.
- Name *string `json:"name,omitempty"`
- // Hardware type of the volume. DAS (Direct Attached Storage) could be used only in a composite call with a Cube server.
- Type *string `json:"type,omitempty"`
- // The size of the volume in GB.
- Size *float32 `json:"size"`
// The availability zone in which the volume should be provisioned. The storage volume will be provisioned on as few physical storage devices as possible, but this cannot be guaranteed upfront. This is uavailable for DAS (Direct Attached Storage), and subject to availability for SSD.
AvailabilityZone *string `json:"availabilityZone,omitempty"`
+ // The ID of the backup unit that the user has access to. The property is immutable and is only allowed to be set on creation of a new a volume. It is mandatory to provide either 'public image' or 'imageAlias' in conjunction with this property.
+ BackupunitId *string `json:"backupunitId,omitempty"`
+ // Determines whether the volume will be used as a boot volume. Set to `NONE`, the volume will not be used as boot volume. Set to `PRIMARY`, the volume will be used as boot volume and all other volumes must be set to `NONE`. Set to `AUTO` or `null` requires all volumes to be set to `AUTO` or `null`; this will use the legacy behavior, which is to use the volume as a boot volume only if there are no other volumes or cdrom devices.
+ // to set this field to `nil` in order to be marshalled, the explicit nil address `Nilstring` can be used, or the setter `SetBootOrderNil`
+ BootOrder *string `json:"bootOrder,omitempty"`
+ // The UUID of the attached server.
+ BootServer *string `json:"bootServer,omitempty"`
+ // The bus type for this volume; default is VIRTIO.
+ Bus *string `json:"bus,omitempty"`
+ // Hot-plug capable CPU (no reboot required).
+ CpuHotPlug *bool `json:"cpuHotPlug,omitempty"`
+ // The Logical Unit Number of the storage volume. Null for volumes, not mounted to a VM.
+ DeviceNumber *int64 `json:"deviceNumber,omitempty"`
+ // Hot-plug capable Virt-IO drive (no reboot required).
+ DiscVirtioHotPlug *bool `json:"discVirtioHotPlug,omitempty"`
+ // Hot-unplug capable Virt-IO drive (no reboot required). Not supported with Windows VMs.
+ DiscVirtioHotUnplug *bool `json:"discVirtioHotUnplug,omitempty"`
// Image or snapshot ID to be used as template for this volume.
- Image *string `json:"image,omitempty"`
+ Image *string `json:"image,omitempty"`
+ ImageAlias *string `json:"imageAlias,omitempty"`
// Initial password to be set for installed OS. Works with public images only. Not modifiable, forbidden in update requests. Password rules allows all characters from a-z, A-Z, 0-9.
ImagePassword *string `json:"imagePassword,omitempty"`
- ImageAlias *string `json:"imageAlias,omitempty"`
- // Public SSH keys are set on the image as authorized keys for appropriate SSH login to the instance using the corresponding private key. This field may only be set in creation requests. When reading, it always returns null. SSH keys are only supported if a public Linux image is used for the volume creation.
- SshKeys *[]string `json:"sshKeys,omitempty"`
- // The bus type for this volume; default is VIRTIO.
- Bus *string `json:"bus,omitempty"`
// OS type for this volume.
LicenceType *string `json:"licenceType,omitempty"`
- // Hot-plug capable CPU (no reboot required).
- CpuHotPlug *bool `json:"cpuHotPlug,omitempty"`
- // Hot-plug capable RAM (no reboot required).
- RamHotPlug *bool `json:"ramHotPlug,omitempty"`
+ // The name of the resource.
+ Name *string `json:"name,omitempty"`
// Hot-plug capable NIC (no reboot required).
NicHotPlug *bool `json:"nicHotPlug,omitempty"`
// Hot-unplug capable NIC (no reboot required).
NicHotUnplug *bool `json:"nicHotUnplug,omitempty"`
- // Hot-plug capable Virt-IO drive (no reboot required).
- DiscVirtioHotPlug *bool `json:"discVirtioHotPlug,omitempty"`
- // Hot-unplug capable Virt-IO drive (no reboot required). Not supported with Windows VMs.
- DiscVirtioHotUnplug *bool `json:"discVirtioHotUnplug,omitempty"`
- // The Logical Unit Number of the storage volume. Null for volumes, not mounted to a VM.
- DeviceNumber *int64 `json:"deviceNumber,omitempty"`
// The PCI slot number of the storage volume. Null for volumes, not mounted to a VM.
PciSlot *int32 `json:"pciSlot,omitempty"`
- // The ID of the backup unit that the user has access to. The property is immutable and is only allowed to be set on creation of a new a volume. It is mandatory to provide either 'public image' or 'imageAlias' in conjunction with this property.
- BackupunitId *string `json:"backupunitId,omitempty"`
+ // Hot-plug capable RAM (no reboot required).
+ RamHotPlug *bool `json:"ramHotPlug,omitempty"`
+ // The size of the volume in GB.
+ Size *float32 `json:"size"`
+ // Public SSH keys are set on the image as authorized keys for appropriate SSH login to the instance using the corresponding private key. This field may only be set in creation requests. When reading, it always returns null. SSH keys are only supported if a public Linux image is used for the volume creation.
+ SshKeys *[]string `json:"sshKeys,omitempty"`
+ // Hardware type of the volume. DAS (Direct Attached Storage) could be used only in a composite call with a Cube server.
+ Type *string `json:"type,omitempty"`
// The cloud-init configuration for the volume as base64 encoded string. The property is immutable and is only allowed to be set on creation of a new a volume. It is mandatory to provide either 'public image' or 'imageAlias' that has cloud-init compatibility in conjunction with this property.
UserData *string `json:"userData,omitempty"`
- // The UUID of the attached server.
- BootServer *string `json:"bootServer,omitempty"`
- // Determines whether the volume will be used as a boot volume. Set to `NONE`, the volume will not be used as boot volume. Set to `PRIMARY`, the volume will be used as boot volume and all other volumes must be set to `NONE`. Set to `AUTO` or `null` requires all volumes to be set to `AUTO` or `null`; this will use the legacy behavior, which is to use the volume as a boot volume only if there are no other volumes or cdrom devices.
- BootOrder *string `json:"bootOrder,omitempty"`
}
// NewVolumeProperties instantiates a new VolumeProperties object
@@ -68,9 +69,9 @@ type VolumeProperties struct {
func NewVolumeProperties(size float32) *VolumeProperties {
this := VolumeProperties{}
- this.Size = &size
var bootOrder = "AUTO"
this.BootOrder = &bootOrder
+ this.Size = &size
return &this
}
@@ -85,836 +86,841 @@ func NewVolumePropertiesWithDefaults() *VolumeProperties {
return &this
}
-// GetName returns the Name field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *VolumeProperties) GetName() *string {
+// GetAvailabilityZone returns the AvailabilityZone field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetAvailabilityZone() *string {
if o == nil {
return nil
}
- return o.Name
+ return o.AvailabilityZone
}
-// GetNameOk returns a tuple with the Name field value
+// GetAvailabilityZoneOk returns a tuple with the AvailabilityZone field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetNameOk() (*string, bool) {
+func (o *VolumeProperties) GetAvailabilityZoneOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Name, true
+ return o.AvailabilityZone, true
}
-// SetName sets field value
-func (o *VolumeProperties) SetName(v string) {
+// SetAvailabilityZone sets field value
+func (o *VolumeProperties) SetAvailabilityZone(v string) {
- o.Name = &v
+ o.AvailabilityZone = &v
}
-// HasName returns a boolean if a field has been set.
-func (o *VolumeProperties) HasName() bool {
- if o != nil && o.Name != nil {
+// HasAvailabilityZone returns a boolean if a field has been set.
+func (o *VolumeProperties) HasAvailabilityZone() bool {
+ if o != nil && o.AvailabilityZone != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *VolumeProperties) GetType() *string {
+// GetBackupunitId returns the BackupunitId field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetBackupunitId() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.BackupunitId
}
-// GetTypeOk returns a tuple with the Type field value
+// GetBackupunitIdOk returns a tuple with the BackupunitId field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetTypeOk() (*string, bool) {
+func (o *VolumeProperties) GetBackupunitIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.BackupunitId, true
}
-// SetType sets field value
-func (o *VolumeProperties) SetType(v string) {
+// SetBackupunitId sets field value
+func (o *VolumeProperties) SetBackupunitId(v string) {
- o.Type = &v
+ o.BackupunitId = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *VolumeProperties) HasType() bool {
- if o != nil && o.Type != nil {
+// HasBackupunitId returns a boolean if a field has been set.
+func (o *VolumeProperties) HasBackupunitId() bool {
+ if o != nil && o.BackupunitId != nil {
return true
}
return false
}
-// GetSize returns the Size field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *VolumeProperties) GetSize() *float32 {
+// GetBootOrder returns the BootOrder field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetBootOrder() *string {
if o == nil {
return nil
}
- return o.Size
+ return o.BootOrder
}
-// GetSizeOk returns a tuple with the Size field value
+// GetBootOrderOk returns a tuple with the BootOrder field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetSizeOk() (*float32, bool) {
+func (o *VolumeProperties) GetBootOrderOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Size, true
+ return o.BootOrder, true
}
-// SetSize sets field value
-func (o *VolumeProperties) SetSize(v float32) {
+// SetBootOrder sets field value
+func (o *VolumeProperties) SetBootOrder(v string) {
- o.Size = &v
+ o.BootOrder = &v
}
-// HasSize returns a boolean if a field has been set.
-func (o *VolumeProperties) HasSize() bool {
- if o != nil && o.Size != nil {
+// sets BootOrder to the explicit address that will be encoded as nil when marshaled
+func (o *VolumeProperties) SetBootOrderNil() {
+ o.BootOrder = &Nilstring
+}
+
+// HasBootOrder returns a boolean if a field has been set.
+func (o *VolumeProperties) HasBootOrder() bool {
+ if o != nil && o.BootOrder != nil {
return true
}
return false
}
-// GetAvailabilityZone returns the AvailabilityZone field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *VolumeProperties) GetAvailabilityZone() *string {
+// GetBootServer returns the BootServer field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetBootServer() *string {
if o == nil {
return nil
}
- return o.AvailabilityZone
+ return o.BootServer
}
-// GetAvailabilityZoneOk returns a tuple with the AvailabilityZone field value
+// GetBootServerOk returns a tuple with the BootServer field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetAvailabilityZoneOk() (*string, bool) {
+func (o *VolumeProperties) GetBootServerOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.AvailabilityZone, true
+ return o.BootServer, true
}
-// SetAvailabilityZone sets field value
-func (o *VolumeProperties) SetAvailabilityZone(v string) {
+// SetBootServer sets field value
+func (o *VolumeProperties) SetBootServer(v string) {
- o.AvailabilityZone = &v
+ o.BootServer = &v
}
-// HasAvailabilityZone returns a boolean if a field has been set.
-func (o *VolumeProperties) HasAvailabilityZone() bool {
- if o != nil && o.AvailabilityZone != nil {
+// HasBootServer returns a boolean if a field has been set.
+func (o *VolumeProperties) HasBootServer() bool {
+ if o != nil && o.BootServer != nil {
return true
}
return false
}
-// GetImage returns the Image field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *VolumeProperties) GetImage() *string {
+// GetBus returns the Bus field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetBus() *string {
if o == nil {
return nil
}
- return o.Image
+ return o.Bus
}
-// GetImageOk returns a tuple with the Image field value
+// GetBusOk returns a tuple with the Bus field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetImageOk() (*string, bool) {
+func (o *VolumeProperties) GetBusOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Image, true
+ return o.Bus, true
}
-// SetImage sets field value
-func (o *VolumeProperties) SetImage(v string) {
+// SetBus sets field value
+func (o *VolumeProperties) SetBus(v string) {
- o.Image = &v
+ o.Bus = &v
}
-// HasImage returns a boolean if a field has been set.
-func (o *VolumeProperties) HasImage() bool {
- if o != nil && o.Image != nil {
+// HasBus returns a boolean if a field has been set.
+func (o *VolumeProperties) HasBus() bool {
+ if o != nil && o.Bus != nil {
return true
}
return false
}
-// GetImagePassword returns the ImagePassword field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *VolumeProperties) GetImagePassword() *string {
+// GetCpuHotPlug returns the CpuHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetCpuHotPlug() *bool {
if o == nil {
return nil
}
- return o.ImagePassword
+ return o.CpuHotPlug
}
-// GetImagePasswordOk returns a tuple with the ImagePassword field value
+// GetCpuHotPlugOk returns a tuple with the CpuHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetImagePasswordOk() (*string, bool) {
+func (o *VolumeProperties) GetCpuHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.ImagePassword, true
+ return o.CpuHotPlug, true
}
-// SetImagePassword sets field value
-func (o *VolumeProperties) SetImagePassword(v string) {
+// SetCpuHotPlug sets field value
+func (o *VolumeProperties) SetCpuHotPlug(v bool) {
- o.ImagePassword = &v
+ o.CpuHotPlug = &v
}
-// HasImagePassword returns a boolean if a field has been set.
-func (o *VolumeProperties) HasImagePassword() bool {
- if o != nil && o.ImagePassword != nil {
+// HasCpuHotPlug returns a boolean if a field has been set.
+func (o *VolumeProperties) HasCpuHotPlug() bool {
+ if o != nil && o.CpuHotPlug != nil {
return true
}
return false
}
-// GetImageAlias returns the ImageAlias field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *VolumeProperties) GetImageAlias() *string {
+// GetDeviceNumber returns the DeviceNumber field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetDeviceNumber() *int64 {
if o == nil {
return nil
}
- return o.ImageAlias
+ return o.DeviceNumber
}
-// GetImageAliasOk returns a tuple with the ImageAlias field value
+// GetDeviceNumberOk returns a tuple with the DeviceNumber field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetImageAliasOk() (*string, bool) {
+func (o *VolumeProperties) GetDeviceNumberOk() (*int64, bool) {
if o == nil {
return nil, false
}
- return o.ImageAlias, true
+ return o.DeviceNumber, true
}
-// SetImageAlias sets field value
-func (o *VolumeProperties) SetImageAlias(v string) {
+// SetDeviceNumber sets field value
+func (o *VolumeProperties) SetDeviceNumber(v int64) {
- o.ImageAlias = &v
+ o.DeviceNumber = &v
}
-// HasImageAlias returns a boolean if a field has been set.
-func (o *VolumeProperties) HasImageAlias() bool {
- if o != nil && o.ImageAlias != nil {
+// HasDeviceNumber returns a boolean if a field has been set.
+func (o *VolumeProperties) HasDeviceNumber() bool {
+ if o != nil && o.DeviceNumber != nil {
return true
}
return false
}
-// GetSshKeys returns the SshKeys field value
-// If the value is explicit nil, the zero value for []string will be returned
-func (o *VolumeProperties) GetSshKeys() *[]string {
+// GetDiscVirtioHotPlug returns the DiscVirtioHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetDiscVirtioHotPlug() *bool {
if o == nil {
return nil
}
- return o.SshKeys
+ return o.DiscVirtioHotPlug
}
-// GetSshKeysOk returns a tuple with the SshKeys field value
+// GetDiscVirtioHotPlugOk returns a tuple with the DiscVirtioHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetSshKeysOk() (*[]string, bool) {
+func (o *VolumeProperties) GetDiscVirtioHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.SshKeys, true
+ return o.DiscVirtioHotPlug, true
}
-// SetSshKeys sets field value
-func (o *VolumeProperties) SetSshKeys(v []string) {
+// SetDiscVirtioHotPlug sets field value
+func (o *VolumeProperties) SetDiscVirtioHotPlug(v bool) {
- o.SshKeys = &v
+ o.DiscVirtioHotPlug = &v
}
-// HasSshKeys returns a boolean if a field has been set.
-func (o *VolumeProperties) HasSshKeys() bool {
- if o != nil && o.SshKeys != nil {
+// HasDiscVirtioHotPlug returns a boolean if a field has been set.
+func (o *VolumeProperties) HasDiscVirtioHotPlug() bool {
+ if o != nil && o.DiscVirtioHotPlug != nil {
return true
}
return false
}
-// GetBus returns the Bus field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *VolumeProperties) GetBus() *string {
+// GetDiscVirtioHotUnplug returns the DiscVirtioHotUnplug field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetDiscVirtioHotUnplug() *bool {
if o == nil {
return nil
}
- return o.Bus
+ return o.DiscVirtioHotUnplug
}
-// GetBusOk returns a tuple with the Bus field value
+// GetDiscVirtioHotUnplugOk returns a tuple with the DiscVirtioHotUnplug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetBusOk() (*string, bool) {
+func (o *VolumeProperties) GetDiscVirtioHotUnplugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.Bus, true
+ return o.DiscVirtioHotUnplug, true
}
-// SetBus sets field value
-func (o *VolumeProperties) SetBus(v string) {
+// SetDiscVirtioHotUnplug sets field value
+func (o *VolumeProperties) SetDiscVirtioHotUnplug(v bool) {
- o.Bus = &v
+ o.DiscVirtioHotUnplug = &v
}
-// HasBus returns a boolean if a field has been set.
-func (o *VolumeProperties) HasBus() bool {
- if o != nil && o.Bus != nil {
+// HasDiscVirtioHotUnplug returns a boolean if a field has been set.
+func (o *VolumeProperties) HasDiscVirtioHotUnplug() bool {
+ if o != nil && o.DiscVirtioHotUnplug != nil {
return true
}
return false
}
-// GetLicenceType returns the LicenceType field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *VolumeProperties) GetLicenceType() *string {
+// GetImage returns the Image field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetImage() *string {
if o == nil {
return nil
}
- return o.LicenceType
+ return o.Image
}
-// GetLicenceTypeOk returns a tuple with the LicenceType field value
+// GetImageOk returns a tuple with the Image field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetLicenceTypeOk() (*string, bool) {
+func (o *VolumeProperties) GetImageOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.LicenceType, true
+ return o.Image, true
}
-// SetLicenceType sets field value
-func (o *VolumeProperties) SetLicenceType(v string) {
+// SetImage sets field value
+func (o *VolumeProperties) SetImage(v string) {
- o.LicenceType = &v
+ o.Image = &v
}
-// HasLicenceType returns a boolean if a field has been set.
-func (o *VolumeProperties) HasLicenceType() bool {
- if o != nil && o.LicenceType != nil {
+// HasImage returns a boolean if a field has been set.
+func (o *VolumeProperties) HasImage() bool {
+ if o != nil && o.Image != nil {
return true
}
return false
}
-// GetCpuHotPlug returns the CpuHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *VolumeProperties) GetCpuHotPlug() *bool {
+// GetImageAlias returns the ImageAlias field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetImageAlias() *string {
if o == nil {
return nil
}
- return o.CpuHotPlug
+ return o.ImageAlias
}
-// GetCpuHotPlugOk returns a tuple with the CpuHotPlug field value
+// GetImageAliasOk returns a tuple with the ImageAlias field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetCpuHotPlugOk() (*bool, bool) {
+func (o *VolumeProperties) GetImageAliasOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.CpuHotPlug, true
+ return o.ImageAlias, true
}
-// SetCpuHotPlug sets field value
-func (o *VolumeProperties) SetCpuHotPlug(v bool) {
+// SetImageAlias sets field value
+func (o *VolumeProperties) SetImageAlias(v string) {
- o.CpuHotPlug = &v
+ o.ImageAlias = &v
}
-// HasCpuHotPlug returns a boolean if a field has been set.
-func (o *VolumeProperties) HasCpuHotPlug() bool {
- if o != nil && o.CpuHotPlug != nil {
+// HasImageAlias returns a boolean if a field has been set.
+func (o *VolumeProperties) HasImageAlias() bool {
+ if o != nil && o.ImageAlias != nil {
return true
}
return false
}
-// GetRamHotPlug returns the RamHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *VolumeProperties) GetRamHotPlug() *bool {
+// GetImagePassword returns the ImagePassword field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetImagePassword() *string {
if o == nil {
return nil
}
- return o.RamHotPlug
+ return o.ImagePassword
}
-// GetRamHotPlugOk returns a tuple with the RamHotPlug field value
+// GetImagePasswordOk returns a tuple with the ImagePassword field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetRamHotPlugOk() (*bool, bool) {
+func (o *VolumeProperties) GetImagePasswordOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.RamHotPlug, true
+ return o.ImagePassword, true
}
-// SetRamHotPlug sets field value
-func (o *VolumeProperties) SetRamHotPlug(v bool) {
+// SetImagePassword sets field value
+func (o *VolumeProperties) SetImagePassword(v string) {
- o.RamHotPlug = &v
+ o.ImagePassword = &v
}
-// HasRamHotPlug returns a boolean if a field has been set.
-func (o *VolumeProperties) HasRamHotPlug() bool {
- if o != nil && o.RamHotPlug != nil {
+// HasImagePassword returns a boolean if a field has been set.
+func (o *VolumeProperties) HasImagePassword() bool {
+ if o != nil && o.ImagePassword != nil {
return true
}
return false
}
-// GetNicHotPlug returns the NicHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *VolumeProperties) GetNicHotPlug() *bool {
+// GetLicenceType returns the LicenceType field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetLicenceType() *string {
if o == nil {
return nil
}
- return o.NicHotPlug
+ return o.LicenceType
}
-// GetNicHotPlugOk returns a tuple with the NicHotPlug field value
+// GetLicenceTypeOk returns a tuple with the LicenceType field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetNicHotPlugOk() (*bool, bool) {
+func (o *VolumeProperties) GetLicenceTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.NicHotPlug, true
+ return o.LicenceType, true
}
-// SetNicHotPlug sets field value
-func (o *VolumeProperties) SetNicHotPlug(v bool) {
+// SetLicenceType sets field value
+func (o *VolumeProperties) SetLicenceType(v string) {
- o.NicHotPlug = &v
+ o.LicenceType = &v
}
-// HasNicHotPlug returns a boolean if a field has been set.
-func (o *VolumeProperties) HasNicHotPlug() bool {
- if o != nil && o.NicHotPlug != nil {
+// HasLicenceType returns a boolean if a field has been set.
+func (o *VolumeProperties) HasLicenceType() bool {
+ if o != nil && o.LicenceType != nil {
return true
}
return false
}
-// GetNicHotUnplug returns the NicHotUnplug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *VolumeProperties) GetNicHotUnplug() *bool {
+// GetName returns the Name field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetName() *string {
if o == nil {
return nil
}
- return o.NicHotUnplug
+ return o.Name
}
-// GetNicHotUnplugOk returns a tuple with the NicHotUnplug field value
+// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetNicHotUnplugOk() (*bool, bool) {
+func (o *VolumeProperties) GetNameOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.NicHotUnplug, true
+ return o.Name, true
}
-// SetNicHotUnplug sets field value
-func (o *VolumeProperties) SetNicHotUnplug(v bool) {
+// SetName sets field value
+func (o *VolumeProperties) SetName(v string) {
- o.NicHotUnplug = &v
+ o.Name = &v
}
-// HasNicHotUnplug returns a boolean if a field has been set.
-func (o *VolumeProperties) HasNicHotUnplug() bool {
- if o != nil && o.NicHotUnplug != nil {
+// HasName returns a boolean if a field has been set.
+func (o *VolumeProperties) HasName() bool {
+ if o != nil && o.Name != nil {
return true
}
return false
}
-// GetDiscVirtioHotPlug returns the DiscVirtioHotPlug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *VolumeProperties) GetDiscVirtioHotPlug() *bool {
+// GetNicHotPlug returns the NicHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetNicHotPlug() *bool {
if o == nil {
return nil
}
- return o.DiscVirtioHotPlug
+ return o.NicHotPlug
}
-// GetDiscVirtioHotPlugOk returns a tuple with the DiscVirtioHotPlug field value
+// GetNicHotPlugOk returns a tuple with the NicHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetDiscVirtioHotPlugOk() (*bool, bool) {
+func (o *VolumeProperties) GetNicHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.DiscVirtioHotPlug, true
+ return o.NicHotPlug, true
}
-// SetDiscVirtioHotPlug sets field value
-func (o *VolumeProperties) SetDiscVirtioHotPlug(v bool) {
+// SetNicHotPlug sets field value
+func (o *VolumeProperties) SetNicHotPlug(v bool) {
- o.DiscVirtioHotPlug = &v
+ o.NicHotPlug = &v
}
-// HasDiscVirtioHotPlug returns a boolean if a field has been set.
-func (o *VolumeProperties) HasDiscVirtioHotPlug() bool {
- if o != nil && o.DiscVirtioHotPlug != nil {
+// HasNicHotPlug returns a boolean if a field has been set.
+func (o *VolumeProperties) HasNicHotPlug() bool {
+ if o != nil && o.NicHotPlug != nil {
return true
}
return false
}
-// GetDiscVirtioHotUnplug returns the DiscVirtioHotUnplug field value
-// If the value is explicit nil, the zero value for bool will be returned
-func (o *VolumeProperties) GetDiscVirtioHotUnplug() *bool {
+// GetNicHotUnplug returns the NicHotUnplug field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetNicHotUnplug() *bool {
if o == nil {
return nil
}
- return o.DiscVirtioHotUnplug
+ return o.NicHotUnplug
}
-// GetDiscVirtioHotUnplugOk returns a tuple with the DiscVirtioHotUnplug field value
+// GetNicHotUnplugOk returns a tuple with the NicHotUnplug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetDiscVirtioHotUnplugOk() (*bool, bool) {
+func (o *VolumeProperties) GetNicHotUnplugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.DiscVirtioHotUnplug, true
+ return o.NicHotUnplug, true
}
-// SetDiscVirtioHotUnplug sets field value
-func (o *VolumeProperties) SetDiscVirtioHotUnplug(v bool) {
+// SetNicHotUnplug sets field value
+func (o *VolumeProperties) SetNicHotUnplug(v bool) {
- o.DiscVirtioHotUnplug = &v
+ o.NicHotUnplug = &v
}
-// HasDiscVirtioHotUnplug returns a boolean if a field has been set.
-func (o *VolumeProperties) HasDiscVirtioHotUnplug() bool {
- if o != nil && o.DiscVirtioHotUnplug != nil {
+// HasNicHotUnplug returns a boolean if a field has been set.
+func (o *VolumeProperties) HasNicHotUnplug() bool {
+ if o != nil && o.NicHotUnplug != nil {
return true
}
return false
}
-// GetDeviceNumber returns the DeviceNumber field value
-// If the value is explicit nil, the zero value for int64 will be returned
-func (o *VolumeProperties) GetDeviceNumber() *int64 {
+// GetPciSlot returns the PciSlot field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetPciSlot() *int32 {
if o == nil {
return nil
}
- return o.DeviceNumber
+ return o.PciSlot
}
-// GetDeviceNumberOk returns a tuple with the DeviceNumber field value
+// GetPciSlotOk returns a tuple with the PciSlot field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetDeviceNumberOk() (*int64, bool) {
+func (o *VolumeProperties) GetPciSlotOk() (*int32, bool) {
if o == nil {
return nil, false
}
- return o.DeviceNumber, true
+ return o.PciSlot, true
}
-// SetDeviceNumber sets field value
-func (o *VolumeProperties) SetDeviceNumber(v int64) {
+// SetPciSlot sets field value
+func (o *VolumeProperties) SetPciSlot(v int32) {
- o.DeviceNumber = &v
+ o.PciSlot = &v
}
-// HasDeviceNumber returns a boolean if a field has been set.
-func (o *VolumeProperties) HasDeviceNumber() bool {
- if o != nil && o.DeviceNumber != nil {
+// HasPciSlot returns a boolean if a field has been set.
+func (o *VolumeProperties) HasPciSlot() bool {
+ if o != nil && o.PciSlot != nil {
return true
}
return false
}
-// GetPciSlot returns the PciSlot field value
-// If the value is explicit nil, the zero value for int32 will be returned
-func (o *VolumeProperties) GetPciSlot() *int32 {
+// GetRamHotPlug returns the RamHotPlug field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetRamHotPlug() *bool {
if o == nil {
return nil
}
- return o.PciSlot
+ return o.RamHotPlug
}
-// GetPciSlotOk returns a tuple with the PciSlot field value
+// GetRamHotPlugOk returns a tuple with the RamHotPlug field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetPciSlotOk() (*int32, bool) {
+func (o *VolumeProperties) GetRamHotPlugOk() (*bool, bool) {
if o == nil {
return nil, false
}
- return o.PciSlot, true
+ return o.RamHotPlug, true
}
-// SetPciSlot sets field value
-func (o *VolumeProperties) SetPciSlot(v int32) {
+// SetRamHotPlug sets field value
+func (o *VolumeProperties) SetRamHotPlug(v bool) {
- o.PciSlot = &v
+ o.RamHotPlug = &v
}
-// HasPciSlot returns a boolean if a field has been set.
-func (o *VolumeProperties) HasPciSlot() bool {
- if o != nil && o.PciSlot != nil {
+// HasRamHotPlug returns a boolean if a field has been set.
+func (o *VolumeProperties) HasRamHotPlug() bool {
+ if o != nil && o.RamHotPlug != nil {
return true
}
return false
}
-// GetBackupunitId returns the BackupunitId field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *VolumeProperties) GetBackupunitId() *string {
+// GetSize returns the Size field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetSize() *float32 {
if o == nil {
return nil
}
- return o.BackupunitId
+ return o.Size
}
-// GetBackupunitIdOk returns a tuple with the BackupunitId field value
+// GetSizeOk returns a tuple with the Size field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetBackupunitIdOk() (*string, bool) {
+func (o *VolumeProperties) GetSizeOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.BackupunitId, true
+ return o.Size, true
}
-// SetBackupunitId sets field value
-func (o *VolumeProperties) SetBackupunitId(v string) {
+// SetSize sets field value
+func (o *VolumeProperties) SetSize(v float32) {
- o.BackupunitId = &v
+ o.Size = &v
}
-// HasBackupunitId returns a boolean if a field has been set.
-func (o *VolumeProperties) HasBackupunitId() bool {
- if o != nil && o.BackupunitId != nil {
+// HasSize returns a boolean if a field has been set.
+func (o *VolumeProperties) HasSize() bool {
+ if o != nil && o.Size != nil {
return true
}
return false
}
-// GetUserData returns the UserData field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *VolumeProperties) GetUserData() *string {
+// GetSshKeys returns the SshKeys field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetSshKeys() *[]string {
if o == nil {
return nil
}
- return o.UserData
+ return o.SshKeys
}
-// GetUserDataOk returns a tuple with the UserData field value
+// GetSshKeysOk returns a tuple with the SshKeys field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetUserDataOk() (*string, bool) {
+func (o *VolumeProperties) GetSshKeysOk() (*[]string, bool) {
if o == nil {
return nil, false
}
- return o.UserData, true
+ return o.SshKeys, true
}
-// SetUserData sets field value
-func (o *VolumeProperties) SetUserData(v string) {
+// SetSshKeys sets field value
+func (o *VolumeProperties) SetSshKeys(v []string) {
- o.UserData = &v
+ o.SshKeys = &v
}
-// HasUserData returns a boolean if a field has been set.
-func (o *VolumeProperties) HasUserData() bool {
- if o != nil && o.UserData != nil {
+// HasSshKeys returns a boolean if a field has been set.
+func (o *VolumeProperties) HasSshKeys() bool {
+ if o != nil && o.SshKeys != nil {
return true
}
return false
}
-// GetBootServer returns the BootServer field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *VolumeProperties) GetBootServer() *string {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetType() *string {
if o == nil {
return nil
}
- return o.BootServer
+ return o.Type
}
-// GetBootServerOk returns a tuple with the BootServer field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetBootServerOk() (*string, bool) {
+func (o *VolumeProperties) GetTypeOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.BootServer, true
+ return o.Type, true
}
-// SetBootServer sets field value
-func (o *VolumeProperties) SetBootServer(v string) {
+// SetType sets field value
+func (o *VolumeProperties) SetType(v string) {
- o.BootServer = &v
+ o.Type = &v
}
-// HasBootServer returns a boolean if a field has been set.
-func (o *VolumeProperties) HasBootServer() bool {
- if o != nil && o.BootServer != nil {
+// HasType returns a boolean if a field has been set.
+func (o *VolumeProperties) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
return false
}
-// GetBootOrder returns the BootOrder field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *VolumeProperties) GetBootOrder() *string {
+// GetUserData returns the UserData field value
+// If the value is explicit nil, nil is returned
+func (o *VolumeProperties) GetUserData() *string {
if o == nil {
return nil
}
- return o.BootOrder
+ return o.UserData
}
-// GetBootOrderOk returns a tuple with the BootOrder field value
+// GetUserDataOk returns a tuple with the UserData field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *VolumeProperties) GetBootOrderOk() (*string, bool) {
+func (o *VolumeProperties) GetUserDataOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.BootOrder, true
+ return o.UserData, true
}
-// SetBootOrder sets field value
-func (o *VolumeProperties) SetBootOrder(v string) {
+// SetUserData sets field value
+func (o *VolumeProperties) SetUserData(v string) {
- o.BootOrder = &v
+ o.UserData = &v
}
-// HasBootOrder returns a boolean if a field has been set.
-func (o *VolumeProperties) HasBootOrder() bool {
- if o != nil && o.BootOrder != nil {
+// HasUserData returns a boolean if a field has been set.
+func (o *VolumeProperties) HasUserData() bool {
+ if o != nil && o.UserData != nil {
return true
}
@@ -923,70 +929,95 @@ func (o *VolumeProperties) HasBootOrder() bool {
func (o VolumeProperties) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Name != nil {
- toSerialize["name"] = o.Name
+ if o.AvailabilityZone != nil {
+ toSerialize["availabilityZone"] = o.AvailabilityZone
}
- if o.Type != nil {
- toSerialize["type"] = o.Type
+
+ if o.BackupunitId != nil {
+ toSerialize["backupunitId"] = o.BackupunitId
}
- if o.Size != nil {
- toSerialize["size"] = o.Size
+
+ if o.BootOrder == &Nilstring {
+ toSerialize["bootOrder"] = nil
+ } else if o.BootOrder != nil {
+ toSerialize["bootOrder"] = o.BootOrder
}
- if o.AvailabilityZone != nil {
- toSerialize["availabilityZone"] = o.AvailabilityZone
+ if o.BootServer != nil {
+ toSerialize["bootServer"] = o.BootServer
+ }
+
+ if o.Bus != nil {
+ toSerialize["bus"] = o.Bus
+ }
+
+ if o.CpuHotPlug != nil {
+ toSerialize["cpuHotPlug"] = o.CpuHotPlug
+ }
+
+ if o.DeviceNumber != nil {
+ toSerialize["deviceNumber"] = o.DeviceNumber
+ }
+
+ if o.DiscVirtioHotPlug != nil {
+ toSerialize["discVirtioHotPlug"] = o.DiscVirtioHotPlug
}
+
+ if o.DiscVirtioHotUnplug != nil {
+ toSerialize["discVirtioHotUnplug"] = o.DiscVirtioHotUnplug
+ }
+
if o.Image != nil {
toSerialize["image"] = o.Image
}
- if o.ImagePassword != nil {
- toSerialize["imagePassword"] = o.ImagePassword
- }
+
if o.ImageAlias != nil {
toSerialize["imageAlias"] = o.ImageAlias
}
- if o.SshKeys != nil {
- toSerialize["sshKeys"] = o.SshKeys
- }
- if o.Bus != nil {
- toSerialize["bus"] = o.Bus
+
+ if o.ImagePassword != nil {
+ toSerialize["imagePassword"] = o.ImagePassword
}
+
if o.LicenceType != nil {
toSerialize["licenceType"] = o.LicenceType
}
- if o.CpuHotPlug != nil {
- toSerialize["cpuHotPlug"] = o.CpuHotPlug
- }
- if o.RamHotPlug != nil {
- toSerialize["ramHotPlug"] = o.RamHotPlug
+
+ if o.Name != nil {
+ toSerialize["name"] = o.Name
}
+
if o.NicHotPlug != nil {
toSerialize["nicHotPlug"] = o.NicHotPlug
}
+
if o.NicHotUnplug != nil {
toSerialize["nicHotUnplug"] = o.NicHotUnplug
}
- if o.DiscVirtioHotPlug != nil {
- toSerialize["discVirtioHotPlug"] = o.DiscVirtioHotPlug
+
+ if o.PciSlot != nil {
+ toSerialize["pciSlot"] = o.PciSlot
}
- if o.DiscVirtioHotUnplug != nil {
- toSerialize["discVirtioHotUnplug"] = o.DiscVirtioHotUnplug
+
+ if o.RamHotPlug != nil {
+ toSerialize["ramHotPlug"] = o.RamHotPlug
}
- if o.DeviceNumber != nil {
- toSerialize["deviceNumber"] = o.DeviceNumber
+
+ if o.Size != nil {
+ toSerialize["size"] = o.Size
}
- if o.PciSlot != nil {
- toSerialize["pciSlot"] = o.PciSlot
+
+ if o.SshKeys != nil {
+ toSerialize["sshKeys"] = o.SshKeys
}
- if o.BackupunitId != nil {
- toSerialize["backupunitId"] = o.BackupunitId
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
}
+
if o.UserData != nil {
toSerialize["userData"] = o.UserData
}
- if o.BootServer != nil {
- toSerialize["bootServer"] = o.BootServer
- }
- toSerialize["bootOrder"] = o.BootOrder
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/model_volumes.go b/vendor/github.com/ionos-cloud/sdk-go/v6/model_volumes.go
index dfe753d8e6d..ec795374f24 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/model_volumes.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/model_volumes.go
@@ -16,19 +16,19 @@ import (
// Volumes struct for Volumes
type Volumes struct {
- // The resource's unique identifier.
- Id *string `json:"id,omitempty"`
- // The type of object that has been created.
- Type *Type `json:"type,omitempty"`
+ Links *PaginationLinks `json:"_links,omitempty"`
// URL to the object representation (absolute path).
Href *string `json:"href,omitempty"`
+ // The resource's unique identifier.
+ Id *string `json:"id,omitempty"`
// Array of items in the collection.
Items *[]Volume `json:"items,omitempty"`
+ // The limit (if specified in the request).
+ Limit *float32 `json:"limit,omitempty"`
// The offset (if specified in the request).
Offset *float32 `json:"offset,omitempty"`
- // The limit (if specified in the request).
- Limit *float32 `json:"limit,omitempty"`
- Links *PaginationLinks `json:"_links,omitempty"`
+ // The type of object that has been created.
+ Type *Type `json:"type,omitempty"`
}
// NewVolumes instantiates a new Volumes object
@@ -49,114 +49,114 @@ func NewVolumesWithDefaults() *Volumes {
return &this
}
-// GetId returns the Id field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Volumes) GetId() *string {
+// GetLinks returns the Links field value
+// If the value is explicit nil, nil is returned
+func (o *Volumes) GetLinks() *PaginationLinks {
if o == nil {
return nil
}
- return o.Id
+ return o.Links
}
-// GetIdOk returns a tuple with the Id field value
+// GetLinksOk returns a tuple with the Links field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Volumes) GetIdOk() (*string, bool) {
+func (o *Volumes) GetLinksOk() (*PaginationLinks, bool) {
if o == nil {
return nil, false
}
- return o.Id, true
+ return o.Links, true
}
-// SetId sets field value
-func (o *Volumes) SetId(v string) {
+// SetLinks sets field value
+func (o *Volumes) SetLinks(v PaginationLinks) {
- o.Id = &v
+ o.Links = &v
}
-// HasId returns a boolean if a field has been set.
-func (o *Volumes) HasId() bool {
- if o != nil && o.Id != nil {
+// HasLinks returns a boolean if a field has been set.
+func (o *Volumes) HasLinks() bool {
+ if o != nil && o.Links != nil {
return true
}
return false
}
-// GetType returns the Type field value
-// If the value is explicit nil, the zero value for Type will be returned
-func (o *Volumes) GetType() *Type {
+// GetHref returns the Href field value
+// If the value is explicit nil, nil is returned
+func (o *Volumes) GetHref() *string {
if o == nil {
return nil
}
- return o.Type
+ return o.Href
}
-// GetTypeOk returns a tuple with the Type field value
+// GetHrefOk returns a tuple with the Href field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Volumes) GetTypeOk() (*Type, bool) {
+func (o *Volumes) GetHrefOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Type, true
+ return o.Href, true
}
-// SetType sets field value
-func (o *Volumes) SetType(v Type) {
+// SetHref sets field value
+func (o *Volumes) SetHref(v string) {
- o.Type = &v
+ o.Href = &v
}
-// HasType returns a boolean if a field has been set.
-func (o *Volumes) HasType() bool {
- if o != nil && o.Type != nil {
+// HasHref returns a boolean if a field has been set.
+func (o *Volumes) HasHref() bool {
+ if o != nil && o.Href != nil {
return true
}
return false
}
-// GetHref returns the Href field value
-// If the value is explicit nil, the zero value for string will be returned
-func (o *Volumes) GetHref() *string {
+// GetId returns the Id field value
+// If the value is explicit nil, nil is returned
+func (o *Volumes) GetId() *string {
if o == nil {
return nil
}
- return o.Href
+ return o.Id
}
-// GetHrefOk returns a tuple with the Href field value
+// GetIdOk returns a tuple with the Id field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Volumes) GetHrefOk() (*string, bool) {
+func (o *Volumes) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
- return o.Href, true
+ return o.Id, true
}
-// SetHref sets field value
-func (o *Volumes) SetHref(v string) {
+// SetId sets field value
+func (o *Volumes) SetId(v string) {
- o.Href = &v
+ o.Id = &v
}
-// HasHref returns a boolean if a field has been set.
-func (o *Volumes) HasHref() bool {
- if o != nil && o.Href != nil {
+// HasId returns a boolean if a field has been set.
+func (o *Volumes) HasId() bool {
+ if o != nil && o.Id != nil {
return true
}
@@ -164,7 +164,7 @@ func (o *Volumes) HasHref() bool {
}
// GetItems returns the Items field value
-// If the value is explicit nil, the zero value for []Volume will be returned
+// If the value is explicit nil, nil is returned
func (o *Volumes) GetItems() *[]Volume {
if o == nil {
return nil
@@ -201,114 +201,114 @@ func (o *Volumes) HasItems() bool {
return false
}
-// GetOffset returns the Offset field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Volumes) GetOffset() *float32 {
+// GetLimit returns the Limit field value
+// If the value is explicit nil, nil is returned
+func (o *Volumes) GetLimit() *float32 {
if o == nil {
return nil
}
- return o.Offset
+ return o.Limit
}
-// GetOffsetOk returns a tuple with the Offset field value
+// GetLimitOk returns a tuple with the Limit field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Volumes) GetOffsetOk() (*float32, bool) {
+func (o *Volumes) GetLimitOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Offset, true
+ return o.Limit, true
}
-// SetOffset sets field value
-func (o *Volumes) SetOffset(v float32) {
+// SetLimit sets field value
+func (o *Volumes) SetLimit(v float32) {
- o.Offset = &v
+ o.Limit = &v
}
-// HasOffset returns a boolean if a field has been set.
-func (o *Volumes) HasOffset() bool {
- if o != nil && o.Offset != nil {
+// HasLimit returns a boolean if a field has been set.
+func (o *Volumes) HasLimit() bool {
+ if o != nil && o.Limit != nil {
return true
}
return false
}
-// GetLimit returns the Limit field value
-// If the value is explicit nil, the zero value for float32 will be returned
-func (o *Volumes) GetLimit() *float32 {
+// GetOffset returns the Offset field value
+// If the value is explicit nil, nil is returned
+func (o *Volumes) GetOffset() *float32 {
if o == nil {
return nil
}
- return o.Limit
+ return o.Offset
}
-// GetLimitOk returns a tuple with the Limit field value
+// GetOffsetOk returns a tuple with the Offset field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Volumes) GetLimitOk() (*float32, bool) {
+func (o *Volumes) GetOffsetOk() (*float32, bool) {
if o == nil {
return nil, false
}
- return o.Limit, true
+ return o.Offset, true
}
-// SetLimit sets field value
-func (o *Volumes) SetLimit(v float32) {
+// SetOffset sets field value
+func (o *Volumes) SetOffset(v float32) {
- o.Limit = &v
+ o.Offset = &v
}
-// HasLimit returns a boolean if a field has been set.
-func (o *Volumes) HasLimit() bool {
- if o != nil && o.Limit != nil {
+// HasOffset returns a boolean if a field has been set.
+func (o *Volumes) HasOffset() bool {
+ if o != nil && o.Offset != nil {
return true
}
return false
}
-// GetLinks returns the Links field value
-// If the value is explicit nil, the zero value for PaginationLinks will be returned
-func (o *Volumes) GetLinks() *PaginationLinks {
+// GetType returns the Type field value
+// If the value is explicit nil, nil is returned
+func (o *Volumes) GetType() *Type {
if o == nil {
return nil
}
- return o.Links
+ return o.Type
}
-// GetLinksOk returns a tuple with the Links field value
+// GetTypeOk returns a tuple with the Type field value
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
-func (o *Volumes) GetLinksOk() (*PaginationLinks, bool) {
+func (o *Volumes) GetTypeOk() (*Type, bool) {
if o == nil {
return nil, false
}
- return o.Links, true
+ return o.Type, true
}
-// SetLinks sets field value
-func (o *Volumes) SetLinks(v PaginationLinks) {
+// SetType sets field value
+func (o *Volumes) SetType(v Type) {
- o.Links = &v
+ o.Type = &v
}
-// HasLinks returns a boolean if a field has been set.
-func (o *Volumes) HasLinks() bool {
- if o != nil && o.Links != nil {
+// HasType returns a boolean if a field has been set.
+func (o *Volumes) HasType() bool {
+ if o != nil && o.Type != nil {
return true
}
@@ -317,27 +317,34 @@ func (o *Volumes) HasLinks() bool {
func (o Volumes) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
- if o.Id != nil {
- toSerialize["id"] = o.Id
- }
- if o.Type != nil {
- toSerialize["type"] = o.Type
+ if o.Links != nil {
+ toSerialize["_links"] = o.Links
}
+
if o.Href != nil {
toSerialize["href"] = o.Href
}
+
+ if o.Id != nil {
+ toSerialize["id"] = o.Id
+ }
+
if o.Items != nil {
toSerialize["items"] = o.Items
}
- if o.Offset != nil {
- toSerialize["offset"] = o.Offset
- }
+
if o.Limit != nil {
toSerialize["limit"] = o.Limit
}
- if o.Links != nil {
- toSerialize["_links"] = o.Links
+
+ if o.Offset != nil {
+ toSerialize["offset"] = o.Offset
}
+
+ if o.Type != nil {
+ toSerialize["type"] = o.Type
+ }
+
return json.Marshal(toSerialize)
}
diff --git a/vendor/github.com/ionos-cloud/sdk-go/v6/utils.go b/vendor/github.com/ionos-cloud/sdk-go/v6/utils.go
index ee096c73151..e37bb71d8e6 100644
--- a/vendor/github.com/ionos-cloud/sdk-go/v6/utils.go
+++ b/vendor/github.com/ionos-cloud/sdk-go/v6/utils.go
@@ -17,6 +17,13 @@ import (
"time"
)
+var (
+ // used to set a nullable field to nil. This is a sentinel address that will be checked in the MarshalJson function.
+ // if set to this address, a nil value will be marshalled
+ Nilstring string = "<>"
+ Nilint32 int32 = -334455
+)
+
// ToPtr - returns a pointer to the given value.
func ToPtr[T any](v T) *T {
return &v
diff --git a/vendor/github.com/kylelemons/godebug/LICENSE b/vendor/github.com/kylelemons/godebug/LICENSE
new file mode 100644
index 00000000000..d6456956733
--- /dev/null
+++ b/vendor/github.com/kylelemons/godebug/LICENSE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/vendor/github.com/kylelemons/godebug/diff/diff.go b/vendor/github.com/kylelemons/godebug/diff/diff.go
new file mode 100644
index 00000000000..200e596c625
--- /dev/null
+++ b/vendor/github.com/kylelemons/godebug/diff/diff.go
@@ -0,0 +1,186 @@
+// Copyright 2013 Google Inc. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// Package diff implements a linewise diff algorithm.
+package diff
+
+import (
+ "bytes"
+ "fmt"
+ "strings"
+)
+
+// Chunk represents a piece of the diff. A chunk will not have both added and
+// deleted lines. Equal lines are always after any added or deleted lines.
+// A Chunk may or may not have any lines in it, especially for the first or last
+// chunk in a computation.
+type Chunk struct {
+ Added []string
+ Deleted []string
+ Equal []string
+}
+
+func (c *Chunk) empty() bool {
+ return len(c.Added) == 0 && len(c.Deleted) == 0 && len(c.Equal) == 0
+}
+
+// Diff returns a string containing a line-by-line unified diff of the linewise
+// changes required to make A into B. Each line is prefixed with '+', '-', or
+// ' ' to indicate if it should be added, removed, or is correct respectively.
+func Diff(A, B string) string {
+ aLines := strings.Split(A, "\n")
+ bLines := strings.Split(B, "\n")
+
+ chunks := DiffChunks(aLines, bLines)
+
+ buf := new(bytes.Buffer)
+ for _, c := range chunks {
+ for _, line := range c.Added {
+ fmt.Fprintf(buf, "+%s\n", line)
+ }
+ for _, line := range c.Deleted {
+ fmt.Fprintf(buf, "-%s\n", line)
+ }
+ for _, line := range c.Equal {
+ fmt.Fprintf(buf, " %s\n", line)
+ }
+ }
+ return strings.TrimRight(buf.String(), "\n")
+}
+
+// DiffChunks uses an O(D(N+M)) shortest-edit-script algorithm
+// to compute the edits required from A to B and returns the
+// edit chunks.
+func DiffChunks(a, b []string) []Chunk {
+ // algorithm: http://www.xmailserver.org/diff2.pdf
+
+ // We'll need these quantities a lot.
+ alen, blen := len(a), len(b) // M, N
+
+ // At most, it will require len(a) deletions and len(b) additions
+ // to transform a into b.
+ maxPath := alen + blen // MAX
+ if maxPath == 0 {
+ // degenerate case: two empty lists are the same
+ return nil
+ }
+
+ // Store the endpoint of the path for diagonals.
+ // We store only the a index, because the b index on any diagonal
+ // (which we know during the loop below) is aidx-diag.
+ // endpoint[maxPath] represents the 0 diagonal.
+ //
+ // Stated differently:
+ // endpoint[d] contains the aidx of a furthest reaching path in diagonal d
+ endpoint := make([]int, 2*maxPath+1) // V
+
+ saved := make([][]int, 0, 8) // Vs
+ save := func() {
+ dup := make([]int, len(endpoint))
+ copy(dup, endpoint)
+ saved = append(saved, dup)
+ }
+
+ var editDistance int // D
+dLoop:
+ for editDistance = 0; editDistance <= maxPath; editDistance++ {
+ // The 0 diag(onal) represents equality of a and b. Each diagonal to
+ // the left is numbered one lower, to the right is one higher, from
+ // -alen to +blen. Negative diagonals favor differences from a,
+ // positive diagonals favor differences from b. The edit distance to a
+ // diagonal d cannot be shorter than d itself.
+ //
+ // The iterations of this loop cover either odds or evens, but not both,
+ // If odd indices are inputs, even indices are outputs and vice versa.
+ for diag := -editDistance; diag <= editDistance; diag += 2 { // k
+ var aidx int // x
+ switch {
+ case diag == -editDistance:
+ // This is a new diagonal; copy from previous iter
+ aidx = endpoint[maxPath-editDistance+1] + 0
+ case diag == editDistance:
+ // This is a new diagonal; copy from previous iter
+ aidx = endpoint[maxPath+editDistance-1] + 1
+ case endpoint[maxPath+diag+1] > endpoint[maxPath+diag-1]:
+ // diagonal d+1 was farther along, so use that
+ aidx = endpoint[maxPath+diag+1] + 0
+ default:
+ // diagonal d-1 was farther (or the same), so use that
+ aidx = endpoint[maxPath+diag-1] + 1
+ }
+ // On diagonal d, we can compute bidx from aidx.
+ bidx := aidx - diag // y
+ // See how far we can go on this diagonal before we find a difference.
+ for aidx < alen && bidx < blen && a[aidx] == b[bidx] {
+ aidx++
+ bidx++
+ }
+ // Store the end of the current edit chain.
+ endpoint[maxPath+diag] = aidx
+ // If we've found the end of both inputs, we're done!
+ if aidx >= alen && bidx >= blen {
+ save() // save the final path
+ break dLoop
+ }
+ }
+ save() // save the current path
+ }
+ if editDistance == 0 {
+ return nil
+ }
+ chunks := make([]Chunk, editDistance+1)
+
+ x, y := alen, blen
+ for d := editDistance; d > 0; d-- {
+ endpoint := saved[d]
+ diag := x - y
+ insert := diag == -d || (diag != d && endpoint[maxPath+diag-1] < endpoint[maxPath+diag+1])
+
+ x1 := endpoint[maxPath+diag]
+ var x0, xM, kk int
+ if insert {
+ kk = diag + 1
+ x0 = endpoint[maxPath+kk]
+ xM = x0
+ } else {
+ kk = diag - 1
+ x0 = endpoint[maxPath+kk]
+ xM = x0 + 1
+ }
+ y0 := x0 - kk
+
+ var c Chunk
+ if insert {
+ c.Added = b[y0:][:1]
+ } else {
+ c.Deleted = a[x0:][:1]
+ }
+ if xM < x1 {
+ c.Equal = a[xM:][:x1-xM]
+ }
+
+ x, y = x0, y0
+ chunks[d] = c
+ }
+ if x > 0 {
+ chunks[0].Equal = a[:x]
+ }
+ if chunks[0].empty() {
+ chunks = chunks[1:]
+ }
+ if len(chunks) == 0 {
+ return nil
+ }
+ return chunks
+}
diff --git a/vendor/github.com/kylelemons/godebug/pretty/.gitignore b/vendor/github.com/kylelemons/godebug/pretty/.gitignore
new file mode 100644
index 00000000000..fa9a735da3c
--- /dev/null
+++ b/vendor/github.com/kylelemons/godebug/pretty/.gitignore
@@ -0,0 +1,5 @@
+*.test
+*.bench
+*.golden
+*.txt
+*.prof
diff --git a/vendor/github.com/kylelemons/godebug/pretty/doc.go b/vendor/github.com/kylelemons/godebug/pretty/doc.go
new file mode 100644
index 00000000000..03b5718a70d
--- /dev/null
+++ b/vendor/github.com/kylelemons/godebug/pretty/doc.go
@@ -0,0 +1,25 @@
+// Copyright 2013 Google Inc. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// Package pretty pretty-prints Go structures.
+//
+// This package uses reflection to examine a Go value and can
+// print out in a nice, aligned fashion. It supports three
+// modes (normal, compact, and extended) for advanced use.
+//
+// See the Reflect and Print examples for what the output looks like.
+package pretty
+
+// TODO:
+// - Catch cycles
diff --git a/vendor/github.com/kylelemons/godebug/pretty/public.go b/vendor/github.com/kylelemons/godebug/pretty/public.go
new file mode 100644
index 00000000000..fbc5d7abbf8
--- /dev/null
+++ b/vendor/github.com/kylelemons/godebug/pretty/public.go
@@ -0,0 +1,188 @@
+// Copyright 2013 Google Inc. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package pretty
+
+import (
+ "bytes"
+ "fmt"
+ "io"
+ "net"
+ "reflect"
+ "time"
+
+ "github.com/kylelemons/godebug/diff"
+)
+
+// A Config represents optional configuration parameters for formatting.
+//
+// Some options, notably ShortList, dramatically increase the overhead
+// of pretty-printing a value.
+type Config struct {
+ // Verbosity options
+ Compact bool // One-line output. Overrides Diffable.
+ Diffable bool // Adds extra newlines for more easily diffable output.
+
+ // Field and value options
+ IncludeUnexported bool // Include unexported fields in output
+ PrintStringers bool // Call String on a fmt.Stringer
+ PrintTextMarshalers bool // Call MarshalText on an encoding.TextMarshaler
+ SkipZeroFields bool // Skip struct fields that have a zero value.
+
+ // Output transforms
+ ShortList int // Maximum character length for short lists if nonzero.
+
+ // Type-specific overrides
+ //
+ // Formatter maps a type to a function that will provide a one-line string
+ // representation of the input value. Conceptually:
+ // Formatter[reflect.TypeOf(v)](v) = "v as a string"
+ //
+ // Note that the first argument need not explicitly match the type, it must
+ // merely be callable with it.
+ //
+ // When processing an input value, if its type exists as a key in Formatter:
+ // 1) If the value is nil, no stringification is performed.
+ // This allows overriding of PrintStringers and PrintTextMarshalers.
+ // 2) The value will be called with the input as its only argument.
+ // The function must return a string as its first return value.
+ //
+ // In addition to func literals, two common values for this will be:
+ // fmt.Sprint (function) func Sprint(...interface{}) string
+ // Type.String (method) func (Type) String() string
+ //
+ // Note that neither of these work if the String method is a pointer
+ // method and the input will be provided as a value. In that case,
+ // use a function that calls .String on the formal value parameter.
+ Formatter map[reflect.Type]interface{}
+
+ // If TrackCycles is enabled, pretty will detect and track
+ // self-referential structures. If a self-referential structure (aka a
+ // "recursive" value) is detected, numbered placeholders will be emitted.
+ //
+ // Pointer tracking is disabled by default for performance reasons.
+ TrackCycles bool
+}
+
+// Default Config objects
+var (
+ // DefaultFormatter is the default set of overrides for stringification.
+ DefaultFormatter = map[reflect.Type]interface{}{
+ reflect.TypeOf(time.Time{}): fmt.Sprint,
+ reflect.TypeOf(net.IP{}): fmt.Sprint,
+ reflect.TypeOf((*error)(nil)).Elem(): fmt.Sprint,
+ }
+
+ // CompareConfig is the default configuration used for Compare.
+ CompareConfig = &Config{
+ Diffable: true,
+ IncludeUnexported: true,
+ Formatter: DefaultFormatter,
+ }
+
+ // DefaultConfig is the default configuration used for all other top-level functions.
+ DefaultConfig = &Config{
+ Formatter: DefaultFormatter,
+ }
+
+ // CycleTracker is a convenience config for formatting and comparing recursive structures.
+ CycleTracker = &Config{
+ Diffable: true,
+ Formatter: DefaultFormatter,
+ TrackCycles: true,
+ }
+)
+
+func (cfg *Config) fprint(buf *bytes.Buffer, vals ...interface{}) {
+ ref := &reflector{
+ Config: cfg,
+ }
+ if cfg.TrackCycles {
+ ref.pointerTracker = new(pointerTracker)
+ }
+ for i, val := range vals {
+ if i > 0 {
+ buf.WriteByte('\n')
+ }
+ newFormatter(cfg, buf).write(ref.val2node(reflect.ValueOf(val)))
+ }
+}
+
+// Print writes the DefaultConfig representation of the given values to standard output.
+func Print(vals ...interface{}) {
+ DefaultConfig.Print(vals...)
+}
+
+// Print writes the configured presentation of the given values to standard output.
+func (cfg *Config) Print(vals ...interface{}) {
+ fmt.Println(cfg.Sprint(vals...))
+}
+
+// Sprint returns a string representation of the given value according to the DefaultConfig.
+func Sprint(vals ...interface{}) string {
+ return DefaultConfig.Sprint(vals...)
+}
+
+// Sprint returns a string representation of the given value according to cfg.
+func (cfg *Config) Sprint(vals ...interface{}) string {
+ buf := new(bytes.Buffer)
+ cfg.fprint(buf, vals...)
+ return buf.String()
+}
+
+// Fprint writes the representation of the given value to the writer according to the DefaultConfig.
+func Fprint(w io.Writer, vals ...interface{}) (n int64, err error) {
+ return DefaultConfig.Fprint(w, vals...)
+}
+
+// Fprint writes the representation of the given value to the writer according to the cfg.
+func (cfg *Config) Fprint(w io.Writer, vals ...interface{}) (n int64, err error) {
+ buf := new(bytes.Buffer)
+ cfg.fprint(buf, vals...)
+ return buf.WriteTo(w)
+}
+
+// Compare returns a string containing a line-by-line unified diff of the
+// values in a and b, using the CompareConfig.
+//
+// Each line in the output is prefixed with '+', '-', or ' ' to indicate which
+// side it's from. Lines from the a side are marked with '-', lines from the
+// b side are marked with '+' and lines that are the same on both sides are
+// marked with ' '.
+//
+// The comparison is based on the intentionally-untyped output of Print, and as
+// such this comparison is pretty forviving. In particular, if the types of or
+// types within in a and b are different but have the same representation,
+// Compare will not indicate any differences between them.
+func Compare(a, b interface{}) string {
+ return CompareConfig.Compare(a, b)
+}
+
+// Compare returns a string containing a line-by-line unified diff of the
+// values in got and want according to the cfg.
+//
+// Each line in the output is prefixed with '+', '-', or ' ' to indicate which
+// side it's from. Lines from the a side are marked with '-', lines from the
+// b side are marked with '+' and lines that are the same on both sides are
+// marked with ' '.
+//
+// The comparison is based on the intentionally-untyped output of Print, and as
+// such this comparison is pretty forviving. In particular, if the types of or
+// types within in a and b are different but have the same representation,
+// Compare will not indicate any differences between them.
+func (cfg *Config) Compare(a, b interface{}) string {
+ diffCfg := *cfg
+ diffCfg.Diffable = true
+ return diff.Diff(cfg.Sprint(a), cfg.Sprint(b))
+}
diff --git a/vendor/github.com/kylelemons/godebug/pretty/reflect.go b/vendor/github.com/kylelemons/godebug/pretty/reflect.go
new file mode 100644
index 00000000000..5cd30b7f036
--- /dev/null
+++ b/vendor/github.com/kylelemons/godebug/pretty/reflect.go
@@ -0,0 +1,241 @@
+// Copyright 2013 Google Inc. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package pretty
+
+import (
+ "encoding"
+ "fmt"
+ "reflect"
+ "sort"
+)
+
+func isZeroVal(val reflect.Value) bool {
+ if !val.CanInterface() {
+ return false
+ }
+ z := reflect.Zero(val.Type()).Interface()
+ return reflect.DeepEqual(val.Interface(), z)
+}
+
+// pointerTracker is a helper for tracking pointer chasing to detect cycles.
+type pointerTracker struct {
+ addrs map[uintptr]int // addr[address] = seen count
+
+ lastID int
+ ids map[uintptr]int // ids[address] = id
+}
+
+// track tracks following a reference (pointer, slice, map, etc). Every call to
+// track should be paired with a call to untrack.
+func (p *pointerTracker) track(ptr uintptr) {
+ if p.addrs == nil {
+ p.addrs = make(map[uintptr]int)
+ }
+ p.addrs[ptr]++
+}
+
+// untrack registers that we have backtracked over the reference to the pointer.
+func (p *pointerTracker) untrack(ptr uintptr) {
+ p.addrs[ptr]--
+ if p.addrs[ptr] == 0 {
+ delete(p.addrs, ptr)
+ }
+}
+
+// seen returns whether the pointer was previously seen along this path.
+func (p *pointerTracker) seen(ptr uintptr) bool {
+ _, ok := p.addrs[ptr]
+ return ok
+}
+
+// keep allocates an ID for the given address and returns it.
+func (p *pointerTracker) keep(ptr uintptr) int {
+ if p.ids == nil {
+ p.ids = make(map[uintptr]int)
+ }
+ if _, ok := p.ids[ptr]; !ok {
+ p.lastID++
+ p.ids[ptr] = p.lastID
+ }
+ return p.ids[ptr]
+}
+
+// id returns the ID for the given address.
+func (p *pointerTracker) id(ptr uintptr) (int, bool) {
+ if p.ids == nil {
+ p.ids = make(map[uintptr]int)
+ }
+ id, ok := p.ids[ptr]
+ return id, ok
+}
+
+// reflector adds local state to the recursive reflection logic.
+type reflector struct {
+ *Config
+ *pointerTracker
+}
+
+// follow handles following a possiblly-recursive reference to the given value
+// from the given ptr address.
+func (r *reflector) follow(ptr uintptr, val reflect.Value) node {
+ if r.pointerTracker == nil {
+ // Tracking disabled
+ return r.val2node(val)
+ }
+
+ // If a parent already followed this, emit a reference marker
+ if r.seen(ptr) {
+ id := r.keep(ptr)
+ return ref{id}
+ }
+
+ // Track the pointer we're following while on this recursive branch
+ r.track(ptr)
+ defer r.untrack(ptr)
+ n := r.val2node(val)
+
+ // If the recursion used this ptr, wrap it with a target marker
+ if id, ok := r.id(ptr); ok {
+ return target{id, n}
+ }
+
+ // Otherwise, return the node unadulterated
+ return n
+}
+
+func (r *reflector) val2node(val reflect.Value) node {
+ if !val.IsValid() {
+ return rawVal("nil")
+ }
+
+ if val.CanInterface() {
+ v := val.Interface()
+ if formatter, ok := r.Formatter[val.Type()]; ok {
+ if formatter != nil {
+ res := reflect.ValueOf(formatter).Call([]reflect.Value{val})
+ return rawVal(res[0].Interface().(string))
+ }
+ } else {
+ if s, ok := v.(fmt.Stringer); ok && r.PrintStringers {
+ return stringVal(s.String())
+ }
+ if t, ok := v.(encoding.TextMarshaler); ok && r.PrintTextMarshalers {
+ if raw, err := t.MarshalText(); err == nil { // if NOT an error
+ return stringVal(string(raw))
+ }
+ }
+ }
+ }
+
+ switch kind := val.Kind(); kind {
+ case reflect.Ptr:
+ if val.IsNil() {
+ return rawVal("nil")
+ }
+ return r.follow(val.Pointer(), val.Elem())
+ case reflect.Interface:
+ if val.IsNil() {
+ return rawVal("nil")
+ }
+ return r.val2node(val.Elem())
+ case reflect.String:
+ return stringVal(val.String())
+ case reflect.Slice:
+ n := list{}
+ length := val.Len()
+ ptr := val.Pointer()
+ for i := 0; i < length; i++ {
+ n = append(n, r.follow(ptr, val.Index(i)))
+ }
+ return n
+ case reflect.Array:
+ n := list{}
+ length := val.Len()
+ for i := 0; i < length; i++ {
+ n = append(n, r.val2node(val.Index(i)))
+ }
+ return n
+ case reflect.Map:
+ // Extract the keys and sort them for stable iteration
+ keys := val.MapKeys()
+ pairs := make([]mapPair, 0, len(keys))
+ for _, key := range keys {
+ pairs = append(pairs, mapPair{
+ key: new(formatter).compactString(r.val2node(key)), // can't be cyclic
+ value: val.MapIndex(key),
+ })
+ }
+ sort.Sort(byKey(pairs))
+
+ // Process the keys into the final representation
+ ptr, n := val.Pointer(), keyvals{}
+ for _, pair := range pairs {
+ n = append(n, keyval{
+ key: pair.key,
+ val: r.follow(ptr, pair.value),
+ })
+ }
+ return n
+ case reflect.Struct:
+ n := keyvals{}
+ typ := val.Type()
+ fields := typ.NumField()
+ for i := 0; i < fields; i++ {
+ sf := typ.Field(i)
+ if !r.IncludeUnexported && sf.PkgPath != "" {
+ continue
+ }
+ field := val.Field(i)
+ if r.SkipZeroFields && isZeroVal(field) {
+ continue
+ }
+ n = append(n, keyval{sf.Name, r.val2node(field)})
+ }
+ return n
+ case reflect.Bool:
+ if val.Bool() {
+ return rawVal("true")
+ }
+ return rawVal("false")
+ case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64:
+ return rawVal(fmt.Sprintf("%d", val.Int()))
+ case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64:
+ return rawVal(fmt.Sprintf("%d", val.Uint()))
+ case reflect.Uintptr:
+ return rawVal(fmt.Sprintf("0x%X", val.Uint()))
+ case reflect.Float32, reflect.Float64:
+ return rawVal(fmt.Sprintf("%v", val.Float()))
+ case reflect.Complex64, reflect.Complex128:
+ return rawVal(fmt.Sprintf("%v", val.Complex()))
+ }
+
+ // Fall back to the default %#v if we can
+ if val.CanInterface() {
+ return rawVal(fmt.Sprintf("%#v", val.Interface()))
+ }
+
+ return rawVal(val.String())
+}
+
+type mapPair struct {
+ key string
+ value reflect.Value
+}
+
+type byKey []mapPair
+
+func (v byKey) Len() int { return len(v) }
+func (v byKey) Swap(i, j int) { v[i], v[j] = v[j], v[i] }
+func (v byKey) Less(i, j int) bool { return v[i].key < v[j].key }
diff --git a/vendor/github.com/kylelemons/godebug/pretty/structure.go b/vendor/github.com/kylelemons/godebug/pretty/structure.go
new file mode 100644
index 00000000000..d876f60cad2
--- /dev/null
+++ b/vendor/github.com/kylelemons/godebug/pretty/structure.go
@@ -0,0 +1,223 @@
+// Copyright 2013 Google Inc. All rights reserved.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+package pretty
+
+import (
+ "bufio"
+ "bytes"
+ "fmt"
+ "io"
+ "strconv"
+ "strings"
+)
+
+// a formatter stores stateful formatting information as well as being
+// an io.Writer for simplicity.
+type formatter struct {
+ *bufio.Writer
+ *Config
+
+ // Self-referential structure tracking
+ tagNumbers map[int]int // tagNumbers[id] = <#n>
+}
+
+// newFormatter creates a new buffered formatter. For the output to be written
+// to the given writer, this must be accompanied by a call to write (or Flush).
+func newFormatter(cfg *Config, w io.Writer) *formatter {
+ return &formatter{
+ Writer: bufio.NewWriter(w),
+ Config: cfg,
+ tagNumbers: make(map[int]int),
+ }
+}
+
+func (f *formatter) write(n node) {
+ defer f.Flush()
+ n.format(f, "")
+}
+
+func (f *formatter) tagFor(id int) int {
+ if tag, ok := f.tagNumbers[id]; ok {
+ return tag
+ }
+ if f.tagNumbers == nil {
+ return 0
+ }
+ tag := len(f.tagNumbers) + 1
+ f.tagNumbers[id] = tag
+ return tag
+}
+
+type node interface {
+ format(f *formatter, indent string)
+}
+
+func (f *formatter) compactString(n node) string {
+ switch k := n.(type) {
+ case stringVal:
+ return string(k)
+ case rawVal:
+ return string(k)
+ }
+
+ buf := new(bytes.Buffer)
+ f2 := newFormatter(&Config{Compact: true}, buf)
+ f2.tagNumbers = f.tagNumbers // reuse tagNumbers just in case
+ f2.write(n)
+ return buf.String()
+}
+
+type stringVal string
+
+func (str stringVal) format(f *formatter, indent string) {
+ f.WriteString(strconv.Quote(string(str)))
+}
+
+type rawVal string
+
+func (r rawVal) format(f *formatter, indent string) {
+ f.WriteString(string(r))
+}
+
+type keyval struct {
+ key string
+ val node
+}
+
+type keyvals []keyval
+
+func (l keyvals) format(f *formatter, indent string) {
+ f.WriteByte('{')
+
+ switch {
+ case f.Compact:
+ // All on one line:
+ for i, kv := range l {
+ if i > 0 {
+ f.WriteByte(',')
+ }
+ f.WriteString(kv.key)
+ f.WriteByte(':')
+ kv.val.format(f, indent)
+ }
+ case f.Diffable:
+ f.WriteByte('\n')
+ inner := indent + " "
+ // Each value gets its own line:
+ for _, kv := range l {
+ f.WriteString(inner)
+ f.WriteString(kv.key)
+ f.WriteString(": ")
+ kv.val.format(f, inner)
+ f.WriteString(",\n")
+ }
+ f.WriteString(indent)
+ default:
+ keyWidth := 0
+ for _, kv := range l {
+ if kw := len(kv.key); kw > keyWidth {
+ keyWidth = kw
+ }
+ }
+ alignKey := indent + " "
+ alignValue := strings.Repeat(" ", keyWidth)
+ inner := alignKey + alignValue + " "
+ // First and last line shared with bracket:
+ for i, kv := range l {
+ if i > 0 {
+ f.WriteString(",\n")
+ f.WriteString(alignKey)
+ }
+ f.WriteString(kv.key)
+ f.WriteString(": ")
+ f.WriteString(alignValue[len(kv.key):])
+ kv.val.format(f, inner)
+ }
+ }
+
+ f.WriteByte('}')
+}
+
+type list []node
+
+func (l list) format(f *formatter, indent string) {
+ if max := f.ShortList; max > 0 {
+ short := f.compactString(l)
+ if len(short) <= max {
+ f.WriteString(short)
+ return
+ }
+ }
+
+ f.WriteByte('[')
+
+ switch {
+ case f.Compact:
+ // All on one line:
+ for i, v := range l {
+ if i > 0 {
+ f.WriteByte(',')
+ }
+ v.format(f, indent)
+ }
+ case f.Diffable:
+ f.WriteByte('\n')
+ inner := indent + " "
+ // Each value gets its own line:
+ for _, v := range l {
+ f.WriteString(inner)
+ v.format(f, inner)
+ f.WriteString(",\n")
+ }
+ f.WriteString(indent)
+ default:
+ inner := indent + " "
+ // First and last line shared with bracket:
+ for i, v := range l {
+ if i > 0 {
+ f.WriteString(",\n")
+ f.WriteString(inner)
+ }
+ v.format(f, inner)
+ }
+ }
+
+ f.WriteByte(']')
+}
+
+type ref struct {
+ id int
+}
+
+func (r ref) format(f *formatter, indent string) {
+ fmt.Fprintf(f, "", f.tagFor(r.id))
+}
+
+type target struct {
+ id int
+ value node
+}
+
+func (t target) format(f *formatter, indent string) {
+ tag := fmt.Sprintf("<#%d> ", f.tagFor(t.id))
+ switch {
+ case f.Diffable, f.Compact:
+ // no indent changes
+ default:
+ indent += strings.Repeat(" ", len(tag))
+ }
+ f.WriteString(tag)
+ t.value.format(f, indent)
+}
diff --git a/vendor/github.com/linode/linodego/.golangci.yml b/vendor/github.com/linode/linodego/.golangci.yml
index 40983e5b05f..26dd77cb5b0 100644
--- a/vendor/github.com/linode/linodego/.golangci.yml
+++ b/vendor/github.com/linode/linodego/.golangci.yml
@@ -29,6 +29,13 @@ linters-settings:
linters:
enable-all: true
disable:
+ # deprecated linters
+ - deadcode
+ - ifshort
+ - varcheck
+ - nosnakecase
+ ####################
+
- bodyclose
- contextcheck
- nilerr
@@ -71,4 +78,5 @@ linters:
- cyclop
- godot
- exhaustive
+ - depguard
fast: false
diff --git a/vendor/github.com/linode/linodego/Makefile b/vendor/github.com/linode/linodego/Makefile
index ebe4ecbc71b..960c1e43219 100644
--- a/vendor/github.com/linode/linodego/Makefile
+++ b/vendor/github.com/linode/linodego/Makefile
@@ -8,7 +8,7 @@ TEST_TIMEOUT := 5h
SKIP_DOCKER ?= 0
GOLANGCILINT := golangci-lint
-GOLANGCILINT_IMG := golangci/golangci-lint:v1.46.2-alpine
+GOLANGCILINT_IMG := golangci/golangci-lint:latest
GOLANGCILINT_ARGS := run
LINODE_URL := https://api.linode.com/
diff --git a/vendor/github.com/linode/linodego/account_events.go b/vendor/github.com/linode/linodego/account_events.go
index e8306a1ba9f..1373244865a 100644
--- a/vendor/github.com/linode/linodego/account_events.go
+++ b/vendor/github.com/linode/linodego/account_events.go
@@ -95,6 +95,7 @@ const (
ActionHostReboot EventAction = "host_reboot"
ActionImageDelete EventAction = "image_delete"
ActionImageUpdate EventAction = "image_update"
+ ActionImageUpload EventAction = "image_upload"
ActionLassieReboot EventAction = "lassie_reboot"
ActionLinodeAddIP EventAction = "linode_addip"
ActionLinodeBoot EventAction = "linode_boot"
diff --git a/vendor/github.com/linode/linodego/account_settings.go b/vendor/github.com/linode/linodego/account_settings.go
index bf60162d059..9a4b1362b7d 100644
--- a/vendor/github.com/linode/linodego/account_settings.go
+++ b/vendor/github.com/linode/linodego/account_settings.go
@@ -29,6 +29,7 @@ type AccountSettingsUpdateOptions struct {
BackupsEnabled *bool `json:"backups_enabled,omitempty"`
// A plan name like "longview-3"..."longview-100", or a nil value for to cancel any existing subscription plan.
+ // Deprecated: Use PUT /longview/plan instead to update the LongviewSubscription
LongviewSubscription *string `json:"longview_subscription,omitempty"`
// The default network helper setting for all new Linodes and Linode Configs for all users on the account.
diff --git a/vendor/github.com/linode/linodego/databases.go b/vendor/github.com/linode/linodego/databases.go
index eace5fdc9ca..8fbb69ffbe4 100644
--- a/vendor/github.com/linode/linodego/databases.go
+++ b/vendor/github.com/linode/linodego/databases.go
@@ -34,7 +34,6 @@ const (
const (
DatabaseEngineTypeMySQL DatabaseEngineType = "mysql"
- DatabaseEngineTypeMongo DatabaseEngineType = "mongodb"
DatabaseEngineTypePostgres DatabaseEngineType = "postgresql"
)
@@ -236,7 +235,7 @@ func (c *Client) ListDatabaseEngines(ctx context.Context, opts *ListOptions) ([]
}
// GetDatabaseEngine returns a specific Database Engine. This endpoint is cached by default.
-func (c *Client) GetDatabaseEngine(ctx context.Context, opts *ListOptions, engineID string) (*DatabaseEngine, error) {
+func (c *Client) GetDatabaseEngine(ctx context.Context, _ *ListOptions, engineID string) (*DatabaseEngine, error) {
e := fmt.Sprintf("databases/engines/%s", engineID)
if result := c.getCachedResponse(e); result != nil {
@@ -279,7 +278,7 @@ func (c *Client) ListDatabaseTypes(ctx context.Context, opts *ListOptions) ([]Da
}
// GetDatabaseType returns a specific Database Type. This endpoint is cached by default.
-func (c *Client) GetDatabaseType(ctx context.Context, opts *ListOptions, typeID string) (*DatabaseType, error) {
+func (c *Client) GetDatabaseType(ctx context.Context, _ *ListOptions, typeID string) (*DatabaseType, error) {
e := fmt.Sprintf("databases/types/%s", typeID)
if result := c.getCachedResponse(e); result != nil {
diff --git a/vendor/github.com/linode/linodego/go.work.sum b/vendor/github.com/linode/linodego/go.work.sum
index ea20c135a67..aa831efea38 100644
--- a/vendor/github.com/linode/linodego/go.work.sum
+++ b/vendor/github.com/linode/linodego/go.work.sum
@@ -45,12 +45,13 @@ golang.org/x/sys v0.0.0-20190209173611-3b5209105503/go.mod h1:STP8DvDyc/dI5b8T5h
golang.org/x/sys v0.0.0-20191022100944-742c48ecaeb7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.6.0 h1:MVltZSvRTcU2ljQOhs94SXPftV6DCNnZViHeQps87pQ=
-golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.8.0 h1:EBmGv8NaZBZTWvrbjNoL6HVt+IVy3QDQpJs7VRIw3tU=
+golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 h1:JGgROgKl9N8DuW20oFS5gxc+lE67/N3FcwmBPMe7ArY=
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
-golang.org/x/term v0.6.0 h1:clScbb1cHjoCkyRbWwBEUZ5H/tIFu5TAXIqaZD0Gcjw=
-golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U=
+golang.org/x/term v0.8.0 h1:n5xxQn2i3PC0yLAbjTpNT85q/Kgzcr2gIoX9OrJUols=
+golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo=
golang.org/x/text v0.0.0-20160726164857-2910a502d2bf/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/tools v0.0.0-20181011042414-1f849cf54d09/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
diff --git a/vendor/github.com/linode/linodego/mongo.go b/vendor/github.com/linode/linodego/mongo.go
deleted file mode 100644
index 47b83fdc0a6..00000000000
--- a/vendor/github.com/linode/linodego/mongo.go
+++ /dev/null
@@ -1,324 +0,0 @@
-package linodego
-
-import (
- "context"
- "encoding/json"
- "fmt"
- "time"
-
- "github.com/go-resty/resty/v2"
- "github.com/linode/linodego/internal/parseabletime"
-)
-
-type MongoDatabaseTarget string
-
-const (
- MongoDatabaseTargetPrimary MongoDatabaseTarget = "primary"
- MongoDatabaseTargetSecondary MongoDatabaseTarget = "secondary"
-)
-
-type MongoCompressionType string
-
-const (
- MongoCompressionNone MongoCompressionType = "none"
- MongoCompressionSnappy MongoCompressionType = "snappy"
- MongoCompressionZlib MongoCompressionType = "zlib"
-)
-
-type MongoStorageEngine string
-
-const (
- MongoStorageWiredTiger MongoStorageEngine = "wiredtiger"
- MongoStorageMmapv1 MongoStorageEngine = "mmapv1"
-)
-
-// A MongoDatabase is a instance of Linode Mongo Managed Databases
-type MongoDatabase struct {
- ID int `json:"id"`
- Status DatabaseStatus `json:"status"`
- Label string `json:"label"`
- Region string `json:"region"`
- Type string `json:"type"`
- Engine string `json:"engine"`
- Version string `json:"version"`
- Encrypted bool `json:"encrypted"`
- AllowList []string `json:"allow_list"`
- Peers []string `json:"peers"`
- Port int `json:"port"`
- ReplicaSet string `json:"replica_set"`
- SSLConnection bool `json:"ssl_connection"`
- ClusterSize int `json:"cluster_size"`
- Hosts DatabaseHost `json:"hosts"`
- CompressionType MongoCompressionType `json:"compression_type"`
- StorageEngine MongoStorageEngine `json:"storage_engine"`
- Updates DatabaseMaintenanceWindow `json:"updates"`
- Created *time.Time `json:"-"`
- Updated *time.Time `json:"-"`
-}
-
-func (d *MongoDatabase) UnmarshalJSON(b []byte) error {
- type Mask MongoDatabase
-
- p := struct {
- *Mask
- Created *parseabletime.ParseableTime `json:"created"`
- Updated *parseabletime.ParseableTime `json:"updated"`
- }{
- Mask: (*Mask)(d),
- }
-
- if err := json.Unmarshal(b, &p); err != nil {
- return err
- }
-
- d.Created = (*time.Time)(p.Created)
- d.Updated = (*time.Time)(p.Updated)
- return nil
-}
-
-// MongoCreateOptions fields are used when creating a new Mongo Database
-type MongoCreateOptions struct {
- Label string `json:"label"`
- Region string `json:"region"`
- Type string `json:"type"`
- Engine string `json:"engine"`
- AllowList []string `json:"allow_list,omitempty"`
- ClusterSize int `json:"cluster_size,omitempty"`
- Encrypted bool `json:"encrypted,omitempty"`
- SSLConnection bool `json:"ssl_connection,omitempty"`
- CompressionType MongoCompressionType `json:"compression_type,omitempty"`
- StorageEngine MongoStorageEngine `json:"storage_engine,omitempty"`
-}
-
-// MongoUpdateOptions fields are used when altering the existing Mongo Database
-type MongoUpdateOptions struct {
- Label string `json:"label,omitempty"`
- AllowList *[]string `json:"allow_list,omitempty"`
- Updates *DatabaseMaintenanceWindow `json:"updates,omitempty"`
-}
-
-// MongoDatabaseSSL is the SSL Certificate to access the Linode Managed Mongo Database
-type MongoDatabaseSSL struct {
- CACertificate []byte `json:"ca_certificate"`
-}
-
-// MongoDatabaseCredential is the Root Credentials to access the Linode Managed Database
-type MongoDatabaseCredential struct {
- Username string `json:"username"`
- Password string `json:"password"`
-}
-
-type MongoDatabasesPagedResponse struct {
- *PageOptions
- Data []MongoDatabase `json:"data"`
-}
-
-func (MongoDatabasesPagedResponse) endpoint(_ ...any) string {
- return "databases/mongodb/instances"
-}
-
-func (resp *MongoDatabasesPagedResponse) castResult(r *resty.Request, e string) (int, int, error) {
- res, err := coupleAPIErrors(r.SetResult(MongoDatabasesPagedResponse{}).Get(e))
- if err != nil {
- return 0, 0, err
- }
- castedRes := res.Result().(*MongoDatabasesPagedResponse)
- resp.Data = append(resp.Data, castedRes.Data...)
- return castedRes.Pages, castedRes.Results, nil
-}
-
-// ListMongoDatabases lists all Mongo Databases associated with the account
-func (c *Client) ListMongoDatabases(ctx context.Context, opts *ListOptions) ([]MongoDatabase, error) {
- response := MongoDatabasesPagedResponse{}
-
- err := c.listHelper(ctx, &response, opts)
- if err != nil {
- return nil, err
- }
-
- return response.Data, nil
-}
-
-// MongoDatabaseBackup is information for interacting with a backup for the existing Mongo Database
-type MongoDatabaseBackup struct {
- ID int `json:"id"`
- Label string `json:"label"`
- Type string `json:"type"`
- Created *time.Time `json:"-"`
-}
-
-func (d *MongoDatabaseBackup) UnmarshalJSON(b []byte) error {
- type Mask MongoDatabaseBackup
-
- p := struct {
- *Mask
- Created *parseabletime.ParseableTime `json:"created"`
- }{
- Mask: (*Mask)(d),
- }
-
- if err := json.Unmarshal(b, &p); err != nil {
- return err
- }
-
- d.Created = (*time.Time)(p.Created)
- return nil
-}
-
-// MongoBackupCreateOptions are options used for CreateMongoDatabaseBackup(...)
-type MongoBackupCreateOptions struct {
- Label string `json:"label"`
- Target MongoDatabaseTarget `json:"target"`
-}
-
-type MongoDatabaseBackupsPagedResponse struct {
- *PageOptions
- Data []MongoDatabaseBackup `json:"data"`
-}
-
-func (MongoDatabaseBackupsPagedResponse) endpoint(ids ...any) string {
- id := ids[0].(int)
- return fmt.Sprintf("databases/mongodb/instances/%d/backups", id)
-}
-
-func (resp *MongoDatabaseBackupsPagedResponse) castResult(r *resty.Request, e string) (int, int, error) {
- res, err := coupleAPIErrors(r.SetResult(MongoDatabaseBackupsPagedResponse{}).Get(e))
- if err != nil {
- return 0, 0, err
- }
- castedRes := res.Result().(*MongoDatabaseBackupsPagedResponse)
- resp.Data = append(resp.Data, castedRes.Data...)
- return castedRes.Pages, castedRes.Results, nil
-}
-
-// ListMongoDatabaseBackups lists all Mongo Database Backups associated with the given Mongo Database
-func (c *Client) ListMongoDatabaseBackups(ctx context.Context, databaseID int, opts *ListOptions) ([]MongoDatabaseBackup, error) {
- response := MongoDatabaseBackupsPagedResponse{}
-
- err := c.listHelper(ctx, &response, opts, databaseID)
- if err != nil {
- return nil, err
- }
-
- return response.Data, nil
-}
-
-// GetMongoDatabase returns a single Mongo Database matching the id
-func (c *Client) GetMongoDatabase(ctx context.Context, databaseID int) (*MongoDatabase, error) {
- e := fmt.Sprintf("databases/mongodb/instances/%d", databaseID)
- req := c.R(ctx).SetResult(&MongoDatabase{})
- r, err := coupleAPIErrors(req.Get(e))
- if err != nil {
- return nil, err
- }
-
- return r.Result().(*MongoDatabase), nil
-}
-
-// CreateMongoDatabase creates a new Mongo Database using the createOpts as configuration, returns the new Mongo Database
-func (c *Client) CreateMongoDatabase(ctx context.Context, opts MongoCreateOptions) (*MongoDatabase, error) {
- body, err := json.Marshal(opts)
- if err != nil {
- return nil, err
- }
-
- e := "databases/mongodb/instances"
- req := c.R(ctx).SetResult(&MongoDatabase{}).SetBody(string(body))
- r, err := coupleAPIErrors(req.Post(e))
- if err != nil {
- return nil, err
- }
- return r.Result().(*MongoDatabase), nil
-}
-
-// DeleteMongoDatabase deletes an existing Mongo Database with the given id
-func (c *Client) DeleteMongoDatabase(ctx context.Context, databaseID int) error {
- e := fmt.Sprintf("databases/mongodb/instances/%d", databaseID)
- _, err := coupleAPIErrors(c.R(ctx).Delete(e))
- return err
-}
-
-// UpdateMongoDatabase updates the given Mongo Database with the provided opts, returns the MongoDatabase with the new settings
-func (c *Client) UpdateMongoDatabase(ctx context.Context, databaseID int, opts MongoUpdateOptions) (*MongoDatabase, error) {
- body, err := json.Marshal(opts)
- if err != nil {
- return nil, err
- }
-
- e := fmt.Sprintf("databases/mongodb/instances/%d", databaseID)
- req := c.R(ctx).SetResult(&MongoDatabase{}).SetBody(string(body))
- r, err := coupleAPIErrors(req.Put(e))
- if err != nil {
- return nil, err
- }
-
- return r.Result().(*MongoDatabase), nil
-}
-
-// PatchMongoDatabase applies security patches and updates to the underlying operating system of the Managed Mongo Database
-func (c *Client) PatchMongoDatabase(ctx context.Context, databaseID int) error {
- e := fmt.Sprintf("databases/mongodb/instances/%d/patch", databaseID)
- _, err := coupleAPIErrors(c.R(ctx).Post(e))
- return err
-}
-
-// GetMongoDatabaseCredentials returns the Root Credentials for the given Mongo Database
-func (c *Client) GetMongoDatabaseCredentials(ctx context.Context, databaseID int) (*MongoDatabaseCredential, error) {
- e := fmt.Sprintf("databases/mongodb/instances/%d/credentials", databaseID)
- req := c.R(ctx).SetResult(&MongoDatabaseCredential{})
- r, err := coupleAPIErrors(req.Get(e))
- if err != nil {
- return nil, err
- }
-
- return r.Result().(*MongoDatabaseCredential), nil
-}
-
-// ResetMongoDatabaseCredentials returns the Root Credentials for the given Mongo Database (may take a few seconds to work)
-func (c *Client) ResetMongoDatabaseCredentials(ctx context.Context, databaseID int) error {
- e := fmt.Sprintf("databases/mongodb/instances/%d/credentials/reset", databaseID)
- _, err := coupleAPIErrors(c.R(ctx).Post(e))
- return err
-}
-
-// GetMongoDatabaseSSL returns the SSL Certificate for the given Mongo Database
-func (c *Client) GetMongoDatabaseSSL(ctx context.Context, databaseID int) (*MongoDatabaseSSL, error) {
- e := fmt.Sprintf("databases/mongodb/instances/%d/ssl", databaseID)
- req := c.R(ctx).SetResult(&MongoDatabaseSSL{})
- r, err := coupleAPIErrors(req.Get(e))
- if err != nil {
- return nil, err
- }
-
- return r.Result().(*MongoDatabaseSSL), nil
-}
-
-// GetMongoDatabaseBackup returns a specific Mongo Database Backup with the given ids
-func (c *Client) GetMongoDatabaseBackup(ctx context.Context, databaseID int, backupID int) (*MongoDatabaseBackup, error) {
- e := fmt.Sprintf("databases/mongodb/instances/%d/backups/%d", databaseID, backupID)
- req := c.R(ctx).SetResult(&MongoDatabaseBackup{})
- r, err := coupleAPIErrors(req.Get(e))
- if err != nil {
- return nil, err
- }
-
- return r.Result().(*MongoDatabaseBackup), nil
-}
-
-// RestoreMongoDatabaseBackup returns the given Mongo Database with the given Backup
-func (c *Client) RestoreMongoDatabaseBackup(ctx context.Context, databaseID int, backupID int) error {
- e := fmt.Sprintf("databases/mongodb/instances/%d/backups/%d/restore", databaseID, backupID)
- _, err := coupleAPIErrors(c.R(ctx).Post(e))
- return err
-}
-
-// CreateMongoDatabaseBackup creates a snapshot for the given Mongo database
-func (c *Client) CreateMongoDatabaseBackup(ctx context.Context, databaseID int, opts MongoBackupCreateOptions) error {
- body, err := json.Marshal(opts)
- if err != nil {
- return err
- }
- e := fmt.Sprintf("databases/mongodb/instances/%d/backups", databaseID)
- _, err = coupleAPIErrors(c.R(ctx).SetBody(string(body)).Post(e))
- return err
-}
diff --git a/vendor/github.com/linode/linodego/pagination.go b/vendor/github.com/linode/linodego/pagination.go
index 2de2cfe32dd..45313e72d78 100644
--- a/vendor/github.com/linode/linodego/pagination.go
+++ b/vendor/github.com/linode/linodego/pagination.go
@@ -16,16 +16,16 @@ import (
// PageOptions are the pagination parameters for List endpoints
type PageOptions struct {
- Page int `url:"page,omitempty" json:"page"`
- Pages int `url:"pages,omitempty" json:"pages"`
- Results int `url:"results,omitempty" json:"results"`
+ Page int `json:"page" url:"page,omitempty"`
+ Pages int `json:"pages" url:"pages,omitempty"`
+ Results int `json:"results" url:"results,omitempty"`
}
// ListOptions are the pagination and filtering (TODO) parameters for endpoints
type ListOptions struct {
*PageOptions
- PageSize int
- Filter string
+ PageSize int `json:"page_size"`
+ Filter string `json:"filter"`
}
// NewListOptions simplified construction of ListOptions using only
diff --git a/vendor/github.com/linode/linodego/waitfor.go b/vendor/github.com/linode/linodego/waitfor.go
index 60fbf9ec3e9..6f872962314 100644
--- a/vendor/github.com/linode/linodego/waitfor.go
+++ b/vendor/github.com/linode/linodego/waitfor.go
@@ -270,8 +270,15 @@ func (client Client) WaitForLKEClusterConditions(
// WaitForEventFinished waits for an entity action to reach the 'finished' state
// before returning. It will timeout with an error after timeoutSeconds.
// If the event indicates a failure both the failed event and the error will be returned.
-// nolint
-func (client Client) WaitForEventFinished(ctx context.Context, id any, entityType EntityType, action EventAction, minStart time.Time, timeoutSeconds int) (*Event, error) {
+//nolint
+func (client Client) WaitForEventFinished(
+ ctx context.Context,
+ id any,
+ entityType EntityType,
+ action EventAction,
+ minStart time.Time,
+ timeoutSeconds int,
+) (*Event, error) {
titledEntityType := strings.Title(string(entityType))
filter := Filter{
Order: Descending,
@@ -291,12 +298,11 @@ func (client Client) WaitForEventFinished(ctx context.Context, id any, entityTyp
// All of the filter supported types have int ids
filterableEntityID, err := strconv.Atoi(fmt.Sprintf("%v", id))
if err != nil {
- return nil, fmt.Errorf("Error parsing Entity ID %q for optimized WaitForEventFinished EventType %q: %w", id, entityType, err)
+ return nil, fmt.Errorf("error parsing Entity ID %q for optimized "+
+ "WaitForEventFinished EventType %q: %w", id, entityType, err)
}
filter.AddField(Eq, "entity.id", filterableEntityID)
filter.AddField(Eq, "entity.type", entityType)
-
- // TODO: are we conformatable with pages = 0 with the event type and id filter?
}
ctx, cancel := context.WithTimeout(ctx, time.Duration(timeoutSeconds)*time.Second)
@@ -369,8 +375,6 @@ func (client Client) WaitForEventFinished(ctx context.Context, id any, entityTyp
continue
}
- // @TODO(displague) This event.Created check shouldn't be needed, but it appears
- // that the ListEvents method is not populating it correctly
if event.Created == nil {
log.Printf("[WARN] event.Created is nil when API returned: %#+v", event.Created)
}
@@ -387,7 +391,7 @@ func (client Client) WaitForEventFinished(ctx context.Context, id any, entityTyp
log.Printf("[INFO] %s %v action %s is finished", titledEntityType, id, action)
return &event, nil
}
- // TODO(displague) can we bump the ticker to TimeRemaining/2 (>=1) when non-nil?
+
nextLog = fmt.Sprintf("[INFO] %s %v action %s is %s", titledEntityType, id, action, event.Status)
}
@@ -456,33 +460,6 @@ func (client Client) WaitForMySQLDatabaseBackup(ctx context.Context, dbID int, l
}
}
-// WaitForMongoDatabaseBackup waits for the backup with the given label to be available.
-func (client Client) WaitForMongoDatabaseBackup(ctx context.Context, dbID int, label string, timeoutSeconds int) (*MongoDatabaseBackup, error) {
- ctx, cancel := context.WithTimeout(ctx, time.Duration(timeoutSeconds)*time.Second)
- defer cancel()
-
- ticker := time.NewTicker(client.millisecondsPerPoll * time.Millisecond)
- defer ticker.Stop()
-
- for {
- select {
- case <-ticker.C:
- backups, err := client.ListMongoDatabaseBackups(ctx, dbID, nil)
- if err != nil {
- return nil, err
- }
-
- for _, backup := range backups {
- if backup.Label == label {
- return &backup, nil
- }
- }
- case <-ctx.Done():
- return nil, fmt.Errorf("failed to wait for backup %s: %w", label, ctx.Err())
- }
- }
-}
-
// WaitForPostgresDatabaseBackup waits for the backup with the given label to be available.
func (client Client) WaitForPostgresDatabaseBackup(ctx context.Context, dbID int, label string, timeoutSeconds int) (*PostgresDatabaseBackup, error) {
ctx, cancel := context.WithTimeout(ctx, time.Duration(timeoutSeconds)*time.Second)
@@ -521,14 +498,6 @@ var databaseStatusHandlers = map[DatabaseEngineType]databaseStatusFunc{
return db.Status, nil
},
- DatabaseEngineTypeMongo: func(ctx context.Context, client Client, dbID int) (DatabaseStatus, error) {
- db, err := client.GetMongoDatabase(ctx, dbID)
- if err != nil {
- return "", err
- }
-
- return db.Status, nil
- },
DatabaseEngineTypePostgres: func(ctx context.Context, client Client, dbID int) (DatabaseStatus, error) {
db, err := client.GetPostgresDatabase(ctx, dbID)
if err != nil {
@@ -726,3 +695,56 @@ func (p *EventPoller) WaitForFinished(
}
}
}
+
+// WaitForResourceFree waits for a resource to have no running events.
+func (client Client) WaitForResourceFree(
+ ctx context.Context, entityType EntityType, entityID any, timeoutSeconds int,
+) error {
+ apiFilter := Filter{
+ Order: Descending,
+ OrderBy: "created",
+ }
+ apiFilter.AddField(Eq, "entity.id", entityID)
+ apiFilter.AddField(Eq, "entity.type", entityType)
+
+ filterStr, err := apiFilter.MarshalJSON()
+ if err != nil {
+ return fmt.Errorf("failed to create filter: %s", err)
+ }
+
+ ctx, cancel := context.WithTimeout(ctx, time.Duration(timeoutSeconds)*time.Second)
+ defer cancel()
+
+ ticker := time.NewTicker(client.millisecondsPerPoll * time.Millisecond)
+ defer ticker.Stop()
+
+ // A helper function to determine whether a resource is busy
+ checkIsBusy := func(events []Event) bool {
+ for _, event := range events {
+ if event.Status == EventStarted || event.Status == EventScheduled {
+ return true
+ }
+ }
+
+ return false
+ }
+
+ for {
+ select {
+ case <-ticker.C:
+ events, err := client.ListEvents(ctx, &ListOptions{
+ Filter: string(filterStr),
+ })
+ if err != nil {
+ return fmt.Errorf("failed to list events: %s", err)
+ }
+
+ if !checkIsBusy(events) {
+ return nil
+ }
+
+ case <-ctx.Done():
+ return fmt.Errorf("failed to wait for resource free: %s", ctx.Err())
+ }
+ }
+}
diff --git a/vendor/github.com/miekg/dns/client.go b/vendor/github.com/miekg/dns/client.go
index 9051ae00778..2cdd49af177 100644
--- a/vendor/github.com/miekg/dns/client.go
+++ b/vendor/github.com/miekg/dns/client.go
@@ -6,7 +6,6 @@ import (
"context"
"crypto/tls"
"encoding/binary"
- "fmt"
"io"
"net"
"strings"
@@ -56,14 +55,20 @@ type Client struct {
// Timeout is a cumulative timeout for dial, write and read, defaults to 0 (disabled) - overrides DialTimeout, ReadTimeout,
// WriteTimeout when non-zero. Can be overridden with net.Dialer.Timeout (see Client.ExchangeWithDialer and
// Client.Dialer) or context.Context.Deadline (see ExchangeContext)
- Timeout time.Duration
- DialTimeout time.Duration // net.DialTimeout, defaults to 2 seconds, or net.Dialer.Timeout if expiring earlier - overridden by Timeout when that value is non-zero
- ReadTimeout time.Duration // net.Conn.SetReadTimeout value for connections, defaults to 2 seconds - overridden by Timeout when that value is non-zero
- WriteTimeout time.Duration // net.Conn.SetWriteTimeout value for connections, defaults to 2 seconds - overridden by Timeout when that value is non-zero
- TsigSecret map[string]string // secret(s) for Tsig map[], zonename must be in canonical form (lowercase, fqdn, see RFC 4034 Section 6.2)
- TsigProvider TsigProvider // An implementation of the TsigProvider interface. If defined it replaces TsigSecret and is used for all TSIG operations.
- SingleInflight bool // if true suppress multiple outstanding queries for the same Qname, Qtype and Qclass
- group singleflight
+ Timeout time.Duration
+ DialTimeout time.Duration // net.DialTimeout, defaults to 2 seconds, or net.Dialer.Timeout if expiring earlier - overridden by Timeout when that value is non-zero
+ ReadTimeout time.Duration // net.Conn.SetReadTimeout value for connections, defaults to 2 seconds - overridden by Timeout when that value is non-zero
+ WriteTimeout time.Duration // net.Conn.SetWriteTimeout value for connections, defaults to 2 seconds - overridden by Timeout when that value is non-zero
+ TsigSecret map[string]string // secret(s) for Tsig map[], zonename must be in canonical form (lowercase, fqdn, see RFC 4034 Section 6.2)
+ TsigProvider TsigProvider // An implementation of the TsigProvider interface. If defined it replaces TsigSecret and is used for all TSIG operations.
+
+ // SingleInflight previously serialised multiple concurrent queries for the
+ // same Qname, Qtype and Qclass to ensure only one would be in flight at a
+ // time.
+ //
+ // Deprecated: This is a no-op. Callers should implement their own in flight
+ // query caching if needed. See github.com/miekg/dns/issues/1449.
+ SingleInflight bool
}
// Exchange performs a synchronous UDP query. It sends the message m to the address
@@ -185,26 +190,7 @@ func (c *Client) ExchangeWithConn(m *Msg, conn *Conn) (r *Msg, rtt time.Duration
return c.exchangeWithConnContext(context.Background(), m, conn)
}
-func (c *Client) exchangeWithConnContext(ctx context.Context, m *Msg, conn *Conn) (r *Msg, rtt time.Duration, err error) {
- if !c.SingleInflight {
- return c.exchangeContext(ctx, m, conn)
- }
-
- q := m.Question[0]
- key := fmt.Sprintf("%s:%d:%d", q.Name, q.Qtype, q.Qclass)
- r, rtt, err, shared := c.group.Do(key, func() (*Msg, time.Duration, error) {
- // When we're doing singleflight we don't want one context cancellation, cancel _all_ outstanding queries.
- // Hence we ignore the context and use Background().
- return c.exchangeContext(context.Background(), m, conn)
- })
- if r != nil && shared {
- r = r.Copy()
- }
-
- return r, rtt, err
-}
-
-func (c *Client) exchangeContext(ctx context.Context, m *Msg, co *Conn) (r *Msg, rtt time.Duration, err error) {
+func (c *Client) exchangeWithConnContext(ctx context.Context, m *Msg, co *Conn) (r *Msg, rtt time.Duration, err error) {
opt := m.IsEdns0()
// If EDNS0 is used use that for size.
if opt != nil && opt.UDPSize() >= MinMsgSize {
diff --git a/vendor/github.com/miekg/dns/defaults.go b/vendor/github.com/miekg/dns/defaults.go
index 75b17f0c1e4..c1558b79c3b 100644
--- a/vendor/github.com/miekg/dns/defaults.go
+++ b/vendor/github.com/miekg/dns/defaults.go
@@ -272,18 +272,24 @@ func IsMsg(buf []byte) error {
// IsFqdn checks if a domain name is fully qualified.
func IsFqdn(s string) bool {
- s2 := strings.TrimSuffix(s, ".")
- if s == s2 {
+ // Check for (and remove) a trailing dot, returning if there isn't one.
+ if s == "" || s[len(s)-1] != '.' {
return false
}
+ s = s[:len(s)-1]
- i := strings.LastIndexFunc(s2, func(r rune) bool {
+ // If we don't have an escape sequence before the final dot, we know it's
+ // fully qualified and can return here.
+ if s == "" || s[len(s)-1] != '\\' {
+ return true
+ }
+
+ // Otherwise we have to check if the dot is escaped or not by checking if
+ // there are an odd or even number of escape sequences before the dot.
+ i := strings.LastIndexFunc(s, func(r rune) bool {
return r != '\\'
})
-
- // Test whether we have an even number of escape sequences before
- // the dot or none.
- return (len(s2)-i)%2 != 0
+ return (len(s)-i)%2 != 0
}
// IsRRset checks if a set of RRs is a valid RRset as defined by RFC 2181.
diff --git a/vendor/github.com/miekg/dns/scan.go b/vendor/github.com/miekg/dns/scan.go
index 57be9882772..3083c3e5f37 100644
--- a/vendor/github.com/miekg/dns/scan.go
+++ b/vendor/github.com/miekg/dns/scan.go
@@ -10,13 +10,13 @@ import (
"strings"
)
-const maxTok = 2048 // Largest token we can return.
+const maxTok = 512 // Token buffer start size, and growth size amount.
// The maximum depth of $INCLUDE directives supported by the
// ZoneParser API.
const maxIncludeDepth = 7
-// Tokinize a RFC 1035 zone file. The tokenizer will normalize it:
+// Tokenize a RFC 1035 zone file. The tokenizer will normalize it:
// * Add ownernames if they are left blank;
// * Suppress sequences of spaces;
// * Make each RR fit on one line (_NEWLINE is send as last)
@@ -765,8 +765,8 @@ func (zl *zlexer) Next() (lex, bool) {
}
var (
- str [maxTok]byte // Hold string text
- com [maxTok]byte // Hold comment text
+ str = make([]byte, maxTok) // Hold string text
+ com = make([]byte, maxTok) // Hold comment text
stri int // Offset in str (0 means empty)
comi int // Offset in com (0 means empty)
@@ -785,14 +785,12 @@ func (zl *zlexer) Next() (lex, bool) {
l.line, l.column = zl.line, zl.column
if stri >= len(str) {
- l.token = "token length insufficient for parsing"
- l.err = true
- return *l, true
+ // if buffer length is insufficient, increase it.
+ str = append(str[:], make([]byte, maxTok)...)
}
if comi >= len(com) {
- l.token = "comment length insufficient for parsing"
- l.err = true
- return *l, true
+ // if buffer length is insufficient, increase it.
+ com = append(com[:], make([]byte, maxTok)...)
}
switch x {
@@ -816,7 +814,7 @@ func (zl *zlexer) Next() (lex, bool) {
if stri == 0 {
// Space directly in the beginning, handled in the grammar
} else if zl.owner {
- // If we have a string and its the first, make it an owner
+ // If we have a string and it's the first, make it an owner
l.value = zOwner
l.token = string(str[:stri])
diff --git a/vendor/github.com/miekg/dns/scan_rr.go b/vendor/github.com/miekg/dns/scan_rr.go
index 2d44a3987a9..d08c8e6a72f 100644
--- a/vendor/github.com/miekg/dns/scan_rr.go
+++ b/vendor/github.com/miekg/dns/scan_rr.go
@@ -904,11 +904,18 @@ func (rr *RRSIG) parse(c *zlexer, o string) *ParseError {
c.Next() // zBlank
l, _ = c.Next()
- i, e := strconv.ParseUint(l.token, 10, 8)
- if e != nil || l.err {
+ if l.err {
return &ParseError{"", "bad RRSIG Algorithm", l}
}
- rr.Algorithm = uint8(i)
+ i, e := strconv.ParseUint(l.token, 10, 8)
+ rr.Algorithm = uint8(i) // if 0 we'll check the mnemonic in the if
+ if e != nil {
+ v, ok := StringToAlgorithm[l.token]
+ if !ok {
+ return &ParseError{"", "bad RRSIG Algorithm", l}
+ }
+ rr.Algorithm = v
+ }
c.Next() // zBlank
l, _ = c.Next()
diff --git a/vendor/github.com/miekg/dns/singleinflight.go b/vendor/github.com/miekg/dns/singleinflight.go
deleted file mode 100644
index febcc300fe1..00000000000
--- a/vendor/github.com/miekg/dns/singleinflight.go
+++ /dev/null
@@ -1,61 +0,0 @@
-// Copyright 2013 The Go Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file.
-
-// Adapted for dns package usage by Miek Gieben.
-
-package dns
-
-import "sync"
-import "time"
-
-// call is an in-flight or completed singleflight.Do call
-type call struct {
- wg sync.WaitGroup
- val *Msg
- rtt time.Duration
- err error
- dups int
-}
-
-// singleflight represents a class of work and forms a namespace in
-// which units of work can be executed with duplicate suppression.
-type singleflight struct {
- sync.Mutex // protects m
- m map[string]*call // lazily initialized
-
- dontDeleteForTesting bool // this is only to be used by TestConcurrentExchanges
-}
-
-// Do executes and returns the results of the given function, making
-// sure that only one execution is in-flight for a given key at a
-// time. If a duplicate comes in, the duplicate caller waits for the
-// original to complete and receives the same results.
-// The return value shared indicates whether v was given to multiple callers.
-func (g *singleflight) Do(key string, fn func() (*Msg, time.Duration, error)) (v *Msg, rtt time.Duration, err error, shared bool) {
- g.Lock()
- if g.m == nil {
- g.m = make(map[string]*call)
- }
- if c, ok := g.m[key]; ok {
- c.dups++
- g.Unlock()
- c.wg.Wait()
- return c.val, c.rtt, c.err, true
- }
- c := new(call)
- c.wg.Add(1)
- g.m[key] = c
- g.Unlock()
-
- c.val, c.rtt, c.err = fn()
- c.wg.Done()
-
- if !g.dontDeleteForTesting {
- g.Lock()
- delete(g.m, key)
- g.Unlock()
- }
-
- return c.val, c.rtt, c.err, c.dups > 0
-}
diff --git a/vendor/github.com/miekg/dns/version.go b/vendor/github.com/miekg/dns/version.go
index f03a169c234..6094585d8b8 100644
--- a/vendor/github.com/miekg/dns/version.go
+++ b/vendor/github.com/miekg/dns/version.go
@@ -3,7 +3,7 @@ package dns
import "fmt"
// Version is current version of this library.
-var Version = v{1, 1, 53}
+var Version = v{1, 1, 54}
// v holds the version of this library.
type v struct {
diff --git a/vendor/github.com/pkg/browser/LICENSE b/vendor/github.com/pkg/browser/LICENSE
new file mode 100644
index 00000000000..65f78fb6291
--- /dev/null
+++ b/vendor/github.com/pkg/browser/LICENSE
@@ -0,0 +1,23 @@
+Copyright (c) 2014, Dave Cheney
+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,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+
+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 A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
+FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/vendor/github.com/pkg/browser/README.md b/vendor/github.com/pkg/browser/README.md
new file mode 100644
index 00000000000..72b1976e303
--- /dev/null
+++ b/vendor/github.com/pkg/browser/README.md
@@ -0,0 +1,55 @@
+
+# browser
+ import "github.com/pkg/browser"
+
+Package browser provides helpers to open files, readers, and urls in a browser window.
+
+The choice of which browser is started is entirely client dependant.
+
+
+
+
+
+## Variables
+``` go
+var Stderr io.Writer = os.Stderr
+```
+Stderr is the io.Writer to which executed commands write standard error.
+
+``` go
+var Stdout io.Writer = os.Stdout
+```
+Stdout is the io.Writer to which executed commands write standard output.
+
+
+## func OpenFile
+``` go
+func OpenFile(path string) error
+```
+OpenFile opens new browser window for the file path.
+
+
+## func OpenReader
+``` go
+func OpenReader(r io.Reader) error
+```
+OpenReader consumes the contents of r and presents the
+results in a new browser window.
+
+
+## func OpenURL
+``` go
+func OpenURL(url string) error
+```
+OpenURL opens a new browser window pointing to url.
+
+
+
+
+
+
+
+
+
+- - -
+Generated by [godoc2md](http://godoc.org/github.com/davecheney/godoc2md)
diff --git a/vendor/github.com/pkg/browser/browser.go b/vendor/github.com/pkg/browser/browser.go
new file mode 100644
index 00000000000..d7969d74d80
--- /dev/null
+++ b/vendor/github.com/pkg/browser/browser.go
@@ -0,0 +1,57 @@
+// Package browser provides helpers to open files, readers, and urls in a browser window.
+//
+// The choice of which browser is started is entirely client dependant.
+package browser
+
+import (
+ "fmt"
+ "io"
+ "io/ioutil"
+ "os"
+ "os/exec"
+ "path/filepath"
+)
+
+// Stdout is the io.Writer to which executed commands write standard output.
+var Stdout io.Writer = os.Stdout
+
+// Stderr is the io.Writer to which executed commands write standard error.
+var Stderr io.Writer = os.Stderr
+
+// OpenFile opens new browser window for the file path.
+func OpenFile(path string) error {
+ path, err := filepath.Abs(path)
+ if err != nil {
+ return err
+ }
+ return OpenURL("file://" + path)
+}
+
+// OpenReader consumes the contents of r and presents the
+// results in a new browser window.
+func OpenReader(r io.Reader) error {
+ f, err := ioutil.TempFile("", "browser.*.html")
+ if err != nil {
+ return fmt.Errorf("browser: could not create temporary file: %v", err)
+ }
+ if _, err := io.Copy(f, r); err != nil {
+ f.Close()
+ return fmt.Errorf("browser: caching temporary file failed: %v", err)
+ }
+ if err := f.Close(); err != nil {
+ return fmt.Errorf("browser: caching temporary file failed: %v", err)
+ }
+ return OpenFile(f.Name())
+}
+
+// OpenURL opens a new browser window pointing to url.
+func OpenURL(url string) error {
+ return openBrowser(url)
+}
+
+func runCmd(prog string, args ...string) error {
+ cmd := exec.Command(prog, args...)
+ cmd.Stdout = Stdout
+ cmd.Stderr = Stderr
+ return cmd.Run()
+}
diff --git a/vendor/github.com/pkg/browser/browser_darwin.go b/vendor/github.com/pkg/browser/browser_darwin.go
new file mode 100644
index 00000000000..8507cf7c2b4
--- /dev/null
+++ b/vendor/github.com/pkg/browser/browser_darwin.go
@@ -0,0 +1,5 @@
+package browser
+
+func openBrowser(url string) error {
+ return runCmd("open", url)
+}
diff --git a/vendor/github.com/pkg/browser/browser_freebsd.go b/vendor/github.com/pkg/browser/browser_freebsd.go
new file mode 100644
index 00000000000..4fc7ff0761b
--- /dev/null
+++ b/vendor/github.com/pkg/browser/browser_freebsd.go
@@ -0,0 +1,14 @@
+package browser
+
+import (
+ "errors"
+ "os/exec"
+)
+
+func openBrowser(url string) error {
+ err := runCmd("xdg-open", url)
+ if e, ok := err.(*exec.Error); ok && e.Err == exec.ErrNotFound {
+ return errors.New("xdg-open: command not found - install xdg-utils from ports(8)")
+ }
+ return err
+}
diff --git a/vendor/github.com/pkg/browser/browser_linux.go b/vendor/github.com/pkg/browser/browser_linux.go
new file mode 100644
index 00000000000..d26cdddf9c1
--- /dev/null
+++ b/vendor/github.com/pkg/browser/browser_linux.go
@@ -0,0 +1,21 @@
+package browser
+
+import (
+ "os/exec"
+ "strings"
+)
+
+func openBrowser(url string) error {
+ providers := []string{"xdg-open", "x-www-browser", "www-browser"}
+
+ // There are multiple possible providers to open a browser on linux
+ // One of them is xdg-open, another is x-www-browser, then there's www-browser, etc.
+ // Look for one that exists and run it
+ for _, provider := range providers {
+ if _, err := exec.LookPath(provider); err == nil {
+ return runCmd(provider, url)
+ }
+ }
+
+ return &exec.Error{Name: strings.Join(providers, ","), Err: exec.ErrNotFound}
+}
diff --git a/vendor/github.com/pkg/browser/browser_netbsd.go b/vendor/github.com/pkg/browser/browser_netbsd.go
new file mode 100644
index 00000000000..65a5e5a2934
--- /dev/null
+++ b/vendor/github.com/pkg/browser/browser_netbsd.go
@@ -0,0 +1,14 @@
+package browser
+
+import (
+ "errors"
+ "os/exec"
+)
+
+func openBrowser(url string) error {
+ err := runCmd("xdg-open", url)
+ if e, ok := err.(*exec.Error); ok && e.Err == exec.ErrNotFound {
+ return errors.New("xdg-open: command not found - install xdg-utils from pkgsrc(7)")
+ }
+ return err
+}
diff --git a/vendor/github.com/pkg/browser/browser_openbsd.go b/vendor/github.com/pkg/browser/browser_openbsd.go
new file mode 100644
index 00000000000..4fc7ff0761b
--- /dev/null
+++ b/vendor/github.com/pkg/browser/browser_openbsd.go
@@ -0,0 +1,14 @@
+package browser
+
+import (
+ "errors"
+ "os/exec"
+)
+
+func openBrowser(url string) error {
+ err := runCmd("xdg-open", url)
+ if e, ok := err.(*exec.Error); ok && e.Err == exec.ErrNotFound {
+ return errors.New("xdg-open: command not found - install xdg-utils from ports(8)")
+ }
+ return err
+}
diff --git a/vendor/github.com/pkg/browser/browser_unsupported.go b/vendor/github.com/pkg/browser/browser_unsupported.go
new file mode 100644
index 00000000000..7c5c17d34d2
--- /dev/null
+++ b/vendor/github.com/pkg/browser/browser_unsupported.go
@@ -0,0 +1,12 @@
+// +build !linux,!windows,!darwin,!openbsd,!freebsd,!netbsd
+
+package browser
+
+import (
+ "fmt"
+ "runtime"
+)
+
+func openBrowser(url string) error {
+ return fmt.Errorf("openBrowser: unsupported operating system: %v", runtime.GOOS)
+}
diff --git a/vendor/github.com/pkg/browser/browser_windows.go b/vendor/github.com/pkg/browser/browser_windows.go
new file mode 100644
index 00000000000..63e192959a5
--- /dev/null
+++ b/vendor/github.com/pkg/browser/browser_windows.go
@@ -0,0 +1,7 @@
+package browser
+
+import "golang.org/x/sys/windows"
+
+func openBrowser(url string) error {
+ return windows.ShellExecute(0, nil, windows.StringToUTF16Ptr(url), nil, nil, windows.SW_SHOWNORMAL)
+}
diff --git a/vendor/github.com/prometheus/client_golang/prometheus/promhttp/instrument_client.go b/vendor/github.com/prometheus/client_golang/prometheus/promhttp/instrument_client.go
index 61fc2e3d189..d3482c40ca7 100644
--- a/vendor/github.com/prometheus/client_golang/prometheus/promhttp/instrument_client.go
+++ b/vendor/github.com/prometheus/client_golang/prometheus/promhttp/instrument_client.go
@@ -78,7 +78,7 @@ func InstrumentRoundTripperCounter(counter *prometheus.CounterVec, next http.Rou
for label, resolve := range rtOpts.extraLabelsFromCtx {
l[label] = resolve(resp.Request.Context())
}
- counter.With(l).(prometheus.ExemplarAdder).AddWithExemplar(1, rtOpts.getExemplarFn(r.Context()))
+ addWithExemplar(counter.With(l), 1, rtOpts.getExemplarFn(r.Context()))
}
return resp, err
}
@@ -122,7 +122,7 @@ func InstrumentRoundTripperDuration(obs prometheus.ObserverVec, next http.RoundT
for label, resolve := range rtOpts.extraLabelsFromCtx {
l[label] = resolve(resp.Request.Context())
}
- obs.With(l).(prometheus.ExemplarObserver).ObserveWithExemplar(time.Since(start).Seconds(), rtOpts.getExemplarFn(r.Context()))
+ observeWithExemplar(obs.With(l), time.Since(start).Seconds(), rtOpts.getExemplarFn(r.Context()))
}
return resp, err
}
diff --git a/vendor/github.com/prometheus/client_golang/prometheus/promhttp/instrument_server.go b/vendor/github.com/prometheus/client_golang/prometheus/promhttp/instrument_server.go
index 71abd755324..3793036ad09 100644
--- a/vendor/github.com/prometheus/client_golang/prometheus/promhttp/instrument_server.go
+++ b/vendor/github.com/prometheus/client_golang/prometheus/promhttp/instrument_server.go
@@ -28,6 +28,26 @@ import (
// magicString is used for the hacky label test in checkLabels. Remove once fixed.
const magicString = "zZgWfBxLqvG8kc8IMv3POi2Bb0tZI3vAnBx+gBaFi9FyPzB/CzKUer1yufDa"
+// observeWithExemplar is a wrapper for [prometheus.ExemplarAdder.ExemplarObserver],
+// which falls back to [prometheus.Observer.Observe] if no labels are provided.
+func observeWithExemplar(obs prometheus.Observer, val float64, labels map[string]string) {
+ if labels == nil {
+ obs.Observe(val)
+ return
+ }
+ obs.(prometheus.ExemplarObserver).ObserveWithExemplar(val, labels)
+}
+
+// addWithExemplar is a wrapper for [prometheus.ExemplarAdder.AddWithExemplar],
+// which falls back to [prometheus.Counter.Add] if no labels are provided.
+func addWithExemplar(obs prometheus.Counter, val float64, labels map[string]string) {
+ if labels == nil {
+ obs.Add(val)
+ return
+ }
+ obs.(prometheus.ExemplarAdder).AddWithExemplar(val, labels)
+}
+
// InstrumentHandlerInFlight is a middleware that wraps the provided
// http.Handler. It sets the provided prometheus.Gauge to the number of
// requests currently handled by the wrapped http.Handler.
@@ -80,7 +100,7 @@ func InstrumentHandlerDuration(obs prometheus.ObserverVec, next http.Handler, op
for label, resolve := range hOpts.extraLabelsFromCtx {
l[label] = resolve(r.Context())
}
- obs.With(l).(prometheus.ExemplarObserver).ObserveWithExemplar(time.Since(now).Seconds(), hOpts.getExemplarFn(r.Context()))
+ observeWithExemplar(obs.With(l), time.Since(now).Seconds(), hOpts.getExemplarFn(r.Context()))
}
}
@@ -91,7 +111,7 @@ func InstrumentHandlerDuration(obs prometheus.ObserverVec, next http.Handler, op
for label, resolve := range hOpts.extraLabelsFromCtx {
l[label] = resolve(r.Context())
}
- obs.With(l).(prometheus.ExemplarObserver).ObserveWithExemplar(time.Since(now).Seconds(), hOpts.getExemplarFn(r.Context()))
+ observeWithExemplar(obs.With(l), time.Since(now).Seconds(), hOpts.getExemplarFn(r.Context()))
}
}
@@ -130,7 +150,7 @@ func InstrumentHandlerCounter(counter *prometheus.CounterVec, next http.Handler,
for label, resolve := range hOpts.extraLabelsFromCtx {
l[label] = resolve(r.Context())
}
- counter.With(l).(prometheus.ExemplarAdder).AddWithExemplar(1, hOpts.getExemplarFn(r.Context()))
+ addWithExemplar(counter.With(l), 1, hOpts.getExemplarFn(r.Context()))
}
}
@@ -141,7 +161,7 @@ func InstrumentHandlerCounter(counter *prometheus.CounterVec, next http.Handler,
for label, resolve := range hOpts.extraLabelsFromCtx {
l[label] = resolve(r.Context())
}
- counter.With(l).(prometheus.ExemplarAdder).AddWithExemplar(1, hOpts.getExemplarFn(r.Context()))
+ addWithExemplar(counter.With(l), 1, hOpts.getExemplarFn(r.Context()))
}
}
@@ -183,7 +203,7 @@ func InstrumentHandlerTimeToWriteHeader(obs prometheus.ObserverVec, next http.Ha
for label, resolve := range hOpts.extraLabelsFromCtx {
l[label] = resolve(r.Context())
}
- obs.With(l).(prometheus.ExemplarObserver).ObserveWithExemplar(time.Since(now).Seconds(), hOpts.getExemplarFn(r.Context()))
+ observeWithExemplar(obs.With(l), time.Since(now).Seconds(), hOpts.getExemplarFn(r.Context()))
})
next.ServeHTTP(d, r)
}
@@ -227,7 +247,7 @@ func InstrumentHandlerRequestSize(obs prometheus.ObserverVec, next http.Handler,
for label, resolve := range hOpts.extraLabelsFromCtx {
l[label] = resolve(r.Context())
}
- obs.With(l).(prometheus.ExemplarObserver).ObserveWithExemplar(float64(size), hOpts.getExemplarFn(r.Context()))
+ observeWithExemplar(obs.With(l), float64(size), hOpts.getExemplarFn(r.Context()))
}
}
@@ -239,7 +259,7 @@ func InstrumentHandlerRequestSize(obs prometheus.ObserverVec, next http.Handler,
for label, resolve := range hOpts.extraLabelsFromCtx {
l[label] = resolve(r.Context())
}
- obs.With(l).(prometheus.ExemplarObserver).ObserveWithExemplar(float64(size), hOpts.getExemplarFn(r.Context()))
+ observeWithExemplar(obs.With(l), float64(size), hOpts.getExemplarFn(r.Context()))
}
}
@@ -279,7 +299,7 @@ func InstrumentHandlerResponseSize(obs prometheus.ObserverVec, next http.Handler
for label, resolve := range hOpts.extraLabelsFromCtx {
l[label] = resolve(r.Context())
}
- obs.With(l).(prometheus.ExemplarObserver).ObserveWithExemplar(float64(d.Written()), hOpts.getExemplarFn(r.Context()))
+ observeWithExemplar(obs.With(l), float64(d.Written()), hOpts.getExemplarFn(r.Context()))
})
}
diff --git a/vendor/github.com/prometheus/client_golang/prometheus/promhttp/option.go b/vendor/github.com/prometheus/client_golang/prometheus/promhttp/option.go
index af7403df4c0..5d4383aa14a 100644
--- a/vendor/github.com/prometheus/client_golang/prometheus/promhttp/option.go
+++ b/vendor/github.com/prometheus/client_golang/prometheus/promhttp/option.go
@@ -66,9 +66,9 @@ func WithExtraMethods(methods ...string) Option {
})
}
-// WithExemplarFromContext adds allows to put a hook to all counter and histogram metrics.
-// If the hook function returns non-nil labels, exemplars will be added for that request, otherwise metric
-// will get instrumented without exemplar.
+// WithExemplarFromContext allows to inject function that will get exemplar from context that will be put to counter and histogram metrics.
+// If the function returns nil labels or the metric does not support exemplars, no exemplar will be added (noop), but
+// metric will continue to observe/increment.
func WithExemplarFromContext(getExemplarFn func(requestCtx context.Context) prometheus.Labels) Option {
return optionApplyFunc(func(o *options) {
o.getExemplarFn = getExemplarFn
diff --git a/vendor/github.com/prometheus/client_model/go/metrics.pb.go b/vendor/github.com/prometheus/client_model/go/metrics.pb.go
index 35904ea1986..2b5bca4b999 100644
--- a/vendor/github.com/prometheus/client_model/go/metrics.pb.go
+++ b/vendor/github.com/prometheus/client_model/go/metrics.pb.go
@@ -1,25 +1,38 @@
+// Copyright 2013 Prometheus Team
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
// Code generated by protoc-gen-go. DO NOT EDIT.
+// versions:
+// protoc-gen-go v1.30.0
+// protoc v3.20.3
// source: io/prometheus/client/metrics.proto
package io_prometheus_client
import (
- fmt "fmt"
- proto "github.com/golang/protobuf/proto"
- timestamp "github.com/golang/protobuf/ptypes/timestamp"
- math "math"
+ protoreflect "google.golang.org/protobuf/reflect/protoreflect"
+ protoimpl "google.golang.org/protobuf/runtime/protoimpl"
+ timestamppb "google.golang.org/protobuf/types/known/timestamppb"
+ reflect "reflect"
+ sync "sync"
)
-// Reference imports to suppress errors if they are not otherwise used.
-var _ = proto.Marshal
-var _ = fmt.Errorf
-var _ = math.Inf
-
-// This is a compile-time assertion to ensure that this generated file
-// is compatible with the proto package it is being compiled against.
-// A compilation error at this line likely means your copy of the
-// proto package needs to be updated.
-const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
+const (
+ // Verify that this generated code is sufficiently up-to-date.
+ _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
+ // Verify that runtime/protoimpl is sufficiently up-to-date.
+ _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
+)
type MetricType int32
@@ -38,23 +51,25 @@ const (
MetricType_GAUGE_HISTOGRAM MetricType = 5
)
-var MetricType_name = map[int32]string{
- 0: "COUNTER",
- 1: "GAUGE",
- 2: "SUMMARY",
- 3: "UNTYPED",
- 4: "HISTOGRAM",
- 5: "GAUGE_HISTOGRAM",
-}
-
-var MetricType_value = map[string]int32{
- "COUNTER": 0,
- "GAUGE": 1,
- "SUMMARY": 2,
- "UNTYPED": 3,
- "HISTOGRAM": 4,
- "GAUGE_HISTOGRAM": 5,
-}
+// Enum value maps for MetricType.
+var (
+ MetricType_name = map[int32]string{
+ 0: "COUNTER",
+ 1: "GAUGE",
+ 2: "SUMMARY",
+ 3: "UNTYPED",
+ 4: "HISTOGRAM",
+ 5: "GAUGE_HISTOGRAM",
+ }
+ MetricType_value = map[string]int32{
+ "COUNTER": 0,
+ "GAUGE": 1,
+ "SUMMARY": 2,
+ "UNTYPED": 3,
+ "HISTOGRAM": 4,
+ "GAUGE_HISTOGRAM": 5,
+ }
+)
func (x MetricType) Enum() *MetricType {
p := new(MetricType)
@@ -63,449 +78,519 @@ func (x MetricType) Enum() *MetricType {
}
func (x MetricType) String() string {
- return proto.EnumName(MetricType_name, int32(x))
+ return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
-func (x *MetricType) UnmarshalJSON(data []byte) error {
- value, err := proto.UnmarshalJSONEnum(MetricType_value, data, "MetricType")
+func (MetricType) Descriptor() protoreflect.EnumDescriptor {
+ return file_io_prometheus_client_metrics_proto_enumTypes[0].Descriptor()
+}
+
+func (MetricType) Type() protoreflect.EnumType {
+ return &file_io_prometheus_client_metrics_proto_enumTypes[0]
+}
+
+func (x MetricType) Number() protoreflect.EnumNumber {
+ return protoreflect.EnumNumber(x)
+}
+
+// Deprecated: Do not use.
+func (x *MetricType) UnmarshalJSON(b []byte) error {
+ num, err := protoimpl.X.UnmarshalJSONEnum(x.Descriptor(), b)
if err != nil {
return err
}
- *x = MetricType(value)
+ *x = MetricType(num)
return nil
}
+// Deprecated: Use MetricType.Descriptor instead.
func (MetricType) EnumDescriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{0}
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{0}
}
type LabelPair struct {
- Name *string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
- Value *string `protobuf:"bytes,2,opt,name=value" json:"value,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
-func (m *LabelPair) Reset() { *m = LabelPair{} }
-func (m *LabelPair) String() string { return proto.CompactTextString(m) }
-func (*LabelPair) ProtoMessage() {}
-func (*LabelPair) Descriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{0}
+ Name *string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
+ Value *string `protobuf:"bytes,2,opt,name=value" json:"value,omitempty"`
}
-func (m *LabelPair) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_LabelPair.Unmarshal(m, b)
-}
-func (m *LabelPair) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_LabelPair.Marshal(b, m, deterministic)
-}
-func (m *LabelPair) XXX_Merge(src proto.Message) {
- xxx_messageInfo_LabelPair.Merge(m, src)
+func (x *LabelPair) Reset() {
+ *x = LabelPair{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[0]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
}
-func (m *LabelPair) XXX_Size() int {
- return xxx_messageInfo_LabelPair.Size(m)
+
+func (x *LabelPair) String() string {
+ return protoimpl.X.MessageStringOf(x)
}
-func (m *LabelPair) XXX_DiscardUnknown() {
- xxx_messageInfo_LabelPair.DiscardUnknown(m)
+
+func (*LabelPair) ProtoMessage() {}
+
+func (x *LabelPair) ProtoReflect() protoreflect.Message {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[0]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
}
-var xxx_messageInfo_LabelPair proto.InternalMessageInfo
+// Deprecated: Use LabelPair.ProtoReflect.Descriptor instead.
+func (*LabelPair) Descriptor() ([]byte, []int) {
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{0}
+}
-func (m *LabelPair) GetName() string {
- if m != nil && m.Name != nil {
- return *m.Name
+func (x *LabelPair) GetName() string {
+ if x != nil && x.Name != nil {
+ return *x.Name
}
return ""
}
-func (m *LabelPair) GetValue() string {
- if m != nil && m.Value != nil {
- return *m.Value
+func (x *LabelPair) GetValue() string {
+ if x != nil && x.Value != nil {
+ return *x.Value
}
return ""
}
type Gauge struct {
- Value *float64 `protobuf:"fixed64,1,opt,name=value" json:"value,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
-func (m *Gauge) Reset() { *m = Gauge{} }
-func (m *Gauge) String() string { return proto.CompactTextString(m) }
-func (*Gauge) ProtoMessage() {}
-func (*Gauge) Descriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{1}
+ Value *float64 `protobuf:"fixed64,1,opt,name=value" json:"value,omitempty"`
}
-func (m *Gauge) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_Gauge.Unmarshal(m, b)
-}
-func (m *Gauge) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_Gauge.Marshal(b, m, deterministic)
-}
-func (m *Gauge) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Gauge.Merge(m, src)
+func (x *Gauge) Reset() {
+ *x = Gauge{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[1]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
}
-func (m *Gauge) XXX_Size() int {
- return xxx_messageInfo_Gauge.Size(m)
+
+func (x *Gauge) String() string {
+ return protoimpl.X.MessageStringOf(x)
}
-func (m *Gauge) XXX_DiscardUnknown() {
- xxx_messageInfo_Gauge.DiscardUnknown(m)
+
+func (*Gauge) ProtoMessage() {}
+
+func (x *Gauge) ProtoReflect() protoreflect.Message {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[1]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
}
-var xxx_messageInfo_Gauge proto.InternalMessageInfo
+// Deprecated: Use Gauge.ProtoReflect.Descriptor instead.
+func (*Gauge) Descriptor() ([]byte, []int) {
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{1}
+}
-func (m *Gauge) GetValue() float64 {
- if m != nil && m.Value != nil {
- return *m.Value
+func (x *Gauge) GetValue() float64 {
+ if x != nil && x.Value != nil {
+ return *x.Value
}
return 0
}
type Counter struct {
- Value *float64 `protobuf:"fixed64,1,opt,name=value" json:"value,omitempty"`
- Exemplar *Exemplar `protobuf:"bytes,2,opt,name=exemplar" json:"exemplar,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
-func (m *Counter) Reset() { *m = Counter{} }
-func (m *Counter) String() string { return proto.CompactTextString(m) }
-func (*Counter) ProtoMessage() {}
-func (*Counter) Descriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{2}
+ Value *float64 `protobuf:"fixed64,1,opt,name=value" json:"value,omitempty"`
+ Exemplar *Exemplar `protobuf:"bytes,2,opt,name=exemplar" json:"exemplar,omitempty"`
}
-func (m *Counter) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_Counter.Unmarshal(m, b)
-}
-func (m *Counter) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_Counter.Marshal(b, m, deterministic)
-}
-func (m *Counter) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Counter.Merge(m, src)
+func (x *Counter) Reset() {
+ *x = Counter{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[2]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
}
-func (m *Counter) XXX_Size() int {
- return xxx_messageInfo_Counter.Size(m)
+
+func (x *Counter) String() string {
+ return protoimpl.X.MessageStringOf(x)
}
-func (m *Counter) XXX_DiscardUnknown() {
- xxx_messageInfo_Counter.DiscardUnknown(m)
+
+func (*Counter) ProtoMessage() {}
+
+func (x *Counter) ProtoReflect() protoreflect.Message {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[2]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
}
-var xxx_messageInfo_Counter proto.InternalMessageInfo
+// Deprecated: Use Counter.ProtoReflect.Descriptor instead.
+func (*Counter) Descriptor() ([]byte, []int) {
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{2}
+}
-func (m *Counter) GetValue() float64 {
- if m != nil && m.Value != nil {
- return *m.Value
+func (x *Counter) GetValue() float64 {
+ if x != nil && x.Value != nil {
+ return *x.Value
}
return 0
}
-func (m *Counter) GetExemplar() *Exemplar {
- if m != nil {
- return m.Exemplar
+func (x *Counter) GetExemplar() *Exemplar {
+ if x != nil {
+ return x.Exemplar
}
return nil
}
type Quantile struct {
- Quantile *float64 `protobuf:"fixed64,1,opt,name=quantile" json:"quantile,omitempty"`
- Value *float64 `protobuf:"fixed64,2,opt,name=value" json:"value,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
-func (m *Quantile) Reset() { *m = Quantile{} }
-func (m *Quantile) String() string { return proto.CompactTextString(m) }
-func (*Quantile) ProtoMessage() {}
-func (*Quantile) Descriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{3}
+ Quantile *float64 `protobuf:"fixed64,1,opt,name=quantile" json:"quantile,omitempty"`
+ Value *float64 `protobuf:"fixed64,2,opt,name=value" json:"value,omitempty"`
}
-func (m *Quantile) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_Quantile.Unmarshal(m, b)
-}
-func (m *Quantile) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_Quantile.Marshal(b, m, deterministic)
-}
-func (m *Quantile) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Quantile.Merge(m, src)
+func (x *Quantile) Reset() {
+ *x = Quantile{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[3]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
}
-func (m *Quantile) XXX_Size() int {
- return xxx_messageInfo_Quantile.Size(m)
+
+func (x *Quantile) String() string {
+ return protoimpl.X.MessageStringOf(x)
}
-func (m *Quantile) XXX_DiscardUnknown() {
- xxx_messageInfo_Quantile.DiscardUnknown(m)
+
+func (*Quantile) ProtoMessage() {}
+
+func (x *Quantile) ProtoReflect() protoreflect.Message {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[3]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
}
-var xxx_messageInfo_Quantile proto.InternalMessageInfo
+// Deprecated: Use Quantile.ProtoReflect.Descriptor instead.
+func (*Quantile) Descriptor() ([]byte, []int) {
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{3}
+}
-func (m *Quantile) GetQuantile() float64 {
- if m != nil && m.Quantile != nil {
- return *m.Quantile
+func (x *Quantile) GetQuantile() float64 {
+ if x != nil && x.Quantile != nil {
+ return *x.Quantile
}
return 0
}
-func (m *Quantile) GetValue() float64 {
- if m != nil && m.Value != nil {
- return *m.Value
+func (x *Quantile) GetValue() float64 {
+ if x != nil && x.Value != nil {
+ return *x.Value
}
return 0
}
type Summary struct {
- SampleCount *uint64 `protobuf:"varint,1,opt,name=sample_count,json=sampleCount" json:"sample_count,omitempty"`
- SampleSum *float64 `protobuf:"fixed64,2,opt,name=sample_sum,json=sampleSum" json:"sample_sum,omitempty"`
- Quantile []*Quantile `protobuf:"bytes,3,rep,name=quantile" json:"quantile,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
-func (m *Summary) Reset() { *m = Summary{} }
-func (m *Summary) String() string { return proto.CompactTextString(m) }
-func (*Summary) ProtoMessage() {}
-func (*Summary) Descriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{4}
+ SampleCount *uint64 `protobuf:"varint,1,opt,name=sample_count,json=sampleCount" json:"sample_count,omitempty"`
+ SampleSum *float64 `protobuf:"fixed64,2,opt,name=sample_sum,json=sampleSum" json:"sample_sum,omitempty"`
+ Quantile []*Quantile `protobuf:"bytes,3,rep,name=quantile" json:"quantile,omitempty"`
}
-func (m *Summary) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_Summary.Unmarshal(m, b)
-}
-func (m *Summary) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_Summary.Marshal(b, m, deterministic)
-}
-func (m *Summary) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Summary.Merge(m, src)
+func (x *Summary) Reset() {
+ *x = Summary{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[4]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
}
-func (m *Summary) XXX_Size() int {
- return xxx_messageInfo_Summary.Size(m)
+
+func (x *Summary) String() string {
+ return protoimpl.X.MessageStringOf(x)
}
-func (m *Summary) XXX_DiscardUnknown() {
- xxx_messageInfo_Summary.DiscardUnknown(m)
+
+func (*Summary) ProtoMessage() {}
+
+func (x *Summary) ProtoReflect() protoreflect.Message {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[4]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
}
-var xxx_messageInfo_Summary proto.InternalMessageInfo
+// Deprecated: Use Summary.ProtoReflect.Descriptor instead.
+func (*Summary) Descriptor() ([]byte, []int) {
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{4}
+}
-func (m *Summary) GetSampleCount() uint64 {
- if m != nil && m.SampleCount != nil {
- return *m.SampleCount
+func (x *Summary) GetSampleCount() uint64 {
+ if x != nil && x.SampleCount != nil {
+ return *x.SampleCount
}
return 0
}
-func (m *Summary) GetSampleSum() float64 {
- if m != nil && m.SampleSum != nil {
- return *m.SampleSum
+func (x *Summary) GetSampleSum() float64 {
+ if x != nil && x.SampleSum != nil {
+ return *x.SampleSum
}
return 0
}
-func (m *Summary) GetQuantile() []*Quantile {
- if m != nil {
- return m.Quantile
+func (x *Summary) GetQuantile() []*Quantile {
+ if x != nil {
+ return x.Quantile
}
return nil
}
type Untyped struct {
- Value *float64 `protobuf:"fixed64,1,opt,name=value" json:"value,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
-func (m *Untyped) Reset() { *m = Untyped{} }
-func (m *Untyped) String() string { return proto.CompactTextString(m) }
-func (*Untyped) ProtoMessage() {}
-func (*Untyped) Descriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{5}
+ Value *float64 `protobuf:"fixed64,1,opt,name=value" json:"value,omitempty"`
}
-func (m *Untyped) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_Untyped.Unmarshal(m, b)
-}
-func (m *Untyped) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_Untyped.Marshal(b, m, deterministic)
-}
-func (m *Untyped) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Untyped.Merge(m, src)
+func (x *Untyped) Reset() {
+ *x = Untyped{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[5]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
}
-func (m *Untyped) XXX_Size() int {
- return xxx_messageInfo_Untyped.Size(m)
+
+func (x *Untyped) String() string {
+ return protoimpl.X.MessageStringOf(x)
}
-func (m *Untyped) XXX_DiscardUnknown() {
- xxx_messageInfo_Untyped.DiscardUnknown(m)
+
+func (*Untyped) ProtoMessage() {}
+
+func (x *Untyped) ProtoReflect() protoreflect.Message {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[5]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
}
-var xxx_messageInfo_Untyped proto.InternalMessageInfo
+// Deprecated: Use Untyped.ProtoReflect.Descriptor instead.
+func (*Untyped) Descriptor() ([]byte, []int) {
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{5}
+}
-func (m *Untyped) GetValue() float64 {
- if m != nil && m.Value != nil {
- return *m.Value
+func (x *Untyped) GetValue() float64 {
+ if x != nil && x.Value != nil {
+ return *x.Value
}
return 0
}
type Histogram struct {
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
SampleCount *uint64 `protobuf:"varint,1,opt,name=sample_count,json=sampleCount" json:"sample_count,omitempty"`
- SampleCountFloat *float64 `protobuf:"fixed64,4,opt,name=sample_count_float,json=sampleCountFloat" json:"sample_count_float,omitempty"`
+ SampleCountFloat *float64 `protobuf:"fixed64,4,opt,name=sample_count_float,json=sampleCountFloat" json:"sample_count_float,omitempty"` // Overrides sample_count if > 0.
SampleSum *float64 `protobuf:"fixed64,2,opt,name=sample_sum,json=sampleSum" json:"sample_sum,omitempty"`
// Buckets for the conventional histogram.
- Bucket []*Bucket `protobuf:"bytes,3,rep,name=bucket" json:"bucket,omitempty"`
+ Bucket []*Bucket `protobuf:"bytes,3,rep,name=bucket" json:"bucket,omitempty"` // Ordered in increasing order of upper_bound, +Inf bucket is optional.
// schema defines the bucket schema. Currently, valid numbers are -4 <= n <= 8.
// They are all for base-2 bucket schemas, where 1 is a bucket boundary in each case, and
// then each power of two is divided into 2^n logarithmic buckets.
// Or in other words, each bucket boundary is the previous boundary times 2^(2^-n).
// In the future, more bucket schemas may be added using numbers < -4 or > 8.
Schema *int32 `protobuf:"zigzag32,5,opt,name=schema" json:"schema,omitempty"`
- ZeroThreshold *float64 `protobuf:"fixed64,6,opt,name=zero_threshold,json=zeroThreshold" json:"zero_threshold,omitempty"`
- ZeroCount *uint64 `protobuf:"varint,7,opt,name=zero_count,json=zeroCount" json:"zero_count,omitempty"`
- ZeroCountFloat *float64 `protobuf:"fixed64,8,opt,name=zero_count_float,json=zeroCountFloat" json:"zero_count_float,omitempty"`
+ ZeroThreshold *float64 `protobuf:"fixed64,6,opt,name=zero_threshold,json=zeroThreshold" json:"zero_threshold,omitempty"` // Breadth of the zero bucket.
+ ZeroCount *uint64 `protobuf:"varint,7,opt,name=zero_count,json=zeroCount" json:"zero_count,omitempty"` // Count in zero bucket.
+ ZeroCountFloat *float64 `protobuf:"fixed64,8,opt,name=zero_count_float,json=zeroCountFloat" json:"zero_count_float,omitempty"` // Overrides sb_zero_count if > 0.
// Negative buckets for the native histogram.
NegativeSpan []*BucketSpan `protobuf:"bytes,9,rep,name=negative_span,json=negativeSpan" json:"negative_span,omitempty"`
// Use either "negative_delta" or "negative_count", the former for
// regular histograms with integer counts, the latter for float
// histograms.
- NegativeDelta []int64 `protobuf:"zigzag64,10,rep,name=negative_delta,json=negativeDelta" json:"negative_delta,omitempty"`
- NegativeCount []float64 `protobuf:"fixed64,11,rep,name=negative_count,json=negativeCount" json:"negative_count,omitempty"`
+ NegativeDelta []int64 `protobuf:"zigzag64,10,rep,name=negative_delta,json=negativeDelta" json:"negative_delta,omitempty"` // Count delta of each bucket compared to previous one (or to zero for 1st bucket).
+ NegativeCount []float64 `protobuf:"fixed64,11,rep,name=negative_count,json=negativeCount" json:"negative_count,omitempty"` // Absolute count of each bucket.
// Positive buckets for the native histogram.
PositiveSpan []*BucketSpan `protobuf:"bytes,12,rep,name=positive_span,json=positiveSpan" json:"positive_span,omitempty"`
// Use either "positive_delta" or "positive_count", the former for
// regular histograms with integer counts, the latter for float
// histograms.
- PositiveDelta []int64 `protobuf:"zigzag64,13,rep,name=positive_delta,json=positiveDelta" json:"positive_delta,omitempty"`
- PositiveCount []float64 `protobuf:"fixed64,14,rep,name=positive_count,json=positiveCount" json:"positive_count,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
+ PositiveDelta []int64 `protobuf:"zigzag64,13,rep,name=positive_delta,json=positiveDelta" json:"positive_delta,omitempty"` // Count delta of each bucket compared to previous one (or to zero for 1st bucket).
+ PositiveCount []float64 `protobuf:"fixed64,14,rep,name=positive_count,json=positiveCount" json:"positive_count,omitempty"` // Absolute count of each bucket.
}
-func (m *Histogram) Reset() { *m = Histogram{} }
-func (m *Histogram) String() string { return proto.CompactTextString(m) }
-func (*Histogram) ProtoMessage() {}
-func (*Histogram) Descriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{6}
+func (x *Histogram) Reset() {
+ *x = Histogram{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[6]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
}
-func (m *Histogram) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_Histogram.Unmarshal(m, b)
+func (x *Histogram) String() string {
+ return protoimpl.X.MessageStringOf(x)
}
-func (m *Histogram) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_Histogram.Marshal(b, m, deterministic)
-}
-func (m *Histogram) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Histogram.Merge(m, src)
-}
-func (m *Histogram) XXX_Size() int {
- return xxx_messageInfo_Histogram.Size(m)
-}
-func (m *Histogram) XXX_DiscardUnknown() {
- xxx_messageInfo_Histogram.DiscardUnknown(m)
+
+func (*Histogram) ProtoMessage() {}
+
+func (x *Histogram) ProtoReflect() protoreflect.Message {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[6]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
}
-var xxx_messageInfo_Histogram proto.InternalMessageInfo
+// Deprecated: Use Histogram.ProtoReflect.Descriptor instead.
+func (*Histogram) Descriptor() ([]byte, []int) {
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{6}
+}
-func (m *Histogram) GetSampleCount() uint64 {
- if m != nil && m.SampleCount != nil {
- return *m.SampleCount
+func (x *Histogram) GetSampleCount() uint64 {
+ if x != nil && x.SampleCount != nil {
+ return *x.SampleCount
}
return 0
}
-func (m *Histogram) GetSampleCountFloat() float64 {
- if m != nil && m.SampleCountFloat != nil {
- return *m.SampleCountFloat
+func (x *Histogram) GetSampleCountFloat() float64 {
+ if x != nil && x.SampleCountFloat != nil {
+ return *x.SampleCountFloat
}
return 0
}
-func (m *Histogram) GetSampleSum() float64 {
- if m != nil && m.SampleSum != nil {
- return *m.SampleSum
+func (x *Histogram) GetSampleSum() float64 {
+ if x != nil && x.SampleSum != nil {
+ return *x.SampleSum
}
return 0
}
-func (m *Histogram) GetBucket() []*Bucket {
- if m != nil {
- return m.Bucket
+func (x *Histogram) GetBucket() []*Bucket {
+ if x != nil {
+ return x.Bucket
}
return nil
}
-func (m *Histogram) GetSchema() int32 {
- if m != nil && m.Schema != nil {
- return *m.Schema
+func (x *Histogram) GetSchema() int32 {
+ if x != nil && x.Schema != nil {
+ return *x.Schema
}
return 0
}
-func (m *Histogram) GetZeroThreshold() float64 {
- if m != nil && m.ZeroThreshold != nil {
- return *m.ZeroThreshold
+func (x *Histogram) GetZeroThreshold() float64 {
+ if x != nil && x.ZeroThreshold != nil {
+ return *x.ZeroThreshold
}
return 0
}
-func (m *Histogram) GetZeroCount() uint64 {
- if m != nil && m.ZeroCount != nil {
- return *m.ZeroCount
+func (x *Histogram) GetZeroCount() uint64 {
+ if x != nil && x.ZeroCount != nil {
+ return *x.ZeroCount
}
return 0
}
-func (m *Histogram) GetZeroCountFloat() float64 {
- if m != nil && m.ZeroCountFloat != nil {
- return *m.ZeroCountFloat
+func (x *Histogram) GetZeroCountFloat() float64 {
+ if x != nil && x.ZeroCountFloat != nil {
+ return *x.ZeroCountFloat
}
return 0
}
-func (m *Histogram) GetNegativeSpan() []*BucketSpan {
- if m != nil {
- return m.NegativeSpan
+func (x *Histogram) GetNegativeSpan() []*BucketSpan {
+ if x != nil {
+ return x.NegativeSpan
}
return nil
}
-func (m *Histogram) GetNegativeDelta() []int64 {
- if m != nil {
- return m.NegativeDelta
+func (x *Histogram) GetNegativeDelta() []int64 {
+ if x != nil {
+ return x.NegativeDelta
}
return nil
}
-func (m *Histogram) GetNegativeCount() []float64 {
- if m != nil {
- return m.NegativeCount
+func (x *Histogram) GetNegativeCount() []float64 {
+ if x != nil {
+ return x.NegativeCount
}
return nil
}
-func (m *Histogram) GetPositiveSpan() []*BucketSpan {
- if m != nil {
- return m.PositiveSpan
+func (x *Histogram) GetPositiveSpan() []*BucketSpan {
+ if x != nil {
+ return x.PositiveSpan
}
return nil
}
-func (m *Histogram) GetPositiveDelta() []int64 {
- if m != nil {
- return m.PositiveDelta
+func (x *Histogram) GetPositiveDelta() []int64 {
+ if x != nil {
+ return x.PositiveDelta
}
return nil
}
-func (m *Histogram) GetPositiveCount() []float64 {
- if m != nil {
- return m.PositiveCount
+func (x *Histogram) GetPositiveCount() []float64 {
+ if x != nil {
+ return x.PositiveCount
}
return nil
}
@@ -513,64 +598,72 @@ func (m *Histogram) GetPositiveCount() []float64 {
// A Bucket of a conventional histogram, each of which is treated as
// an individual counter-like time series by Prometheus.
type Bucket struct {
- CumulativeCount *uint64 `protobuf:"varint,1,opt,name=cumulative_count,json=cumulativeCount" json:"cumulative_count,omitempty"`
- CumulativeCountFloat *float64 `protobuf:"fixed64,4,opt,name=cumulative_count_float,json=cumulativeCountFloat" json:"cumulative_count_float,omitempty"`
- UpperBound *float64 `protobuf:"fixed64,2,opt,name=upper_bound,json=upperBound" json:"upper_bound,omitempty"`
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ CumulativeCount *uint64 `protobuf:"varint,1,opt,name=cumulative_count,json=cumulativeCount" json:"cumulative_count,omitempty"` // Cumulative in increasing order.
+ CumulativeCountFloat *float64 `protobuf:"fixed64,4,opt,name=cumulative_count_float,json=cumulativeCountFloat" json:"cumulative_count_float,omitempty"` // Overrides cumulative_count if > 0.
+ UpperBound *float64 `protobuf:"fixed64,2,opt,name=upper_bound,json=upperBound" json:"upper_bound,omitempty"` // Inclusive.
Exemplar *Exemplar `protobuf:"bytes,3,opt,name=exemplar" json:"exemplar,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
}
-func (m *Bucket) Reset() { *m = Bucket{} }
-func (m *Bucket) String() string { return proto.CompactTextString(m) }
-func (*Bucket) ProtoMessage() {}
-func (*Bucket) Descriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{7}
+func (x *Bucket) Reset() {
+ *x = Bucket{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[7]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
}
-func (m *Bucket) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_Bucket.Unmarshal(m, b)
-}
-func (m *Bucket) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_Bucket.Marshal(b, m, deterministic)
-}
-func (m *Bucket) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Bucket.Merge(m, src)
-}
-func (m *Bucket) XXX_Size() int {
- return xxx_messageInfo_Bucket.Size(m)
+func (x *Bucket) String() string {
+ return protoimpl.X.MessageStringOf(x)
}
-func (m *Bucket) XXX_DiscardUnknown() {
- xxx_messageInfo_Bucket.DiscardUnknown(m)
+
+func (*Bucket) ProtoMessage() {}
+
+func (x *Bucket) ProtoReflect() protoreflect.Message {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[7]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
}
-var xxx_messageInfo_Bucket proto.InternalMessageInfo
+// Deprecated: Use Bucket.ProtoReflect.Descriptor instead.
+func (*Bucket) Descriptor() ([]byte, []int) {
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{7}
+}
-func (m *Bucket) GetCumulativeCount() uint64 {
- if m != nil && m.CumulativeCount != nil {
- return *m.CumulativeCount
+func (x *Bucket) GetCumulativeCount() uint64 {
+ if x != nil && x.CumulativeCount != nil {
+ return *x.CumulativeCount
}
return 0
}
-func (m *Bucket) GetCumulativeCountFloat() float64 {
- if m != nil && m.CumulativeCountFloat != nil {
- return *m.CumulativeCountFloat
+func (x *Bucket) GetCumulativeCountFloat() float64 {
+ if x != nil && x.CumulativeCountFloat != nil {
+ return *x.CumulativeCountFloat
}
return 0
}
-func (m *Bucket) GetUpperBound() float64 {
- if m != nil && m.UpperBound != nil {
- return *m.UpperBound
+func (x *Bucket) GetUpperBound() float64 {
+ if x != nil && x.UpperBound != nil {
+ return *x.UpperBound
}
return 0
}
-func (m *Bucket) GetExemplar() *Exemplar {
- if m != nil {
- return m.Exemplar
+func (x *Bucket) GetExemplar() *Exemplar {
+ if x != nil {
+ return x.Exemplar
}
return nil
}
@@ -582,333 +675,658 @@ func (m *Bucket) GetExemplar() *Exemplar {
// structured here (with all the buckets in a single array separate
// from the Spans).
type BucketSpan struct {
- Offset *int32 `protobuf:"zigzag32,1,opt,name=offset" json:"offset,omitempty"`
- Length *uint32 `protobuf:"varint,2,opt,name=length" json:"length,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
-func (m *BucketSpan) Reset() { *m = BucketSpan{} }
-func (m *BucketSpan) String() string { return proto.CompactTextString(m) }
-func (*BucketSpan) ProtoMessage() {}
-func (*BucketSpan) Descriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{8}
+ Offset *int32 `protobuf:"zigzag32,1,opt,name=offset" json:"offset,omitempty"` // Gap to previous span, or starting point for 1st span (which can be negative).
+ Length *uint32 `protobuf:"varint,2,opt,name=length" json:"length,omitempty"` // Length of consecutive buckets.
}
-func (m *BucketSpan) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_BucketSpan.Unmarshal(m, b)
-}
-func (m *BucketSpan) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_BucketSpan.Marshal(b, m, deterministic)
-}
-func (m *BucketSpan) XXX_Merge(src proto.Message) {
- xxx_messageInfo_BucketSpan.Merge(m, src)
+func (x *BucketSpan) Reset() {
+ *x = BucketSpan{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[8]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
}
-func (m *BucketSpan) XXX_Size() int {
- return xxx_messageInfo_BucketSpan.Size(m)
+
+func (x *BucketSpan) String() string {
+ return protoimpl.X.MessageStringOf(x)
}
-func (m *BucketSpan) XXX_DiscardUnknown() {
- xxx_messageInfo_BucketSpan.DiscardUnknown(m)
+
+func (*BucketSpan) ProtoMessage() {}
+
+func (x *BucketSpan) ProtoReflect() protoreflect.Message {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[8]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
}
-var xxx_messageInfo_BucketSpan proto.InternalMessageInfo
+// Deprecated: Use BucketSpan.ProtoReflect.Descriptor instead.
+func (*BucketSpan) Descriptor() ([]byte, []int) {
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{8}
+}
-func (m *BucketSpan) GetOffset() int32 {
- if m != nil && m.Offset != nil {
- return *m.Offset
+func (x *BucketSpan) GetOffset() int32 {
+ if x != nil && x.Offset != nil {
+ return *x.Offset
}
return 0
}
-func (m *BucketSpan) GetLength() uint32 {
- if m != nil && m.Length != nil {
- return *m.Length
+func (x *BucketSpan) GetLength() uint32 {
+ if x != nil && x.Length != nil {
+ return *x.Length
}
return 0
}
type Exemplar struct {
- Label []*LabelPair `protobuf:"bytes,1,rep,name=label" json:"label,omitempty"`
- Value *float64 `protobuf:"fixed64,2,opt,name=value" json:"value,omitempty"`
- Timestamp *timestamp.Timestamp `protobuf:"bytes,3,opt,name=timestamp" json:"timestamp,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
-func (m *Exemplar) Reset() { *m = Exemplar{} }
-func (m *Exemplar) String() string { return proto.CompactTextString(m) }
-func (*Exemplar) ProtoMessage() {}
-func (*Exemplar) Descriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{9}
+ Label []*LabelPair `protobuf:"bytes,1,rep,name=label" json:"label,omitempty"`
+ Value *float64 `protobuf:"fixed64,2,opt,name=value" json:"value,omitempty"`
+ Timestamp *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=timestamp" json:"timestamp,omitempty"` // OpenMetrics-style.
}
-func (m *Exemplar) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_Exemplar.Unmarshal(m, b)
-}
-func (m *Exemplar) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_Exemplar.Marshal(b, m, deterministic)
-}
-func (m *Exemplar) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Exemplar.Merge(m, src)
+func (x *Exemplar) Reset() {
+ *x = Exemplar{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[9]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
}
-func (m *Exemplar) XXX_Size() int {
- return xxx_messageInfo_Exemplar.Size(m)
+
+func (x *Exemplar) String() string {
+ return protoimpl.X.MessageStringOf(x)
}
-func (m *Exemplar) XXX_DiscardUnknown() {
- xxx_messageInfo_Exemplar.DiscardUnknown(m)
+
+func (*Exemplar) ProtoMessage() {}
+
+func (x *Exemplar) ProtoReflect() protoreflect.Message {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[9]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
}
-var xxx_messageInfo_Exemplar proto.InternalMessageInfo
+// Deprecated: Use Exemplar.ProtoReflect.Descriptor instead.
+func (*Exemplar) Descriptor() ([]byte, []int) {
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{9}
+}
-func (m *Exemplar) GetLabel() []*LabelPair {
- if m != nil {
- return m.Label
+func (x *Exemplar) GetLabel() []*LabelPair {
+ if x != nil {
+ return x.Label
}
return nil
}
-func (m *Exemplar) GetValue() float64 {
- if m != nil && m.Value != nil {
- return *m.Value
+func (x *Exemplar) GetValue() float64 {
+ if x != nil && x.Value != nil {
+ return *x.Value
}
return 0
}
-func (m *Exemplar) GetTimestamp() *timestamp.Timestamp {
- if m != nil {
- return m.Timestamp
+func (x *Exemplar) GetTimestamp() *timestamppb.Timestamp {
+ if x != nil {
+ return x.Timestamp
}
return nil
}
type Metric struct {
- Label []*LabelPair `protobuf:"bytes,1,rep,name=label" json:"label,omitempty"`
- Gauge *Gauge `protobuf:"bytes,2,opt,name=gauge" json:"gauge,omitempty"`
- Counter *Counter `protobuf:"bytes,3,opt,name=counter" json:"counter,omitempty"`
- Summary *Summary `protobuf:"bytes,4,opt,name=summary" json:"summary,omitempty"`
- Untyped *Untyped `protobuf:"bytes,5,opt,name=untyped" json:"untyped,omitempty"`
- Histogram *Histogram `protobuf:"bytes,7,opt,name=histogram" json:"histogram,omitempty"`
- TimestampMs *int64 `protobuf:"varint,6,opt,name=timestamp_ms,json=timestampMs" json:"timestamp_ms,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *Metric) Reset() { *m = Metric{} }
-func (m *Metric) String() string { return proto.CompactTextString(m) }
-func (*Metric) ProtoMessage() {}
-func (*Metric) Descriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{10}
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Label []*LabelPair `protobuf:"bytes,1,rep,name=label" json:"label,omitempty"`
+ Gauge *Gauge `protobuf:"bytes,2,opt,name=gauge" json:"gauge,omitempty"`
+ Counter *Counter `protobuf:"bytes,3,opt,name=counter" json:"counter,omitempty"`
+ Summary *Summary `protobuf:"bytes,4,opt,name=summary" json:"summary,omitempty"`
+ Untyped *Untyped `protobuf:"bytes,5,opt,name=untyped" json:"untyped,omitempty"`
+ Histogram *Histogram `protobuf:"bytes,7,opt,name=histogram" json:"histogram,omitempty"`
+ TimestampMs *int64 `protobuf:"varint,6,opt,name=timestamp_ms,json=timestampMs" json:"timestamp_ms,omitempty"`
+}
+
+func (x *Metric) Reset() {
+ *x = Metric{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[10]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
}
-func (m *Metric) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_Metric.Unmarshal(m, b)
+func (x *Metric) String() string {
+ return protoimpl.X.MessageStringOf(x)
}
-func (m *Metric) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_Metric.Marshal(b, m, deterministic)
-}
-func (m *Metric) XXX_Merge(src proto.Message) {
- xxx_messageInfo_Metric.Merge(m, src)
-}
-func (m *Metric) XXX_Size() int {
- return xxx_messageInfo_Metric.Size(m)
-}
-func (m *Metric) XXX_DiscardUnknown() {
- xxx_messageInfo_Metric.DiscardUnknown(m)
+
+func (*Metric) ProtoMessage() {}
+
+func (x *Metric) ProtoReflect() protoreflect.Message {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[10]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
}
-var xxx_messageInfo_Metric proto.InternalMessageInfo
+// Deprecated: Use Metric.ProtoReflect.Descriptor instead.
+func (*Metric) Descriptor() ([]byte, []int) {
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{10}
+}
-func (m *Metric) GetLabel() []*LabelPair {
- if m != nil {
- return m.Label
+func (x *Metric) GetLabel() []*LabelPair {
+ if x != nil {
+ return x.Label
}
return nil
}
-func (m *Metric) GetGauge() *Gauge {
- if m != nil {
- return m.Gauge
+func (x *Metric) GetGauge() *Gauge {
+ if x != nil {
+ return x.Gauge
}
return nil
}
-func (m *Metric) GetCounter() *Counter {
- if m != nil {
- return m.Counter
+func (x *Metric) GetCounter() *Counter {
+ if x != nil {
+ return x.Counter
}
return nil
}
-func (m *Metric) GetSummary() *Summary {
- if m != nil {
- return m.Summary
+func (x *Metric) GetSummary() *Summary {
+ if x != nil {
+ return x.Summary
}
return nil
}
-func (m *Metric) GetUntyped() *Untyped {
- if m != nil {
- return m.Untyped
+func (x *Metric) GetUntyped() *Untyped {
+ if x != nil {
+ return x.Untyped
}
return nil
}
-func (m *Metric) GetHistogram() *Histogram {
- if m != nil {
- return m.Histogram
+func (x *Metric) GetHistogram() *Histogram {
+ if x != nil {
+ return x.Histogram
}
return nil
}
-func (m *Metric) GetTimestampMs() int64 {
- if m != nil && m.TimestampMs != nil {
- return *m.TimestampMs
+func (x *Metric) GetTimestampMs() int64 {
+ if x != nil && x.TimestampMs != nil {
+ return *x.TimestampMs
}
return 0
}
type MetricFamily struct {
- Name *string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
- Help *string `protobuf:"bytes,2,opt,name=help" json:"help,omitempty"`
- Type *MetricType `protobuf:"varint,3,opt,name=type,enum=io.prometheus.client.MetricType" json:"type,omitempty"`
- Metric []*Metric `protobuf:"bytes,4,rep,name=metric" json:"metric,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
-}
-
-func (m *MetricFamily) Reset() { *m = MetricFamily{} }
-func (m *MetricFamily) String() string { return proto.CompactTextString(m) }
-func (*MetricFamily) ProtoMessage() {}
-func (*MetricFamily) Descriptor() ([]byte, []int) {
- return fileDescriptor_d1e5ddb18987a258, []int{11}
+ state protoimpl.MessageState
+ sizeCache protoimpl.SizeCache
+ unknownFields protoimpl.UnknownFields
+
+ Name *string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
+ Help *string `protobuf:"bytes,2,opt,name=help" json:"help,omitempty"`
+ Type *MetricType `protobuf:"varint,3,opt,name=type,enum=io.prometheus.client.MetricType" json:"type,omitempty"`
+ Metric []*Metric `protobuf:"bytes,4,rep,name=metric" json:"metric,omitempty"`
+}
+
+func (x *MetricFamily) Reset() {
+ *x = MetricFamily{}
+ if protoimpl.UnsafeEnabled {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[11]
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ ms.StoreMessageInfo(mi)
+ }
}
-func (m *MetricFamily) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_MetricFamily.Unmarshal(m, b)
-}
-func (m *MetricFamily) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_MetricFamily.Marshal(b, m, deterministic)
-}
-func (m *MetricFamily) XXX_Merge(src proto.Message) {
- xxx_messageInfo_MetricFamily.Merge(m, src)
-}
-func (m *MetricFamily) XXX_Size() int {
- return xxx_messageInfo_MetricFamily.Size(m)
+func (x *MetricFamily) String() string {
+ return protoimpl.X.MessageStringOf(x)
}
-func (m *MetricFamily) XXX_DiscardUnknown() {
- xxx_messageInfo_MetricFamily.DiscardUnknown(m)
+
+func (*MetricFamily) ProtoMessage() {}
+
+func (x *MetricFamily) ProtoReflect() protoreflect.Message {
+ mi := &file_io_prometheus_client_metrics_proto_msgTypes[11]
+ if protoimpl.UnsafeEnabled && x != nil {
+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+ if ms.LoadMessageInfo() == nil {
+ ms.StoreMessageInfo(mi)
+ }
+ return ms
+ }
+ return mi.MessageOf(x)
}
-var xxx_messageInfo_MetricFamily proto.InternalMessageInfo
+// Deprecated: Use MetricFamily.ProtoReflect.Descriptor instead.
+func (*MetricFamily) Descriptor() ([]byte, []int) {
+ return file_io_prometheus_client_metrics_proto_rawDescGZIP(), []int{11}
+}
-func (m *MetricFamily) GetName() string {
- if m != nil && m.Name != nil {
- return *m.Name
+func (x *MetricFamily) GetName() string {
+ if x != nil && x.Name != nil {
+ return *x.Name
}
return ""
}
-func (m *MetricFamily) GetHelp() string {
- if m != nil && m.Help != nil {
- return *m.Help
+func (x *MetricFamily) GetHelp() string {
+ if x != nil && x.Help != nil {
+ return *x.Help
}
return ""
}
-func (m *MetricFamily) GetType() MetricType {
- if m != nil && m.Type != nil {
- return *m.Type
+func (x *MetricFamily) GetType() MetricType {
+ if x != nil && x.Type != nil {
+ return *x.Type
}
return MetricType_COUNTER
}
-func (m *MetricFamily) GetMetric() []*Metric {
- if m != nil {
- return m.Metric
+func (x *MetricFamily) GetMetric() []*Metric {
+ if x != nil {
+ return x.Metric
}
return nil
}
-func init() {
- proto.RegisterEnum("io.prometheus.client.MetricType", MetricType_name, MetricType_value)
- proto.RegisterType((*LabelPair)(nil), "io.prometheus.client.LabelPair")
- proto.RegisterType((*Gauge)(nil), "io.prometheus.client.Gauge")
- proto.RegisterType((*Counter)(nil), "io.prometheus.client.Counter")
- proto.RegisterType((*Quantile)(nil), "io.prometheus.client.Quantile")
- proto.RegisterType((*Summary)(nil), "io.prometheus.client.Summary")
- proto.RegisterType((*Untyped)(nil), "io.prometheus.client.Untyped")
- proto.RegisterType((*Histogram)(nil), "io.prometheus.client.Histogram")
- proto.RegisterType((*Bucket)(nil), "io.prometheus.client.Bucket")
- proto.RegisterType((*BucketSpan)(nil), "io.prometheus.client.BucketSpan")
- proto.RegisterType((*Exemplar)(nil), "io.prometheus.client.Exemplar")
- proto.RegisterType((*Metric)(nil), "io.prometheus.client.Metric")
- proto.RegisterType((*MetricFamily)(nil), "io.prometheus.client.MetricFamily")
-}
-
-func init() {
- proto.RegisterFile("io/prometheus/client/metrics.proto", fileDescriptor_d1e5ddb18987a258)
-}
-
-var fileDescriptor_d1e5ddb18987a258 = []byte{
- // 896 bytes of a gzipped FileDescriptorProto
- 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x56, 0xdd, 0x8e, 0xdb, 0x44,
- 0x18, 0xc5, 0x9b, 0x5f, 0x7f, 0xd9, 0x6c, 0xd3, 0x61, 0x55, 0x59, 0x0b, 0xcb, 0x06, 0x4b, 0x48,
- 0x0b, 0x42, 0x8e, 0x40, 0x5b, 0x81, 0x0a, 0x5c, 0xec, 0xb6, 0xe9, 0x16, 0x89, 0xb4, 0x65, 0x92,
- 0x5c, 0x14, 0x2e, 0xac, 0x49, 0x32, 0xeb, 0x58, 0x78, 0x3c, 0xc6, 0x1e, 0x57, 0x2c, 0x2f, 0xc0,
- 0x35, 0xaf, 0xc0, 0xc3, 0xf0, 0x22, 0x3c, 0x08, 0x68, 0xfe, 0xec, 0xdd, 0xe2, 0x94, 0xd2, 0x3b,
- 0x7f, 0x67, 0xce, 0xf7, 0xcd, 0x39, 0xe3, 0xc9, 0x71, 0xc0, 0x8f, 0xf9, 0x24, 0xcb, 0x39, 0xa3,
- 0x62, 0x4b, 0xcb, 0x62, 0xb2, 0x4e, 0x62, 0x9a, 0x8a, 0x09, 0xa3, 0x22, 0x8f, 0xd7, 0x45, 0x90,
- 0xe5, 0x5c, 0x70, 0x74, 0x18, 0xf3, 0xa0, 0xe6, 0x04, 0x9a, 0x73, 0x74, 0x12, 0x71, 0x1e, 0x25,
- 0x74, 0xa2, 0x38, 0xab, 0xf2, 0x6a, 0x22, 0x62, 0x46, 0x0b, 0x41, 0x58, 0xa6, 0xdb, 0xfc, 0xfb,
- 0xe0, 0x7e, 0x47, 0x56, 0x34, 0x79, 0x4e, 0xe2, 0x1c, 0x21, 0x68, 0xa7, 0x84, 0x51, 0xcf, 0x19,
- 0x3b, 0xa7, 0x2e, 0x56, 0xcf, 0xe8, 0x10, 0x3a, 0x2f, 0x49, 0x52, 0x52, 0x6f, 0x4f, 0x81, 0xba,
- 0xf0, 0x8f, 0xa1, 0x73, 0x49, 0xca, 0xe8, 0xc6, 0xb2, 0xec, 0x71, 0xec, 0xf2, 0x8f, 0xd0, 0x7b,
- 0xc8, 0xcb, 0x54, 0xd0, 0xbc, 0x99, 0x80, 0x1e, 0x40, 0x9f, 0xfe, 0x42, 0x59, 0x96, 0x90, 0x5c,
- 0x0d, 0x1e, 0x7c, 0xfe, 0x41, 0xd0, 0x64, 0x20, 0x98, 0x1a, 0x16, 0xae, 0xf8, 0xfe, 0xd7, 0xd0,
- 0xff, 0xbe, 0x24, 0xa9, 0x88, 0x13, 0x8a, 0x8e, 0xa0, 0xff, 0xb3, 0x79, 0x36, 0x1b, 0x54, 0xf5,
- 0x6d, 0xe5, 0x95, 0xb4, 0xdf, 0x1c, 0xe8, 0xcd, 0x4b, 0xc6, 0x48, 0x7e, 0x8d, 0x3e, 0x84, 0xfd,
- 0x82, 0xb0, 0x2c, 0xa1, 0xe1, 0x5a, 0xaa, 0x55, 0x13, 0xda, 0x78, 0xa0, 0x31, 0x65, 0x00, 0x1d,
- 0x03, 0x18, 0x4a, 0x51, 0x32, 0x33, 0xc9, 0xd5, 0xc8, 0xbc, 0x64, 0xd2, 0x47, 0xb5, 0x7f, 0x6b,
- 0xdc, 0xda, 0xed, 0xc3, 0x2a, 0xae, 0xf5, 0xf9, 0x27, 0xd0, 0x5b, 0xa6, 0xe2, 0x3a, 0xa3, 0x9b,
- 0x1d, 0xa7, 0xf8, 0x57, 0x1b, 0xdc, 0x27, 0x71, 0x21, 0x78, 0x94, 0x13, 0xf6, 0x26, 0x62, 0x3f,
- 0x05, 0x74, 0x93, 0x12, 0x5e, 0x25, 0x9c, 0x08, 0xaf, 0xad, 0x66, 0x8e, 0x6e, 0x10, 0x1f, 0x4b,
- 0xfc, 0xbf, 0xac, 0x9d, 0x41, 0x77, 0x55, 0xae, 0x7f, 0xa2, 0xc2, 0x18, 0x7b, 0xbf, 0xd9, 0xd8,
- 0x85, 0xe2, 0x60, 0xc3, 0x45, 0xf7, 0xa0, 0x5b, 0xac, 0xb7, 0x94, 0x11, 0xaf, 0x33, 0x76, 0x4e,
- 0xef, 0x62, 0x53, 0xa1, 0x8f, 0xe0, 0xe0, 0x57, 0x9a, 0xf3, 0x50, 0x6c, 0x73, 0x5a, 0x6c, 0x79,
- 0xb2, 0xf1, 0xba, 0x6a, 0xc3, 0xa1, 0x44, 0x17, 0x16, 0x94, 0x9a, 0x14, 0x4d, 0x5b, 0xec, 0x29,
- 0x8b, 0xae, 0x44, 0xb4, 0xc1, 0x53, 0x18, 0xd5, 0xcb, 0xc6, 0x5e, 0x5f, 0xcd, 0x39, 0xa8, 0x48,
- 0xda, 0xdc, 0x14, 0x86, 0x29, 0x8d, 0x88, 0x88, 0x5f, 0xd2, 0xb0, 0xc8, 0x48, 0xea, 0xb9, 0xca,
- 0xc4, 0xf8, 0x75, 0x26, 0xe6, 0x19, 0x49, 0xf1, 0xbe, 0x6d, 0x93, 0x95, 0x94, 0x5d, 0x8d, 0xd9,
- 0xd0, 0x44, 0x10, 0x0f, 0xc6, 0xad, 0x53, 0x84, 0xab, 0xe1, 0x8f, 0x24, 0x78, 0x8b, 0xa6, 0xa5,
- 0x0f, 0xc6, 0x2d, 0xe9, 0xce, 0xa2, 0x5a, 0xfe, 0x14, 0x86, 0x19, 0x2f, 0xe2, 0x5a, 0xd4, 0xfe,
- 0x9b, 0x8a, 0xb2, 0x6d, 0x56, 0x54, 0x35, 0x46, 0x8b, 0x1a, 0x6a, 0x51, 0x16, 0xad, 0x44, 0x55,
- 0x34, 0x2d, 0xea, 0x40, 0x8b, 0xb2, 0xa8, 0x12, 0xe5, 0xff, 0xe9, 0x40, 0x57, 0x6f, 0x85, 0x3e,
- 0x86, 0xd1, 0xba, 0x64, 0x65, 0x72, 0xd3, 0x88, 0xbe, 0x66, 0x77, 0x6a, 0x5c, 0x5b, 0x39, 0x83,
- 0x7b, 0xaf, 0x52, 0x6f, 0x5d, 0xb7, 0xc3, 0x57, 0x1a, 0xf4, 0x5b, 0x39, 0x81, 0x41, 0x99, 0x65,
- 0x34, 0x0f, 0x57, 0xbc, 0x4c, 0x37, 0xe6, 0xce, 0x81, 0x82, 0x2e, 0x24, 0x72, 0x2b, 0x17, 0x5a,
- 0xff, 0x3b, 0x17, 0xa0, 0x3e, 0x32, 0x79, 0x11, 0xf9, 0xd5, 0x55, 0x41, 0xb5, 0x83, 0xbb, 0xd8,
- 0x54, 0x12, 0x4f, 0x68, 0x1a, 0x89, 0xad, 0xda, 0x7d, 0x88, 0x4d, 0xe5, 0xff, 0xee, 0x40, 0xdf,
- 0x0e, 0x45, 0xf7, 0xa1, 0x93, 0xc8, 0x54, 0xf4, 0x1c, 0xf5, 0x82, 0x4e, 0x9a, 0x35, 0x54, 0xc1,
- 0x89, 0x35, 0xbb, 0x39, 0x71, 0xd0, 0x97, 0xe0, 0x56, 0xa9, 0x6b, 0x4c, 0x1d, 0x05, 0x3a, 0x97,
- 0x03, 0x9b, 0xcb, 0xc1, 0xc2, 0x32, 0x70, 0x4d, 0xf6, 0xff, 0xde, 0x83, 0xee, 0x4c, 0xa5, 0xfc,
- 0xdb, 0x2a, 0xfa, 0x0c, 0x3a, 0x91, 0xcc, 0x69, 0x13, 0xb2, 0xef, 0x35, 0xb7, 0xa9, 0x28, 0xc7,
- 0x9a, 0x89, 0xbe, 0x80, 0xde, 0x5a, 0x67, 0xb7, 0x11, 0x7b, 0xdc, 0xdc, 0x64, 0x02, 0x1e, 0x5b,
- 0xb6, 0x6c, 0x2c, 0x74, 0xb0, 0xaa, 0x3b, 0xb0, 0xb3, 0xd1, 0xa4, 0x2f, 0xb6, 0x6c, 0xd9, 0x58,
- 0xea, 0x20, 0x54, 0xa1, 0xb1, 0xb3, 0xd1, 0xa4, 0x25, 0xb6, 0x6c, 0xf4, 0x0d, 0xb8, 0x5b, 0x9b,
- 0x8f, 0x2a, 0x2c, 0x76, 0x1e, 0x4c, 0x15, 0xa3, 0xb8, 0xee, 0x90, 0x89, 0x5a, 0x9d, 0x75, 0xc8,
- 0x0a, 0x95, 0x48, 0x2d, 0x3c, 0xa8, 0xb0, 0x59, 0xe1, 0xff, 0xe1, 0xc0, 0xbe, 0x7e, 0x03, 0x8f,
- 0x09, 0x8b, 0x93, 0xeb, 0xc6, 0x4f, 0x24, 0x82, 0xf6, 0x96, 0x26, 0x99, 0xf9, 0x42, 0xaa, 0x67,
- 0x74, 0x06, 0x6d, 0xa9, 0x51, 0x1d, 0xe1, 0xc1, 0xae, 0x5f, 0xb8, 0x9e, 0xbc, 0xb8, 0xce, 0x28,
- 0x56, 0x6c, 0x99, 0xb9, 0xfa, 0xab, 0xee, 0xb5, 0x5f, 0x97, 0xb9, 0xba, 0x0f, 0x1b, 0xee, 0x27,
- 0x2b, 0x80, 0x7a, 0x12, 0x1a, 0x40, 0xef, 0xe1, 0xb3, 0xe5, 0xd3, 0xc5, 0x14, 0x8f, 0xde, 0x41,
- 0x2e, 0x74, 0x2e, 0xcf, 0x97, 0x97, 0xd3, 0x91, 0x23, 0xf1, 0xf9, 0x72, 0x36, 0x3b, 0xc7, 0x2f,
- 0x46, 0x7b, 0xb2, 0x58, 0x3e, 0x5d, 0xbc, 0x78, 0x3e, 0x7d, 0x34, 0x6a, 0xa1, 0x21, 0xb8, 0x4f,
- 0xbe, 0x9d, 0x2f, 0x9e, 0x5d, 0xe2, 0xf3, 0xd9, 0xa8, 0x8d, 0xde, 0x85, 0x3b, 0xaa, 0x27, 0xac,
- 0xc1, 0xce, 0x05, 0x86, 0xc6, 0x3f, 0x18, 0x3f, 0x3c, 0x88, 0x62, 0xb1, 0x2d, 0x57, 0xc1, 0x9a,
- 0xb3, 0x7f, 0xff, 0x45, 0x09, 0x19, 0xdf, 0xd0, 0x64, 0x12, 0xf1, 0xaf, 0x62, 0x1e, 0xd6, 0xab,
- 0xa1, 0x5e, 0xfd, 0x27, 0x00, 0x00, 0xff, 0xff, 0x16, 0x77, 0x81, 0x98, 0xd7, 0x08, 0x00, 0x00,
+var File_io_prometheus_client_metrics_proto protoreflect.FileDescriptor
+
+var file_io_prometheus_client_metrics_proto_rawDesc = []byte{
+ 0x0a, 0x22, 0x69, 0x6f, 0x2f, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73, 0x2f,
+ 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2f, 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x73, 0x2e, 0x70,
+ 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x14, 0x69, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68,
+ 0x65, 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x1a, 0x1f, 0x67, 0x6f, 0x6f, 0x67,
+ 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65,
+ 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x35, 0x0a, 0x09, 0x4c,
+ 0x61, 0x62, 0x65, 0x6c, 0x50, 0x61, 0x69, 0x72, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65,
+ 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c,
+ 0x75, 0x65, 0x22, 0x1d, 0x0a, 0x05, 0x47, 0x61, 0x75, 0x67, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76,
+ 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75,
+ 0x65, 0x22, 0x5b, 0x0a, 0x07, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, 0x52, 0x05, 0x76, 0x61, 0x6c,
+ 0x75, 0x65, 0x12, 0x3a, 0x0a, 0x08, 0x65, 0x78, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x72, 0x18, 0x02,
+ 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x69, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74,
+ 0x68, 0x65, 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x45, 0x78, 0x65, 0x6d,
+ 0x70, 0x6c, 0x61, 0x72, 0x52, 0x08, 0x65, 0x78, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x72, 0x22, 0x3c,
+ 0x0a, 0x08, 0x51, 0x75, 0x61, 0x6e, 0x74, 0x69, 0x6c, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x71, 0x75,
+ 0x61, 0x6e, 0x74, 0x69, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, 0x52, 0x08, 0x71, 0x75,
+ 0x61, 0x6e, 0x74, 0x69, 0x6c, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18,
+ 0x02, 0x20, 0x01, 0x28, 0x01, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x87, 0x01, 0x0a,
+ 0x07, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x12, 0x21, 0x0a, 0x0c, 0x73, 0x61, 0x6d, 0x70,
+ 0x6c, 0x65, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b,
+ 0x73, 0x61, 0x6d, 0x70, 0x6c, 0x65, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x73,
+ 0x61, 0x6d, 0x70, 0x6c, 0x65, 0x5f, 0x73, 0x75, 0x6d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x01, 0x52,
+ 0x09, 0x73, 0x61, 0x6d, 0x70, 0x6c, 0x65, 0x53, 0x75, 0x6d, 0x12, 0x3a, 0x0a, 0x08, 0x71, 0x75,
+ 0x61, 0x6e, 0x74, 0x69, 0x6c, 0x65, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x69,
+ 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69,
+ 0x65, 0x6e, 0x74, 0x2e, 0x51, 0x75, 0x61, 0x6e, 0x74, 0x69, 0x6c, 0x65, 0x52, 0x08, 0x71, 0x75,
+ 0x61, 0x6e, 0x74, 0x69, 0x6c, 0x65, 0x22, 0x1f, 0x0a, 0x07, 0x55, 0x6e, 0x74, 0x79, 0x70, 0x65,
+ 0x64, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01,
+ 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0xe3, 0x04, 0x0a, 0x09, 0x48, 0x69, 0x73, 0x74,
+ 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x12, 0x21, 0x0a, 0x0c, 0x73, 0x61, 0x6d, 0x70, 0x6c, 0x65, 0x5f,
+ 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x73, 0x61, 0x6d,
+ 0x70, 0x6c, 0x65, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x2c, 0x0a, 0x12, 0x73, 0x61, 0x6d, 0x70,
+ 0x6c, 0x65, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x66, 0x6c, 0x6f, 0x61, 0x74, 0x18, 0x04,
+ 0x20, 0x01, 0x28, 0x01, 0x52, 0x10, 0x73, 0x61, 0x6d, 0x70, 0x6c, 0x65, 0x43, 0x6f, 0x75, 0x6e,
+ 0x74, 0x46, 0x6c, 0x6f, 0x61, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 0x61, 0x6d, 0x70, 0x6c, 0x65,
+ 0x5f, 0x73, 0x75, 0x6d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x01, 0x52, 0x09, 0x73, 0x61, 0x6d, 0x70,
+ 0x6c, 0x65, 0x53, 0x75, 0x6d, 0x12, 0x34, 0x0a, 0x06, 0x62, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x18,
+ 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x69, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65,
+ 0x74, 0x68, 0x65, 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x42, 0x75, 0x63,
+ 0x6b, 0x65, 0x74, 0x52, 0x06, 0x62, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x73,
+ 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x05, 0x20, 0x01, 0x28, 0x11, 0x52, 0x06, 0x73, 0x63, 0x68,
+ 0x65, 0x6d, 0x61, 0x12, 0x25, 0x0a, 0x0e, 0x7a, 0x65, 0x72, 0x6f, 0x5f, 0x74, 0x68, 0x72, 0x65,
+ 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x18, 0x06, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0d, 0x7a, 0x65, 0x72,
+ 0x6f, 0x54, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x7a, 0x65,
+ 0x72, 0x6f, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09,
+ 0x7a, 0x65, 0x72, 0x6f, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x28, 0x0a, 0x10, 0x7a, 0x65, 0x72,
+ 0x6f, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x66, 0x6c, 0x6f, 0x61, 0x74, 0x18, 0x08, 0x20,
+ 0x01, 0x28, 0x01, 0x52, 0x0e, 0x7a, 0x65, 0x72, 0x6f, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x46, 0x6c,
+ 0x6f, 0x61, 0x74, 0x12, 0x45, 0x0a, 0x0d, 0x6e, 0x65, 0x67, 0x61, 0x74, 0x69, 0x76, 0x65, 0x5f,
+ 0x73, 0x70, 0x61, 0x6e, 0x18, 0x09, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x69, 0x6f, 0x2e,
+ 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e,
+ 0x74, 0x2e, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x53, 0x70, 0x61, 0x6e, 0x52, 0x0c, 0x6e, 0x65,
+ 0x67, 0x61, 0x74, 0x69, 0x76, 0x65, 0x53, 0x70, 0x61, 0x6e, 0x12, 0x25, 0x0a, 0x0e, 0x6e, 0x65,
+ 0x67, 0x61, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x74, 0x61, 0x18, 0x0a, 0x20, 0x03,
+ 0x28, 0x12, 0x52, 0x0d, 0x6e, 0x65, 0x67, 0x61, 0x74, 0x69, 0x76, 0x65, 0x44, 0x65, 0x6c, 0x74,
+ 0x61, 0x12, 0x25, 0x0a, 0x0e, 0x6e, 0x65, 0x67, 0x61, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x63, 0x6f,
+ 0x75, 0x6e, 0x74, 0x18, 0x0b, 0x20, 0x03, 0x28, 0x01, 0x52, 0x0d, 0x6e, 0x65, 0x67, 0x61, 0x74,
+ 0x69, 0x76, 0x65, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x45, 0x0a, 0x0d, 0x70, 0x6f, 0x73, 0x69,
+ 0x74, 0x69, 0x76, 0x65, 0x5f, 0x73, 0x70, 0x61, 0x6e, 0x18, 0x0c, 0x20, 0x03, 0x28, 0x0b, 0x32,
+ 0x20, 0x2e, 0x69, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73, 0x2e,
+ 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x53, 0x70, 0x61,
+ 0x6e, 0x52, 0x0c, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x76, 0x65, 0x53, 0x70, 0x61, 0x6e, 0x12,
+ 0x25, 0x0a, 0x0e, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x74,
+ 0x61, 0x18, 0x0d, 0x20, 0x03, 0x28, 0x12, 0x52, 0x0d, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x76,
+ 0x65, 0x44, 0x65, 0x6c, 0x74, 0x61, 0x12, 0x25, 0x0a, 0x0e, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69,
+ 0x76, 0x65, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x0e, 0x20, 0x03, 0x28, 0x01, 0x52, 0x0d,
+ 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x76, 0x65, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0xc6, 0x01,
+ 0x0a, 0x06, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74, 0x12, 0x29, 0x0a, 0x10, 0x63, 0x75, 0x6d, 0x75,
+ 0x6c, 0x61, 0x74, 0x69, 0x76, 0x65, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01,
+ 0x28, 0x04, 0x52, 0x0f, 0x63, 0x75, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x69, 0x76, 0x65, 0x43, 0x6f,
+ 0x75, 0x6e, 0x74, 0x12, 0x34, 0x0a, 0x16, 0x63, 0x75, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x69, 0x76,
+ 0x65, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x66, 0x6c, 0x6f, 0x61, 0x74, 0x18, 0x04, 0x20,
+ 0x01, 0x28, 0x01, 0x52, 0x14, 0x63, 0x75, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x69, 0x76, 0x65, 0x43,
+ 0x6f, 0x75, 0x6e, 0x74, 0x46, 0x6c, 0x6f, 0x61, 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x75, 0x70, 0x70,
+ 0x65, 0x72, 0x5f, 0x62, 0x6f, 0x75, 0x6e, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0a,
+ 0x75, 0x70, 0x70, 0x65, 0x72, 0x42, 0x6f, 0x75, 0x6e, 0x64, 0x12, 0x3a, 0x0a, 0x08, 0x65, 0x78,
+ 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x69,
+ 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69,
+ 0x65, 0x6e, 0x74, 0x2e, 0x45, 0x78, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x72, 0x52, 0x08, 0x65, 0x78,
+ 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x72, 0x22, 0x3c, 0x0a, 0x0a, 0x42, 0x75, 0x63, 0x6b, 0x65, 0x74,
+ 0x53, 0x70, 0x61, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x18, 0x01,
+ 0x20, 0x01, 0x28, 0x11, 0x52, 0x06, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x12, 0x16, 0x0a, 0x06,
+ 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x06, 0x6c, 0x65,
+ 0x6e, 0x67, 0x74, 0x68, 0x22, 0x91, 0x01, 0x0a, 0x08, 0x45, 0x78, 0x65, 0x6d, 0x70, 0x6c, 0x61,
+ 0x72, 0x12, 0x35, 0x0a, 0x05, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b,
+ 0x32, 0x1f, 0x2e, 0x69, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73,
+ 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x50, 0x61, 0x69,
+ 0x72, 0x52, 0x05, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75,
+ 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x01, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x38,
+ 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x03, 0x20, 0x01, 0x28,
+ 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
+ 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x09, 0x74,
+ 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x22, 0xff, 0x02, 0x0a, 0x06, 0x4d, 0x65, 0x74,
+ 0x72, 0x69, 0x63, 0x12, 0x35, 0x0a, 0x05, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x18, 0x01, 0x20, 0x03,
+ 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x69, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65,
+ 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x50,
+ 0x61, 0x69, 0x72, 0x52, 0x05, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x12, 0x31, 0x0a, 0x05, 0x67, 0x61,
+ 0x75, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x69, 0x6f, 0x2e, 0x70,
+ 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74,
+ 0x2e, 0x47, 0x61, 0x75, 0x67, 0x65, 0x52, 0x05, 0x67, 0x61, 0x75, 0x67, 0x65, 0x12, 0x37, 0x0a,
+ 0x07, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d,
+ 0x2e, 0x69, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73, 0x2e, 0x63,
+ 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x52, 0x07, 0x63,
+ 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x12, 0x37, 0x0a, 0x07, 0x73, 0x75, 0x6d, 0x6d, 0x61, 0x72,
+ 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x69, 0x6f, 0x2e, 0x70, 0x72, 0x6f,
+ 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x53,
+ 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x52, 0x07, 0x73, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x12,
+ 0x37, 0x0a, 0x07, 0x75, 0x6e, 0x74, 0x79, 0x70, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b,
+ 0x32, 0x1d, 0x2e, 0x69, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73,
+ 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x55, 0x6e, 0x74, 0x79, 0x70, 0x65, 0x64, 0x52,
+ 0x07, 0x75, 0x6e, 0x74, 0x79, 0x70, 0x65, 0x64, 0x12, 0x3d, 0x0a, 0x09, 0x68, 0x69, 0x73, 0x74,
+ 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x69, 0x6f,
+ 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69, 0x65,
+ 0x6e, 0x74, 0x2e, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x52, 0x09, 0x68, 0x69,
+ 0x73, 0x74, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x12, 0x21, 0x0a, 0x0c, 0x74, 0x69, 0x6d, 0x65, 0x73,
+ 0x74, 0x61, 0x6d, 0x70, 0x5f, 0x6d, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x74,
+ 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x4d, 0x73, 0x22, 0xa2, 0x01, 0x0a, 0x0c, 0x4d,
+ 0x65, 0x74, 0x72, 0x69, 0x63, 0x46, 0x61, 0x6d, 0x69, 0x6c, 0x79, 0x12, 0x12, 0x0a, 0x04, 0x6e,
+ 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12,
+ 0x12, 0x0a, 0x04, 0x68, 0x65, 0x6c, 0x70, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x68,
+ 0x65, 0x6c, 0x70, 0x12, 0x34, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28,
+ 0x0e, 0x32, 0x20, 0x2e, 0x69, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75,
+ 0x73, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x54,
+ 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x34, 0x0a, 0x06, 0x6d, 0x65, 0x74,
+ 0x72, 0x69, 0x63, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x69, 0x6f, 0x2e, 0x70,
+ 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74,
+ 0x2e, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x52, 0x06, 0x6d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x2a,
+ 0x62, 0x0a, 0x0a, 0x4d, 0x65, 0x74, 0x72, 0x69, 0x63, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b, 0x0a,
+ 0x07, 0x43, 0x4f, 0x55, 0x4e, 0x54, 0x45, 0x52, 0x10, 0x00, 0x12, 0x09, 0x0a, 0x05, 0x47, 0x41,
+ 0x55, 0x47, 0x45, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07, 0x53, 0x55, 0x4d, 0x4d, 0x41, 0x52, 0x59,
+ 0x10, 0x02, 0x12, 0x0b, 0x0a, 0x07, 0x55, 0x4e, 0x54, 0x59, 0x50, 0x45, 0x44, 0x10, 0x03, 0x12,
+ 0x0d, 0x0a, 0x09, 0x48, 0x49, 0x53, 0x54, 0x4f, 0x47, 0x52, 0x41, 0x4d, 0x10, 0x04, 0x12, 0x13,
+ 0x0a, 0x0f, 0x47, 0x41, 0x55, 0x47, 0x45, 0x5f, 0x48, 0x49, 0x53, 0x54, 0x4f, 0x47, 0x52, 0x41,
+ 0x4d, 0x10, 0x05, 0x42, 0x52, 0x0a, 0x14, 0x69, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74,
+ 0x68, 0x65, 0x75, 0x73, 0x2e, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5a, 0x3a, 0x67, 0x69, 0x74,
+ 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65,
+ 0x75, 0x73, 0x2f, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x5f, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x2f,
+ 0x67, 0x6f, 0x3b, 0x69, 0x6f, 0x5f, 0x70, 0x72, 0x6f, 0x6d, 0x65, 0x74, 0x68, 0x65, 0x75, 0x73,
+ 0x5f, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74,
+}
+
+var (
+ file_io_prometheus_client_metrics_proto_rawDescOnce sync.Once
+ file_io_prometheus_client_metrics_proto_rawDescData = file_io_prometheus_client_metrics_proto_rawDesc
+)
+
+func file_io_prometheus_client_metrics_proto_rawDescGZIP() []byte {
+ file_io_prometheus_client_metrics_proto_rawDescOnce.Do(func() {
+ file_io_prometheus_client_metrics_proto_rawDescData = protoimpl.X.CompressGZIP(file_io_prometheus_client_metrics_proto_rawDescData)
+ })
+ return file_io_prometheus_client_metrics_proto_rawDescData
+}
+
+var file_io_prometheus_client_metrics_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
+var file_io_prometheus_client_metrics_proto_msgTypes = make([]protoimpl.MessageInfo, 12)
+var file_io_prometheus_client_metrics_proto_goTypes = []interface{}{
+ (MetricType)(0), // 0: io.prometheus.client.MetricType
+ (*LabelPair)(nil), // 1: io.prometheus.client.LabelPair
+ (*Gauge)(nil), // 2: io.prometheus.client.Gauge
+ (*Counter)(nil), // 3: io.prometheus.client.Counter
+ (*Quantile)(nil), // 4: io.prometheus.client.Quantile
+ (*Summary)(nil), // 5: io.prometheus.client.Summary
+ (*Untyped)(nil), // 6: io.prometheus.client.Untyped
+ (*Histogram)(nil), // 7: io.prometheus.client.Histogram
+ (*Bucket)(nil), // 8: io.prometheus.client.Bucket
+ (*BucketSpan)(nil), // 9: io.prometheus.client.BucketSpan
+ (*Exemplar)(nil), // 10: io.prometheus.client.Exemplar
+ (*Metric)(nil), // 11: io.prometheus.client.Metric
+ (*MetricFamily)(nil), // 12: io.prometheus.client.MetricFamily
+ (*timestamppb.Timestamp)(nil), // 13: google.protobuf.Timestamp
+}
+var file_io_prometheus_client_metrics_proto_depIdxs = []int32{
+ 10, // 0: io.prometheus.client.Counter.exemplar:type_name -> io.prometheus.client.Exemplar
+ 4, // 1: io.prometheus.client.Summary.quantile:type_name -> io.prometheus.client.Quantile
+ 8, // 2: io.prometheus.client.Histogram.bucket:type_name -> io.prometheus.client.Bucket
+ 9, // 3: io.prometheus.client.Histogram.negative_span:type_name -> io.prometheus.client.BucketSpan
+ 9, // 4: io.prometheus.client.Histogram.positive_span:type_name -> io.prometheus.client.BucketSpan
+ 10, // 5: io.prometheus.client.Bucket.exemplar:type_name -> io.prometheus.client.Exemplar
+ 1, // 6: io.prometheus.client.Exemplar.label:type_name -> io.prometheus.client.LabelPair
+ 13, // 7: io.prometheus.client.Exemplar.timestamp:type_name -> google.protobuf.Timestamp
+ 1, // 8: io.prometheus.client.Metric.label:type_name -> io.prometheus.client.LabelPair
+ 2, // 9: io.prometheus.client.Metric.gauge:type_name -> io.prometheus.client.Gauge
+ 3, // 10: io.prometheus.client.Metric.counter:type_name -> io.prometheus.client.Counter
+ 5, // 11: io.prometheus.client.Metric.summary:type_name -> io.prometheus.client.Summary
+ 6, // 12: io.prometheus.client.Metric.untyped:type_name -> io.prometheus.client.Untyped
+ 7, // 13: io.prometheus.client.Metric.histogram:type_name -> io.prometheus.client.Histogram
+ 0, // 14: io.prometheus.client.MetricFamily.type:type_name -> io.prometheus.client.MetricType
+ 11, // 15: io.prometheus.client.MetricFamily.metric:type_name -> io.prometheus.client.Metric
+ 16, // [16:16] is the sub-list for method output_type
+ 16, // [16:16] is the sub-list for method input_type
+ 16, // [16:16] is the sub-list for extension type_name
+ 16, // [16:16] is the sub-list for extension extendee
+ 0, // [0:16] is the sub-list for field type_name
+}
+
+func init() { file_io_prometheus_client_metrics_proto_init() }
+func file_io_prometheus_client_metrics_proto_init() {
+ if File_io_prometheus_client_metrics_proto != nil {
+ return
+ }
+ if !protoimpl.UnsafeEnabled {
+ file_io_prometheus_client_metrics_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*LabelPair); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_io_prometheus_client_metrics_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Gauge); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_io_prometheus_client_metrics_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Counter); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_io_prometheus_client_metrics_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Quantile); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_io_prometheus_client_metrics_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Summary); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_io_prometheus_client_metrics_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Untyped); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_io_prometheus_client_metrics_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Histogram); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_io_prometheus_client_metrics_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Bucket); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_io_prometheus_client_metrics_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*BucketSpan); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_io_prometheus_client_metrics_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Exemplar); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_io_prometheus_client_metrics_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*Metric); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ file_io_prometheus_client_metrics_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} {
+ switch v := v.(*MetricFamily); i {
+ case 0:
+ return &v.state
+ case 1:
+ return &v.sizeCache
+ case 2:
+ return &v.unknownFields
+ default:
+ return nil
+ }
+ }
+ }
+ type x struct{}
+ out := protoimpl.TypeBuilder{
+ File: protoimpl.DescBuilder{
+ GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
+ RawDescriptor: file_io_prometheus_client_metrics_proto_rawDesc,
+ NumEnums: 1,
+ NumMessages: 12,
+ NumExtensions: 0,
+ NumServices: 0,
+ },
+ GoTypes: file_io_prometheus_client_metrics_proto_goTypes,
+ DependencyIndexes: file_io_prometheus_client_metrics_proto_depIdxs,
+ EnumInfos: file_io_prometheus_client_metrics_proto_enumTypes,
+ MessageInfos: file_io_prometheus_client_metrics_proto_msgTypes,
+ }.Build()
+ File_io_prometheus_client_metrics_proto = out.File
+ file_io_prometheus_client_metrics_proto_rawDesc = nil
+ file_io_prometheus_client_metrics_proto_goTypes = nil
+ file_io_prometheus_client_metrics_proto_depIdxs = nil
}
diff --git a/vendor/github.com/prometheus/common/config/http_config.go b/vendor/github.com/prometheus/common/config/http_config.go
index 73163206419..37aa966748b 100644
--- a/vendor/github.com/prometheus/common/config/http_config.go
+++ b/vendor/github.com/prometheus/common/config/http_config.go
@@ -579,8 +579,7 @@ func NewRoundTripperFromConfig(cfg HTTPClientConfig, name string, optFuncs ...HT
// No need for a RoundTripper that reloads the CA file automatically.
return newRT(tlsConfig)
}
-
- return NewTLSRoundTripper(tlsConfig, cfg.TLSConfig.CAFile, cfg.TLSConfig.CertFile, cfg.TLSConfig.KeyFile, newRT)
+ return NewTLSRoundTripper(tlsConfig, cfg.TLSConfig.roundTripperSettings(), newRT)
}
type authorizationCredentialsRoundTripper struct {
@@ -750,7 +749,7 @@ func (rt *oauth2RoundTripper) RoundTrip(req *http.Request) (*http.Response, erro
if len(rt.config.TLSConfig.CAFile) == 0 {
t, _ = tlsTransport(tlsConfig)
} else {
- t, err = NewTLSRoundTripper(tlsConfig, rt.config.TLSConfig.CAFile, rt.config.TLSConfig.CertFile, rt.config.TLSConfig.KeyFile, tlsTransport)
+ t, err = NewTLSRoundTripper(tlsConfig, rt.config.TLSConfig.roundTripperSettings(), tlsTransport)
if err != nil {
return nil, err
}
@@ -817,6 +816,10 @@ func cloneRequest(r *http.Request) *http.Request {
// NewTLSConfig creates a new tls.Config from the given TLSConfig.
func NewTLSConfig(cfg *TLSConfig) (*tls.Config, error) {
+ if err := cfg.Validate(); err != nil {
+ return nil, err
+ }
+
tlsConfig := &tls.Config{
InsecureSkipVerify: cfg.InsecureSkipVerify,
MinVersion: uint16(cfg.MinVersion),
@@ -831,7 +834,11 @@ func NewTLSConfig(cfg *TLSConfig) (*tls.Config, error) {
// If a CA cert is provided then let's read it in so we can validate the
// scrape target's certificate properly.
- if len(cfg.CAFile) > 0 {
+ if len(cfg.CA) > 0 {
+ if !updateRootCA(tlsConfig, []byte(cfg.CA)) {
+ return nil, fmt.Errorf("unable to use inline CA cert")
+ }
+ } else if len(cfg.CAFile) > 0 {
b, err := readCAFile(cfg.CAFile)
if err != nil {
return nil, err
@@ -844,12 +851,9 @@ func NewTLSConfig(cfg *TLSConfig) (*tls.Config, error) {
if len(cfg.ServerName) > 0 {
tlsConfig.ServerName = cfg.ServerName
}
+
// If a client cert & key is provided then configure TLS config accordingly.
- if len(cfg.CertFile) > 0 && len(cfg.KeyFile) == 0 {
- return nil, fmt.Errorf("client cert file %q specified without client key file", cfg.CertFile)
- } else if len(cfg.KeyFile) > 0 && len(cfg.CertFile) == 0 {
- return nil, fmt.Errorf("client key file %q specified without client cert file", cfg.KeyFile)
- } else if len(cfg.CertFile) > 0 && len(cfg.KeyFile) > 0 {
+ if cfg.usingClientCert() && cfg.usingClientKey() {
// Verify that client cert and key are valid.
if _, err := cfg.getClientCertificate(nil); err != nil {
return nil, err
@@ -862,6 +866,12 @@ func NewTLSConfig(cfg *TLSConfig) (*tls.Config, error) {
// TLSConfig configures the options for TLS connections.
type TLSConfig struct {
+ // Text of the CA cert to use for the targets.
+ CA string `yaml:"ca,omitempty" json:"ca,omitempty"`
+ // Text of the client cert file for the targets.
+ Cert string `yaml:"cert,omitempty" json:"cert,omitempty"`
+ // Text of the client key file for the targets.
+ Key Secret `yaml:"key,omitempty" json:"key,omitempty"`
// The CA cert to use for the targets.
CAFile string `yaml:"ca_file,omitempty" json:"ca_file,omitempty"`
// The client cert file for the targets.
@@ -891,29 +901,77 @@ func (c *TLSConfig) SetDirectory(dir string) {
// UnmarshalYAML implements the yaml.Unmarshaler interface.
func (c *TLSConfig) UnmarshalYAML(unmarshal func(interface{}) error) error {
type plain TLSConfig
- return unmarshal((*plain)(c))
+ if err := unmarshal((*plain)(c)); err != nil {
+ return err
+ }
+ return c.Validate()
}
-// readCertAndKey reads the cert and key files from the disk.
-func readCertAndKey(certFile, keyFile string) ([]byte, []byte, error) {
- certData, err := os.ReadFile(certFile)
- if err != nil {
- return nil, nil, err
+// Validate validates the TLSConfig to check that only one of the inlined or
+// file-based fields for the TLS CA, client certificate, and client key are
+// used.
+func (c *TLSConfig) Validate() error {
+ if len(c.CA) > 0 && len(c.CAFile) > 0 {
+ return fmt.Errorf("at most one of ca and ca_file must be configured")
+ }
+ if len(c.Cert) > 0 && len(c.CertFile) > 0 {
+ return fmt.Errorf("at most one of cert and cert_file must be configured")
+ }
+ if len(c.Key) > 0 && len(c.KeyFile) > 0 {
+ return fmt.Errorf("at most one of key and key_file must be configured")
}
- keyData, err := os.ReadFile(keyFile)
- if err != nil {
- return nil, nil, err
+ if c.usingClientCert() && !c.usingClientKey() {
+ return fmt.Errorf("exactly one of key or key_file must be configured when a client certificate is configured")
+ } else if c.usingClientKey() && !c.usingClientCert() {
+ return fmt.Errorf("exactly one of cert or cert_file must be configured when a client key is configured")
}
- return certData, keyData, nil
+ return nil
+}
+
+func (c *TLSConfig) usingClientCert() bool {
+ return len(c.Cert) > 0 || len(c.CertFile) > 0
+}
+
+func (c *TLSConfig) usingClientKey() bool {
+ return len(c.Key) > 0 || len(c.KeyFile) > 0
+}
+
+func (c *TLSConfig) roundTripperSettings() TLSRoundTripperSettings {
+ return TLSRoundTripperSettings{
+ CA: c.CA,
+ CAFile: c.CAFile,
+ Cert: c.Cert,
+ CertFile: c.CertFile,
+ Key: string(c.Key),
+ KeyFile: c.KeyFile,
+ }
}
// getClientCertificate reads the pair of client cert and key from disk and returns a tls.Certificate.
func (c *TLSConfig) getClientCertificate(_ *tls.CertificateRequestInfo) (*tls.Certificate, error) {
- certData, keyData, err := readCertAndKey(c.CertFile, c.KeyFile)
- if err != nil {
- return nil, fmt.Errorf("unable to read specified client cert (%s) & key (%s): %s", c.CertFile, c.KeyFile, err)
+ var (
+ certData, keyData []byte
+ err error
+ )
+
+ if c.CertFile != "" {
+ certData, err = os.ReadFile(c.CertFile)
+ if err != nil {
+ return nil, fmt.Errorf("unable to read specified client cert (%s): %s", c.CertFile, err)
+ }
+ } else {
+ certData = []byte(c.Cert)
+ }
+
+ if c.KeyFile != "" {
+ keyData, err = os.ReadFile(c.KeyFile)
+ if err != nil {
+ return nil, fmt.Errorf("unable to read specified client key (%s): %s", c.KeyFile, err)
+ }
+ } else {
+ keyData = []byte(c.Key)
}
cert, err := tls.X509KeyPair(certData, keyData)
@@ -946,30 +1004,32 @@ func updateRootCA(cfg *tls.Config, b []byte) bool {
// tlsRoundTripper is a RoundTripper that updates automatically its TLS
// configuration whenever the content of the CA file changes.
type tlsRoundTripper struct {
- caFile string
- certFile string
- keyFile string
+ settings TLSRoundTripperSettings
// newRT returns a new RoundTripper.
newRT func(*tls.Config) (http.RoundTripper, error)
mtx sync.RWMutex
rt http.RoundTripper
- hashCAFile []byte
- hashCertFile []byte
- hashKeyFile []byte
+ hashCAData []byte
+ hashCertData []byte
+ hashKeyData []byte
tlsConfig *tls.Config
}
+type TLSRoundTripperSettings struct {
+ CA, CAFile string
+ Cert, CertFile string
+ Key, KeyFile string
+}
+
func NewTLSRoundTripper(
cfg *tls.Config,
- caFile, certFile, keyFile string,
+ settings TLSRoundTripperSettings,
newRT func(*tls.Config) (http.RoundTripper, error),
) (http.RoundTripper, error) {
t := &tlsRoundTripper{
- caFile: caFile,
- certFile: certFile,
- keyFile: keyFile,
+ settings: settings,
newRT: newRT,
tlsConfig: cfg,
}
@@ -979,7 +1039,7 @@ func NewTLSRoundTripper(
return nil, err
}
t.rt = rt
- _, t.hashCAFile, t.hashCertFile, t.hashKeyFile, err = t.getTLSFilesWithHash()
+ _, t.hashCAData, t.hashCertData, t.hashKeyData, err = t.getTLSDataWithHash()
if err != nil {
return nil, err
}
@@ -987,36 +1047,66 @@ func NewTLSRoundTripper(
return t, nil
}
-func (t *tlsRoundTripper) getTLSFilesWithHash() ([]byte, []byte, []byte, []byte, error) {
- b1, err := readCAFile(t.caFile)
- if err != nil {
- return nil, nil, nil, nil, err
+func (t *tlsRoundTripper) getTLSDataWithHash() ([]byte, []byte, []byte, []byte, error) {
+ var (
+ caBytes, certBytes, keyBytes []byte
+
+ err error
+ )
+
+ if t.settings.CAFile != "" {
+ caBytes, err = os.ReadFile(t.settings.CAFile)
+ if err != nil {
+ return nil, nil, nil, nil, err
+ }
+ } else if t.settings.CA != "" {
+ caBytes = []byte(t.settings.CA)
+ }
+
+ if t.settings.CertFile != "" {
+ certBytes, err = os.ReadFile(t.settings.CertFile)
+ if err != nil {
+ return nil, nil, nil, nil, err
+ }
+ } else if t.settings.Cert != "" {
+ certBytes = []byte(t.settings.Cert)
}
- h1 := sha256.Sum256(b1)
- var h2, h3 [32]byte
- if t.certFile != "" {
- b2, b3, err := readCertAndKey(t.certFile, t.keyFile)
+ if t.settings.KeyFile != "" {
+ keyBytes, err = os.ReadFile(t.settings.KeyFile)
if err != nil {
return nil, nil, nil, nil, err
}
- h2, h3 = sha256.Sum256(b2), sha256.Sum256(b3)
+ } else if t.settings.Key != "" {
+ keyBytes = []byte(t.settings.Key)
+ }
+
+ var caHash, certHash, keyHash [32]byte
+
+ if len(caBytes) > 0 {
+ caHash = sha256.Sum256(caBytes)
+ }
+ if len(certBytes) > 0 {
+ certHash = sha256.Sum256(certBytes)
+ }
+ if len(keyBytes) > 0 {
+ keyHash = sha256.Sum256(keyBytes)
}
- return b1, h1[:], h2[:], h3[:], nil
+ return caBytes, caHash[:], certHash[:], keyHash[:], nil
}
// RoundTrip implements the http.RoundTrip interface.
func (t *tlsRoundTripper) RoundTrip(req *http.Request) (*http.Response, error) {
- caData, caHash, certHash, keyHash, err := t.getTLSFilesWithHash()
+ caData, caHash, certHash, keyHash, err := t.getTLSDataWithHash()
if err != nil {
return nil, err
}
t.mtx.RLock()
- equal := bytes.Equal(caHash[:], t.hashCAFile) &&
- bytes.Equal(certHash[:], t.hashCertFile) &&
- bytes.Equal(keyHash[:], t.hashKeyFile)
+ equal := bytes.Equal(caHash[:], t.hashCAData) &&
+ bytes.Equal(certHash[:], t.hashCertData) &&
+ bytes.Equal(keyHash[:], t.hashKeyData)
rt := t.rt
t.mtx.RUnlock()
if equal {
@@ -1029,7 +1119,7 @@ func (t *tlsRoundTripper) RoundTrip(req *http.Request) (*http.Response, error) {
// using GetClientCertificate.
tlsConfig := t.tlsConfig.Clone()
if !updateRootCA(tlsConfig, caData) {
- return nil, fmt.Errorf("unable to use specified CA cert %s", t.caFile)
+ return nil, fmt.Errorf("unable to use specified CA cert %s", t.settings.CAFile)
}
rt, err = t.newRT(tlsConfig)
if err != nil {
@@ -1039,9 +1129,9 @@ func (t *tlsRoundTripper) RoundTrip(req *http.Request) (*http.Response, error) {
t.mtx.Lock()
t.rt = rt
- t.hashCAFile = caHash[:]
- t.hashCertFile = certHash[:]
- t.hashKeyFile = keyHash[:]
+ t.hashCAData = caHash[:]
+ t.hashCertData = certHash[:]
+ t.hashKeyData = keyHash[:]
t.mtx.Unlock()
return rt.RoundTrip(req)
diff --git a/vendor/github.com/prometheus/common/expfmt/decode.go b/vendor/github.com/prometheus/common/expfmt/decode.go
index f4fc8845522..90639781513 100644
--- a/vendor/github.com/prometheus/common/expfmt/decode.go
+++ b/vendor/github.com/prometheus/common/expfmt/decode.go
@@ -132,7 +132,10 @@ func (d *textDecoder) Decode(v *dto.MetricFamily) error {
}
// Pick off one MetricFamily per Decode until there's nothing left.
for key, fam := range d.fams {
- *v = *fam
+ v.Name = fam.Name
+ v.Help = fam.Help
+ v.Type = fam.Type
+ v.Metric = fam.Metric
delete(d.fams, key)
return nil
}
diff --git a/vendor/github.com/prometheus/common/expfmt/encode.go b/vendor/github.com/prometheus/common/expfmt/encode.go
index 64dc0eb40c2..7f611ffaad7 100644
--- a/vendor/github.com/prometheus/common/expfmt/encode.go
+++ b/vendor/github.com/prometheus/common/expfmt/encode.go
@@ -18,9 +18,9 @@ import (
"io"
"net/http"
- "github.com/golang/protobuf/proto" //nolint:staticcheck // Ignore SA1019. Need to keep deprecated package for compatibility.
"github.com/matttproud/golang_protobuf_extensions/pbutil"
"github.com/prometheus/common/internal/bitbucket.org/ww/goautoneg"
+ "google.golang.org/protobuf/encoding/prototext"
dto "github.com/prometheus/client_model/go"
)
@@ -99,8 +99,11 @@ func NegotiateIncludingOpenMetrics(h http.Header) Format {
if ac.Type == "text" && ac.SubType == "plain" && (ver == TextVersion || ver == "") {
return FmtText
}
- if ac.Type+"/"+ac.SubType == OpenMetricsType && (ver == OpenMetricsVersion || ver == "") {
- return FmtOpenMetrics
+ if ac.Type+"/"+ac.SubType == OpenMetricsType && (ver == OpenMetricsVersion_0_0_1 || ver == OpenMetricsVersion_1_0_0 || ver == "") {
+ if ver == OpenMetricsVersion_1_0_0 {
+ return FmtOpenMetrics_1_0_0
+ }
+ return FmtOpenMetrics_0_0_1
}
}
return FmtText
@@ -133,7 +136,7 @@ func NewEncoder(w io.Writer, format Format) Encoder {
case FmtProtoText:
return encoderCloser{
encode: func(v *dto.MetricFamily) error {
- _, err := fmt.Fprintln(w, proto.MarshalTextString(v))
+ _, err := fmt.Fprintln(w, prototext.Format(v))
return err
},
close: func() error { return nil },
@@ -146,7 +149,7 @@ func NewEncoder(w io.Writer, format Format) Encoder {
},
close: func() error { return nil },
}
- case FmtOpenMetrics:
+ case FmtOpenMetrics_0_0_1, FmtOpenMetrics_1_0_0:
return encoderCloser{
encode: func(v *dto.MetricFamily) error {
_, err := MetricFamilyToOpenMetrics(w, v)
diff --git a/vendor/github.com/prometheus/common/expfmt/expfmt.go b/vendor/github.com/prometheus/common/expfmt/expfmt.go
index 0f176fa64f2..c4cb20f0d3e 100644
--- a/vendor/github.com/prometheus/common/expfmt/expfmt.go
+++ b/vendor/github.com/prometheus/common/expfmt/expfmt.go
@@ -19,20 +19,22 @@ type Format string
// Constants to assemble the Content-Type values for the different wire protocols.
const (
- TextVersion = "0.0.4"
- ProtoType = `application/vnd.google.protobuf`
- ProtoProtocol = `io.prometheus.client.MetricFamily`
- ProtoFmt = ProtoType + "; proto=" + ProtoProtocol + ";"
- OpenMetricsType = `application/openmetrics-text`
- OpenMetricsVersion = "0.0.1"
+ TextVersion = "0.0.4"
+ ProtoType = `application/vnd.google.protobuf`
+ ProtoProtocol = `io.prometheus.client.MetricFamily`
+ ProtoFmt = ProtoType + "; proto=" + ProtoProtocol + ";"
+ OpenMetricsType = `application/openmetrics-text`
+ OpenMetricsVersion_0_0_1 = "0.0.1"
+ OpenMetricsVersion_1_0_0 = "1.0.0"
// The Content-Type values for the different wire protocols.
- FmtUnknown Format = ``
- FmtText Format = `text/plain; version=` + TextVersion + `; charset=utf-8`
- FmtProtoDelim Format = ProtoFmt + ` encoding=delimited`
- FmtProtoText Format = ProtoFmt + ` encoding=text`
- FmtProtoCompact Format = ProtoFmt + ` encoding=compact-text`
- FmtOpenMetrics Format = OpenMetricsType + `; version=` + OpenMetricsVersion + `; charset=utf-8`
+ FmtUnknown Format = ``
+ FmtText Format = `text/plain; version=` + TextVersion + `; charset=utf-8`
+ FmtProtoDelim Format = ProtoFmt + ` encoding=delimited`
+ FmtProtoText Format = ProtoFmt + ` encoding=text`
+ FmtProtoCompact Format = ProtoFmt + ` encoding=compact-text`
+ FmtOpenMetrics_1_0_0 Format = OpenMetricsType + `; version=` + OpenMetricsVersion_1_0_0 + `; charset=utf-8`
+ FmtOpenMetrics_0_0_1 Format = OpenMetricsType + `; version=` + OpenMetricsVersion_0_0_1 + `; charset=utf-8`
)
const (
diff --git a/vendor/github.com/prometheus/common/expfmt/text_parse.go b/vendor/github.com/prometheus/common/expfmt/text_parse.go
index ac2482782c7..35db1cc9d73 100644
--- a/vendor/github.com/prometheus/common/expfmt/text_parse.go
+++ b/vendor/github.com/prometheus/common/expfmt/text_parse.go
@@ -24,8 +24,8 @@ import (
dto "github.com/prometheus/client_model/go"
- "github.com/golang/protobuf/proto" //nolint:staticcheck // Ignore SA1019. Need to keep deprecated package for compatibility.
"github.com/prometheus/common/model"
+ "google.golang.org/protobuf/proto"
)
// A stateFn is a function that represents a state in a state machine. By
diff --git a/vendor/github.com/prometheus/common/promlog/log.go b/vendor/github.com/prometheus/common/promlog/log.go
index 35e95c89329..3ac7b3fdf12 100644
--- a/vendor/github.com/prometheus/common/promlog/log.go
+++ b/vendor/github.com/prometheus/common/promlog/log.go
@@ -111,13 +111,16 @@ type Config struct {
// New returns a new leveled oklog logger. Each logged line will be annotated
// with a timestamp. The output always goes to stderr.
func New(config *Config) log.Logger {
- var l log.Logger
if config.Format != nil && config.Format.s == "json" {
- l = log.NewJSONLogger(log.NewSyncWriter(os.Stderr))
- } else {
- l = log.NewLogfmtLogger(log.NewSyncWriter(os.Stderr))
+ return NewWithLogger(log.NewJSONLogger(log.NewSyncWriter(os.Stderr)), config)
}
+ return NewWithLogger(log.NewLogfmtLogger(log.NewSyncWriter(os.Stderr)), config)
+}
+
+// NewWithLogger returns a new leveled oklog logger with a custom log.Logger.
+// Each logged line will be annotated with a timestamp.
+func NewWithLogger(l log.Logger, config *Config) log.Logger {
if config.Level != nil {
l = log.With(l, "ts", timestampFormat, "caller", log.Caller(5))
l = level.NewFilter(l, config.Level.o)
@@ -131,13 +134,17 @@ func New(config *Config) log.Logger {
// with a timestamp. The output always goes to stderr. Some properties can be
// changed, like the level.
func NewDynamic(config *Config) *logger {
- var l log.Logger
if config.Format != nil && config.Format.s == "json" {
- l = log.NewJSONLogger(log.NewSyncWriter(os.Stderr))
- } else {
- l = log.NewLogfmtLogger(log.NewSyncWriter(os.Stderr))
+ return NewDynamicWithLogger(log.NewJSONLogger(log.NewSyncWriter(os.Stderr)), config)
}
+ return NewDynamicWithLogger(log.NewLogfmtLogger(log.NewSyncWriter(os.Stderr)), config)
+}
+
+// NewDynamicWithLogger returns a new leveled logger with a custom io.Writer.
+// Each logged line will be annotated with a timestamp.
+// Some properties can be changed, like the level.
+func NewDynamicWithLogger(l log.Logger, config *Config) *logger {
lo := &logger{
base: l,
leveled: l,
diff --git a/vendor/github.com/prometheus/exporter-toolkit/web/landing_page.css b/vendor/github.com/prometheus/exporter-toolkit/web/landing_page.css
index cc939eaf811..260bc8a0967 100644
--- a/vendor/github.com/prometheus/exporter-toolkit/web/landing_page.css
+++ b/vendor/github.com/prometheus/exporter-toolkit/web/landing_page.css
@@ -5,9 +5,14 @@ body {
header {
background-color: {{.HeaderColor}};
color: #fff;
- font-size: 2rem;
+ font-size: 1rem;
padding: 1rem;
}
main {
padding: 1rem;
}
+label {
+ display: inline-block;
+ width: {{.Form.Width}}em;
+}
+{{.ExtraCSS}}
diff --git a/vendor/github.com/prometheus/exporter-toolkit/web/landing_page.go b/vendor/github.com/prometheus/exporter-toolkit/web/landing_page.go
index f0747ac3622..68266213edd 100644
--- a/vendor/github.com/prometheus/exporter-toolkit/web/landing_page.go
+++ b/vendor/github.com/prometheus/exporter-toolkit/web/landing_page.go
@@ -31,10 +31,29 @@ type LandingConfig struct {
CSS string // CSS style tag for the landing page.
Name string // The name of the exporter, generally suffixed by _exporter.
Description string // A short description about the exporter.
+ Form LandingForm // A POST form.
Links []LandingLinks // Links displayed on the landing page.
+ ExtraHTML string // Additional HTML to be embedded.
+ ExtraCSS string // Additional CSS to be embedded.
Version string // The version displayed.
}
+// LandingForm provides a configuration struct for creating a POST form on the landing page.
+type LandingForm struct {
+ Action string
+ Inputs []LandingFormInput
+ Width float64
+}
+
+// LandingFormInput represents a single form input field.
+type LandingFormInput struct {
+ Label string
+ Type string
+ Name string
+ Placeholder string
+ Value string
+}
+
type LandingLinks struct {
Address string // The URL the link points to.
Text string // The text of the link.
@@ -54,6 +73,15 @@ var (
func NewLandingPage(c LandingConfig) (*LandingPageHandler, error) {
var buf bytes.Buffer
+
+ length := 0
+ for _, input := range c.Form.Inputs {
+ inputLength := len(input.Label)
+ if inputLength > length {
+ length = inputLength
+ }
+ }
+ c.Form.Width = (float64(length) + 1) / 2
if c.CSS == "" {
if c.HeaderColor == "" {
// Default to Prometheus orange.
@@ -78,5 +106,6 @@ func NewLandingPage(c LandingConfig) (*LandingPageHandler, error) {
}
func (h *LandingPageHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
+ w.Header().Add("Content-Type", "text/html; charset=UTF-8")
w.Write(h.landingPage)
}
diff --git a/vendor/github.com/prometheus/exporter-toolkit/web/landing_page.html b/vendor/github.com/prometheus/exporter-toolkit/web/landing_page.html
index 68c401702cf..4f2e1817729 100644
--- a/vendor/github.com/prometheus/exporter-toolkit/web/landing_page.html
+++ b/vendor/github.com/prometheus/exporter-toolkit/web/landing_page.html
@@ -19,6 +19,17 @@ {{.Name}}
{{ end }}