Alpha (#4)
* chore: initial push to be able to work together * chore: add missing wait folder * chore: add missing folders * chore: cleanup alpha branch * feat: mssql alpha instance (#2) * fix: remove unused attribute types and functions from backup models * fix: update API client references to use sqlserverflexalpha package * fix: update package references to use sqlserverflexalpha and modify user data source model * fix: add sqlserverflexalpha user data source to provider * fix: add sqlserverflexalpha user resource and update related functionality * chore: add stackit_sqlserverflexalpha_user resource and instance_id variable * fix: refactor sqlserverflexalpha user resource and enhance schema with status and default_database --------- Co-authored-by: Andre Harms <andre.harms@stackit.cloud> Co-authored-by: Marcel S. Henselin <marcel.henselin@stackit.cloud> * feat: add sqlserver instance * chore: fixing tests * chore: update docs --------- Co-authored-by: Marcel S. Henselin <marcel.henselin@stackit.cloud> Co-authored-by: Andre Harms <andre.harms@stackit.cloud>
This commit is contained in:
parent
45073a716b
commit
2733834fc9
351 changed files with 62744 additions and 3 deletions
436
pkg/sqlserverflexalpha/model_get_backup_response.go
Normal file
436
pkg/sqlserverflexalpha/model_get_backup_response.go
Normal file
|
|
@ -0,0 +1,436 @@
|
|||
/*
|
||||
STACKIT MSSQL Service API
|
||||
|
||||
This is the documentation for the STACKIT MSSQL service
|
||||
|
||||
API version: 3alpha1
|
||||
*/
|
||||
|
||||
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
||||
|
||||
package sqlserverflexalpha
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
)
|
||||
|
||||
// checks if the GetBackupResponse type satisfies the MappedNullable interface at compile time
|
||||
var _ MappedNullable = &GetBackupResponse{}
|
||||
|
||||
/*
|
||||
types and functions for completionTime
|
||||
*/
|
||||
|
||||
//// isAny
|
||||
//type GetBackupResponseGetCompletionTimeAttributeType = any
|
||||
//type GetBackupResponseGetCompletionTimeArgType = any
|
||||
//type GetBackupResponseGetCompletionTimeRetType = any
|
||||
//
|
||||
//func getGetBackupResponseGetCompletionTimeAttributeTypeOk(arg GetBackupResponseGetCompletionTimeAttributeType) (ret GetBackupResponseGetCompletionTimeRetType, ok bool) {
|
||||
// if arg == nil {
|
||||
// return ret, false
|
||||
// }
|
||||
// return *arg, true
|
||||
//}
|
||||
//
|
||||
//func setGetBackupResponseGetCompletionTimeAttributeType(arg *GetBackupResponseGetCompletionTimeAttributeType, val GetBackupResponseGetCompletionTimeRetType) {
|
||||
// *arg = &val
|
||||
//}
|
||||
|
||||
// isModel
|
||||
type GetBackupResponseGetCompletionTimeAttributeType = *string
|
||||
type GetBackupResponseGetCompletionTimeArgType = string
|
||||
type GetBackupResponseGetCompletionTimeRetType = string
|
||||
|
||||
func getGetBackupResponseGetCompletionTimeAttributeTypeOk(arg GetBackupResponseGetCompletionTimeAttributeType) (ret GetBackupResponseGetCompletionTimeRetType, ok bool) {
|
||||
if arg == nil {
|
||||
return ret, false
|
||||
}
|
||||
return *arg, true
|
||||
}
|
||||
|
||||
func setGetBackupResponseGetCompletionTimeAttributeType(arg *GetBackupResponseGetCompletionTimeAttributeType, val GetBackupResponseGetCompletionTimeRetType) {
|
||||
*arg = &val
|
||||
}
|
||||
|
||||
/*
|
||||
types and functions for id
|
||||
*/
|
||||
|
||||
//// isAny
|
||||
//type GetBackupResponseGetIdAttributeType = any
|
||||
//type GetBackupResponseGetIdArgType = any
|
||||
//type GetBackupResponseGetIdRetType = any
|
||||
//
|
||||
//func getGetBackupResponseGetIdAttributeTypeOk(arg GetBackupResponseGetIdAttributeType) (ret GetBackupResponseGetIdRetType, ok bool) {
|
||||
// if arg == nil {
|
||||
// return ret, false
|
||||
// }
|
||||
// return *arg, true
|
||||
//}
|
||||
//
|
||||
//func setGetBackupResponseGetIdAttributeType(arg *GetBackupResponseGetIdAttributeType, val GetBackupResponseGetIdRetType) {
|
||||
// *arg = &val
|
||||
//}
|
||||
|
||||
// isModel
|
||||
type GetBackupResponseGetIdAttributeType = *int64
|
||||
type GetBackupResponseGetIdArgType = int64
|
||||
type GetBackupResponseGetIdRetType = int64
|
||||
|
||||
func getGetBackupResponseGetIdAttributeTypeOk(arg GetBackupResponseGetIdAttributeType) (ret GetBackupResponseGetIdRetType, ok bool) {
|
||||
if arg == nil {
|
||||
return ret, false
|
||||
}
|
||||
return *arg, true
|
||||
}
|
||||
|
||||
func setGetBackupResponseGetIdAttributeType(arg *GetBackupResponseGetIdAttributeType, val GetBackupResponseGetIdRetType) {
|
||||
*arg = &val
|
||||
}
|
||||
|
||||
/*
|
||||
types and functions for name
|
||||
*/
|
||||
|
||||
//// isAny
|
||||
//type GetBackupResponseGetNameAttributeType = any
|
||||
//type GetBackupResponseGetNameArgType = any
|
||||
//type GetBackupResponseGetNameRetType = any
|
||||
//
|
||||
//func getGetBackupResponseGetNameAttributeTypeOk(arg GetBackupResponseGetNameAttributeType) (ret GetBackupResponseGetNameRetType, ok bool) {
|
||||
// if arg == nil {
|
||||
// return ret, false
|
||||
// }
|
||||
// return *arg, true
|
||||
//}
|
||||
//
|
||||
//func setGetBackupResponseGetNameAttributeType(arg *GetBackupResponseGetNameAttributeType, val GetBackupResponseGetNameRetType) {
|
||||
// *arg = &val
|
||||
//}
|
||||
|
||||
// isModel
|
||||
type GetBackupResponseGetNameAttributeType = *string
|
||||
type GetBackupResponseGetNameArgType = string
|
||||
type GetBackupResponseGetNameRetType = string
|
||||
|
||||
func getGetBackupResponseGetNameAttributeTypeOk(arg GetBackupResponseGetNameAttributeType) (ret GetBackupResponseGetNameRetType, ok bool) {
|
||||
if arg == nil {
|
||||
return ret, false
|
||||
}
|
||||
return *arg, true
|
||||
}
|
||||
|
||||
func setGetBackupResponseGetNameAttributeType(arg *GetBackupResponseGetNameAttributeType, val GetBackupResponseGetNameRetType) {
|
||||
*arg = &val
|
||||
}
|
||||
|
||||
/*
|
||||
types and functions for retainedUntil
|
||||
*/
|
||||
|
||||
//// isAny
|
||||
//type GetBackupResponseGetRetainedUntilAttributeType = any
|
||||
//type GetBackupResponseGetRetainedUntilArgType = any
|
||||
//type GetBackupResponseGetRetainedUntilRetType = any
|
||||
//
|
||||
//func getGetBackupResponseGetRetainedUntilAttributeTypeOk(arg GetBackupResponseGetRetainedUntilAttributeType) (ret GetBackupResponseGetRetainedUntilRetType, ok bool) {
|
||||
// if arg == nil {
|
||||
// return ret, false
|
||||
// }
|
||||
// return *arg, true
|
||||
//}
|
||||
//
|
||||
//func setGetBackupResponseGetRetainedUntilAttributeType(arg *GetBackupResponseGetRetainedUntilAttributeType, val GetBackupResponseGetRetainedUntilRetType) {
|
||||
// *arg = &val
|
||||
//}
|
||||
|
||||
// isModel
|
||||
type GetBackupResponseGetRetainedUntilAttributeType = *string
|
||||
type GetBackupResponseGetRetainedUntilArgType = string
|
||||
type GetBackupResponseGetRetainedUntilRetType = string
|
||||
|
||||
func getGetBackupResponseGetRetainedUntilAttributeTypeOk(arg GetBackupResponseGetRetainedUntilAttributeType) (ret GetBackupResponseGetRetainedUntilRetType, ok bool) {
|
||||
if arg == nil {
|
||||
return ret, false
|
||||
}
|
||||
return *arg, true
|
||||
}
|
||||
|
||||
func setGetBackupResponseGetRetainedUntilAttributeType(arg *GetBackupResponseGetRetainedUntilAttributeType, val GetBackupResponseGetRetainedUntilRetType) {
|
||||
*arg = &val
|
||||
}
|
||||
|
||||
/*
|
||||
types and functions for size
|
||||
*/
|
||||
|
||||
//// isAny
|
||||
//type GetBackupResponseGetSizeAttributeType = any
|
||||
//type GetBackupResponseGetSizeArgType = any
|
||||
//type GetBackupResponseGetSizeRetType = any
|
||||
//
|
||||
//func getGetBackupResponseGetSizeAttributeTypeOk(arg GetBackupResponseGetSizeAttributeType) (ret GetBackupResponseGetSizeRetType, ok bool) {
|
||||
// if arg == nil {
|
||||
// return ret, false
|
||||
// }
|
||||
// return *arg, true
|
||||
//}
|
||||
//
|
||||
//func setGetBackupResponseGetSizeAttributeType(arg *GetBackupResponseGetSizeAttributeType, val GetBackupResponseGetSizeRetType) {
|
||||
// *arg = &val
|
||||
//}
|
||||
|
||||
// isModel
|
||||
type GetBackupResponseGetSizeAttributeType = *int64
|
||||
type GetBackupResponseGetSizeArgType = int64
|
||||
type GetBackupResponseGetSizeRetType = int64
|
||||
|
||||
func getGetBackupResponseGetSizeAttributeTypeOk(arg GetBackupResponseGetSizeAttributeType) (ret GetBackupResponseGetSizeRetType, ok bool) {
|
||||
if arg == nil {
|
||||
return ret, false
|
||||
}
|
||||
return *arg, true
|
||||
}
|
||||
|
||||
func setGetBackupResponseGetSizeAttributeType(arg *GetBackupResponseGetSizeAttributeType, val GetBackupResponseGetSizeRetType) {
|
||||
*arg = &val
|
||||
}
|
||||
|
||||
/*
|
||||
types and functions for type
|
||||
*/
|
||||
|
||||
//// isAny
|
||||
//type GetBackupResponseGetTypeAttributeType = any
|
||||
//type GetBackupResponseGetTypeArgType = any
|
||||
//type GetBackupResponseGetTypeRetType = any
|
||||
//
|
||||
//func getGetBackupResponseGetTypeAttributeTypeOk(arg GetBackupResponseGetTypeAttributeType) (ret GetBackupResponseGetTypeRetType, ok bool) {
|
||||
// if arg == nil {
|
||||
// return ret, false
|
||||
// }
|
||||
// return *arg, true
|
||||
//}
|
||||
//
|
||||
//func setGetBackupResponseGetTypeAttributeType(arg *GetBackupResponseGetTypeAttributeType, val GetBackupResponseGetTypeRetType) {
|
||||
// *arg = &val
|
||||
//}
|
||||
|
||||
// isModel
|
||||
type GetBackupResponseGetTypeAttributeType = *string
|
||||
type GetBackupResponseGetTypeArgType = string
|
||||
type GetBackupResponseGetTypeRetType = string
|
||||
|
||||
func getGetBackupResponseGetTypeAttributeTypeOk(arg GetBackupResponseGetTypeAttributeType) (ret GetBackupResponseGetTypeRetType, ok bool) {
|
||||
if arg == nil {
|
||||
return ret, false
|
||||
}
|
||||
return *arg, true
|
||||
}
|
||||
|
||||
func setGetBackupResponseGetTypeAttributeType(arg *GetBackupResponseGetTypeAttributeType, val GetBackupResponseGetTypeRetType) {
|
||||
*arg = &val
|
||||
}
|
||||
|
||||
// GetBackupResponse struct for GetBackupResponse
|
||||
type GetBackupResponse struct {
|
||||
// REQUIRED
|
||||
CompletionTime GetBackupResponseGetCompletionTimeAttributeType `json:"completionTime" required:"true"`
|
||||
// REQUIRED
|
||||
Id GetBackupResponseGetIdAttributeType `json:"id" required:"true"`
|
||||
// REQUIRED
|
||||
Name GetBackupResponseGetNameAttributeType `json:"name" required:"true"`
|
||||
// REQUIRED
|
||||
RetainedUntil GetBackupResponseGetRetainedUntilAttributeType `json:"retainedUntil" required:"true"`
|
||||
// REQUIRED
|
||||
Size GetBackupResponseGetSizeAttributeType `json:"size" required:"true"`
|
||||
// REQUIRED
|
||||
Type GetBackupResponseGetTypeAttributeType `json:"type" required:"true"`
|
||||
}
|
||||
|
||||
type _GetBackupResponse GetBackupResponse
|
||||
|
||||
// NewGetBackupResponse instantiates a new GetBackupResponse 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 NewGetBackupResponse(completionTime GetBackupResponseGetCompletionTimeArgType, id GetBackupResponseGetIdArgType, name GetBackupResponseGetNameArgType, retainedUntil GetBackupResponseGetRetainedUntilArgType, size GetBackupResponseGetSizeArgType, types GetBackupResponseGetTypeArgType) *GetBackupResponse {
|
||||
this := GetBackupResponse{}
|
||||
setGetBackupResponseGetCompletionTimeAttributeType(&this.CompletionTime, completionTime)
|
||||
setGetBackupResponseGetIdAttributeType(&this.Id, id)
|
||||
setGetBackupResponseGetNameAttributeType(&this.Name, name)
|
||||
setGetBackupResponseGetRetainedUntilAttributeType(&this.RetainedUntil, retainedUntil)
|
||||
setGetBackupResponseGetSizeAttributeType(&this.Size, size)
|
||||
setGetBackupResponseGetTypeAttributeType(&this.Type, types)
|
||||
return &this
|
||||
}
|
||||
|
||||
// NewGetBackupResponseWithDefaults instantiates a new GetBackupResponse 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 NewGetBackupResponseWithDefaults() *GetBackupResponse {
|
||||
this := GetBackupResponse{}
|
||||
return &this
|
||||
}
|
||||
|
||||
// GetCompletionTime returns the CompletionTime field value
|
||||
func (o *GetBackupResponse) GetCompletionTime() (ret GetBackupResponseGetCompletionTimeRetType) {
|
||||
ret, _ = o.GetCompletionTimeOk()
|
||||
return ret
|
||||
}
|
||||
|
||||
// GetCompletionTimeOk returns a tuple with the CompletionTime field value
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *GetBackupResponse) GetCompletionTimeOk() (ret GetBackupResponseGetCompletionTimeRetType, ok bool) {
|
||||
return getGetBackupResponseGetCompletionTimeAttributeTypeOk(o.CompletionTime)
|
||||
}
|
||||
|
||||
// SetCompletionTime sets field value
|
||||
func (o *GetBackupResponse) SetCompletionTime(v GetBackupResponseGetCompletionTimeRetType) {
|
||||
setGetBackupResponseGetCompletionTimeAttributeType(&o.CompletionTime, v)
|
||||
}
|
||||
|
||||
// GetId returns the Id field value
|
||||
func (o *GetBackupResponse) GetId() (ret GetBackupResponseGetIdRetType) {
|
||||
ret, _ = o.GetIdOk()
|
||||
return ret
|
||||
}
|
||||
|
||||
// GetIdOk returns a tuple with the Id field value
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *GetBackupResponse) GetIdOk() (ret GetBackupResponseGetIdRetType, ok bool) {
|
||||
return getGetBackupResponseGetIdAttributeTypeOk(o.Id)
|
||||
}
|
||||
|
||||
// SetId sets field value
|
||||
func (o *GetBackupResponse) SetId(v GetBackupResponseGetIdRetType) {
|
||||
setGetBackupResponseGetIdAttributeType(&o.Id, v)
|
||||
}
|
||||
|
||||
// GetName returns the Name field value
|
||||
func (o *GetBackupResponse) GetName() (ret GetBackupResponseGetNameRetType) {
|
||||
ret, _ = o.GetNameOk()
|
||||
return ret
|
||||
}
|
||||
|
||||
// GetNameOk returns a tuple with the Name field value
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *GetBackupResponse) GetNameOk() (ret GetBackupResponseGetNameRetType, ok bool) {
|
||||
return getGetBackupResponseGetNameAttributeTypeOk(o.Name)
|
||||
}
|
||||
|
||||
// SetName sets field value
|
||||
func (o *GetBackupResponse) SetName(v GetBackupResponseGetNameRetType) {
|
||||
setGetBackupResponseGetNameAttributeType(&o.Name, v)
|
||||
}
|
||||
|
||||
// GetRetainedUntil returns the RetainedUntil field value
|
||||
func (o *GetBackupResponse) GetRetainedUntil() (ret GetBackupResponseGetRetainedUntilRetType) {
|
||||
ret, _ = o.GetRetainedUntilOk()
|
||||
return ret
|
||||
}
|
||||
|
||||
// GetRetainedUntilOk returns a tuple with the RetainedUntil field value
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *GetBackupResponse) GetRetainedUntilOk() (ret GetBackupResponseGetRetainedUntilRetType, ok bool) {
|
||||
return getGetBackupResponseGetRetainedUntilAttributeTypeOk(o.RetainedUntil)
|
||||
}
|
||||
|
||||
// SetRetainedUntil sets field value
|
||||
func (o *GetBackupResponse) SetRetainedUntil(v GetBackupResponseGetRetainedUntilRetType) {
|
||||
setGetBackupResponseGetRetainedUntilAttributeType(&o.RetainedUntil, v)
|
||||
}
|
||||
|
||||
// GetSize returns the Size field value
|
||||
func (o *GetBackupResponse) GetSize() (ret GetBackupResponseGetSizeRetType) {
|
||||
ret, _ = o.GetSizeOk()
|
||||
return ret
|
||||
}
|
||||
|
||||
// GetSizeOk returns a tuple with the Size field value
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *GetBackupResponse) GetSizeOk() (ret GetBackupResponseGetSizeRetType, ok bool) {
|
||||
return getGetBackupResponseGetSizeAttributeTypeOk(o.Size)
|
||||
}
|
||||
|
||||
// SetSize sets field value
|
||||
func (o *GetBackupResponse) SetSize(v GetBackupResponseGetSizeRetType) {
|
||||
setGetBackupResponseGetSizeAttributeType(&o.Size, v)
|
||||
}
|
||||
|
||||
// GetType returns the Type field value
|
||||
func (o *GetBackupResponse) GetType() (ret GetBackupResponseGetTypeRetType) {
|
||||
ret, _ = o.GetTypeOk()
|
||||
return ret
|
||||
}
|
||||
|
||||
// GetTypeOk returns a tuple with the Type field value
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *GetBackupResponse) GetTypeOk() (ret GetBackupResponseGetTypeRetType, ok bool) {
|
||||
return getGetBackupResponseGetTypeAttributeTypeOk(o.Type)
|
||||
}
|
||||
|
||||
// SetType sets field value
|
||||
func (o *GetBackupResponse) SetType(v GetBackupResponseGetTypeRetType) {
|
||||
setGetBackupResponseGetTypeAttributeType(&o.Type, v)
|
||||
}
|
||||
|
||||
func (o GetBackupResponse) ToMap() (map[string]interface{}, error) {
|
||||
toSerialize := map[string]interface{}{}
|
||||
if val, ok := getGetBackupResponseGetCompletionTimeAttributeTypeOk(o.CompletionTime); ok {
|
||||
toSerialize["CompletionTime"] = val
|
||||
}
|
||||
if val, ok := getGetBackupResponseGetIdAttributeTypeOk(o.Id); ok {
|
||||
toSerialize["Id"] = val
|
||||
}
|
||||
if val, ok := getGetBackupResponseGetNameAttributeTypeOk(o.Name); ok {
|
||||
toSerialize["Name"] = val
|
||||
}
|
||||
if val, ok := getGetBackupResponseGetRetainedUntilAttributeTypeOk(o.RetainedUntil); ok {
|
||||
toSerialize["RetainedUntil"] = val
|
||||
}
|
||||
if val, ok := getGetBackupResponseGetSizeAttributeTypeOk(o.Size); ok {
|
||||
toSerialize["Size"] = val
|
||||
}
|
||||
if val, ok := getGetBackupResponseGetTypeAttributeTypeOk(o.Type); ok {
|
||||
toSerialize["Type"] = val
|
||||
}
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
type NullableGetBackupResponse struct {
|
||||
value *GetBackupResponse
|
||||
isSet bool
|
||||
}
|
||||
|
||||
func (v NullableGetBackupResponse) Get() *GetBackupResponse {
|
||||
return v.value
|
||||
}
|
||||
|
||||
func (v *NullableGetBackupResponse) Set(val *GetBackupResponse) {
|
||||
v.value = val
|
||||
v.isSet = true
|
||||
}
|
||||
|
||||
func (v NullableGetBackupResponse) IsSet() bool {
|
||||
return v.isSet
|
||||
}
|
||||
|
||||
func (v *NullableGetBackupResponse) Unset() {
|
||||
v.value = nil
|
||||
v.isSet = false
|
||||
}
|
||||
|
||||
func NewNullableGetBackupResponse(val *GetBackupResponse) *NullableGetBackupResponse {
|
||||
return &NullableGetBackupResponse{value: val, isSet: true}
|
||||
}
|
||||
|
||||
func (v NullableGetBackupResponse) MarshalJSON() ([]byte, error) {
|
||||
return json.Marshal(v.value)
|
||||
}
|
||||
|
||||
func (v *NullableGetBackupResponse) UnmarshalJSON(src []byte) error {
|
||||
v.isSet = true
|
||||
return json.Unmarshal(src, &v.value)
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue