1 Star 0 Fork 0

MrCoder / openapi

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
model_fqdn_pattern_matching_rule.go 4.70 KB
一键复制 编辑 原始数据 按行查看 历史
MrCoder 提交于 2023-12-22 15:27 . update
/*
Neasdf_BaselineDNSPattern
EASDF Baseline DNS Pattern Service. © 2023, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved.
API version: 1.0.1
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package OpenAPI_Neasdf_BaselineDNSPattern
import (
"encoding/json"
)
// checks if the FqdnPatternMatchingRule type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &FqdnPatternMatchingRule{}
// FqdnPatternMatchingRule a matching rule for a FQDN pattern
type FqdnPatternMatchingRule struct {
Regex *string `json:"regex,omitempty"`
StringMatchingRule *StringMatchingRule `json:"stringMatchingRule,omitempty"`
}
// NewFqdnPatternMatchingRule instantiates a new FqdnPatternMatchingRule 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 NewFqdnPatternMatchingRule() *FqdnPatternMatchingRule {
this := FqdnPatternMatchingRule{}
return &this
}
// NewFqdnPatternMatchingRuleWithDefaults instantiates a new FqdnPatternMatchingRule 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 NewFqdnPatternMatchingRuleWithDefaults() *FqdnPatternMatchingRule {
this := FqdnPatternMatchingRule{}
return &this
}
// GetRegex returns the Regex field value if set, zero value otherwise.
func (o *FqdnPatternMatchingRule) GetRegex() string {
if o == nil || IsNil(o.Regex) {
var ret string
return ret
}
return *o.Regex
}
// GetRegexOk returns a tuple with the Regex field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *FqdnPatternMatchingRule) GetRegexOk() (*string, bool) {
if o == nil || IsNil(o.Regex) {
return nil, false
}
return o.Regex, true
}
// HasRegex returns a boolean if a field has been set.
func (o *FqdnPatternMatchingRule) HasRegex() bool {
if o != nil && !IsNil(o.Regex) {
return true
}
return false
}
// SetRegex gets a reference to the given string and assigns it to the Regex field.
func (o *FqdnPatternMatchingRule) SetRegex(v string) {
o.Regex = &v
}
// GetStringMatchingRule returns the StringMatchingRule field value if set, zero value otherwise.
func (o *FqdnPatternMatchingRule) GetStringMatchingRule() StringMatchingRule {
if o == nil || IsNil(o.StringMatchingRule) {
var ret StringMatchingRule
return ret
}
return *o.StringMatchingRule
}
// GetStringMatchingRuleOk returns a tuple with the StringMatchingRule field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *FqdnPatternMatchingRule) GetStringMatchingRuleOk() (*StringMatchingRule, bool) {
if o == nil || IsNil(o.StringMatchingRule) {
return nil, false
}
return o.StringMatchingRule, true
}
// HasStringMatchingRule returns a boolean if a field has been set.
func (o *FqdnPatternMatchingRule) HasStringMatchingRule() bool {
if o != nil && !IsNil(o.StringMatchingRule) {
return true
}
return false
}
// SetStringMatchingRule gets a reference to the given StringMatchingRule and assigns it to the StringMatchingRule field.
func (o *FqdnPatternMatchingRule) SetStringMatchingRule(v StringMatchingRule) {
o.StringMatchingRule = &v
}
func (o FqdnPatternMatchingRule) MarshalJSON() ([]byte, error) {
toSerialize, err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o FqdnPatternMatchingRule) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
if !IsNil(o.Regex) {
toSerialize["regex"] = o.Regex
}
if !IsNil(o.StringMatchingRule) {
toSerialize["stringMatchingRule"] = o.StringMatchingRule
}
return toSerialize, nil
}
type NullableFqdnPatternMatchingRule struct {
value *FqdnPatternMatchingRule
isSet bool
}
func (v NullableFqdnPatternMatchingRule) Get() *FqdnPatternMatchingRule {
return v.value
}
func (v *NullableFqdnPatternMatchingRule) Set(val *FqdnPatternMatchingRule) {
v.value = val
v.isSet = true
}
func (v NullableFqdnPatternMatchingRule) IsSet() bool {
return v.isSet
}
func (v *NullableFqdnPatternMatchingRule) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableFqdnPatternMatchingRule(val *FqdnPatternMatchingRule) *NullableFqdnPatternMatchingRule {
return &NullableFqdnPatternMatchingRule{value: val, isSet: true}
}
func (v NullableFqdnPatternMatchingRule) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableFqdnPatternMatchingRule) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}
Go
1
https://gitee.com/konglinglong/openapi.git
git@gitee.com:konglinglong/openapi.git
konglinglong
openapi
openapi
e403a3c726a4

搜索帮助