aboutsummaryrefslogtreecommitdiff
path: root/weed/s3api/s3api_xsd_generated.go
blob: a8e4ef4043526a2ac3d6f93e4af9691159b2122b (plain)
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
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
package s3api

import (
	"bytes"
	"encoding/base64"
	"encoding/xml"
	"time"
)

type AccessControlList struct {
	Grant []Grant `xml:"Grant,omitempty"`
}

type AccessControlPolicy struct {
	Owner             CanonicalUser     `xml:"Owner"`
	AccessControlList AccessControlList `xml:"AccessControlList"`
}

type AmazonCustomerByEmail struct {
	EmailAddress string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ EmailAddress"`
}

type BucketLoggingStatus struct {
	LoggingEnabled LoggingSettings `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LoggingEnabled,omitempty"`
}

type CanonicalUser struct {
	ID          string `xml:"ID"`
	DisplayName string `xml:"DisplayName,omitempty"`
}

type CopyObject struct {
	SourceBucket                string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ SourceBucket"`
	SourceKey                   string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ SourceKey"`
	DestinationBucket           string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ DestinationBucket"`
	DestinationKey              string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ DestinationKey"`
	MetadataDirective           MetadataDirective `xml:"http://s3.amazonaws.com/doc/2006-03-01/ MetadataDirective,omitempty"`
	Metadata                    []MetadataEntry   `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Metadata,omitempty"`
	AccessControlList           AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AccessControlList,omitempty"`
	CopySourceIfModifiedSince   time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopySourceIfModifiedSince,omitempty"`
	CopySourceIfUnmodifiedSince time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopySourceIfUnmodifiedSince,omitempty"`
	CopySourceIfMatch           []string          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopySourceIfMatch,omitempty"`
	CopySourceIfNoneMatch       []string          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopySourceIfNoneMatch,omitempty"`
	StorageClass                StorageClass      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ StorageClass,omitempty"`
	AWSAccessKeyId              string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp                   time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature                   string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential                  string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *CopyObject) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T CopyObject
	var layout struct {
		*T
		CopySourceIfModifiedSince   *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopySourceIfModifiedSince,omitempty"`
		CopySourceIfUnmodifiedSince *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopySourceIfUnmodifiedSince,omitempty"`
		Timestamp                   *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.CopySourceIfModifiedSince = (*xsdDateTime)(&layout.T.CopySourceIfModifiedSince)
	layout.CopySourceIfUnmodifiedSince = (*xsdDateTime)(&layout.T.CopySourceIfUnmodifiedSince)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *CopyObject) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T CopyObject
	var overlay struct {
		*T
		CopySourceIfModifiedSince   *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopySourceIfModifiedSince,omitempty"`
		CopySourceIfUnmodifiedSince *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopySourceIfUnmodifiedSince,omitempty"`
		Timestamp                   *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.CopySourceIfModifiedSince = (*xsdDateTime)(&overlay.T.CopySourceIfModifiedSince)
	overlay.CopySourceIfUnmodifiedSince = (*xsdDateTime)(&overlay.T.CopySourceIfUnmodifiedSince)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type CopyObjectResponse struct {
	CopyObjectResult CopyObjectResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopyObjectResult"`
}

type CopyObjectResult struct {
	LastModified time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	ETag         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ETag"`
}

func (t *CopyObjectResult) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T CopyObjectResult
	var layout struct {
		*T
		LastModified *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	}
	layout.T = (*T)(t)
	layout.LastModified = (*xsdDateTime)(&layout.T.LastModified)
	return e.EncodeElement(layout, start)
}
func (t *CopyObjectResult) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T CopyObjectResult
	var overlay struct {
		*T
		LastModified *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	}
	overlay.T = (*T)(t)
	overlay.LastModified = (*xsdDateTime)(&overlay.T.LastModified)
	return d.DecodeElement(&overlay, &start)
}

type CreateBucket struct {
	Bucket            string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	AccessControlList AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AccessControlList,omitempty"`
	AWSAccessKeyId    string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp         time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature         string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
}

