-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmodel_folder.go
277 lines (233 loc) · 7.03 KB
/
model_folder.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
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
/* Copyright 2018-2020 KoreWireless
*
* This is part of the KoreWireless Omnicore SDK.
* It is licensed under the BSD 3-Clause license; you may not use this file
* except in compliance with the License.
*
* You may obtain a copy of the License at:
* https://opensource.org/licenses/BSD-3-Clause
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package OmniCore
import (
"encoding/json"
)
// checks if the Folder type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &Folder{}
// Folder struct for Folder
type Folder struct {
NoOfFiles *int32 `json:"noOfFiles,omitempty"`
FileSize *float32 `json:"fileSize,omitempty"`
Noofoperations *int32 `json:"noofoperations,omitempty"`
Updatedon *string `json:"updatedon,omitempty"`
Registryid *string `json:"registryid,omitempty"`
}
// NewFolder instantiates a new Folder 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 NewFolder() *Folder {
this := Folder{}
return &this
}
// NewFolderWithDefaults instantiates a new Folder 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 NewFolderWithDefaults() *Folder {
this := Folder{}
return &this
}
// GetNoOfFiles returns the NoOfFiles field value if set, zero value otherwise.
func (o *Folder) GetNoOfFiles() int32 {
if o == nil || IsNil(o.NoOfFiles) {
var ret int32
return ret
}
return *o.NoOfFiles
}
// GetNoOfFilesOk returns a tuple with the NoOfFiles field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *Folder) GetNoOfFilesOk() (*int32, bool) {
if o == nil || IsNil(o.NoOfFiles) {
return nil, false
}
return o.NoOfFiles, true
}
// HasNoOfFiles returns a boolean if a field has been set.
func (o *Folder) HasNoOfFiles() bool {
if o != nil && !IsNil(o.NoOfFiles) {
return true
}
return false
}
// SetNoOfFiles gets a reference to the given int32 and assigns it to the NoOfFiles field.
func (o *Folder) SetNoOfFiles(v int32) {
o.NoOfFiles = &v
}
// GetFileSize returns the FileSize field value if set, zero value otherwise.
func (o *Folder) GetFileSize() float32 {
if o == nil || IsNil(o.FileSize) {
var ret float32
return ret
}
return *o.FileSize
}
// GetFileSizeOk returns a tuple with the FileSize field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *Folder) GetFileSizeOk() (*float32, bool) {
if o == nil || IsNil(o.FileSize) {
return nil, false
}
return o.FileSize, true
}
// HasFileSize returns a boolean if a field has been set.
func (o *Folder) HasFileSize() bool {
if o != nil && !IsNil(o.FileSize) {
return true
}
return false
}
// SetFileSize gets a reference to the given float32 and assigns it to the FileSize field.
func (o *Folder) SetFileSize(v float32) {
o.FileSize = &v
}
// GetNoofoperations returns the Noofoperations field value if set, zero value otherwise.
func (o *Folder) GetNoofoperations() int32 {
if o == nil || IsNil(o.Noofoperations) {
var ret int32
return ret
}
return *o.Noofoperations
}
// GetNoofoperationsOk returns a tuple with the Noofoperations field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *Folder) GetNoofoperationsOk() (*int32, bool) {
if o == nil || IsNil(o.Noofoperations) {
return nil, false
}
return o.Noofoperations, true
}
// HasNoofoperations returns a boolean if a field has been set.
func (o *Folder) HasNoofoperations() bool {
if o != nil && !IsNil(o.Noofoperations) {
return true
}
return false
}
// SetNoofoperations gets a reference to the given int32 and assigns it to the Noofoperations field.
func (o *Folder) SetNoofoperations(v int32) {
o.Noofoperations = &v
}
// GetUpdatedon returns the Updatedon field value if set, zero value otherwise.
func (o *Folder) GetUpdatedon() string {
if o == nil || IsNil(o.Updatedon) {
var ret string
return ret
}
return *o.Updatedon
}
// GetUpdatedonOk returns a tuple with the Updatedon field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *Folder) GetUpdatedonOk() (*string, bool) {
if o == nil || IsNil(o.Updatedon) {
return nil, false
}
return o.Updatedon, true
}
// HasUpdatedon returns a boolean if a field has been set.
func (o *Folder) HasUpdatedon() bool {
if o != nil && !IsNil(o.Updatedon) {
return true
}
return false
}
// SetUpdatedon gets a reference to the given string and assigns it to the Updatedon field.
func (o *Folder) SetUpdatedon(v string) {
o.Updatedon = &v
}
// GetRegistryid returns the Registryid field value if set, zero value otherwise.
func (o *Folder) GetRegistryid() string {
if o == nil || IsNil(o.Registryid) {
var ret string
return ret
}
return *o.Registryid
}
// GetRegistryidOk returns a tuple with the Registryid field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *Folder) GetRegistryidOk() (*string, bool) {
if o == nil || IsNil(o.Registryid) {
return nil, false
}
return o.Registryid, true
}
// HasRegistryid returns a boolean if a field has been set.
func (o *Folder) HasRegistryid() bool {
if o != nil && !IsNil(o.Registryid) {
return true
}
return false
}
// SetRegistryid gets a reference to the given string and assigns it to the Registryid field.
func (o *Folder) SetRegistryid(v string) {
o.Registryid = &v
}
func (o Folder) MarshalJSON() ([]byte, error) {
toSerialize,err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o Folder) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
if !IsNil(o.NoOfFiles) {
toSerialize["noOfFiles"] = o.NoOfFiles
}
if !IsNil(o.FileSize) {
toSerialize["fileSize"] = o.FileSize
}
if !IsNil(o.Noofoperations) {
toSerialize["noofoperations"] = o.Noofoperations
}
if !IsNil(o.Updatedon) {
toSerialize["updatedon"] = o.Updatedon
}
if !IsNil(o.Registryid) {
toSerialize["registryid"] = o.Registryid
}
return toSerialize, nil
}
type NullableFolder struct {
value *Folder
isSet bool
}
func (v NullableFolder) Get() *Folder {
return v.value
}
func (v *NullableFolder) Set(val *Folder) {
v.value = val
v.isSet = true
}
func (v NullableFolder) IsSet() bool {
return v.isSet
}
func (v *NullableFolder) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableFolder(val *Folder) *NullableFolder {
return &NullableFolder{value: val, isSet: true}
}
func (v NullableFolder) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableFolder) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}