forked from aws/aws-sdk-java
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCopyPartRequest.java
More file actions
796 lines (738 loc) · 28.8 KB
/
CopyPartRequest.java
File metadata and controls
796 lines (738 loc) · 28.8 KB
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
/*
* Copyright 2011-2013 Amazon Technologies, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://aws.amazon.com/apache2.0
*
* This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES
* OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and
* limitations under the License.
*/
package com.amazonaws.services.s3.model;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import com.amazonaws.AmazonWebServiceRequest;
import com.amazonaws.services.s3.AmazonS3;
import com.amazonaws.services.s3.AmazonS3Client;
import com.amazonaws.services.s3.internal.Constants;
/**
* <p>
* Provides options for copying an Amazon S3 object from a source location to a
* part of a multipart upload.
* </p>
* <p>
* All <code>CopyPartRequests</code> must specify an upload id, a source bucket
* and key, along with a destination bucket and key. Beyond that, requests also
* specify constraints controlling if the copy will be performed or not.</li>
*
* @see AmazonS3Client#copyObject(com.amazonaws.services.s3.model.CopyPartRequest)
* @see AmazonS3Client#initiateMultipartUpload(InitiateMultipartUploadRequest)
* @see AmazonS3Client#uploadPart(UploadPartRequest)
* @see CopyPartResult
*/
public class CopyPartRequest extends AmazonWebServiceRequest {
/**
* The upload id of the multipart upload into which to copy this part.
*
* @see AmazonS3#initiateMultipartUpload(InitiateMultipartUploadRequest)
*/
private String uploadId;
/**
* The part number to copy into.
*
* @see AmazonS3#uploadPart(UploadPartRequest)
*/
private int partNumber;
/** The name of the bucket containing the object to be copied */
private String sourceBucketName;
/**
* The key in the source bucket under which the object to be copied is
* stored
*/
private String sourceKey;
/**
* Optional version Id specifying which version of the source object to
* copy. If not specified, the most recent version of the source object will
* be copied.
* <p>
* For more information about enabling versioning for a bucket, see
* {@link AmazonS3#withBucketVersioningConfiguration(withBucketVersioningConfigurationRequest)}.
*/
private String sourceVersionId;
/** The name of the bucket to contain the copy of the source object */
private String destinationBucketName;
/**
* The key in the destination bucket under which the source object will be
* copied
*/
private String destinationKey;
/**
* Optional list of ETag values that constrain the copy request to only be
* executed if the source object's ETag matches one of the specified ETag
* values.
*/
private final List<String> matchingETagConstraints = new ArrayList<String>();
/**
* Optional list of ETag values that constrain the copy request to only be
* executed if the source object's ETag does not match any of the specified
* ETag constraint values.
*/
private final List<String> nonmatchingEtagConstraints = new ArrayList<String>();
/**
* Optional field that constrains the copy request to only be executed if
* the source object has not been modified since the specified date.
*/
private Date unmodifiedSinceConstraint;
/**
* Optional field that constrains the copy request to only be executed if
* the source object has been modified since the specified date.
*/
private Date modifiedSinceConstraint;
/**
* Optional field that copies the object starting at the given zero-based
* byte offset. Used with {@link CopyPartRequest#lastByte}
*/
private Long firstByte;
/**
* Optional field that copies the object up to and including the given
* zero-based byte offset. Used with {@link CopyPartRequest#firstByte}.
*/
private Long lastByte;
/**
* Returns the ID of the existing, initiated multipart upload with which
* this new part will be associated.
*
* @return the ID of the existing, initiated multipart upload with which
* this new part will be associated.
*/
public String getUploadId() {
return uploadId;
}
/**
* Sets the ID of the existing, initiated multipart upload with which this
* new part will be associated.
*
* @param uploadId
* the ID of the existing, initiated multipart upload with which
* this new part will be associated.
*/
public void setUploadId(String uploadId) {
this.uploadId = uploadId;
}
/**
* Sets the ID of the existing, initiated multipart upload with which this
* new part will be associated.
*
* @param uploadId
* the ID of the existing, initiated multipart upload with which
* this new part will be associated. * @return This
* <code>CopyPartRequest</code>, enabling additional method calls
* to be chained together.
*/
public CopyPartRequest withUploadId(String uploadId) {
this.uploadId = uploadId;
return this;
}
/**
* Returns the part number describing this part's position relative to the
* other parts in the multipart upload. Part number must be between 1 and
* 10,000 (inclusive).
*
* @return the part number describing this part's position relative to the
* other parts in the multipart upload. Part number must be between
* 1 and 10,000 (inclusive).
*/
public int getPartNumber() {
return partNumber;
}
/**
* Sets the part number describing this part's position relative to the
* other parts in the multipart upload. Part number must be between 1 and
* 10,000 (inclusive).
*
* @param partNumber
* the part number describing this part's position relative to
* the other parts in the multipart upload. Part number must be
* between 1 and 10,000 (inclusive).
*/
public void setPartNumber(int partNumber) {
this.partNumber = partNumber;
}
/**
* Sets the part number describing this part's position relative to the
* other parts in the multipart upload. Part number must be between 1 and
* 10,000 (inclusive).
*
* @param partNumber
* the part number describing this part's position relative to
* the other parts in the multipart upload. Part number must be
* between 1 and 10,000 (inclusive).
* @return This <code>CopyPartRequest</code>, enabling additional method
* calls to be chained together.
*/
public CopyPartRequest withPartNumber(int partNumber) {
this.partNumber = partNumber;
return this;
}
/**
* Gets the name of the bucket containing the source object to be copied.
*
* @return The name of the bucket containing the source object to be copied.
* @see CopyPartRequest#setSourceBucketName(String sourceBucketName)
*/
public String getSourceBucketName() {
return sourceBucketName;
}
/**
* Sets the name of the bucket containing the source object to be copied.
*
* @param sourceBucketName
* The name of the bucket containing the source object to be
* copied.
* @see CopyPartRequest#getSourceBucketName()
*/
public void setSourceBucketName(String sourceBucketName) {
this.sourceBucketName = sourceBucketName;
}
/**
* Sets the name of the bucket containing the source object to be copied.
*
* @param sourceBucketName
* The name of the bucket containing the source object to be
* copied.
* @see CopyPartRequest#getSourceBucketName()
* @return This <code>CopyPartRequest</code>, enabling additional method
* calls to be chained together.
*/
public CopyPartRequest withSourceBucketName(String sourceBucketName) {
this.sourceBucketName = sourceBucketName;
return this;
}
/**
* Gets the source bucket key under which the source object to be copied is
* stored.
*
* @return The source bucket key under which the source object to be copied
* is stored.
* @see CopyPartRequest#setSourceKey(String sourceKey)
*/
public String getSourceKey() {
return sourceKey;
}
/**
* Sets the source bucket key under which the source object to be copied is
* stored.
*
* @param sourceKey
* The source bucket key under which the source object to be
* copied is stored.
* @see CopyPartRequest#setSourceKey(String sourceKey)
*/
public void setSourceKey(String sourceKey) {
this.sourceKey = sourceKey;
}
/**
* Sets the source bucket key under which the source object to be copied is
* stored.
*
* @param sourceKey
* The source bucket key under which the source object to be
* copied is stored.
* @see CopyPartRequest#setSourceKey(String sourceKey)
* @return This <code>CopyPartRequest</code>, enabling additional method
* calls to be chained together.
*/
public CopyPartRequest withSourceKey(String sourceKey) {
this.sourceKey = sourceKey;
return this;
}
/**
* <p>
* Gets the version ID specifying which version of the source object to
* copy. If not specified, the most recent version of the source object will
* be copied.
* </p>
* <p>
* Objects created before enabling versioning or when versioning is
* suspended are given the default <code>null</code> version ID (see
* {@link Constants#NULL_VERSION_ID}). Note that the <code>null</code>
* version ID is a valid version ID and is not the same as not having a
* version ID.
* </p>
* <p>
* For more information about enabling versioning for a bucket, see
* {@link AmazonS3#setBucketVersioningConfiguration(SetBucketVersioningConfigurationRequest)}
* .
* </p>
*
* @return The version ID specifying which version of the source object to
* copy.
* @see Constants#NULL_VERSION_ID
* @see CopyPartRequest#setSourceVersionId(String sourceVersionId)
*/
public String getSourceVersionId() {
return sourceVersionId;
}
/**
* <p>
* Sets the optional version ID specifying which version of the source
* object to copy. If not specified, the most recent version of the source
* object will be copied.
* </p>
* <p>
* Objects created before enabling versioning or when versioning is
* suspended are given the default <code>null</code> version ID (see
* {@link Constants#NULL_VERSION_ID}). Note that the <code>null</code>
* version ID is a valid version ID and is not the same as not having a
* version ID.
* </p>
* <p>
* For more information about enabling versioning for a bucket, see
* {@link AmazonS3#setBucketVersioningConfiguration(SetBucketVersioningConfigurationRequest)}
* .
* </p>
*
* @param sourceVersionId
* The optional version ID specifying which version of the source
* object to copy.
*/
public void setSourceVersionId(String sourceVersionId) {
this.sourceVersionId = sourceVersionId;
}
/**
* <p>
* Sets the optional version ID specifying which version of the source
* object to copy. If not specified, the most recent version of the source
* object will be copied.
* </p>
* <p>
* Objects created before enabling versioning or when versioning is
* suspended are given the default <code>null</code> version ID (see
* {@link Constants#NULL_VERSION_ID}). Note that the <code>null</code>
* version ID is a valid version ID and is not the same as not having a
* version ID.
* </p>
* <p>
* For more information about enabling versioning for a bucket, see
* {@link AmazonS3#setBucketVersioningConfiguration(SetBucketVersioningConfigurationRequest)}
* .
* </p>
*
* @param sourceVersionId
* The optional version ID specifying which version of the source
* object to copy.
* @return This <code>CopyPartRequest</code>, enabling additional method
* calls to be chained together.
*/
public CopyPartRequest withSourceVersionId(String sourceVersionId) {
this.sourceVersionId = sourceVersionId;
return this;
}
/**
* Gets the destination bucket name which will contain the new,
* copied object.
*
* @return The name of the destination bucket which will contain the new,
* copied object.
*
* @see CopyPartRequest#setDestinationBucketName(String destinationBucketName)
*/
public String getDestinationBucketName() {
return destinationBucketName;
}
/**
* Sets the destination bucket name which will contain the new,
* copied object.
*
* @param destinationBucketName
* The name of the destination bucket which will contain the new,
* copied object.
*
* @see CopyPartRequest#getDestinationBucketName()
*/
public void setDestinationBucketName(String destinationBucketName) {
this.destinationBucketName = destinationBucketName;
}
/**
* Sets the name of the destination bucket which will contain the new,
* copied object and returns this object, enabling additional method calls
* to be chained together.
*
* @param destinationBucketName
* The name of the destination bucket which will contain the new,
* copied object.
*
* @return This <code>CopyPartRequest</code>, enabling additional method calls to be
* chained together.
*/
public CopyPartRequest withDestinationBucketName(String destinationBucketName) {
setDestinationBucketName(destinationBucketName);
return this;
}
/**
* Gets the destination bucket key under which the new, copied
* object will be stored.
*
* @return The destination bucket key under which the new, copied
* object will be stored.
*
* @see CopyPartRequest#setDestinationKey(String destinationKey)
*/
public String getDestinationKey() {
return destinationKey;
}
/**
* Sets the destination bucket key under which the new, copied object
* will be stored.
*
* @param destinationKey
* The destination bucket key under which the new, copied
* object will be stored.
*
* @see CopyPartRequest#getDestinationKey()
*/
public void setDestinationKey(String destinationKey) {
this.destinationKey = destinationKey;
}
/**
* Sets the destination bucket key under which the new, copied object
* will be stored and returns this object, enabling additional method calls
* can be chained together.
*
* @param destinationKey
* The destination bucket key under which the new, copied
* object will be stored.
*
* @return This <code>CopyPartRequest</code>, enabling additional method calls to be
* chained together.
*/
public CopyPartRequest withDestinationKey(String destinationKey) {
setDestinationKey(destinationKey);
return this;
}
/**
* Returns the optional start range to copy from the source object.
*
* @return the optional start range to copy from the source object.
*/
public Long getFirstByte() {
return firstByte;
}
/**
* Sets the optional zero-based byte offset to begin copying the source
* object.
*
* @param firstByte
* the optional zero-based byte offset to begin copying the
* source object.
*/
public void setFirstByte(Long firstByte) {
this.firstByte = firstByte;
}
/**
* Sets the optional zero-based byte offset to begin copying the source
* object.
*
* @param firstByte
* the optional zero-based byte offset to begin copying the
* source object.
* @return This <code>CopyPartRequest</code>, enabling additional method
* calls to be chained together.
*/
public CopyPartRequest withFirstByte(Long firstByte) {
this.firstByte = firstByte;
return this;
}
/**
* Returns the optional zero-based byte offset to stop copying the source.
*
* @return the optional zero-based byte offset to stop copying the source.
*/
public Long getLastByte() {
return lastByte;
}
/**
* Sets the optional zero-based byte offset to stop copying the source.
*/
public void setLastByte(Long lastByte) {
this.lastByte = lastByte;
}
/**
* Sets the optional zero-based byte offset to stop copying the source.
*
* @return This <code>CopyPartRequest</code>, enabling additional method
* calls to be chained together.
*/
public CopyPartRequest withLastByte(Long lastByte) {
this.lastByte = lastByte;
return this;
}
/**
* <p>
* Gets the optional list of ETag constraints that, when present,
* <b>must</b> include a match for the source object's current ETag in order
* for the copy object request to be executed. Only one ETag in the list
* needs to match for the request to be executed by Amazon S3.
* </p>
* <p>
* Matching ETag constraints may be used with the unmodified since
* constraint, but not with any other type of constraint.
* </p>
*
* @return The optional list of ETag constraints that when present must
* include a match for the source object's current ETag in order for
* this request to be executed.
*/
public List<String> getMatchingETagConstraints() {
return matchingETagConstraints;
}
/**
* <p>
* Sets the optional list of ETag constraints that, when present,
* <b>must</b> include a match for the source object's current ETag in order
* for the copy object request to be executed. If none of the specified
* ETags match the source object's current ETag, the copy object operation
* will be aborted. Only one ETag in the list needs to match for the request
* to be executed by Amazon S3.
* </p>
* <p>
* Matching ETag constraints may be used with the unmodified since
* constraint, but not with any other type of constraint.
* </p>
*
* @param eTagList
* The optional list of ETag constraints that must include a
* match for the source object's current ETag in order for this
* request to be executed.
*/
public void setMatchingETagConstraints(List<String> eTagList) {
this.matchingETagConstraints.clear();
this.matchingETagConstraints.addAll(eTagList);
}
/**
* <p>
* Adds a single ETag constraint to this request and returns this object,
* enabling additional method calls to be chained together. Multiple ETag
* constraints can be added to a request, but one must match the source
* object's current ETag in order for the copy object request to be
* executed. If none of the ETag constraints added to this request match the
* source object's current ETag, the copy object operation will be aborted.
* </p>
* <p>
* Matching ETag constraints may be used with the unmodified since
* constraint, but not with any other type of constraint.
* </p>
*
* @param eTag
* The matching ETag constraint to add to this request.
* @return This <code>CopyPartRequest</code>, enabling additional method
* calls to be chained together.
*/
public CopyPartRequest withMatchingETagConstraint(String eTag) {
this.matchingETagConstraints.add(eTag);
return this;
}
/**
* <p>
* Gets the optional list of ETag constraints that, when present, <b>must
* not</b> include a match for the source object's current ETag in order for
* the copy object request to be executed. If any entry in the non-matching
* ETag constraint list matches the source object's current ETag, this copy
* request <b>will not</b> be executed by Amazon S3.
* </p>
* <p>
* Non-matching ETag constraints may be used with the modified since
* constraint, but not with any other type of constraint.
* </p>
*
* @return The optional list of ETag constraints that when present <b>must
* not</b> include a match for the source object's current ETag in
* order for this request to be executed.
*/
public List<String> getNonmatchingETagConstraints() {
return nonmatchingEtagConstraints;
}
/**
* <p>
* Sets the optional list of ETag constraints that, when present, <b>must
* not</b> include a match for the source object's current ETag in order for
* the copy object request to be executed. If any entry in the non-matching
* ETag constraint list matches the source object's current ETag, this copy
* request <b>will not</b> be executed by Amazon S3.
* </p>
* <p>
* Non-matching ETag constraints may be used with the modified since
* constraint, but not with any other type of constraint.
* </p>
*
* @param eTagList
* The list of ETag constraints that, when present, <b>must
* not</b> include a match for the source object's current ETag
* in order for this request to be executed.
*/
public void setNonmatchingETagConstraints(List<String> eTagList) {
this.nonmatchingEtagConstraints.clear();
this.nonmatchingEtagConstraints.addAll(eTagList);
}
/**
* <p>
* Adds a single ETag constraint to this request and returns this object,
* enabling additional method calls to be chained together. Multiple ETag
* constraints can be added to a request, but all ETag constraints <b>must
* not</b> match the source object's current ETag in order for the copy
* object request to be executed. If any entry in the non-matching ETag
* constraint list matches the source object's current ETag, this copy
* request <b>will not</b> be executed by Amazon S3.
* </p>
* <p>
* Non-matching ETag constraints may be used with the modified since
* constraint, but not with any other type of constraint.
* </p>
*
* @param eTag
* The non-matching ETag constraint to add to this request.
* @return This <code>CopyPartRequest</code>, enabling additional method
* calls to be chained together.
*/
public CopyPartRequest withNonmatchingETagConstraint(String eTag) {
this.nonmatchingEtagConstraints.add(eTag);
return this;
}
/**
* <p>
* Gets the optional unmodified constraint that restricts this request to
* executing only if the source object has <b>not</b> been modified after
* the specified date.
* </p>
* <p>
* The unmodified since constraint may be used with matching ETag
* constraints, but not with any other type of constraint.
* </p>
*
* @return The optional unmodified constraint that restricts this request to
* executing only if the source object has <b>not</b> been modified
* after the specified date.
*/
public Date getUnmodifiedSinceConstraint() {
return unmodifiedSinceConstraint;
}
/**
* <p>
* Sets the optional unmodified constraint that restricts this request to
* executing only if the source object has <b>not</b> been modified after
* the specified date.
* </p>
* <p>
* The unmodified constraint may be used with matching ETag constraints, but
* not with any other type of constraint.
* </p>
* <p>
* Note that Amazon S3 will ignore any dates occurring in the future.
* </p>
*
* @param date
* The unmodified constraint that restricts this request to
* executing only if the source object has <b>not</b> been
* modified after this date.
*/
public void setUnmodifiedSinceConstraint(Date date) {
this.unmodifiedSinceConstraint = date;
}
/**
* <p>
* Sets the optional unmodified constraint that restricts this request to
* executing only if the source object has <b>not</b> been modified after
* the specified date. Returns this object, enabling additional method calls
* to be chained together.
* </p>
* <p>
* The unmodified constraint may be used with matching ETag constraints, but
* not with any other type of constraint.
* </p>
* <p>
* Note that Amazon S3 will ignore any dates occurring in the future.
* </p>
*
* @param date
* The unmodified constraint that restricts this request to
* executing only if the source object has <b>not</b> been
* modified after this date.
* @return This <code>CopyPartRequest</code>, enabling additional method
* calls to be chained together.
*/
public CopyPartRequest withUnmodifiedSinceConstraint(Date date) {
setUnmodifiedSinceConstraint(date);
return this;
}
/**
* <p>
* Gets the optional modified constraint that restricts this request to
* executing only if the source object <b>has</b> been modified after the
* specified date.
* </p>
* <p>
* The modified constraint may be used with non-matching ETag constraints,
* but not with any other type of constraint.
* </p>
*
* @return The optional modified constraint that restricts this request to
* executing only if the source object <b>has</b> been modified
* after the specified date.
*/
public Date getModifiedSinceConstraint() {
return modifiedSinceConstraint;
}
/**
* <p>
* Sets the optional modified constraint that restricts this request to
* executing only if the source object <b>has</b> been modified after the
* specified date.
* </p>
* <p>
* The modified constraint may be used with non-matching ETag constraints,
* but not with any other type of constraint.
* </p>
* <p>
* Note that Amazon S3 will ignore any dates occurring in the future.
* </p>
*
* @param date
* The modified constraint that restricts this request to
* executing only if the source object <b>has</b> been modified
* after the specified date.
*/
public void setModifiedSinceConstraint(Date date) {
this.modifiedSinceConstraint = date;
}
/**
* <p>
* Sets the optional modified constraint that restricts this request to
* executing only if the source object <b>has</b> been modified after the
* specified date. Returns this object, enabling additional method calls to
* be chained together.
* </p>
* <p>
* The modified constraint may be used with non-matching ETag constraints,
* but not with any other type of constraint.
* </p>
* <p>
* Note that Amazon S3 will ignore any dates occurring in the future.
* </p>
*
* @param date
* The modified constraint that restricts this request to
* executing only if the source object <b>has</b> been modified
* after the specified date.
* @return This <code>CopyPartRequest</code>, enabling additional method
* calls to be chained together.
*/
public CopyPartRequest withModifiedSinceConstraint(Date date) {
setModifiedSinceConstraint(date);
return this;
}
}