func (t *CreateBucket) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T CreateBucket
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *CreateBucket) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T CreateBucket
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type CreateBucketConfiguration struct {
	LocationConstraint string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LocationConstraint"`
}

type CreateBucketResponse struct {
	CreateBucketReturn CreateBucketResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CreateBucketReturn"`
}

type CreateBucketResult struct {
	BucketName string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ BucketName"`
}

type DeleteBucket struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *DeleteBucket) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T DeleteBucket
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *DeleteBucket) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T DeleteBucket
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type DeleteBucketResponse struct {
	DeleteBucketResponse Status `xml:"http://s3.amazonaws.com/doc/2006-03-01/ DeleteBucketResponse"`
}

type DeleteMarkerEntry struct {
	Key          string        `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	VersionId    string        `xml:"http://s3.amazonaws.com/doc/2006-03-01/ VersionId"`
	IsLatest     bool          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IsLatest"`
	LastModified time.Time     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	Owner        CanonicalUser `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Owner,omitempty"`
}

func (t *DeleteMarkerEntry) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T DeleteMarkerEntry
	var layout struct {
		*T
		LastModified *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	}
	layout.T = (*T)(t)
	layout.LastModified = (*xsdDateTime)(&layout.T.LastModified)
	return e.EncodeElement(layout, start)
}
func (t *DeleteMarkerEntry) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T DeleteMarkerEntry
	var overlay struct {
		*T
		LastModified *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	}
	overlay.T = (*T)(t)
	overlay.LastModified = (*xsdDateTime)(&overlay.T.LastModified)
	return d.DecodeElement(&overlay, &start)
}

type DeleteObject struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key            string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *DeleteObject) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T DeleteObject
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *DeleteObject) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T DeleteObject
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type DeleteObjectResponse struct {
	DeleteObjectResponse Status `xml:"http://s3.amazonaws.com/doc/2006-03-01/ DeleteObjectResponse"`
}

type GetBucketAccessControlPolicy struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *GetBucketAccessControlPolicy) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T GetBucketAccessControlPolicy
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *GetBucketAccessControlPolicy) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T GetBucketAccessControlPolicy
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type GetBucketAccessControlPolicyResponse struct {
	GetBucketAccessControlPolicyResponse AccessControlPolicy `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetBucketAccessControlPolicyResponse"`
}

type GetBucketLoggingStatus struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *GetBucketLoggingStatus) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T GetBucketLoggingStatus
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *GetBucketLoggingStatus) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T GetBucketLoggingStatus
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type GetBucketLoggingStatusResponse struct {
	GetBucketLoggingStatusResponse BucketLoggingStatus `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetBucketLoggingStatusResponse"`
}

type GetObject struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key            string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	GetMetadata    bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetMetadata"`
	GetData        bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetData"`
	InlineData     bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ InlineData"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *GetObject) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T GetObject
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *GetObject) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T GetObject
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type GetObjectAccessControlPolicy struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key            string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *GetObjectAccessControlPolicy) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T GetObjectAccessControlPolicy
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *GetObjectAccessControlPolicy) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T GetObjectAccessControlPolicy
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type GetObjectAccessControlPolicyResponse struct {
	GetObjectAccessControlPolicyResponse AccessControlPolicy `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetObjectAccessControlPolicyResponse"`
}

