terraform-provider-stackitp.../pkg/edgebeta/model_user.go
Marcel S. Henselin 9f41c4da7f
Some checks failed
Publish / Check GoReleaser config (push) Successful in 4s
Release / goreleaser (push) Failing after 29s
Publish / Publish provider (push) Failing after 4m24s
feat: auto generated files and new structure (#4)
## Description

<!-- **Please link some issue here describing what you are trying to achieve.**

In case there is no issue present for your PR, please consider creating one.
At least please give us some description what you are trying to achieve and why your change is needed. -->

relates to #1234

## Checklist

- [ ] Issue was linked above
- [ ] Code format was applied: `make fmt`
- [ ] Examples were added / adjusted (see `examples/` directory)
- [x] Docs are up-to-date: `make generate-docs` (will be checked by CI)
- [ ] Unit tests got implemented or updated
- [ ] Acceptance tests got implemented or updated (see e.g. [here](f5f99d1709/stackit/internal/services/dns/dns_acc_test.go))
- [x] Unit tests are passing: `make test` (will be checked by CI)
- [x] No linter issues: `make lint` (will be checked by CI)

Reviewed-on: #4
Reviewed-by: Andre_Harms <andre.harms@stackit.cloud>
Co-authored-by: Marcel S. Henselin <marcel.henselin@stackit.cloud>
Co-committed-by: Marcel S. Henselin <marcel.henselin@stackit.cloud>
2026-01-29 14:10:25 +00:00

172 lines
4.3 KiB
Go

/*
STACKIT Edge Cloud API
This API provides endpoints for managing STACKIT Edge Cloud instances.
API version: 1beta1
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package edgebeta
import (
"encoding/json"
)
// checks if the User type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &User{}
/*
types and functions for email
*/
// isNotNullableString
type UserGetEmailAttributeType = *string
func getUserGetEmailAttributeTypeOk(arg UserGetEmailAttributeType) (ret UserGetEmailRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
func setUserGetEmailAttributeType(arg *UserGetEmailAttributeType, val UserGetEmailRetType) {
*arg = &val
}
type UserGetEmailArgType = string
type UserGetEmailRetType = string
/*
types and functions for internalId
*/
// isNotNullableString
type UserGetInternalIdAttributeType = *string
func getUserGetInternalIdAttributeTypeOk(arg UserGetInternalIdAttributeType) (ret UserGetInternalIdRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
func setUserGetInternalIdAttributeType(arg *UserGetInternalIdAttributeType, val UserGetInternalIdRetType) {
*arg = &val
}
type UserGetInternalIdArgType = string
type UserGetInternalIdRetType = string
// User struct for User
type User struct {
// The email of the user.
// REQUIRED
Email UserGetEmailAttributeType `json:"email" required:"true"`
// The UUID of the user.
// REQUIRED
InternalId UserGetInternalIdAttributeType `json:"internalId" required:"true"`
}
type _User User
// NewUser instantiates a new User 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 NewUser(email UserGetEmailArgType, internalId UserGetInternalIdArgType) *User {
this := User{}
setUserGetEmailAttributeType(&this.Email, email)
setUserGetInternalIdAttributeType(&this.InternalId, internalId)
return &this
}
// NewUserWithDefaults instantiates a new User 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 NewUserWithDefaults() *User {
this := User{}
return &this
}
// GetEmail returns the Email field value
func (o *User) GetEmail() (ret UserGetEmailRetType) {
ret, _ = o.GetEmailOk()
return ret
}
// GetEmailOk returns a tuple with the Email field value
// and a boolean to check if the value has been set.
func (o *User) GetEmailOk() (ret UserGetEmailRetType, ok bool) {
return getUserGetEmailAttributeTypeOk(o.Email)
}
// SetEmail sets field value
func (o *User) SetEmail(v UserGetEmailRetType) {
setUserGetEmailAttributeType(&o.Email, v)
}
// GetInternalId returns the InternalId field value
func (o *User) GetInternalId() (ret UserGetInternalIdRetType) {
ret, _ = o.GetInternalIdOk()
return ret
}
// GetInternalIdOk returns a tuple with the InternalId field value
// and a boolean to check if the value has been set.
func (o *User) GetInternalIdOk() (ret UserGetInternalIdRetType, ok bool) {
return getUserGetInternalIdAttributeTypeOk(o.InternalId)
}
// SetInternalId sets field value
func (o *User) SetInternalId(v UserGetInternalIdRetType) {
setUserGetInternalIdAttributeType(&o.InternalId, v)
}
func (o User) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
if val, ok := getUserGetEmailAttributeTypeOk(o.Email); ok {
toSerialize["Email"] = val
}
if val, ok := getUserGetInternalIdAttributeTypeOk(o.InternalId); ok {
toSerialize["InternalId"] = val
}
return toSerialize, nil
}
type NullableUser struct {
value *User
isSet bool
}
func (v NullableUser) Get() *User {
return v.value
}
func (v *NullableUser) Set(val *User) {
v.value = val
v.isSet = true
}
func (v NullableUser) IsSet() bool {
return v.isSet
}
func (v *NullableUser) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableUser(val *User) *NullableUser {
return &NullableUser{value: val, isSet: true}
}
func (v NullableUser) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableUser) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}