-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathmodel_meta_query.go
774 lines (660 loc) · 21.3 KB
/
model_meta_query.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
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
/*
Zinc Search engine API
Zinc Search engine API documents https://docs.zincsearch.com
API version: 0.3.3
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package client
import (
"encoding/json"
)
// MetaQuery struct for MetaQuery
type MetaQuery struct {
Bool *MetaBoolQuery `json:"bool,omitempty"`
Exists *MetaExistsQuery `json:"exists,omitempty"`
// simple, PrefixQuery
Fuzzy *map[string]MetaFuzzyQuery `json:"fuzzy,omitempty"`
Ids *MetaIdsQuery `json:"ids,omitempty"`
// simple, MatchQuery
Match *map[string]MetaMatchQuery `json:"match,omitempty"`
MatchAll map[string]interface{} `json:"match_all,omitempty"`
// simple, MatchBoolPrefixQuery
MatchBoolPrefix *map[string]MetaMatchBoolPrefixQuery `json:"match_bool_prefix,omitempty"`
MatchNone map[string]interface{} `json:"match_none,omitempty"`
// simple, MatchPhraseQuery
MatchPhrase *map[string]MetaMatchPhraseQuery `json:"match_phrase,omitempty"`
// simple, MatchPhrasePrefixQuery
MatchPhrasePrefix *map[string]MetaMatchPhrasePrefixQuery `json:"match_phrase_prefix,omitempty"`
MultiMatch *MetaMultiMatchQuery `json:"multi_match,omitempty"`
// .
Prefix *map[string]MetaPrefixQuery `json:"prefix,omitempty"`
QueryString *MetaQueryStringQuery `json:"query_string,omitempty"`
// simple, FuzzyQuery
Range *map[string]MetaRangeQuery `json:"range,omitempty"`
// simple, FuzzyQuery
Regexp *map[string]MetaRegexpQuery `json:"regexp,omitempty"`
SimpleQueryString *MetaSimpleQueryStringQuery `json:"simple_query_string,omitempty"`
// simple, TermQuery
Term *map[string]MetaTermQuery `json:"term,omitempty"`
// .
Terms *map[string]map[string]interface{} `json:"terms,omitempty"`
// simple, WildcardQuery
Wildcard *map[string]MetaWildcardQuery `json:"wildcard,omitempty"`
}
// NewMetaQuery instantiates a new MetaQuery 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 NewMetaQuery() *MetaQuery {
this := MetaQuery{}
return &this
}
// NewMetaQueryWithDefaults instantiates a new MetaQuery 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 NewMetaQueryWithDefaults() *MetaQuery {
this := MetaQuery{}
return &this
}
// GetBool returns the Bool field value if set, zero value otherwise.
func (o *MetaQuery) GetBool() MetaBoolQuery {
if o == nil || o.Bool == nil {
var ret MetaBoolQuery
return ret
}
return *o.Bool
}
// GetBoolOk returns a tuple with the Bool field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetBoolOk() (*MetaBoolQuery, bool) {
if o == nil || o.Bool == nil {
return nil, false
}
return o.Bool, true
}
// HasBool returns a boolean if a field has been set.
func (o *MetaQuery) HasBool() bool {
if o != nil && o.Bool != nil {
return true
}
return false
}
// SetBool gets a reference to the given MetaBoolQuery and assigns it to the Bool field.
func (o *MetaQuery) SetBool(v MetaBoolQuery) {
o.Bool = &v
}
// GetExists returns the Exists field value if set, zero value otherwise.
func (o *MetaQuery) GetExists() MetaExistsQuery {
if o == nil || o.Exists == nil {
var ret MetaExistsQuery
return ret
}
return *o.Exists
}
// GetExistsOk returns a tuple with the Exists field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetExistsOk() (*MetaExistsQuery, bool) {
if o == nil || o.Exists == nil {
return nil, false
}
return o.Exists, true
}
// HasExists returns a boolean if a field has been set.
func (o *MetaQuery) HasExists() bool {
if o != nil && o.Exists != nil {
return true
}
return false
}
// SetExists gets a reference to the given MetaExistsQuery and assigns it to the Exists field.
func (o *MetaQuery) SetExists(v MetaExistsQuery) {
o.Exists = &v
}
// GetFuzzy returns the Fuzzy field value if set, zero value otherwise.
func (o *MetaQuery) GetFuzzy() map[string]MetaFuzzyQuery {
if o == nil || o.Fuzzy == nil {
var ret map[string]MetaFuzzyQuery
return ret
}
return *o.Fuzzy
}
// GetFuzzyOk returns a tuple with the Fuzzy field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetFuzzyOk() (*map[string]MetaFuzzyQuery, bool) {
if o == nil || o.Fuzzy == nil {
return nil, false
}
return o.Fuzzy, true
}
// HasFuzzy returns a boolean if a field has been set.
func (o *MetaQuery) HasFuzzy() bool {
if o != nil && o.Fuzzy != nil {
return true
}
return false
}
// SetFuzzy gets a reference to the given map[string]MetaFuzzyQuery and assigns it to the Fuzzy field.
func (o *MetaQuery) SetFuzzy(v map[string]MetaFuzzyQuery) {
o.Fuzzy = &v
}
// GetIds returns the Ids field value if set, zero value otherwise.
func (o *MetaQuery) GetIds() MetaIdsQuery {
if o == nil || o.Ids == nil {
var ret MetaIdsQuery
return ret
}
return *o.Ids
}
// GetIdsOk returns a tuple with the Ids field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetIdsOk() (*MetaIdsQuery, bool) {
if o == nil || o.Ids == nil {
return nil, false
}
return o.Ids, true
}
// HasIds returns a boolean if a field has been set.
func (o *MetaQuery) HasIds() bool {
if o != nil && o.Ids != nil {
return true
}
return false
}
// SetIds gets a reference to the given MetaIdsQuery and assigns it to the Ids field.
func (o *MetaQuery) SetIds(v MetaIdsQuery) {
o.Ids = &v
}
// GetMatch returns the Match field value if set, zero value otherwise.
func (o *MetaQuery) GetMatch() map[string]MetaMatchQuery {
if o == nil || o.Match == nil {
var ret map[string]MetaMatchQuery
return ret
}
return *o.Match
}
// GetMatchOk returns a tuple with the Match field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetMatchOk() (*map[string]MetaMatchQuery, bool) {
if o == nil || o.Match == nil {
return nil, false
}
return o.Match, true
}
// HasMatch returns a boolean if a field has been set.
func (o *MetaQuery) HasMatch() bool {
if o != nil && o.Match != nil {
return true
}
return false
}
// SetMatch gets a reference to the given map[string]MetaMatchQuery and assigns it to the Match field.
func (o *MetaQuery) SetMatch(v map[string]MetaMatchQuery) {
o.Match = &v
}
// GetMatchAll returns the MatchAll field value if set, zero value otherwise.
func (o *MetaQuery) GetMatchAll() map[string]interface{} {
if o == nil || o.MatchAll == nil {
var ret map[string]interface{}
return ret
}
return o.MatchAll
}
// GetMatchAllOk returns a tuple with the MatchAll field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetMatchAllOk() (map[string]interface{}, bool) {
if o == nil || o.MatchAll == nil {
return nil, false
}
return o.MatchAll, true
}
// HasMatchAll returns a boolean if a field has been set.
func (o *MetaQuery) HasMatchAll() bool {
if o != nil && o.MatchAll != nil {
return true
}
return false
}
// SetMatchAll gets a reference to the given map[string]interface{} and assigns it to the MatchAll field.
func (o *MetaQuery) SetMatchAll(v map[string]interface{}) {
o.MatchAll = v
}
// GetMatchBoolPrefix returns the MatchBoolPrefix field value if set, zero value otherwise.
func (o *MetaQuery) GetMatchBoolPrefix() map[string]MetaMatchBoolPrefixQuery {
if o == nil || o.MatchBoolPrefix == nil {
var ret map[string]MetaMatchBoolPrefixQuery
return ret
}
return *o.MatchBoolPrefix
}
// GetMatchBoolPrefixOk returns a tuple with the MatchBoolPrefix field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetMatchBoolPrefixOk() (*map[string]MetaMatchBoolPrefixQuery, bool) {
if o == nil || o.MatchBoolPrefix == nil {
return nil, false
}
return o.MatchBoolPrefix, true
}
// HasMatchBoolPrefix returns a boolean if a field has been set.
func (o *MetaQuery) HasMatchBoolPrefix() bool {
if o != nil && o.MatchBoolPrefix != nil {
return true
}
return false
}
// SetMatchBoolPrefix gets a reference to the given map[string]MetaMatchBoolPrefixQuery and assigns it to the MatchBoolPrefix field.
func (o *MetaQuery) SetMatchBoolPrefix(v map[string]MetaMatchBoolPrefixQuery) {
o.MatchBoolPrefix = &v
}
// GetMatchNone returns the MatchNone field value if set, zero value otherwise.
func (o *MetaQuery) GetMatchNone() map[string]interface{} {
if o == nil || o.MatchNone == nil {
var ret map[string]interface{}
return ret
}
return o.MatchNone
}
// GetMatchNoneOk returns a tuple with the MatchNone field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetMatchNoneOk() (map[string]interface{}, bool) {
if o == nil || o.MatchNone == nil {
return nil, false
}
return o.MatchNone, true
}
// HasMatchNone returns a boolean if a field has been set.
func (o *MetaQuery) HasMatchNone() bool {
if o != nil && o.MatchNone != nil {
return true
}
return false
}
// SetMatchNone gets a reference to the given map[string]interface{} and assigns it to the MatchNone field.
func (o *MetaQuery) SetMatchNone(v map[string]interface{}) {
o.MatchNone = v
}
// GetMatchPhrase returns the MatchPhrase field value if set, zero value otherwise.
func (o *MetaQuery) GetMatchPhrase() map[string]MetaMatchPhraseQuery {
if o == nil || o.MatchPhrase == nil {
var ret map[string]MetaMatchPhraseQuery
return ret
}
return *o.MatchPhrase
}
// GetMatchPhraseOk returns a tuple with the MatchPhrase field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetMatchPhraseOk() (*map[string]MetaMatchPhraseQuery, bool) {
if o == nil || o.MatchPhrase == nil {
return nil, false
}
return o.MatchPhrase, true
}
// HasMatchPhrase returns a boolean if a field has been set.
func (o *MetaQuery) HasMatchPhrase() bool {
if o != nil && o.MatchPhrase != nil {
return true
}
return false
}
// SetMatchPhrase gets a reference to the given map[string]MetaMatchPhraseQuery and assigns it to the MatchPhrase field.
func (o *MetaQuery) SetMatchPhrase(v map[string]MetaMatchPhraseQuery) {
o.MatchPhrase = &v
}
// GetMatchPhrasePrefix returns the MatchPhrasePrefix field value if set, zero value otherwise.
func (o *MetaQuery) GetMatchPhrasePrefix() map[string]MetaMatchPhrasePrefixQuery {
if o == nil || o.MatchPhrasePrefix == nil {
var ret map[string]MetaMatchPhrasePrefixQuery
return ret
}
return *o.MatchPhrasePrefix
}
// GetMatchPhrasePrefixOk returns a tuple with the MatchPhrasePrefix field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetMatchPhrasePrefixOk() (*map[string]MetaMatchPhrasePrefixQuery, bool) {
if o == nil || o.MatchPhrasePrefix == nil {
return nil, false
}
return o.MatchPhrasePrefix, true
}
// HasMatchPhrasePrefix returns a boolean if a field has been set.
func (o *MetaQuery) HasMatchPhrasePrefix() bool {
if o != nil && o.MatchPhrasePrefix != nil {
return true
}
return false
}
// SetMatchPhrasePrefix gets a reference to the given map[string]MetaMatchPhrasePrefixQuery and assigns it to the MatchPhrasePrefix field.
func (o *MetaQuery) SetMatchPhrasePrefix(v map[string]MetaMatchPhrasePrefixQuery) {
o.MatchPhrasePrefix = &v
}
// GetMultiMatch returns the MultiMatch field value if set, zero value otherwise.
func (o *MetaQuery) GetMultiMatch() MetaMultiMatchQuery {
if o == nil || o.MultiMatch == nil {
var ret MetaMultiMatchQuery
return ret
}
return *o.MultiMatch
}
// GetMultiMatchOk returns a tuple with the MultiMatch field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetMultiMatchOk() (*MetaMultiMatchQuery, bool) {
if o == nil || o.MultiMatch == nil {
return nil, false
}
return o.MultiMatch, true
}
// HasMultiMatch returns a boolean if a field has been set.
func (o *MetaQuery) HasMultiMatch() bool {
if o != nil && o.MultiMatch != nil {
return true
}
return false
}
// SetMultiMatch gets a reference to the given MetaMultiMatchQuery and assigns it to the MultiMatch field.
func (o *MetaQuery) SetMultiMatch(v MetaMultiMatchQuery) {
o.MultiMatch = &v
}
// GetPrefix returns the Prefix field value if set, zero value otherwise.
func (o *MetaQuery) GetPrefix() map[string]MetaPrefixQuery {
if o == nil || o.Prefix == nil {
var ret map[string]MetaPrefixQuery
return ret
}
return *o.Prefix
}
// GetPrefixOk returns a tuple with the Prefix field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetPrefixOk() (*map[string]MetaPrefixQuery, bool) {
if o == nil || o.Prefix == nil {
return nil, false
}
return o.Prefix, true
}
// HasPrefix returns a boolean if a field has been set.
func (o *MetaQuery) HasPrefix() bool {
if o != nil && o.Prefix != nil {
return true
}
return false
}
// SetPrefix gets a reference to the given map[string]MetaPrefixQuery and assigns it to the Prefix field.
func (o *MetaQuery) SetPrefix(v map[string]MetaPrefixQuery) {
o.Prefix = &v
}
// GetQueryString returns the QueryString field value if set, zero value otherwise.
func (o *MetaQuery) GetQueryString() MetaQueryStringQuery {
if o == nil || o.QueryString == nil {
var ret MetaQueryStringQuery
return ret
}
return *o.QueryString
}
// GetQueryStringOk returns a tuple with the QueryString field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetQueryStringOk() (*MetaQueryStringQuery, bool) {
if o == nil || o.QueryString == nil {
return nil, false
}
return o.QueryString, true
}
// HasQueryString returns a boolean if a field has been set.
func (o *MetaQuery) HasQueryString() bool {
if o != nil && o.QueryString != nil {
return true
}
return false
}
// SetQueryString gets a reference to the given MetaQueryStringQuery and assigns it to the QueryString field.
func (o *MetaQuery) SetQueryString(v MetaQueryStringQuery) {
o.QueryString = &v
}
// GetRange returns the Range field value if set, zero value otherwise.
func (o *MetaQuery) GetRange() map[string]MetaRangeQuery {
if o == nil || o.Range == nil {
var ret map[string]MetaRangeQuery
return ret
}
return *o.Range
}
// GetRangeOk returns a tuple with the Range field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetRangeOk() (*map[string]MetaRangeQuery, bool) {
if o == nil || o.Range == nil {
return nil, false
}
return o.Range, true
}
// HasRange returns a boolean if a field has been set.
func (o *MetaQuery) HasRange() bool {
if o != nil && o.Range != nil {
return true
}
return false
}
// SetRange gets a reference to the given map[string]MetaRangeQuery and assigns it to the Range field.
func (o *MetaQuery) SetRange(v map[string]MetaRangeQuery) {
o.Range = &v
}
// GetRegexp returns the Regexp field value if set, zero value otherwise.
func (o *MetaQuery) GetRegexp() map[string]MetaRegexpQuery {
if o == nil || o.Regexp == nil {
var ret map[string]MetaRegexpQuery
return ret
}
return *o.Regexp
}
// GetRegexpOk returns a tuple with the Regexp field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetRegexpOk() (*map[string]MetaRegexpQuery, bool) {
if o == nil || o.Regexp == nil {
return nil, false
}
return o.Regexp, true
}
// HasRegexp returns a boolean if a field has been set.
func (o *MetaQuery) HasRegexp() bool {
if o != nil && o.Regexp != nil {
return true
}
return false
}
// SetRegexp gets a reference to the given map[string]MetaRegexpQuery and assigns it to the Regexp field.
func (o *MetaQuery) SetRegexp(v map[string]MetaRegexpQuery) {
o.Regexp = &v
}
// GetSimpleQueryString returns the SimpleQueryString field value if set, zero value otherwise.
func (o *MetaQuery) GetSimpleQueryString() MetaSimpleQueryStringQuery {
if o == nil || o.SimpleQueryString == nil {
var ret MetaSimpleQueryStringQuery
return ret
}
return *o.SimpleQueryString
}
// GetSimpleQueryStringOk returns a tuple with the SimpleQueryString field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetSimpleQueryStringOk() (*MetaSimpleQueryStringQuery, bool) {
if o == nil || o.SimpleQueryString == nil {
return nil, false
}
return o.SimpleQueryString, true
}
// HasSimpleQueryString returns a boolean if a field has been set.
func (o *MetaQuery) HasSimpleQueryString() bool {
if o != nil && o.SimpleQueryString != nil {
return true
}
return false
}
// SetSimpleQueryString gets a reference to the given MetaSimpleQueryStringQuery and assigns it to the SimpleQueryString field.
func (o *MetaQuery) SetSimpleQueryString(v MetaSimpleQueryStringQuery) {
o.SimpleQueryString = &v
}
// GetTerm returns the Term field value if set, zero value otherwise.
func (o *MetaQuery) GetTerm() map[string]MetaTermQuery {
if o == nil || o.Term == nil {
var ret map[string]MetaTermQuery
return ret
}
return *o.Term
}
// GetTermOk returns a tuple with the Term field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetTermOk() (*map[string]MetaTermQuery, bool) {
if o == nil || o.Term == nil {
return nil, false
}
return o.Term, true
}
// HasTerm returns a boolean if a field has been set.
func (o *MetaQuery) HasTerm() bool {
if o != nil && o.Term != nil {
return true
}
return false
}
// SetTerm gets a reference to the given map[string]MetaTermQuery and assigns it to the Term field.
func (o *MetaQuery) SetTerm(v map[string]MetaTermQuery) {
o.Term = &v
}
// GetTerms returns the Terms field value if set, zero value otherwise.
func (o *MetaQuery) GetTerms() map[string]map[string]interface{} {
if o == nil || o.Terms == nil {
var ret map[string]map[string]interface{}
return ret
}
return *o.Terms
}
// GetTermsOk returns a tuple with the Terms field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetTermsOk() (*map[string]map[string]interface{}, bool) {
if o == nil || o.Terms == nil {
return nil, false
}
return o.Terms, true
}
// HasTerms returns a boolean if a field has been set.
func (o *MetaQuery) HasTerms() bool {
if o != nil && o.Terms != nil {
return true
}
return false
}
// SetTerms gets a reference to the given map[string]map[string]interface{} and assigns it to the Terms field.
func (o *MetaQuery) SetTerms(v map[string]map[string]interface{}) {
o.Terms = &v
}
// GetWildcard returns the Wildcard field value if set, zero value otherwise.
func (o *MetaQuery) GetWildcard() map[string]MetaWildcardQuery {
if o == nil || o.Wildcard == nil {
var ret map[string]MetaWildcardQuery
return ret
}
return *o.Wildcard
}
// GetWildcardOk returns a tuple with the Wildcard field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MetaQuery) GetWildcardOk() (*map[string]MetaWildcardQuery, bool) {
if o == nil || o.Wildcard == nil {
return nil, false
}
return o.Wildcard, true
}
// HasWildcard returns a boolean if a field has been set.
func (o *MetaQuery) HasWildcard() bool {
if o != nil && o.Wildcard != nil {
return true
}
return false
}
// SetWildcard gets a reference to the given map[string]MetaWildcardQuery and assigns it to the Wildcard field.
func (o *MetaQuery) SetWildcard(v map[string]MetaWildcardQuery) {
o.Wildcard = &v
}
func (o MetaQuery) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
if o.Bool != nil {
toSerialize["bool"] = o.Bool
}
if o.Exists != nil {
toSerialize["exists"] = o.Exists
}
if o.Fuzzy != nil {
toSerialize["fuzzy"] = o.Fuzzy
}
if o.Ids != nil {
toSerialize["ids"] = o.Ids
}
if o.Match != nil {
toSerialize["match"] = o.Match
}
if o.MatchAll != nil {
toSerialize["match_all"] = o.MatchAll
}
if o.MatchBoolPrefix != nil {
toSerialize["match_bool_prefix"] = o.MatchBoolPrefix
}
if o.MatchNone != nil {
toSerialize["match_none"] = o.MatchNone
}
if o.MatchPhrase != nil {
toSerialize["match_phrase"] = o.MatchPhrase
}
if o.MatchPhrasePrefix != nil {
toSerialize["match_phrase_prefix"] = o.MatchPhrasePrefix
}
if o.MultiMatch != nil {
toSerialize["multi_match"] = o.MultiMatch
}
if o.Prefix != nil {
toSerialize["prefix"] = o.Prefix
}
if o.QueryString != nil {
toSerialize["query_string"] = o.QueryString
}
if o.Range != nil {
toSerialize["range"] = o.Range
}
if o.Regexp != nil {
toSerialize["regexp"] = o.Regexp
}
if o.SimpleQueryString != nil {
toSerialize["simple_query_string"] = o.SimpleQueryString
}
if o.Term != nil {
toSerialize["term"] = o.Term
}
if o.Terms != nil {
toSerialize["terms"] = o.Terms
}
if o.Wildcard != nil {
toSerialize["wildcard"] = o.Wildcard
}
return json.Marshal(toSerialize)
}
type NullableMetaQuery struct {
value *MetaQuery
isSet bool
}
func (v NullableMetaQuery) Get() *MetaQuery {
return v.value
}
func (v *NullableMetaQuery) Set(val *MetaQuery) {
v.value = val
v.isSet = true
}
func (v NullableMetaQuery) IsSet() bool {
return v.isSet
}
func (v *NullableMetaQuery) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableMetaQuery(val *MetaQuery) *NullableMetaQuery {
return &NullableMetaQuery{value: val, isSet: true}
}
func (v NullableMetaQuery) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableMetaQuery) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}