type GetObjectExtended struct {
	Bucket                                 string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key                                    string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	GetMetadata                            bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetMetadata"`
	GetData                                bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetData"`
	InlineData                             bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ InlineData"`
	ByteRangeStart                         int64     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ByteRangeStart,omitempty"`
	ByteRangeEnd                           int64     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ByteRangeEnd,omitempty"`
	IfModifiedSince                        time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IfModifiedSince,omitempty"`
	IfUnmodifiedSince                      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IfUnmodifiedSince,omitempty"`
	IfMatch                                []string  `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IfMatch,omitempty"`
	IfNoneMatch                            []string  `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IfNoneMatch,omitempty"`
	ReturnCompleteObjectOnConditionFailure bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ReturnCompleteObjectOnConditionFailure,omitempty"`
	AWSAccessKeyId                         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp                              time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature                              string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential                             string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *GetObjectExtended) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T GetObjectExtended
	var layout struct {
		*T
		IfModifiedSince   *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IfModifiedSince,omitempty"`
		IfUnmodifiedSince *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IfUnmodifiedSince,omitempty"`
		Timestamp         *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.IfModifiedSince = (*xsdDateTime)(&layout.T.IfModifiedSince)
	layout.IfUnmodifiedSince = (*xsdDateTime)(&layout.T.IfUnmodifiedSince)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *GetObjectExtended) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T GetObjectExtended
	var overlay struct {
		*T
		IfModifiedSince   *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IfModifiedSince,omitempty"`
		IfUnmodifiedSince *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IfUnmodifiedSince,omitempty"`
		Timestamp         *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.IfModifiedSince = (*xsdDateTime)(&overlay.T.IfModifiedSince)
	overlay.IfUnmodifiedSince = (*xsdDateTime)(&overlay.T.IfUnmodifiedSince)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type GetObjectExtendedResponse struct {
	GetObjectResponse GetObjectResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetObjectResponse"`
}

type GetObjectResponse struct {
	GetObjectResponse GetObjectResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetObjectResponse"`
}

type GetObjectResult struct {
	Metadata     []MetadataEntry `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Metadata,omitempty"`
	Data         []byte          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Data,omitempty"`
	LastModified time.Time       `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	ETag         string          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ETag"`
	Status       Status          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Status"`
}

func (t *GetObjectResult) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T GetObjectResult
	var layout struct {
		*T
		Data         *xsdBase64Binary `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Data,omitempty"`
		LastModified *xsdDateTime     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	}
	layout.T = (*T)(t)
	layout.Data = (*xsdBase64Binary)(&layout.T.Data)
	layout.LastModified = (*xsdDateTime)(&layout.T.LastModified)
	return e.EncodeElement(layout, start)
}
func (t *GetObjectResult) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T GetObjectResult
	var overlay struct {
		*T
		Data         *xsdBase64Binary `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Data,omitempty"`
		LastModified *xsdDateTime     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	}
	overlay.T = (*T)(t)
	overlay.Data = (*xsdBase64Binary)(&overlay.T.Data)
	overlay.LastModified = (*xsdDateTime)(&overlay.T.LastModified)
	return d.DecodeElement(&overlay, &start)
}

type Grant struct {
	Grantee    Grantee    `xml:"Grantee"`
	Permission Permission `xml:"Permission"`
}

type Grantee struct {
	XMLNS       string `xml:"xmlns:xsi,attr"`
	XMLXSI      string `xml:"xsi:type,attr"`
	Type        string `xml:"Type"`
	ID          string `xml:"ID,omitempty"`
	DisplayName string `xml:"DisplayName,omitempty"`
	URI         string `xml:"URI,omitempty"`
}

type Group struct {
	URI string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ URI"`
}

type ListAllMyBuckets struct {
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
}

func (t *ListAllMyBuckets) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T ListAllMyBuckets
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *ListAllMyBuckets) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T ListAllMyBuckets
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type ListAllMyBucketsEntry struct {
	Name         string    `xml:"Name"`
	CreationDate time.Time `xml:"CreationDate"`
}

func (t *ListAllMyBucketsEntry) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T ListAllMyBucketsEntry
	var layout struct {
		*T
		CreationDate *xsdDateTime `xml:"CreationDate"`
	}
	layout.T = (*T)(t)
	layout.CreationDate = (*xsdDateTime)(&layout.T.CreationDate)
	return e.EncodeElement(layout, start)
}
func (t *ListAllMyBucketsEntry) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T ListAllMyBucketsEntry
	var overlay struct {
		*T
		CreationDate *xsdDateTime `xml:"CreationDate"`
	}
	overlay.T = (*T)(t)
	overlay.CreationDate = (*xsdDateTime)(&overlay.T.CreationDate)
	return d.DecodeElement(&overlay, &start)
}

