/* Intelligent DNS API No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) API version: 1.0.0 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. package idns import ( "encoding/json" ) // checks if the DnsSecDelegationSigner type satisfies the MappedNullable interface at compile time var _ MappedNullable = &DnsSecDelegationSigner{} // DnsSecDelegationSigner struct for DnsSecDelegationSigner type DnsSecDelegationSigner struct { DigestType *DnsSecDelegationSignerDigestType `json:"digest_type,omitempty"` AlgorithmType *DnsSecDelegationSignerDigestType `json:"algorithm_type,omitempty"` Digest *string `json:"digest,omitempty"` KeyTag *int32 `json:"key_tag,omitempty"` } // NewDnsSecDelegationSigner instantiates a new DnsSecDelegationSigner 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 NewDnsSecDelegationSigner() *DnsSecDelegationSigner { this := DnsSecDelegationSigner{} return &this } // NewDnsSecDelegationSignerWithDefaults instantiates a new DnsSecDelegationSigner 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 NewDnsSecDelegationSignerWithDefaults() *DnsSecDelegationSigner { this := DnsSecDelegationSigner{} return &this } // GetDigestType returns the DigestType field value if set, zero value otherwise. func (o *DnsSecDelegationSigner) GetDigestType() DnsSecDelegationSignerDigestType { if o == nil || IsNil(o.DigestType) { var ret DnsSecDelegationSignerDigestType return ret } return *o.DigestType } // GetDigestTypeOk returns a tuple with the DigestType field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *DnsSecDelegationSigner) GetDigestTypeOk() (*DnsSecDelegationSignerDigestType, bool) { if o == nil || IsNil(o.DigestType) { return nil, false } return o.DigestType, true } // HasDigestType returns a boolean if a field has been set. func (o *DnsSecDelegationSigner) HasDigestType() bool { if o != nil && !IsNil(o.DigestType) { return true } return false } // SetDigestType gets a reference to the given DnsSecDelegationSignerDigestType and assigns it to the DigestType field. func (o *DnsSecDelegationSigner) SetDigestType(v DnsSecDelegationSignerDigestType) { o.DigestType = &v } // GetAlgorithmType returns the AlgorithmType field value if set, zero value otherwise. func (o *DnsSecDelegationSigner) GetAlgorithmType() DnsSecDelegationSignerDigestType { if o == nil || IsNil(o.AlgorithmType) { var ret DnsSecDelegationSignerDigestType return ret } return *o.AlgorithmType } // GetAlgorithmTypeOk returns a tuple with the AlgorithmType field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *DnsSecDelegationSigner) GetAlgorithmTypeOk() (*DnsSecDelegationSignerDigestType, bool) { if o == nil || IsNil(o.AlgorithmType) { return nil, false } return o.AlgorithmType, true } // HasAlgorithmType returns a boolean if a field has been set. func (o *DnsSecDelegationSigner) HasAlgorithmType() bool { if o != nil && !IsNil(o.AlgorithmType) { return true } return false } // SetAlgorithmType gets a reference to the given DnsSecDelegationSignerDigestType and assigns it to the AlgorithmType field. func (o *DnsSecDelegationSigner) SetAlgorithmType(v DnsSecDelegationSignerDigestType) { o.AlgorithmType = &v } // GetDigest returns the Digest field value if set, zero value otherwise. func (o *DnsSecDelegationSigner) GetDigest() string { if o == nil || IsNil(o.Digest) { var ret string return ret } return *o.Digest } // GetDigestOk returns a tuple with the Digest field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *DnsSecDelegationSigner) GetDigestOk() (*string, bool) { if o == nil || IsNil(o.Digest) { return nil, false } return o.Digest, true } // HasDigest returns a boolean if a field has been set. func (o *DnsSecDelegationSigner) HasDigest() bool { if o != nil && !IsNil(o.Digest) { return true } return false } // SetDigest gets a reference to the given string and assigns it to the Digest field. func (o *DnsSecDelegationSigner) SetDigest(v string) { o.Digest = &v } // GetKeyTag returns the KeyTag field value if set, zero value otherwise. func (o *DnsSecDelegationSigner) GetKeyTag() int32 { if o == nil || IsNil(o.KeyTag) { var ret int32 return ret } return *o.KeyTag } // GetKeyTagOk returns a tuple with the KeyTag field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *DnsSecDelegationSigner) GetKeyTagOk() (*int32, bool) { if o == nil || IsNil(o.KeyTag) { return nil, false } return o.KeyTag, true } // HasKeyTag returns a boolean if a field has been set. func (o *DnsSecDelegationSigner) HasKeyTag() bool { if o != nil && !IsNil(o.KeyTag) { return true } return false } // SetKeyTag gets a reference to the given int32 and assigns it to the KeyTag field. func (o *DnsSecDelegationSigner) SetKeyTag(v int32) { o.KeyTag = &v } func (o DnsSecDelegationSigner) MarshalJSON() ([]byte, error) { toSerialize,err := o.ToMap() if err != nil { return []byte{}, err } return json.Marshal(toSerialize) } func (o DnsSecDelegationSigner) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} if !IsNil(o.DigestType) { toSerialize["digest_type"] = o.DigestType } if !IsNil(o.AlgorithmType) { toSerialize["algorithm_type"] = o.AlgorithmType } if !IsNil(o.Digest) { toSerialize["digest"] = o.Digest } if !IsNil(o.KeyTag) { toSerialize["key_tag"] = o.KeyTag } return toSerialize, nil } type NullableDnsSecDelegationSigner struct { value *DnsSecDelegationSigner isSet bool } func (v NullableDnsSecDelegationSigner) Get() *DnsSecDelegationSigner { return v.value } func (v *NullableDnsSecDelegationSigner) Set(val *DnsSecDelegationSigner) { v.value = val v.isSet = true } func (v NullableDnsSecDelegationSigner) IsSet() bool { return v.isSet } func (v *NullableDnsSecDelegationSigner) Unset() { v.value = nil v.isSet = false } func NewNullableDnsSecDelegationSigner(val *DnsSecDelegationSigner) *NullableDnsSecDelegationSigner { return &NullableDnsSecDelegationSigner{value: val, isSet: true} } func (v NullableDnsSecDelegationSigner) MarshalJSON() ([]byte, error) { return json.Marshal(v.value) } func (v *NullableDnsSecDelegationSigner) UnmarshalJSON(src []byte) error { v.isSet = true return json.Unmarshal(src, &v.value) }