File tree Expand file tree Collapse file tree 2 files changed +18
-7
lines changed
gcloud-java-storage/src/main/java/com/google/gcloud/storage Expand file tree Collapse file tree 2 files changed +18
-7
lines changed Original file line number Diff line number Diff line change 3232import java .util .concurrent .Callable ;
3333
3434/**
35- * Google Storage blob copy writer. This class holds the result of a copy request. If source and
35+ * Google Storage blob copy writer. A {@code CopyWriter} object allows to copy both blob's data and
36+ * information. To override source blob's information call {@link Storage#copy(Storage.CopyRequest)}
37+ * with a {@code CopyRequest} object where the copy target is set via
38+ * {@link Storage.CopyRequest.Builder#target(BlobInfo, Storage.BlobTargetOption...)} or
39+ * {@link Storage.CopyRequest.Builder#target(BlobInfo, Iterable)}.
40+ *
41+ * <p>This class holds the result of a copy request. If source and
3642 * destination blobs share the same location and storage class the copy is completed in one RPC call
3743 * otherwise one or more {@link #copyChunk} calls are necessary to complete the copy. In addition,
3844 * {@link CopyWriter#result()} can be used to automatically complete the copy and return information
Original file line number Diff line number Diff line change @@ -1385,12 +1385,17 @@ public static Builder builder() {
13851385 Blob compose (ComposeRequest composeRequest );
13861386
13871387 /**
1388- * Sends a copy request. Returns a {@link CopyWriter} object for the provided
1389- * {@code CopyRequest}. If source and destination objects share the same location and storage
1390- * class the source blob is copied with one request and {@link CopyWriter#result()} immediately
1391- * returns, regardless of the {@link CopyRequest#megabytesCopiedPerChunk} parameter.
1392- * If source and destination have different location or storage class {@link CopyWriter#result()}
1393- * might issue multiple RPC calls depending on blob's size.
1388+ * Sends a copy request. This method copies both blob's data and information. To override source
1389+ * blob's information set the copy target via
1390+ * {@link CopyRequest.Builder#target(BlobInfo, BlobTargetOption...)} or
1391+ * {@link CopyRequest.Builder#target(BlobInfo, Iterable)}.
1392+ *
1393+ * <p>This method returns a {@link CopyWriter} object for the provided {@code CopyRequest}. If
1394+ * source and destination objects share the same location and storage class the source blob is
1395+ * copied with one request and {@link CopyWriter#result()} immediately returns, regardless of the
1396+ * {@link CopyRequest#megabytesCopiedPerChunk} parameter. If source and destination have different
1397+ * location or storage class {@link CopyWriter#result()} might issue multiple RPC calls depending
1398+ * on blob's size.
13941399 *
13951400 * <p>Example usage of copy:
13961401 * <pre> {@code BlobInfo blob = service.copy(copyRequest).result();}
You can’t perform that action at this time.
0 commit comments