type ListAllMyBucketsList struct {
	Bucket []ListAllMyBucketsEntry `xml:"Bucket,omitempty"`
}

type ListAllMyBucketsResponse struct {
	ListAllMyBucketsResponse ListAllMyBucketsResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ListAllMyBucketsResponse"`
}

type ListBucket struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Prefix         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Prefix,omitempty"`
	Marker         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Marker,omitempty"`
	MaxKeys        int       `xml:"http://s3.amazonaws.com/doc/2006-03-01/ MaxKeys,omitempty"`
	Delimiter      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Delimiter,omitempty"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *ListBucket) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T ListBucket
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *ListBucket) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T ListBucket
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type ListBucketResponse struct {
	ListBucketResponse ListBucketResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ListBucketResponse"`
}

type ListBucketResult struct {
	XMLName        xml.Name        `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ListBucketResult"`
	Metadata       []MetadataEntry `xml:"Metadata,omitempty"`
	Name           string          `xml:"Name"`
	Prefix         string          `xml:"Prefix"`
	Marker         string          `xml:"Marker"`
	NextMarker     string          `xml:"NextMarker,omitempty"`
	MaxKeys        int             `xml:"MaxKeys"`
	Delimiter      string          `xml:"Delimiter,omitempty"`
	IsTruncated    bool            `xml:"IsTruncated"`
	Contents       []ListEntry     `xml:"Contents,omitempty"`
	CommonPrefixes []PrefixEntry   `xml:"CommonPrefixes,omitempty"`
}

type ListEntry struct {
	Key          string        `xml:"Key"`
	LastModified time.Time     `xml:"LastModified"`
	ETag         string        `xml:"ETag"`
	Size         int64         `xml:"Size"`
	Owner        CanonicalUser `xml:"Owner,omitempty"`
	StorageClass StorageClass  `xml:"StorageClass"`
}

func (t *ListEntry) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T ListEntry
	var layout struct {
		*T
		LastModified *xsdDateTime `xml:"LastModified"`
	}
	layout.T = (*T)(t)
	layout.LastModified = (*xsdDateTime)(&layout.T.LastModified)
	return e.EncodeElement(layout, start)
}
func (t *ListEntry) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T ListEntry
	var overlay struct {
		*T
		LastModified *xsdDateTime `xml:"LastModified"`
	}
	overlay.T = (*T)(t)
	overlay.LastModified = (*xsdDateTime)(&overlay.T.LastModified)
	return d.DecodeElement(&overlay, &start)
}

type ListVersionsResponse struct {
	ListVersionsResponse ListVersionsResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ListVersionsResponse"`
}

type ListVersionsResult struct {
	Metadata            []MetadataEntry   `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Metadata,omitempty"`
	Name                string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Name"`
	Prefix              string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Prefix"`
	KeyMarker           string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ KeyMarker"`
	VersionIdMarker     string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ VersionIdMarker"`
	NextKeyMarker       string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ NextKeyMarker,omitempty"`
	NextVersionIdMarker string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ NextVersionIdMarker,omitempty"`
	MaxKeys             int               `xml:"http://s3.amazonaws.com/doc/2006-03-01/ MaxKeys"`
	Delimiter           string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Delimiter,omitempty"`
	IsTruncated         bool              `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IsTruncated"`
	Version             VersionEntry      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Version"`
	DeleteMarker        DeleteMarkerEntry `xml:"http://s3.amazonaws.com/doc/2006-03-01/ DeleteMarker"`
	CommonPrefixes      []PrefixEntry     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CommonPrefixes,omitempty"`
}

type LoggingSettings struct {
	TargetBucket string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ TargetBucket"`
	TargetPrefix string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ TargetPrefix"`
	TargetGrants AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ TargetGrants,omitempty"`
}

// May be one of COPY, REPLACE
type MetadataDirective string

type MetadataEntry struct {
	Name  string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Name"`
	Value string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Value"`
}

// May be one of Enabled, Disabled
type MfaDeleteStatus string

