/
model_custconf_origin_pull_policy.go
896 lines (772 loc) · 31.1 KB
/
model_custconf_origin_pull_policy.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
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
/*
* Sites
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* API version: 1.0.0
* Generated by: OpenAPI Generator (https://openapi-generator.tech)
*/
package sites
import (
"encoding/json"
)
// CustconfOriginPullPolicy The CDN caching policy allows you to control how your origin's content is cached on the CDN.
type CustconfOriginPullPolicy struct {
// This is used by the API to perform conflict checking
Id *string `json:"id,omitempty"`
// String of values delimited by a ',' character. This is a pattern match expression for each status code this policy applies to. For example, 2*, 3* applies this policy to all 200 and 300 level HTTP responses from your origin.
StatusCodeMatch *string `json:"statusCodeMatch,omitempty"`
ExpirePolicy *OriginPullPolicyExpirePolicyEnumWrapperValue `json:"expirePolicy,omitempty"`
// This is the expiration time used for assets pulled from your origin. When using Cache-Control headers expiration methods, this value is used if your origin doesn't return a max-age directive in the Cache-Control HTTP header. Please note that a value of 0 in this fields instructs the caching server to retain assets for as long as possible.
ExpireSeconds *int32 `json:"expireSeconds,omitempty"`
// This enables the processing of no-store HTTP Cache-Control directives on your container. By enabling this option, responses from your origin containing the no-store directive are not cached. Be aware that requests for non-cacheable assets are always forwarded to your origin and may impose a high request and bandwidth load on your origin.
HonorNoStore *bool `json:"honorNoStore,omitempty"`
// This enables the processing of no-cache HTTP Cache-Control directives on your container. By enabling this option, responses from your origin containing the no-cache directive force the CDN to submit every subsequent request to your origin for validation before serving the asset stored in the cache.
HonorNoCache *bool `json:"honorNoCache,omitempty"`
HonorMustRevalidate *bool `json:"honorMustRevalidate,omitempty"`
NoCacheBehavior *OriginPullPolicyNoCacheBehaviorEnumWrapperValue `json:"noCacheBehavior,omitempty"`
// This enables the CDN to apply the no-cache behavior for assets delivered by your origin containing a max-age directive equal to zero.
MaxAgeZeroToNoCache *bool `json:"maxAgeZeroToNoCache,omitempty"`
// This enables the CDN to apply the no-cache behavior for assets delivered by your origin containing the must-revalidate directive.
MustRevalidateToNoCache *bool `json:"mustRevalidateToNoCache,omitempty"`
// This allows you to define a custom directive that, when used by your origin in the Cache-Control response headers, forces the CDN to proxy the request to the end user without caching the result.
BypassCacheIdentifier *string `json:"bypassCacheIdentifier,omitempty"`
// This forces the CDN to not cache any asset pulled from your origin that would otherwise be stored at this location in the cache. Typically this policy is used to prevent 4XX and 5XX response codes from overwriting a file in the cache when used with corresponding Origin Status Code Match setting. If bypass cache behavior is desired for all assets at a scope, Origin Pull Queue Behavior in the Origin Pull Settings also needs to be set to NOCACHE for that scope.
ForceBypassCache *bool `json:"forceBypassCache,omitempty"`
// String of values delimited by a ',' character. This is the list of your origin's HTTP headers that you want the CDN to cache and deliver to end users.
HttpHeaders *string `json:"httpHeaders,omitempty"`
// This enables the processing of private HTTP Cache-Control directives on your container. By enabling this option, responses from your origin containing the private directive are not cached. Be aware that requests for non-cacheable assets are always forwarded to your origin and may impose a high request and bandwidth load on your origin.
HonorPrivate *bool `json:"honorPrivate,omitempty"`
// This enables the processing of s-maxage HTTP Cache-Control directives on your container. By enabling this option, the s-maxage HTTP Cache-Control directive in the responses from your origin takes precedence over the max-age directive. If both max-age and s-maxage need to be preserved in the client response, the Cache-Control header must be added to the \"Http Header Caching\" setting.
HonorSMaxAge *bool `json:"honorSMaxAge,omitempty"`
UpdateHttpHeadersOn304Response *bool `json:"updateHttpHeadersOn304Response,omitempty"`
DefaultCacheBehavior *OriginPullPolicyDefaultCacheBehaviorEnumWrapperValue `json:"defaultCacheBehavior,omitempty"`
Enabled *bool `json:"enabled,omitempty"`
// String of values delimited by a ',' character.
MethodFilter *string `json:"methodFilter,omitempty"`
// String of values delimited by a ',' character.
PathFilter *string `json:"pathFilter,omitempty"`
// String of values delimited by a ',' character.
HeaderFilter *string `json:"headerFilter,omitempty"`
// String of values delimited by a ',' character.
ContentTypeFilter *string `json:"contentTypeFilter,omitempty"`
}
// NewCustconfOriginPullPolicy instantiates a new CustconfOriginPullPolicy 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 NewCustconfOriginPullPolicy() *CustconfOriginPullPolicy {
this := CustconfOriginPullPolicy{}
var expirePolicy OriginPullPolicyExpirePolicyEnumWrapperValue = "UNKNOWN"
this.ExpirePolicy = &expirePolicy
var noCacheBehavior OriginPullPolicyNoCacheBehaviorEnumWrapperValue = "UNKNOWN"
this.NoCacheBehavior = &noCacheBehavior
var defaultCacheBehavior OriginPullPolicyDefaultCacheBehaviorEnumWrapperValue = "UNKNOWN"
this.DefaultCacheBehavior = &defaultCacheBehavior
return &this
}
// NewCustconfOriginPullPolicyWithDefaults instantiates a new CustconfOriginPullPolicy 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 NewCustconfOriginPullPolicyWithDefaults() *CustconfOriginPullPolicy {
this := CustconfOriginPullPolicy{}
var expirePolicy OriginPullPolicyExpirePolicyEnumWrapperValue = "UNKNOWN"
this.ExpirePolicy = &expirePolicy
var noCacheBehavior OriginPullPolicyNoCacheBehaviorEnumWrapperValue = "UNKNOWN"
this.NoCacheBehavior = &noCacheBehavior
var defaultCacheBehavior OriginPullPolicyDefaultCacheBehaviorEnumWrapperValue = "UNKNOWN"
this.DefaultCacheBehavior = &defaultCacheBehavior
return &this
}
// GetId returns the Id field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetId() string {
if o == nil || o.Id == nil {
var ret string
return ret
}
return *o.Id
}
// GetIdOk returns a tuple with the Id field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetIdOk() (*string, bool) {
if o == nil || o.Id == nil {
return nil, false
}
return o.Id, true
}
// HasId returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasId() bool {
if o != nil && o.Id != nil {
return true
}
return false
}
// SetId gets a reference to the given string and assigns it to the Id field.
func (o *CustconfOriginPullPolicy) SetId(v string) {
o.Id = &v
}
// GetStatusCodeMatch returns the StatusCodeMatch field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetStatusCodeMatch() string {
if o == nil || o.StatusCodeMatch == nil {
var ret string
return ret
}
return *o.StatusCodeMatch
}
// GetStatusCodeMatchOk returns a tuple with the StatusCodeMatch field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetStatusCodeMatchOk() (*string, bool) {
if o == nil || o.StatusCodeMatch == nil {
return nil, false
}
return o.StatusCodeMatch, true
}
// HasStatusCodeMatch returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasStatusCodeMatch() bool {
if o != nil && o.StatusCodeMatch != nil {
return true
}
return false
}
// SetStatusCodeMatch gets a reference to the given string and assigns it to the StatusCodeMatch field.
func (o *CustconfOriginPullPolicy) SetStatusCodeMatch(v string) {
o.StatusCodeMatch = &v
}
// GetExpirePolicy returns the ExpirePolicy field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetExpirePolicy() OriginPullPolicyExpirePolicyEnumWrapperValue {
if o == nil || o.ExpirePolicy == nil {
var ret OriginPullPolicyExpirePolicyEnumWrapperValue
return ret
}
return *o.ExpirePolicy
}
// GetExpirePolicyOk returns a tuple with the ExpirePolicy field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetExpirePolicyOk() (*OriginPullPolicyExpirePolicyEnumWrapperValue, bool) {
if o == nil || o.ExpirePolicy == nil {
return nil, false
}
return o.ExpirePolicy, true
}
// HasExpirePolicy returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasExpirePolicy() bool {
if o != nil && o.ExpirePolicy != nil {
return true
}
return false
}
// SetExpirePolicy gets a reference to the given OriginPullPolicyExpirePolicyEnumWrapperValue and assigns it to the ExpirePolicy field.
func (o *CustconfOriginPullPolicy) SetExpirePolicy(v OriginPullPolicyExpirePolicyEnumWrapperValue) {
o.ExpirePolicy = &v
}
// GetExpireSeconds returns the ExpireSeconds field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetExpireSeconds() int32 {
if o == nil || o.ExpireSeconds == nil {
var ret int32
return ret
}
return *o.ExpireSeconds
}
// GetExpireSecondsOk returns a tuple with the ExpireSeconds field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetExpireSecondsOk() (*int32, bool) {
if o == nil || o.ExpireSeconds == nil {
return nil, false
}
return o.ExpireSeconds, true
}
// HasExpireSeconds returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasExpireSeconds() bool {
if o != nil && o.ExpireSeconds != nil {
return true
}
return false
}
// SetExpireSeconds gets a reference to the given int32 and assigns it to the ExpireSeconds field.
func (o *CustconfOriginPullPolicy) SetExpireSeconds(v int32) {
o.ExpireSeconds = &v
}
// GetHonorNoStore returns the HonorNoStore field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetHonorNoStore() bool {
if o == nil || o.HonorNoStore == nil {
var ret bool
return ret
}
return *o.HonorNoStore
}
// GetHonorNoStoreOk returns a tuple with the HonorNoStore field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetHonorNoStoreOk() (*bool, bool) {
if o == nil || o.HonorNoStore == nil {
return nil, false
}
return o.HonorNoStore, true
}
// HasHonorNoStore returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasHonorNoStore() bool {
if o != nil && o.HonorNoStore != nil {
return true
}
return false
}
// SetHonorNoStore gets a reference to the given bool and assigns it to the HonorNoStore field.
func (o *CustconfOriginPullPolicy) SetHonorNoStore(v bool) {
o.HonorNoStore = &v
}
// GetHonorNoCache returns the HonorNoCache field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetHonorNoCache() bool {
if o == nil || o.HonorNoCache == nil {
var ret bool
return ret
}
return *o.HonorNoCache
}
// GetHonorNoCacheOk returns a tuple with the HonorNoCache field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetHonorNoCacheOk() (*bool, bool) {
if o == nil || o.HonorNoCache == nil {
return nil, false
}
return o.HonorNoCache, true
}
// HasHonorNoCache returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasHonorNoCache() bool {
if o != nil && o.HonorNoCache != nil {
return true
}
return false
}
// SetHonorNoCache gets a reference to the given bool and assigns it to the HonorNoCache field.
func (o *CustconfOriginPullPolicy) SetHonorNoCache(v bool) {
o.HonorNoCache = &v
}
// GetHonorMustRevalidate returns the HonorMustRevalidate field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetHonorMustRevalidate() bool {
if o == nil || o.HonorMustRevalidate == nil {
var ret bool
return ret
}
return *o.HonorMustRevalidate
}
// GetHonorMustRevalidateOk returns a tuple with the HonorMustRevalidate field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetHonorMustRevalidateOk() (*bool, bool) {
if o == nil || o.HonorMustRevalidate == nil {
return nil, false
}
return o.HonorMustRevalidate, true
}
// HasHonorMustRevalidate returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasHonorMustRevalidate() bool {
if o != nil && o.HonorMustRevalidate != nil {
return true
}
return false
}
// SetHonorMustRevalidate gets a reference to the given bool and assigns it to the HonorMustRevalidate field.
func (o *CustconfOriginPullPolicy) SetHonorMustRevalidate(v bool) {
o.HonorMustRevalidate = &v
}
// GetNoCacheBehavior returns the NoCacheBehavior field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetNoCacheBehavior() OriginPullPolicyNoCacheBehaviorEnumWrapperValue {
if o == nil || o.NoCacheBehavior == nil {
var ret OriginPullPolicyNoCacheBehaviorEnumWrapperValue
return ret
}
return *o.NoCacheBehavior
}
// GetNoCacheBehaviorOk returns a tuple with the NoCacheBehavior field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetNoCacheBehaviorOk() (*OriginPullPolicyNoCacheBehaviorEnumWrapperValue, bool) {
if o == nil || o.NoCacheBehavior == nil {
return nil, false
}
return o.NoCacheBehavior, true
}
// HasNoCacheBehavior returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasNoCacheBehavior() bool {
if o != nil && o.NoCacheBehavior != nil {
return true
}
return false
}
// SetNoCacheBehavior gets a reference to the given OriginPullPolicyNoCacheBehaviorEnumWrapperValue and assigns it to the NoCacheBehavior field.
func (o *CustconfOriginPullPolicy) SetNoCacheBehavior(v OriginPullPolicyNoCacheBehaviorEnumWrapperValue) {
o.NoCacheBehavior = &v
}
// GetMaxAgeZeroToNoCache returns the MaxAgeZeroToNoCache field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetMaxAgeZeroToNoCache() bool {
if o == nil || o.MaxAgeZeroToNoCache == nil {
var ret bool
return ret
}
return *o.MaxAgeZeroToNoCache
}
// GetMaxAgeZeroToNoCacheOk returns a tuple with the MaxAgeZeroToNoCache field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetMaxAgeZeroToNoCacheOk() (*bool, bool) {
if o == nil || o.MaxAgeZeroToNoCache == nil {
return nil, false
}
return o.MaxAgeZeroToNoCache, true
}
// HasMaxAgeZeroToNoCache returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasMaxAgeZeroToNoCache() bool {
if o != nil && o.MaxAgeZeroToNoCache != nil {
return true
}
return false
}
// SetMaxAgeZeroToNoCache gets a reference to the given bool and assigns it to the MaxAgeZeroToNoCache field.
func (o *CustconfOriginPullPolicy) SetMaxAgeZeroToNoCache(v bool) {
o.MaxAgeZeroToNoCache = &v
}
// GetMustRevalidateToNoCache returns the MustRevalidateToNoCache field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetMustRevalidateToNoCache() bool {
if o == nil || o.MustRevalidateToNoCache == nil {
var ret bool
return ret
}
return *o.MustRevalidateToNoCache
}
// GetMustRevalidateToNoCacheOk returns a tuple with the MustRevalidateToNoCache field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetMustRevalidateToNoCacheOk() (*bool, bool) {
if o == nil || o.MustRevalidateToNoCache == nil {
return nil, false
}
return o.MustRevalidateToNoCache, true
}
// HasMustRevalidateToNoCache returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasMustRevalidateToNoCache() bool {
if o != nil && o.MustRevalidateToNoCache != nil {
return true
}
return false
}
// SetMustRevalidateToNoCache gets a reference to the given bool and assigns it to the MustRevalidateToNoCache field.
func (o *CustconfOriginPullPolicy) SetMustRevalidateToNoCache(v bool) {
o.MustRevalidateToNoCache = &v
}
// GetBypassCacheIdentifier returns the BypassCacheIdentifier field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetBypassCacheIdentifier() string {
if o == nil || o.BypassCacheIdentifier == nil {
var ret string
return ret
}
return *o.BypassCacheIdentifier
}
// GetBypassCacheIdentifierOk returns a tuple with the BypassCacheIdentifier field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetBypassCacheIdentifierOk() (*string, bool) {
if o == nil || o.BypassCacheIdentifier == nil {
return nil, false
}
return o.BypassCacheIdentifier, true
}
// HasBypassCacheIdentifier returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasBypassCacheIdentifier() bool {
if o != nil && o.BypassCacheIdentifier != nil {
return true
}
return false
}
// SetBypassCacheIdentifier gets a reference to the given string and assigns it to the BypassCacheIdentifier field.
func (o *CustconfOriginPullPolicy) SetBypassCacheIdentifier(v string) {
o.BypassCacheIdentifier = &v
}
// GetForceBypassCache returns the ForceBypassCache field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetForceBypassCache() bool {
if o == nil || o.ForceBypassCache == nil {
var ret bool
return ret
}
return *o.ForceBypassCache
}
// GetForceBypassCacheOk returns a tuple with the ForceBypassCache field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetForceBypassCacheOk() (*bool, bool) {
if o == nil || o.ForceBypassCache == nil {
return nil, false
}
return o.ForceBypassCache, true
}
// HasForceBypassCache returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasForceBypassCache() bool {
if o != nil && o.ForceBypassCache != nil {
return true
}
return false
}
// SetForceBypassCache gets a reference to the given bool and assigns it to the ForceBypassCache field.
func (o *CustconfOriginPullPolicy) SetForceBypassCache(v bool) {
o.ForceBypassCache = &v
}
// GetHttpHeaders returns the HttpHeaders field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetHttpHeaders() string {
if o == nil || o.HttpHeaders == nil {
var ret string
return ret
}
return *o.HttpHeaders
}
// GetHttpHeadersOk returns a tuple with the HttpHeaders field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetHttpHeadersOk() (*string, bool) {
if o == nil || o.HttpHeaders == nil {
return nil, false
}
return o.HttpHeaders, true
}
// HasHttpHeaders returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasHttpHeaders() bool {
if o != nil && o.HttpHeaders != nil {
return true
}
return false
}
// SetHttpHeaders gets a reference to the given string and assigns it to the HttpHeaders field.
func (o *CustconfOriginPullPolicy) SetHttpHeaders(v string) {
o.HttpHeaders = &v
}
// GetHonorPrivate returns the HonorPrivate field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetHonorPrivate() bool {
if o == nil || o.HonorPrivate == nil {
var ret bool
return ret
}
return *o.HonorPrivate
}
// GetHonorPrivateOk returns a tuple with the HonorPrivate field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetHonorPrivateOk() (*bool, bool) {
if o == nil || o.HonorPrivate == nil {
return nil, false
}
return o.HonorPrivate, true
}
// HasHonorPrivate returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasHonorPrivate() bool {
if o != nil && o.HonorPrivate != nil {
return true
}
return false
}
// SetHonorPrivate gets a reference to the given bool and assigns it to the HonorPrivate field.
func (o *CustconfOriginPullPolicy) SetHonorPrivate(v bool) {
o.HonorPrivate = &v
}
// GetHonorSMaxAge returns the HonorSMaxAge field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetHonorSMaxAge() bool {
if o == nil || o.HonorSMaxAge == nil {
var ret bool
return ret
}
return *o.HonorSMaxAge
}
// GetHonorSMaxAgeOk returns a tuple with the HonorSMaxAge field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetHonorSMaxAgeOk() (*bool, bool) {
if o == nil || o.HonorSMaxAge == nil {
return nil, false
}
return o.HonorSMaxAge, true
}
// HasHonorSMaxAge returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasHonorSMaxAge() bool {
if o != nil && o.HonorSMaxAge != nil {
return true
}
return false
}
// SetHonorSMaxAge gets a reference to the given bool and assigns it to the HonorSMaxAge field.
func (o *CustconfOriginPullPolicy) SetHonorSMaxAge(v bool) {
o.HonorSMaxAge = &v
}
// GetUpdateHttpHeadersOn304Response returns the UpdateHttpHeadersOn304Response field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetUpdateHttpHeadersOn304Response() bool {
if o == nil || o.UpdateHttpHeadersOn304Response == nil {
var ret bool
return ret
}
return *o.UpdateHttpHeadersOn304Response
}
// GetUpdateHttpHeadersOn304ResponseOk returns a tuple with the UpdateHttpHeadersOn304Response field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetUpdateHttpHeadersOn304ResponseOk() (*bool, bool) {
if o == nil || o.UpdateHttpHeadersOn304Response == nil {
return nil, false
}
return o.UpdateHttpHeadersOn304Response, true
}
// HasUpdateHttpHeadersOn304Response returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasUpdateHttpHeadersOn304Response() bool {
if o != nil && o.UpdateHttpHeadersOn304Response != nil {
return true
}
return false
}
// SetUpdateHttpHeadersOn304Response gets a reference to the given bool and assigns it to the UpdateHttpHeadersOn304Response field.
func (o *CustconfOriginPullPolicy) SetUpdateHttpHeadersOn304Response(v bool) {
o.UpdateHttpHeadersOn304Response = &v
}
// GetDefaultCacheBehavior returns the DefaultCacheBehavior field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetDefaultCacheBehavior() OriginPullPolicyDefaultCacheBehaviorEnumWrapperValue {
if o == nil || o.DefaultCacheBehavior == nil {
var ret OriginPullPolicyDefaultCacheBehaviorEnumWrapperValue
return ret
}
return *o.DefaultCacheBehavior
}
// GetDefaultCacheBehaviorOk returns a tuple with the DefaultCacheBehavior field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetDefaultCacheBehaviorOk() (*OriginPullPolicyDefaultCacheBehaviorEnumWrapperValue, bool) {
if o == nil || o.DefaultCacheBehavior == nil {
return nil, false
}
return o.DefaultCacheBehavior, true
}
// HasDefaultCacheBehavior returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasDefaultCacheBehavior() bool {
if o != nil && o.DefaultCacheBehavior != nil {
return true
}
return false
}
// SetDefaultCacheBehavior gets a reference to the given OriginPullPolicyDefaultCacheBehaviorEnumWrapperValue and assigns it to the DefaultCacheBehavior field.
func (o *CustconfOriginPullPolicy) SetDefaultCacheBehavior(v OriginPullPolicyDefaultCacheBehaviorEnumWrapperValue) {
o.DefaultCacheBehavior = &v
}
// GetEnabled returns the Enabled field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetEnabled() bool {
if o == nil || o.Enabled == nil {
var ret bool
return ret
}
return *o.Enabled
}
// GetEnabledOk returns a tuple with the Enabled field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetEnabledOk() (*bool, bool) {
if o == nil || o.Enabled == nil {
return nil, false
}
return o.Enabled, true
}
// HasEnabled returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasEnabled() bool {
if o != nil && o.Enabled != nil {
return true
}
return false
}
// SetEnabled gets a reference to the given bool and assigns it to the Enabled field.
func (o *CustconfOriginPullPolicy) SetEnabled(v bool) {
o.Enabled = &v
}
// GetMethodFilter returns the MethodFilter field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetMethodFilter() string {
if o == nil || o.MethodFilter == nil {
var ret string
return ret
}
return *o.MethodFilter
}
// GetMethodFilterOk returns a tuple with the MethodFilter field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetMethodFilterOk() (*string, bool) {
if o == nil || o.MethodFilter == nil {
return nil, false
}
return o.MethodFilter, true
}
// HasMethodFilter returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasMethodFilter() bool {
if o != nil && o.MethodFilter != nil {
return true
}
return false
}
// SetMethodFilter gets a reference to the given string and assigns it to the MethodFilter field.
func (o *CustconfOriginPullPolicy) SetMethodFilter(v string) {
o.MethodFilter = &v
}
// GetPathFilter returns the PathFilter field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetPathFilter() string {
if o == nil || o.PathFilter == nil {
var ret string
return ret
}
return *o.PathFilter
}
// GetPathFilterOk returns a tuple with the PathFilter field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetPathFilterOk() (*string, bool) {
if o == nil || o.PathFilter == nil {
return nil, false
}
return o.PathFilter, true
}
// HasPathFilter returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasPathFilter() bool {
if o != nil && o.PathFilter != nil {
return true
}
return false
}
// SetPathFilter gets a reference to the given string and assigns it to the PathFilter field.
func (o *CustconfOriginPullPolicy) SetPathFilter(v string) {
o.PathFilter = &v
}
// GetHeaderFilter returns the HeaderFilter field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetHeaderFilter() string {
if o == nil || o.HeaderFilter == nil {
var ret string
return ret
}
return *o.HeaderFilter
}
// GetHeaderFilterOk returns a tuple with the HeaderFilter field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetHeaderFilterOk() (*string, bool) {
if o == nil || o.HeaderFilter == nil {
return nil, false
}
return o.HeaderFilter, true
}
// HasHeaderFilter returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasHeaderFilter() bool {
if o != nil && o.HeaderFilter != nil {
return true
}
return false
}
// SetHeaderFilter gets a reference to the given string and assigns it to the HeaderFilter field.
func (o *CustconfOriginPullPolicy) SetHeaderFilter(v string) {
o.HeaderFilter = &v
}
// GetContentTypeFilter returns the ContentTypeFilter field value if set, zero value otherwise.
func (o *CustconfOriginPullPolicy) GetContentTypeFilter() string {
if o == nil || o.ContentTypeFilter == nil {
var ret string
return ret
}
return *o.ContentTypeFilter
}
// GetContentTypeFilterOk returns a tuple with the ContentTypeFilter field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CustconfOriginPullPolicy) GetContentTypeFilterOk() (*string, bool) {
if o == nil || o.ContentTypeFilter == nil {
return nil, false
}
return o.ContentTypeFilter, true
}
// HasContentTypeFilter returns a boolean if a field has been set.
func (o *CustconfOriginPullPolicy) HasContentTypeFilter() bool {
if o != nil && o.ContentTypeFilter != nil {
return true
}
return false
}
// SetContentTypeFilter gets a reference to the given string and assigns it to the ContentTypeFilter field.
func (o *CustconfOriginPullPolicy) SetContentTypeFilter(v string) {
o.ContentTypeFilter = &v
}
func (o CustconfOriginPullPolicy) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
if o.Id != nil {
toSerialize["id"] = o.Id
}
if o.StatusCodeMatch != nil {
toSerialize["statusCodeMatch"] = o.StatusCodeMatch
}
if o.ExpirePolicy != nil {
toSerialize["expirePolicy"] = o.ExpirePolicy
}
if o.ExpireSeconds != nil {
toSerialize["expireSeconds"] = o.ExpireSeconds
}
if o.HonorNoStore != nil {
toSerialize["honorNoStore"] = o.HonorNoStore
}
if o.HonorNoCache != nil {
toSerialize["honorNoCache"] = o.HonorNoCache
}
if o.HonorMustRevalidate != nil {
toSerialize["honorMustRevalidate"] = o.HonorMustRevalidate
}
if o.NoCacheBehavior != nil {
toSerialize["noCacheBehavior"] = o.NoCacheBehavior
}
if o.MaxAgeZeroToNoCache != nil {
toSerialize["maxAgeZeroToNoCache"] = o.MaxAgeZeroToNoCache
}
if o.MustRevalidateToNoCache != nil {
toSerialize["mustRevalidateToNoCache"] = o.MustRevalidateToNoCache
}
if o.BypassCacheIdentifier != nil {
toSerialize["bypassCacheIdentifier"] = o.BypassCacheIdentifier
}
if o.ForceBypassCache != nil {
toSerialize["forceBypassCache"] = o.ForceBypassCache
}
if o.HttpHeaders != nil {
toSerialize["httpHeaders"] = o.HttpHeaders
}
if o.HonorPrivate != nil {
toSerialize["honorPrivate"] = o.HonorPrivate
}
if o.HonorSMaxAge != nil {
toSerialize["honorSMaxAge"] = o.HonorSMaxAge
}
if o.UpdateHttpHeadersOn304Response != nil {
toSerialize["updateHttpHeadersOn304Response"] = o.UpdateHttpHeadersOn304Response
}
if o.DefaultCacheBehavior != nil {
toSerialize["defaultCacheBehavior"] = o.DefaultCacheBehavior
}
if o.Enabled != nil {
toSerialize["enabled"] = o.Enabled
}
if o.MethodFilter != nil {
toSerialize["methodFilter"] = o.MethodFilter
}
if o.PathFilter != nil {
toSerialize["pathFilter"] = o.PathFilter
}
if o.HeaderFilter != nil {
toSerialize["headerFilter"] = o.HeaderFilter
}
if o.ContentTypeFilter != nil {
toSerialize["contentTypeFilter"] = o.ContentTypeFilter
}
return json.Marshal(toSerialize)
}
type NullableCustconfOriginPullPolicy struct {
value *CustconfOriginPullPolicy
isSet bool
}
func (v NullableCustconfOriginPullPolicy) Get() *CustconfOriginPullPolicy {
return v.value
}
func (v *NullableCustconfOriginPullPolicy) Set(val *CustconfOriginPullPolicy) {
v.value = val
v.isSet = true
}
func (v NullableCustconfOriginPullPolicy) IsSet() bool {
return v.isSet
}
func (v *NullableCustconfOriginPullPolicy) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableCustconfOriginPullPolicy(val *CustconfOriginPullPolicy) *NullableCustconfOriginPullPolicy {
return &NullableCustconfOriginPullPolicy{value: val, isSet: true}
}
func (v NullableCustconfOriginPullPolicy) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableCustconfOriginPullPolicy) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}