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
175
pkg/postgresflexalpha/model_create_user_request_payload.go
Normal file
175
pkg/postgresflexalpha/model_create_user_request_payload.go
Normal file
|
|
@ -0,0 +1,175 @@
|
|||
/*
|
||||
PostgreSQL Flex API
|
||||
|
||||
This is the documentation for the STACKIT Postgres Flex service
|
||||
|
||||
API version: 3alpha1
|
||||
*/
|
||||
|
||||
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
||||
|
||||
package postgresflexalpha
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
)
|
||||
|
||||
// checks if the CreateUserRequestPayload type satisfies the MappedNullable interface at compile time
|
||||
var _ MappedNullable = &CreateUserRequestPayload{}
|
||||
|
||||
/*
|
||||
types and functions for name
|
||||
*/
|
||||
|
||||
// isNotNullableString
|
||||
type CreateUserRequestPayloadGetNameAttributeType = *string
|
||||
|
||||
func getCreateUserRequestPayloadGetNameAttributeTypeOk(arg CreateUserRequestPayloadGetNameAttributeType) (ret CreateUserRequestPayloadGetNameRetType, ok bool) {
|
||||
if arg == nil {
|
||||
return ret, false
|
||||
}
|
||||
return *arg, true
|
||||
}
|
||||
|
||||
func setCreateUserRequestPayloadGetNameAttributeType(arg *CreateUserRequestPayloadGetNameAttributeType, val CreateUserRequestPayloadGetNameRetType) {
|
||||
*arg = &val
|
||||
}
|
||||
|
||||
type CreateUserRequestPayloadGetNameArgType = string
|
||||
type CreateUserRequestPayloadGetNameRetType = string
|
||||
|
||||
/*
|
||||
types and functions for roles
|
||||
*/
|
||||
|
||||
// isArray
|
||||
type CreateUserRequestPayloadGetRolesAttributeType = *[]UserRole
|
||||
type CreateUserRequestPayloadGetRolesArgType = []UserRole
|
||||
type CreateUserRequestPayloadGetRolesRetType = []UserRole
|
||||
|
||||
func getCreateUserRequestPayloadGetRolesAttributeTypeOk(arg CreateUserRequestPayloadGetRolesAttributeType) (ret CreateUserRequestPayloadGetRolesRetType, ok bool) {
|
||||
if arg == nil {
|
||||
return ret, false
|
||||
}
|
||||
return *arg, true
|
||||
}
|
||||
|
||||
func setCreateUserRequestPayloadGetRolesAttributeType(arg *CreateUserRequestPayloadGetRolesAttributeType, val CreateUserRequestPayloadGetRolesRetType) {
|
||||
*arg = &val
|
||||
}
|
||||
|
||||
// CreateUserRequestPayload struct for CreateUserRequestPayload
|
||||
type CreateUserRequestPayload struct {
|
||||
// The name of the user.
|
||||
// REQUIRED
|
||||
Name CreateUserRequestPayloadGetNameAttributeType `json:"name" required:"true"`
|
||||
// A list containing the user roles for the instance.
|
||||
Roles CreateUserRequestPayloadGetRolesAttributeType `json:"roles,omitempty"`
|
||||
}
|
||||
|
||||
type _CreateUserRequestPayload CreateUserRequestPayload
|
||||
|
||||
// NewCreateUserRequestPayload instantiates a new CreateUserRequestPayload 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 NewCreateUserRequestPayload(name CreateUserRequestPayloadGetNameArgType) *CreateUserRequestPayload {
|
||||
this := CreateUserRequestPayload{}
|
||||
setCreateUserRequestPayloadGetNameAttributeType(&this.Name, name)
|
||||
return &this
|
||||
}
|
||||
|
||||
// NewCreateUserRequestPayloadWithDefaults instantiates a new CreateUserRequestPayload 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 NewCreateUserRequestPayloadWithDefaults() *CreateUserRequestPayload {
|
||||
this := CreateUserRequestPayload{}
|
||||
return &this
|
||||
}
|
||||
|
||||
// GetName returns the Name field value
|
||||
func (o *CreateUserRequestPayload) GetName() (ret CreateUserRequestPayloadGetNameRetType) {
|
||||
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 *CreateUserRequestPayload) GetNameOk() (ret CreateUserRequestPayloadGetNameRetType, ok bool) {
|
||||
return getCreateUserRequestPayloadGetNameAttributeTypeOk(o.Name)
|
||||
}
|
||||
|
||||
// SetName sets field value
|
||||
func (o *CreateUserRequestPayload) SetName(v CreateUserRequestPayloadGetNameRetType) {
|
||||
setCreateUserRequestPayloadGetNameAttributeType(&o.Name, v)
|
||||
}
|
||||
|
||||
// GetRoles returns the Roles field value if set, zero value otherwise.
|
||||
func (o *CreateUserRequestPayload) GetRoles() (res CreateUserRequestPayloadGetRolesRetType) {
|
||||
res, _ = o.GetRolesOk()
|
||||
return
|
||||
}
|
||||
|
||||
// GetRolesOk returns a tuple with the Roles field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *CreateUserRequestPayload) GetRolesOk() (ret CreateUserRequestPayloadGetRolesRetType, ok bool) {
|
||||
return getCreateUserRequestPayloadGetRolesAttributeTypeOk(o.Roles)
|
||||
}
|
||||
|
||||
// HasRoles returns a boolean if a field has been set.
|
||||
func (o *CreateUserRequestPayload) HasRoles() bool {
|
||||
_, ok := o.GetRolesOk()
|
||||
return ok
|
||||
}
|
||||
|
||||
// SetRoles gets a reference to the given []UserRole and assigns it to the Roles field.
|
||||
func (o *CreateUserRequestPayload) SetRoles(v CreateUserRequestPayloadGetRolesRetType) {
|
||||
setCreateUserRequestPayloadGetRolesAttributeType(&o.Roles, v)
|
||||
}
|
||||
|
||||
func (o CreateUserRequestPayload) ToMap() (map[string]interface{}, error) {
|
||||
toSerialize := map[string]interface{}{}
|
||||
if val, ok := getCreateUserRequestPayloadGetNameAttributeTypeOk(o.Name); ok {
|
||||
toSerialize["Name"] = val
|
||||
}
|
||||
if val, ok := getCreateUserRequestPayloadGetRolesAttributeTypeOk(o.Roles); ok {
|
||||
toSerialize["Roles"] = val
|
||||
}
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
type NullableCreateUserRequestPayload struct {
|
||||
value *CreateUserRequestPayload
|
||||
isSet bool
|
||||
}
|
||||
|
||||
func (v NullableCreateUserRequestPayload) Get() *CreateUserRequestPayload {
|
||||
return v.value
|
||||
}
|
||||
|
||||
func (v *NullableCreateUserRequestPayload) Set(val *CreateUserRequestPayload) {
|
||||
v.value = val
|
||||
v.isSet = true
|
||||
}
|
||||
|
||||
func (v NullableCreateUserRequestPayload) IsSet() bool {
|
||||
return v.isSet
|
||||
}
|
||||
|
||||
func (v *NullableCreateUserRequestPayload) Unset() {
|
||||
v.value = nil
|
||||
v.isSet = false
|
||||
}
|
||||
|
||||
func NewNullableCreateUserRequestPayload(val *CreateUserRequestPayload) *NullableCreateUserRequestPayload {
|
||||
return &NullableCreateUserRequestPayload{value: val, isSet: true}
|
||||
}
|
||||
|
||||
func (v NullableCreateUserRequestPayload) MarshalJSON() ([]byte, error) {
|
||||
return json.Marshal(v.value)
|
||||
}
|
||||
|
||||
func (v *NullableCreateUserRequestPayload) UnmarshalJSON(src []byte) error {
|
||||
v.isSet = true
|
||||
return json.Unmarshal(src, &v.value)
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue