terraform-provider-stackitp.../pkg/cdnbeta/model_put_custom_domain_custom_certificate.go
2026-01-21 09:07:29 +01:00

216 lines
8 KiB
Go

/*
CDN API
API used to create and manage your CDN distributions.
API version: 1beta2.0.0
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package cdnbeta
import (
"encoding/json"
)
// checks if the PutCustomDomainCustomCertificate type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &PutCustomDomainCustomCertificate{}
/*
types and functions for certificate
*/
// isNotNullableString
type PutCustomDomainCustomCertificateGetCertificateAttributeType = *string
func getPutCustomDomainCustomCertificateGetCertificateAttributeTypeOk(arg PutCustomDomainCustomCertificateGetCertificateAttributeType) (ret PutCustomDomainCustomCertificateGetCertificateRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
func setPutCustomDomainCustomCertificateGetCertificateAttributeType(arg *PutCustomDomainCustomCertificateGetCertificateAttributeType, val PutCustomDomainCustomCertificateGetCertificateRetType) {
*arg = &val
}
type PutCustomDomainCustomCertificateGetCertificateArgType = string
type PutCustomDomainCustomCertificateGetCertificateRetType = string
/*
types and functions for key
*/
// isNotNullableString
type PutCustomDomainCustomCertificateGetKeyAttributeType = *string
func getPutCustomDomainCustomCertificateGetKeyAttributeTypeOk(arg PutCustomDomainCustomCertificateGetKeyAttributeType) (ret PutCustomDomainCustomCertificateGetKeyRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
func setPutCustomDomainCustomCertificateGetKeyAttributeType(arg *PutCustomDomainCustomCertificateGetKeyAttributeType, val PutCustomDomainCustomCertificateGetKeyRetType) {
*arg = &val
}
type PutCustomDomainCustomCertificateGetKeyArgType = string
type PutCustomDomainCustomCertificateGetKeyRetType = string
/*
types and functions for type
*/
// isNotNullableString
type PutCustomDomainCustomCertificateGetTypeAttributeType = *string
func getPutCustomDomainCustomCertificateGetTypeAttributeTypeOk(arg PutCustomDomainCustomCertificateGetTypeAttributeType) (ret PutCustomDomainCustomCertificateGetTypeRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
func setPutCustomDomainCustomCertificateGetTypeAttributeType(arg *PutCustomDomainCustomCertificateGetTypeAttributeType, val PutCustomDomainCustomCertificateGetTypeRetType) {
*arg = &val
}
type PutCustomDomainCustomCertificateGetTypeArgType = string
type PutCustomDomainCustomCertificateGetTypeRetType = string
// PutCustomDomainCustomCertificate Returned if a custom certificate is used. Response does not contain the certificate or key.
type PutCustomDomainCustomCertificate struct {
// base64-encoded PEM-encoded certificate
// REQUIRED
Certificate PutCustomDomainCustomCertificateGetCertificateAttributeType `json:"certificate" required:"true"`
// base64-encoded PEM encoded key
// REQUIRED
Key PutCustomDomainCustomCertificateGetKeyAttributeType `json:"key" required:"true"`
// REQUIRED
Type PutCustomDomainCustomCertificateGetTypeAttributeType `json:"type" required:"true"`
}
type _PutCustomDomainCustomCertificate PutCustomDomainCustomCertificate
// NewPutCustomDomainCustomCertificate instantiates a new PutCustomDomainCustomCertificate 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 NewPutCustomDomainCustomCertificate(certificate PutCustomDomainCustomCertificateGetCertificateArgType, key PutCustomDomainCustomCertificateGetKeyArgType, types PutCustomDomainCustomCertificateGetTypeArgType) *PutCustomDomainCustomCertificate {
this := PutCustomDomainCustomCertificate{}
setPutCustomDomainCustomCertificateGetCertificateAttributeType(&this.Certificate, certificate)
setPutCustomDomainCustomCertificateGetKeyAttributeType(&this.Key, key)
setPutCustomDomainCustomCertificateGetTypeAttributeType(&this.Type, types)
return &this
}
// NewPutCustomDomainCustomCertificateWithDefaults instantiates a new PutCustomDomainCustomCertificate 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 NewPutCustomDomainCustomCertificateWithDefaults() *PutCustomDomainCustomCertificate {
this := PutCustomDomainCustomCertificate{}
return &this
}
// GetCertificate returns the Certificate field value
func (o *PutCustomDomainCustomCertificate) GetCertificate() (ret PutCustomDomainCustomCertificateGetCertificateRetType) {
ret, _ = o.GetCertificateOk()
return ret
}
// GetCertificateOk returns a tuple with the Certificate field value
// and a boolean to check if the value has been set.
func (o *PutCustomDomainCustomCertificate) GetCertificateOk() (ret PutCustomDomainCustomCertificateGetCertificateRetType, ok bool) {
return getPutCustomDomainCustomCertificateGetCertificateAttributeTypeOk(o.Certificate)
}
// SetCertificate sets field value
func (o *PutCustomDomainCustomCertificate) SetCertificate(v PutCustomDomainCustomCertificateGetCertificateRetType) {
setPutCustomDomainCustomCertificateGetCertificateAttributeType(&o.Certificate, v)
}
// GetKey returns the Key field value
func (o *PutCustomDomainCustomCertificate) GetKey() (ret PutCustomDomainCustomCertificateGetKeyRetType) {
ret, _ = o.GetKeyOk()
return ret
}
// GetKeyOk returns a tuple with the Key field value
// and a boolean to check if the value has been set.
func (o *PutCustomDomainCustomCertificate) GetKeyOk() (ret PutCustomDomainCustomCertificateGetKeyRetType, ok bool) {
return getPutCustomDomainCustomCertificateGetKeyAttributeTypeOk(o.Key)
}
// SetKey sets field value
func (o *PutCustomDomainCustomCertificate) SetKey(v PutCustomDomainCustomCertificateGetKeyRetType) {
setPutCustomDomainCustomCertificateGetKeyAttributeType(&o.Key, v)
}
// GetType returns the Type field value
func (o *PutCustomDomainCustomCertificate) GetType() (ret PutCustomDomainCustomCertificateGetTypeRetType) {
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 *PutCustomDomainCustomCertificate) GetTypeOk() (ret PutCustomDomainCustomCertificateGetTypeRetType, ok bool) {
return getPutCustomDomainCustomCertificateGetTypeAttributeTypeOk(o.Type)
}
// SetType sets field value
func (o *PutCustomDomainCustomCertificate) SetType(v PutCustomDomainCustomCertificateGetTypeRetType) {
setPutCustomDomainCustomCertificateGetTypeAttributeType(&o.Type, v)
}
func (o PutCustomDomainCustomCertificate) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
if val, ok := getPutCustomDomainCustomCertificateGetCertificateAttributeTypeOk(o.Certificate); ok {
toSerialize["Certificate"] = val
}
if val, ok := getPutCustomDomainCustomCertificateGetKeyAttributeTypeOk(o.Key); ok {
toSerialize["Key"] = val
}
if val, ok := getPutCustomDomainCustomCertificateGetTypeAttributeTypeOk(o.Type); ok {
toSerialize["Type"] = val
}
return toSerialize, nil
}
type NullablePutCustomDomainCustomCertificate struct {
value *PutCustomDomainCustomCertificate
isSet bool
}
func (v NullablePutCustomDomainCustomCertificate) Get() *PutCustomDomainCustomCertificate {
return v.value
}
func (v *NullablePutCustomDomainCustomCertificate) Set(val *PutCustomDomainCustomCertificate) {
v.value = val
v.isSet = true
}
func (v NullablePutCustomDomainCustomCertificate) IsSet() bool {
return v.isSet
}
func (v *NullablePutCustomDomainCustomCertificate) Unset() {
v.value = nil
v.isSet = false
}
func NewNullablePutCustomDomainCustomCertificate(val *PutCustomDomainCustomCertificate) *NullablePutCustomDomainCustomCertificate {
return &NullablePutCustomDomainCustomCertificate{value: val, isSet: true}
}
func (v NullablePutCustomDomainCustomCertificate) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullablePutCustomDomainCustomCertificate) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}