type NotificationConfiguration struct {
	TopicConfiguration []TopicConfiguration `xml:"http://s3.amazonaws.com/doc/2006-03-01/ TopicConfiguration,omitempty"`
}

// May be one of BucketOwner, Requester
type Payer string

// May be one of READ, WRITE, READ_ACP, WRITE_ACP, FULL_CONTROL
type Permission string

type PostResponse struct {
	Location string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Location"`
	Bucket   string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key      string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	ETag     string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ETag"`
}

type PrefixEntry struct {
	Prefix string `xml:"Prefix"`
}

type PutObject struct {
	Bucket            string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key               string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	Metadata          []MetadataEntry   `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Metadata,omitempty"`
	ContentLength     int64             `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ContentLength"`
	AccessControlList AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AccessControlList,omitempty"`
	StorageClass      StorageClass      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ StorageClass,omitempty"`
	AWSAccessKeyId    string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp         time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature         string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential        string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *PutObject) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T PutObject
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *PutObject) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T PutObject
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type PutObjectInline struct {
	Bucket            string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key               string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	Metadata          []MetadataEntry   `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Metadata,omitempty"`
	Data              []byte            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Data"`
	ContentLength     int64             `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ContentLength"`
	AccessControlList AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AccessControlList,omitempty"`
	StorageClass      StorageClass      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ StorageClass,omitempty"`
	AWSAccessKeyId    string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp         time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature         string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential        string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *PutObjectInline) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T PutObjectInline
	var layout struct {
		*T
		Data      *xsdBase64Binary `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Data"`
		Timestamp *xsdDateTime     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Data = (*xsdBase64Binary)(&layout.T.Data)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *PutObjectInline) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T PutObjectInline
	var overlay struct {
		*T
		Data      *xsdBase64Binary `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Data"`
		Timestamp *xsdDateTime     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Data = (*xsdBase64Binary)(&overlay.T.Data)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type PutObjectInlineResponse struct {
	PutObjectInlineResponse PutObjectResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ PutObjectInlineResponse"`
}

type PutObjectResponse struct {
	PutObjectResponse PutObjectResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ PutObjectResponse"`
}

type PutObjectResult struct {
	ETag         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ETag"`
	LastModified time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
}

func (t *PutObjectResult) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T PutObjectResult
	var layout struct {
		*T
		LastModified *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	}
	layout.T = (*T)(t)
	layout.LastModified = (*xsdDateTime)(&layout.T.LastModified)
	return e.EncodeElement(layout, start)
}
func (t *PutObjectResult) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T PutObjectResult
	var overlay struct {
		*T
		LastModified *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	}
	overlay.T = (*T)(t)
	overlay.LastModified = (*xsdDateTime)(&overlay.T.LastModified)
	return d.DecodeElement(&overlay, &start)
}

type RequestPaymentConfiguration struct {
	Payer Payer `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Payer"`
}

type Result struct {
	Status Status `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Status"`
}

type SetBucketAccessControlPolicy struct {
	Bucket            string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	AccessControlList AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AccessControlList,omitempty"`
	AWSAccessKeyId    string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp         time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature         string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential        string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *SetBucketAccessControlPolicy) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T SetBucketAccessControlPolicy
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *SetBucketAccessControlPolicy) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T SetBucketAccessControlPolicy
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type SetBucketAccessControlPolicyResponse struct {
}

type SetBucketLoggingStatus struct {
	Bucket              string              `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	AWSAccessKeyId      string              `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp           time.Time           `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature           string              `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential          string              `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
	BucketLoggingStatus BucketLoggingStatus `xml:"http://s3.amazonaws.com/doc/2006-03-01/ BucketLoggingStatus"`
}

func (t *SetBucketLoggingStatus) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T SetBucketLoggingStatus
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *SetBucketLoggingStatus) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T SetBucketLoggingStatus
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type SetBucketLoggingStatusResponse struct {
}

type SetObjectAccessControlPolicy struct {
	Bucket            string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key               string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	AccessControlList AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AccessControlList"`
	AWSAccessKeyId    string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp         time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature         string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential        string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (t *SetObjectAccessControlPolicy) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T SetObjectAccessControlPolicy
	var layout struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	layout.T = (*T)(t)
	layout.Timestamp = (*xsdDateTime)(&layout.T.Timestamp)
	return e.EncodeElement(layout, start)
}
func (t *SetObjectAccessControlPolicy) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T SetObjectAccessControlPolicy
	var overlay struct {
		*T
		Timestamp *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	}
	overlay.T = (*T)(t)
	overlay.Timestamp = (*xsdDateTime)(&overlay.T.Timestamp)
	return d.DecodeElement(&overlay, &start)
}

