This repository has been archived by the owner on Aug 21, 2023. It is now read-only.
/
model_dns_query_mdt.go
260 lines (217 loc) · 7.06 KB
/
model_dns_query_mdt.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
/*
Neasdf_BaselineDNSPattern
EASDF Baseline DNS Pattern Service. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved.
API version: 1.1.0-alpha.1
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package openapi_Neasdf_BaselineDNSPattern
import (
"encoding/json"
)
// checks if the DnsQueryMdt type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &DnsQueryMdt{}
// DnsQueryMdt DNS Query message detection template
type DnsQueryMdt struct {
MdtId string `json:"mdtId"`
Label *string `json:"label,omitempty"`
// String identifying a IPv4 address formatted in the 'dotted decimal' notation as defined in RFC 1166.
SourceIpv4Addr *string `json:"sourceIpv4Addr,omitempty"`
SourceIpv6Prefix *Ipv6Prefix `json:"sourceIpv6Prefix,omitempty"`
FqdnPatternList []FqdnPatternMatchingRule `json:"fqdnPatternList,omitempty"`
}
// NewDnsQueryMdt instantiates a new DnsQueryMdt 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 NewDnsQueryMdt(mdtId string) *DnsQueryMdt {
this := DnsQueryMdt{}
this.MdtId = mdtId
return &this
}
// NewDnsQueryMdtWithDefaults instantiates a new DnsQueryMdt 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 NewDnsQueryMdtWithDefaults() *DnsQueryMdt {
this := DnsQueryMdt{}
return &this
}
// GetMdtId returns the MdtId field value
func (o *DnsQueryMdt) GetMdtId() string {
if o == nil {
var ret string
return ret
}
return o.MdtId
}
// GetMdtIdOk returns a tuple with the MdtId field value
// and a boolean to check if the value has been set.
func (o *DnsQueryMdt) GetMdtIdOk() (*string, bool) {
if o == nil {
return nil, false
}
return &o.MdtId, true
}
// SetMdtId sets field value
func (o *DnsQueryMdt) SetMdtId(v string) {
o.MdtId = v
}
// GetLabel returns the Label field value if set, zero value otherwise.
func (o *DnsQueryMdt) GetLabel() string {
if o == nil || IsNil(o.Label) {
var ret string
return ret
}
return *o.Label
}
// GetLabelOk returns a tuple with the Label field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *DnsQueryMdt) GetLabelOk() (*string, bool) {
if o == nil || IsNil(o.Label) {
return nil, false
}
return o.Label, true
}
// HasLabel returns a boolean if a field has been set.
func (o *DnsQueryMdt) HasLabel() bool {
if o != nil && !IsNil(o.Label) {
return true
}
return false
}
// SetLabel gets a reference to the given string and assigns it to the Label field.
func (o *DnsQueryMdt) SetLabel(v string) {
o.Label = &v
}
// GetSourceIpv4Addr returns the SourceIpv4Addr field value if set, zero value otherwise.
func (o *DnsQueryMdt) GetSourceIpv4Addr() string {
if o == nil || IsNil(o.SourceIpv4Addr) {
var ret string
return ret
}
return *o.SourceIpv4Addr
}
// GetSourceIpv4AddrOk returns a tuple with the SourceIpv4Addr field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *DnsQueryMdt) GetSourceIpv4AddrOk() (*string, bool) {
if o == nil || IsNil(o.SourceIpv4Addr) {
return nil, false
}
return o.SourceIpv4Addr, true
}
// HasSourceIpv4Addr returns a boolean if a field has been set.
func (o *DnsQueryMdt) HasSourceIpv4Addr() bool {
if o != nil && !IsNil(o.SourceIpv4Addr) {
return true
}
return false
}
// SetSourceIpv4Addr gets a reference to the given string and assigns it to the SourceIpv4Addr field.
func (o *DnsQueryMdt) SetSourceIpv4Addr(v string) {
o.SourceIpv4Addr = &v
}
// GetSourceIpv6Prefix returns the SourceIpv6Prefix field value if set, zero value otherwise.
func (o *DnsQueryMdt) GetSourceIpv6Prefix() Ipv6Prefix {
if o == nil || IsNil(o.SourceIpv6Prefix) {
var ret Ipv6Prefix
return ret
}
return *o.SourceIpv6Prefix
}
// GetSourceIpv6PrefixOk returns a tuple with the SourceIpv6Prefix field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *DnsQueryMdt) GetSourceIpv6PrefixOk() (*Ipv6Prefix, bool) {
if o == nil || IsNil(o.SourceIpv6Prefix) {
return nil, false
}
return o.SourceIpv6Prefix, true
}
// HasSourceIpv6Prefix returns a boolean if a field has been set.
func (o *DnsQueryMdt) HasSourceIpv6Prefix() bool {
if o != nil && !IsNil(o.SourceIpv6Prefix) {
return true
}
return false
}
// SetSourceIpv6Prefix gets a reference to the given Ipv6Prefix and assigns it to the SourceIpv6Prefix field.
func (o *DnsQueryMdt) SetSourceIpv6Prefix(v Ipv6Prefix) {
o.SourceIpv6Prefix = &v
}
// GetFqdnPatternList returns the FqdnPatternList field value if set, zero value otherwise.
func (o *DnsQueryMdt) GetFqdnPatternList() []FqdnPatternMatchingRule {
if o == nil || IsNil(o.FqdnPatternList) {
var ret []FqdnPatternMatchingRule
return ret
}
return o.FqdnPatternList
}
// GetFqdnPatternListOk returns a tuple with the FqdnPatternList field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *DnsQueryMdt) GetFqdnPatternListOk() ([]FqdnPatternMatchingRule, bool) {
if o == nil || IsNil(o.FqdnPatternList) {
return nil, false
}
return o.FqdnPatternList, true
}
// HasFqdnPatternList returns a boolean if a field has been set.
func (o *DnsQueryMdt) HasFqdnPatternList() bool {
if o != nil && !IsNil(o.FqdnPatternList) {
return true
}
return false
}
// SetFqdnPatternList gets a reference to the given []FqdnPatternMatchingRule and assigns it to the FqdnPatternList field.
func (o *DnsQueryMdt) SetFqdnPatternList(v []FqdnPatternMatchingRule) {
o.FqdnPatternList = v
}
func (o DnsQueryMdt) MarshalJSON() ([]byte, error) {
toSerialize, err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o DnsQueryMdt) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
toSerialize["mdtId"] = o.MdtId
if !IsNil(o.Label) {
toSerialize["label"] = o.Label
}
if !IsNil(o.SourceIpv4Addr) {
toSerialize["sourceIpv4Addr"] = o.SourceIpv4Addr
}
if !IsNil(o.SourceIpv6Prefix) {
toSerialize["sourceIpv6Prefix"] = o.SourceIpv6Prefix
}
if !IsNil(o.FqdnPatternList) {
toSerialize["fqdnPatternList"] = o.FqdnPatternList
}
return toSerialize, nil
}
type NullableDnsQueryMdt struct {
value *DnsQueryMdt
isSet bool
}
func (v NullableDnsQueryMdt) Get() *DnsQueryMdt {
return v.value
}
func (v *NullableDnsQueryMdt) Set(val *DnsQueryMdt) {
v.value = val
v.isSet = true
}
func (v NullableDnsQueryMdt) IsSet() bool {
return v.isSet
}
func (v *NullableDnsQueryMdt) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableDnsQueryMdt(val *DnsQueryMdt) *NullableDnsQueryMdt {
return &NullableDnsQueryMdt{value: val, isSet: true}
}
func (v NullableDnsQueryMdt) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableDnsQueryMdt) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}