type SetObjectAccessControlPolicyResponse struct {
}

type Status struct {
	Code        int    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Code"`
	Description string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Description"`
}

// May be one of STANDARD, REDUCED_REDUNDANCY, GLACIER, UNKNOWN
type StorageClass string

type TopicConfiguration struct {
	Topic string   `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Topic"`
	Event []string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Event"`
}

type User struct {
}

type VersionEntry struct {
	Key          string        `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	VersionId    string        `xml:"http://s3.amazonaws.com/doc/2006-03-01/ VersionId"`
	IsLatest     bool          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IsLatest"`
	LastModified time.Time     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	ETag         string        `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ETag"`
	Size         int64         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Size"`
	Owner        CanonicalUser `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Owner,omitempty"`
	StorageClass StorageClass  `xml:"http://s3.amazonaws.com/doc/2006-03-01/ StorageClass"`
}

func (t *VersionEntry) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	type T VersionEntry
	var layout struct {
		*T
		LastModified *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	}
	layout.T = (*T)(t)
	layout.LastModified = (*xsdDateTime)(&layout.T.LastModified)
	return e.EncodeElement(layout, start)
}
func (t *VersionEntry) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
	type T VersionEntry
	var overlay struct {
		*T
		LastModified *xsdDateTime `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	}
	overlay.T = (*T)(t)
	overlay.LastModified = (*xsdDateTime)(&overlay.T.LastModified)
	return d.DecodeElement(&overlay, &start)
}

type VersioningConfiguration struct {
	Status    VersioningStatus `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Status,omitempty"`
	MfaDelete MfaDeleteStatus  `xml:"http://s3.amazonaws.com/doc/2006-03-01/ MfaDelete,omitempty"`
}

// May be one of Enabled, Suspended
type VersioningStatus string

type xsdBase64Binary []byte

func (b *xsdBase64Binary) UnmarshalText(text []byte) (err error) {
	*b, err = base64.StdEncoding.DecodeString(string(text))
	return
}
func (b xsdBase64Binary) MarshalText() ([]byte, error) {
	var buf bytes.Buffer
	enc := base64.NewEncoder(base64.StdEncoding, &buf)
	enc.Write([]byte(b))
	enc.Close()
	return buf.Bytes(), nil
}

type xsdDateTime time.Time

func (t *xsdDateTime) UnmarshalText(text []byte) error {
	return _unmarshalTime(text, (*time.Time)(t), s3TimeFormat)
}
func (t xsdDateTime) MarshalText() ([]byte, error) {
	return []byte((time.Time)(t).Format(s3TimeFormat)), nil
}
func (t xsdDateTime) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
	if (time.Time)(t).IsZero() {
		return nil
	}
	m, err := t.MarshalText()
	if err != nil {
		return err
	}
	return e.EncodeElement(m, start)
}
func (t xsdDateTime) MarshalXMLAttr(name xml.Name) (xml.Attr, error) {
	if (time.Time)(t).IsZero() {
		return xml.Attr{}, nil
	}
	m, err := t.MarshalText()
	return xml.Attr{Name: name, Value: string(m)}, err
}
func _unmarshalTime(text []byte, t *time.Time, format string) (err error) {
	s := string(bytes.TrimSpace(text))
	*t, err = time.Parse(format, s)
	if _, ok := err.(*time.ParseError); ok {
		*t, err = time.Parse(format+"Z07:00", s)
	}
	return err
}