From f5b900445723956c8c3a34cd433d29506f35119b Mon Sep 17 00:00:00 2001 From: cloud-java-bot Date: Thu, 12 Dec 2024 02:30:06 +0000 Subject: [PATCH] chore: generate libraries at Thu Dec 12 02:28:21 UTC 2024 --- .../com/google/storage/v2/StorageClient.java | 164 ++ .../google/storage/v2/StorageSettings.java | 10 + .../storage/v2/stub/GrpcStorageStub.java | 30 + .../google/storage/v2/stub/StorageStub.java | 5 + .../storage/v2/stub/StorageStubSettings.java | 27 +- .../com.google.storage.v2/reflect-config.json | 18 + .../com/google/storage/v2/gapic_metadata.json | 3 + .../google/storage/v2/MockStorageImpl.java | 20 + .../google/storage/v2/StorageClientTest.java | 160 ++ .../com/google/storage/v2/StorageGrpc.java | 109 +- .../storage/v2/BidiWriteObjectRequest.java | 36 +- .../v2/BidiWriteObjectRequestOrBuilder.java | 9 +- .../google/storage/v2/MoveObjectRequest.java | 2309 +++++++++++++++++ .../v2/MoveObjectRequestOrBuilder.java | 391 +++ .../java/com/google/storage/v2/Object.java | 623 +++-- .../google/storage/v2/ObjectOrBuilder.java | 41 + .../com/google/storage/v2/StorageProto.java | 651 ++--- .../proto/google/storage/v2/storage.proto | 95 +- 18 files changed, 4214 insertions(+), 487 deletions(-) create mode 100644 proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/MoveObjectRequest.java create mode 100644 proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/MoveObjectRequestOrBuilder.java diff --git a/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageClient.java b/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageClient.java index 3dfec9ca3c..3c06c7efa3 100644 --- a/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageClient.java +++ b/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageClient.java @@ -476,6 +476,25 @@ * * * + * + *

MoveObject + *

Moves the source object to the destination object in the same bucket. + * + *

Request object method variants only take one parameter, a request object, which must be constructed before the call.

+ * + *

"Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method.

+ * + *

Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service.

+ * + * + * * * *

See the individual methods for example code. @@ -3241,6 +3260,151 @@ public final QueryWriteStatusResponse queryWriteStatus(QueryWriteStatusRequest r return stub.queryWriteStatusCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Moves the source object to the destination object in the same bucket. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (StorageClient storageClient = StorageClient.create()) {
+   *   BucketName bucket = BucketName.of("[PROJECT]", "[BUCKET]");
+   *   String sourceObject = "sourceObject1196439354";
+   *   String destinationObject = "destinationObject-1761603347";
+   *   Object response = storageClient.moveObject(bucket, sourceObject, destinationObject);
+   * }
+   * }
+ * + * @param bucket Required. Name of the bucket in which the object resides. + * @param sourceObject Required. Name of the source object. + * @param destinationObject Required. Name of the destination object. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Object moveObject(BucketName bucket, String sourceObject, String destinationObject) { + MoveObjectRequest request = + MoveObjectRequest.newBuilder() + .setBucket(bucket == null ? null : bucket.toString()) + .setSourceObject(sourceObject) + .setDestinationObject(destinationObject) + .build(); + return moveObject(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Moves the source object to the destination object in the same bucket. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (StorageClient storageClient = StorageClient.create()) {
+   *   String bucket = BucketName.of("[PROJECT]", "[BUCKET]").toString();
+   *   String sourceObject = "sourceObject1196439354";
+   *   String destinationObject = "destinationObject-1761603347";
+   *   Object response = storageClient.moveObject(bucket, sourceObject, destinationObject);
+   * }
+   * }
+ * + * @param bucket Required. Name of the bucket in which the object resides. + * @param sourceObject Required. Name of the source object. + * @param destinationObject Required. Name of the destination object. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Object moveObject(String bucket, String sourceObject, String destinationObject) { + MoveObjectRequest request = + MoveObjectRequest.newBuilder() + .setBucket(bucket) + .setSourceObject(sourceObject) + .setDestinationObject(destinationObject) + .build(); + return moveObject(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Moves the source object to the destination object in the same bucket. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (StorageClient storageClient = StorageClient.create()) {
+   *   MoveObjectRequest request =
+   *       MoveObjectRequest.newBuilder()
+   *           .setBucket(BucketName.of("[PROJECT]", "[BUCKET]").toString())
+   *           .setSourceObject("sourceObject1196439354")
+   *           .setDestinationObject("destinationObject-1761603347")
+   *           .setIfSourceGenerationMatch(-1427877280)
+   *           .setIfSourceGenerationNotMatch(1575612532)
+   *           .setIfSourceMetagenerationMatch(1143319909)
+   *           .setIfSourceMetagenerationNotMatch(1900822777)
+   *           .setIfGenerationMatch(-1086241088)
+   *           .setIfGenerationNotMatch(1475720404)
+   *           .setIfMetagenerationMatch(1043427781)
+   *           .setIfMetagenerationNotMatch(1025430873)
+   *           .build();
+   *   Object response = storageClient.moveObject(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Object moveObject(MoveObjectRequest request) { + return moveObjectCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Moves the source object to the destination object in the same bucket. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (StorageClient storageClient = StorageClient.create()) {
+   *   MoveObjectRequest request =
+   *       MoveObjectRequest.newBuilder()
+   *           .setBucket(BucketName.of("[PROJECT]", "[BUCKET]").toString())
+   *           .setSourceObject("sourceObject1196439354")
+   *           .setDestinationObject("destinationObject-1761603347")
+   *           .setIfSourceGenerationMatch(-1427877280)
+   *           .setIfSourceGenerationNotMatch(1575612532)
+   *           .setIfSourceMetagenerationMatch(1143319909)
+   *           .setIfSourceMetagenerationNotMatch(1900822777)
+   *           .setIfGenerationMatch(-1086241088)
+   *           .setIfGenerationNotMatch(1475720404)
+   *           .setIfMetagenerationMatch(1043427781)
+   *           .setIfMetagenerationNotMatch(1025430873)
+   *           .build();
+   *   ApiFuture future = storageClient.moveObjectCallable().futureCall(request);
+   *   // Do something.
+   *   Object response = future.get();
+   * }
+   * }
+   */
+  public final UnaryCallable moveObjectCallable() {
+    return stub.moveObjectCallable();
+  }
+
   @Override
   public final void close() {
     stub.close();
diff --git a/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageSettings.java b/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageSettings.java
index da7cc623c9..7520528f6c 100644
--- a/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageSettings.java
+++ b/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageSettings.java
@@ -212,6 +212,11 @@ public UnaryCallSettings rewriteObjectSet
     return ((StorageStubSettings) getStubSettings()).queryWriteStatusSettings();
   }
 
+  /** Returns the object with the settings used for calls to moveObject. */
+  public UnaryCallSettings moveObjectSettings() {
+    return ((StorageStubSettings) getStubSettings()).moveObjectSettings();
+  }
+
   public static final StorageSettings create(StorageStubSettings stub) throws IOException {
     return new StorageSettings.Builder(stub.toBuilder()).build();
   }
@@ -430,6 +435,11 @@ public UnaryCallSettings.Builder updateObjectSettin
       return getStubSettingsBuilder().queryWriteStatusSettings();
     }
 
+    /** Returns the builder for the settings used for calls to moveObject. */
+    public UnaryCallSettings.Builder moveObjectSettings() {
+      return getStubSettingsBuilder().moveObjectSettings();
+    }
+
     @Override
     public StorageSettings build() throws IOException {
       return new StorageSettings(this);
diff --git a/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/stub/GrpcStorageStub.java b/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/stub/GrpcStorageStub.java
index adab458a4e..be8b11b582 100644
--- a/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/stub/GrpcStorageStub.java
+++ b/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/stub/GrpcStorageStub.java
@@ -53,6 +53,7 @@
 import com.google.storage.v2.ListObjectsRequest;
 import com.google.storage.v2.ListObjectsResponse;
 import com.google.storage.v2.LockBucketRetentionPolicyRequest;
+import com.google.storage.v2.MoveObjectRequest;
 import com.google.storage.v2.Object;
 import com.google.storage.v2.QueryWriteStatusRequest;
 import com.google.storage.v2.QueryWriteStatusResponse;
@@ -287,6 +288,14 @@ public class GrpcStorageStub extends StorageStub {
                   ProtoUtils.marshaller(QueryWriteStatusResponse.getDefaultInstance()))
               .build();
 
+  private static final MethodDescriptor moveObjectMethodDescriptor =
+      MethodDescriptor.newBuilder()
+          .setType(MethodDescriptor.MethodType.UNARY)
+          .setFullMethodName("google.storage.v2.Storage/MoveObject")
+          .setRequestMarshaller(ProtoUtils.marshaller(MoveObjectRequest.getDefaultInstance()))
+          .setResponseMarshaller(ProtoUtils.marshaller(Object.getDefaultInstance()))
+          .build();
+
   private final UnaryCallable deleteBucketCallable;
   private final UnaryCallable getBucketCallable;
   private final UnaryCallable createBucketCallable;
@@ -320,6 +329,7 @@ public class GrpcStorageStub extends StorageStub {
       startResumableWriteCallable;
   private final UnaryCallable
       queryWriteStatusCallable;
+  private final UnaryCallable moveObjectCallable;
 
   private final BackgroundResource backgroundResources;
   private final GrpcOperationsStub operationsStub;
@@ -371,6 +381,8 @@ public class GrpcStorageStub extends StorageStub {
       PathTemplate.create("{bucket=**}");
   private static final PathTemplate QUERY_WRITE_STATUS_0_PATH_TEMPLATE =
       PathTemplate.create("{bucket=projects/*/buckets/*}/**");
+  private static final PathTemplate MOVE_OBJECT_0_PATH_TEMPLATE =
+      PathTemplate.create("{bucket=**}");
 
   public static final GrpcStorageStub create(StorageStubSettings settings) throws IOException {
     return new GrpcStorageStub(settings, ClientContext.create(settings));
@@ -655,6 +667,16 @@ protected GrpcStorageStub(
                       return builder.build();
                     })
                 .build();
+    GrpcCallSettings moveObjectTransportSettings =
+        GrpcCallSettings.newBuilder()
+            .setMethodDescriptor(moveObjectMethodDescriptor)
+            .setParamsExtractor(
+                request -> {
+                  RequestParamsBuilder builder = RequestParamsBuilder.create();
+                  builder.add(request.getBucket(), "bucket", MOVE_OBJECT_0_PATH_TEMPLATE);
+                  return builder.build();
+                })
+            .build();
 
     this.deleteBucketCallable =
         callableFactory.createUnaryCallable(
@@ -736,6 +758,9 @@ protected GrpcStorageStub(
     this.queryWriteStatusCallable =
         callableFactory.createUnaryCallable(
             queryWriteStatusTransportSettings, settings.queryWriteStatusSettings(), clientContext);
+    this.moveObjectCallable =
+        callableFactory.createUnaryCallable(
+            moveObjectTransportSettings, settings.moveObjectSettings(), clientContext);
 
     this.backgroundResources =
         new BackgroundResourceAggregation(clientContext.getBackgroundResources());
@@ -871,6 +896,11 @@ public UnaryCallable rewriteObjectCallabl
     return queryWriteStatusCallable;
   }
 
+  @Override
+  public UnaryCallable moveObjectCallable() {
+    return moveObjectCallable;
+  }
+
   @Override
   public final void close() {
     try {
diff --git a/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/stub/StorageStub.java b/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/stub/StorageStub.java
index 85c17399fa..7c3d886444 100644
--- a/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/stub/StorageStub.java
+++ b/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/stub/StorageStub.java
@@ -46,6 +46,7 @@
 import com.google.storage.v2.ListObjectsRequest;
 import com.google.storage.v2.ListObjectsResponse;
 import com.google.storage.v2.LockBucketRetentionPolicyRequest;
+import com.google.storage.v2.MoveObjectRequest;
 import com.google.storage.v2.Object;
 import com.google.storage.v2.QueryWriteStatusRequest;
 import com.google.storage.v2.QueryWriteStatusResponse;
@@ -173,6 +174,10 @@ public UnaryCallable rewriteObjectCallabl
     throw new UnsupportedOperationException("Not implemented: queryWriteStatusCallable()");
   }
 
+  public UnaryCallable moveObjectCallable() {
+    throw new UnsupportedOperationException("Not implemented: moveObjectCallable()");
+  }
+
   @Override
   public abstract void close();
 }
diff --git a/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/stub/StorageStubSettings.java b/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/stub/StorageStubSettings.java
index 6a571636e3..40a9a04958 100644
--- a/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/stub/StorageStubSettings.java
+++ b/gapic-google-cloud-storage-v2/src/main/java/com/google/storage/v2/stub/StorageStubSettings.java
@@ -69,6 +69,7 @@
 import com.google.storage.v2.ListObjectsRequest;
 import com.google.storage.v2.ListObjectsResponse;
 import com.google.storage.v2.LockBucketRetentionPolicyRequest;
+import com.google.storage.v2.MoveObjectRequest;
 import com.google.storage.v2.Object;
 import com.google.storage.v2.QueryWriteStatusRequest;
 import com.google.storage.v2.QueryWriteStatusResponse;
@@ -180,6 +181,7 @@ public class StorageStubSettings extends StubSettings {
       startResumableWriteSettings;
   private final UnaryCallSettings
       queryWriteStatusSettings;
+  private final UnaryCallSettings moveObjectSettings;
 
   private static final PagedListDescriptor
       LIST_BUCKETS_PAGE_STR_DESC =
@@ -401,6 +403,11 @@ public UnaryCallSettings rewriteObjectSet
     return queryWriteStatusSettings;
   }
 
+  /** Returns the object with the settings used for calls to moveObject. */
+  public UnaryCallSettings moveObjectSettings() {
+    return moveObjectSettings;
+  }
+
   public StorageStub createStub() throws IOException {
     if (getTransportChannelProvider()
         .getTransportName()
@@ -503,6 +510,7 @@ protected StorageStubSettings(Builder settingsBuilder) throws IOException {
     rewriteObjectSettings = settingsBuilder.rewriteObjectSettings().build();
     startResumableWriteSettings = settingsBuilder.startResumableWriteSettings().build();
     queryWriteStatusSettings = settingsBuilder.queryWriteStatusSettings().build();
+    moveObjectSettings = settingsBuilder.moveObjectSettings().build();
   }
 
   /** Builder for StorageStubSettings. */
@@ -544,6 +552,7 @@ public static class Builder extends StubSettings.Builder
         queryWriteStatusSettings;
+    private final UnaryCallSettings.Builder moveObjectSettings;
     private static final ImmutableMap>
         RETRYABLE_CODE_DEFINITIONS;
 
@@ -606,6 +615,7 @@ protected Builder(ClientContext clientContext) {
       rewriteObjectSettings = UnaryCallSettings.newUnaryCallSettingsBuilder();
       startResumableWriteSettings = UnaryCallSettings.newUnaryCallSettingsBuilder();
       queryWriteStatusSettings = UnaryCallSettings.newUnaryCallSettingsBuilder();
+      moveObjectSettings = UnaryCallSettings.newUnaryCallSettingsBuilder();
 
       unaryMethodSettingsBuilders =
           ImmutableList.>of(
@@ -627,7 +637,8 @@ protected Builder(ClientContext clientContext) {
               listObjectsSettings,
               rewriteObjectSettings,
               startResumableWriteSettings,
-              queryWriteStatusSettings);
+              queryWriteStatusSettings,
+              moveObjectSettings);
       initDefaults(this);
     }
 
@@ -656,6 +667,7 @@ protected Builder(StorageStubSettings settings) {
       rewriteObjectSettings = settings.rewriteObjectSettings.toBuilder();
       startResumableWriteSettings = settings.startResumableWriteSettings.toBuilder();
       queryWriteStatusSettings = settings.queryWriteStatusSettings.toBuilder();
+      moveObjectSettings = settings.moveObjectSettings.toBuilder();
 
       unaryMethodSettingsBuilders =
           ImmutableList.>of(
@@ -677,7 +689,8 @@ protected Builder(StorageStubSettings settings) {
               listObjectsSettings,
               rewriteObjectSettings,
               startResumableWriteSettings,
-              queryWriteStatusSettings);
+              queryWriteStatusSettings,
+              moveObjectSettings);
     }
 
     private static Builder createDefault() {
@@ -793,6 +806,11 @@ private static Builder initDefaults(Builder builder) {
           .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes"))
           .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params"));
 
+      builder
+          .moveObjectSettings()
+          .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes"))
+          .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params"));
+
       return builder;
     }
 
@@ -934,6 +952,11 @@ public UnaryCallSettings.Builder updateObjectSettin
       return queryWriteStatusSettings;
     }
 
+    /** Returns the builder for the settings used for calls to moveObject. */
+    public UnaryCallSettings.Builder moveObjectSettings() {
+      return moveObjectSettings;
+    }
+
     @Override
     public StorageStubSettings build() throws IOException {
       return new StorageStubSettings(this);
diff --git a/gapic-google-cloud-storage-v2/src/main/resources/META-INF/native-image/com.google.storage.v2/reflect-config.json b/gapic-google-cloud-storage-v2/src/main/resources/META-INF/native-image/com.google.storage.v2/reflect-config.json
index 9a4f2eff49..dcba41fdaa 100644
--- a/gapic-google-cloud-storage-v2/src/main/resources/META-INF/native-image/com.google.storage.v2/reflect-config.json
+++ b/gapic-google-cloud-storage-v2/src/main/resources/META-INF/native-image/com.google.storage.v2/reflect-config.json
@@ -2213,6 +2213,24 @@
     "allDeclaredClasses": true,
     "allPublicClasses": true
   },
+  {
+    "name": "com.google.storage.v2.MoveObjectRequest",
+    "queryAllDeclaredConstructors": true,
+    "queryAllPublicConstructors": true,
+    "queryAllDeclaredMethods": true,
+    "allPublicMethods": true,
+    "allDeclaredClasses": true,
+    "allPublicClasses": true
+  },
+  {
+    "name": "com.google.storage.v2.MoveObjectRequest$Builder",
+    "queryAllDeclaredConstructors": true,
+    "queryAllPublicConstructors": true,
+    "queryAllDeclaredMethods": true,
+    "allPublicMethods": true,
+    "allDeclaredClasses": true,
+    "allPublicClasses": true
+  },
   {
     "name": "com.google.storage.v2.Object",
     "queryAllDeclaredConstructors": true,
diff --git a/gapic-google-cloud-storage-v2/src/main/resources/com/google/storage/v2/gapic_metadata.json b/gapic-google-cloud-storage-v2/src/main/resources/com/google/storage/v2/gapic_metadata.json
index 3d06494946..8756be5ca4 100644
--- a/gapic-google-cloud-storage-v2/src/main/resources/com/google/storage/v2/gapic_metadata.json
+++ b/gapic-google-cloud-storage-v2/src/main/resources/com/google/storage/v2/gapic_metadata.json
@@ -46,6 +46,9 @@
             "LockBucketRetentionPolicy": {
               "methods": ["lockBucketRetentionPolicy", "lockBucketRetentionPolicy", "lockBucketRetentionPolicy", "lockBucketRetentionPolicyCallable"]
             },
+            "MoveObject": {
+              "methods": ["moveObject", "moveObject", "moveObject", "moveObjectCallable"]
+            },
             "QueryWriteStatus": {
               "methods": ["queryWriteStatus", "queryWriteStatus", "queryWriteStatusCallable"]
             },
diff --git a/gapic-google-cloud-storage-v2/src/test/java/com/google/storage/v2/MockStorageImpl.java b/gapic-google-cloud-storage-v2/src/test/java/com/google/storage/v2/MockStorageImpl.java
index e016a3007c..ac8c6a6e30 100644
--- a/gapic-google-cloud-storage-v2/src/test/java/com/google/storage/v2/MockStorageImpl.java
+++ b/gapic-google-cloud-storage-v2/src/test/java/com/google/storage/v2/MockStorageImpl.java
@@ -549,4 +549,24 @@ public void queryWriteStatus(
                   Exception.class.getName())));
     }
   }
+
+  @Override
+  public void moveObject(MoveObjectRequest request, StreamObserver responseObserver) {
+    java.lang.Object response = responses.poll();
+    if (response instanceof Object) {
+      requests.add(request);
+      responseObserver.onNext(((Object) response));
+      responseObserver.onCompleted();
+    } else if (response instanceof Exception) {
+      responseObserver.onError(((Exception) response));
+    } else {
+      responseObserver.onError(
+          new IllegalArgumentException(
+              String.format(
+                  "Unrecognized response type %s for method MoveObject, expected %s or %s",
+                  response == null ? "null" : response.getClass().getName(),
+                  Object.class.getName(),
+                  Exception.class.getName())));
+    }
+  }
 }
diff --git a/gapic-google-cloud-storage-v2/src/test/java/com/google/storage/v2/StorageClientTest.java b/gapic-google-cloud-storage-v2/src/test/java/com/google/storage/v2/StorageClientTest.java
index ab4fc0b153..a782a6df91 100644
--- a/gapic-google-cloud-storage-v2/src/test/java/com/google/storage/v2/StorageClientTest.java
+++ b/gapic-google-cloud-storage-v2/src/test/java/com/google/storage/v2/StorageClientTest.java
@@ -1014,6 +1014,7 @@ public void composeObjectTest() throws Exception {
             .addAllAcl(new ArrayList())
             .setContentLanguage("contentLanguage810066673")
             .setDeleteTime(Timestamp.newBuilder().build())
+            .setFinalizeTime(Timestamp.newBuilder().build())
             .setContentType("contentType-389131437")
             .setCreateTime(Timestamp.newBuilder().build())
             .setComponentCount(-485073075)
@@ -1271,6 +1272,7 @@ public void restoreObjectTest() throws Exception {
             .addAllAcl(new ArrayList())
             .setContentLanguage("contentLanguage810066673")
             .setDeleteTime(Timestamp.newBuilder().build())
+            .setFinalizeTime(Timestamp.newBuilder().build())
             .setContentType("contentType-389131437")
             .setCreateTime(Timestamp.newBuilder().build())
             .setComponentCount(-485073075)
@@ -1346,6 +1348,7 @@ public void restoreObjectTest2() throws Exception {
             .addAllAcl(new ArrayList())
             .setContentLanguage("contentLanguage810066673")
             .setDeleteTime(Timestamp.newBuilder().build())
+            .setFinalizeTime(Timestamp.newBuilder().build())
             .setContentType("contentType-389131437")
             .setCreateTime(Timestamp.newBuilder().build())
             .setComponentCount(-485073075)
@@ -1458,6 +1461,7 @@ public void getObjectTest() throws Exception {
             .addAllAcl(new ArrayList())
             .setContentLanguage("contentLanguage810066673")
             .setDeleteTime(Timestamp.newBuilder().build())
+            .setFinalizeTime(Timestamp.newBuilder().build())
             .setContentType("contentType-389131437")
             .setCreateTime(Timestamp.newBuilder().build())
             .setComponentCount(-485073075)
@@ -1530,6 +1534,7 @@ public void getObjectTest2() throws Exception {
             .addAllAcl(new ArrayList())
             .setContentLanguage("contentLanguage810066673")
             .setDeleteTime(Timestamp.newBuilder().build())
+            .setFinalizeTime(Timestamp.newBuilder().build())
             .setContentType("contentType-389131437")
             .setCreateTime(Timestamp.newBuilder().build())
             .setComponentCount(-485073075)
@@ -1602,6 +1607,7 @@ public void getObjectTest3() throws Exception {
             .addAllAcl(new ArrayList())
             .setContentLanguage("contentLanguage810066673")
             .setDeleteTime(Timestamp.newBuilder().build())
+            .setFinalizeTime(Timestamp.newBuilder().build())
             .setContentType("contentType-389131437")
             .setCreateTime(Timestamp.newBuilder().build())
             .setComponentCount(-485073075)
@@ -1677,6 +1683,7 @@ public void getObjectTest4() throws Exception {
             .addAllAcl(new ArrayList())
             .setContentLanguage("contentLanguage810066673")
             .setDeleteTime(Timestamp.newBuilder().build())
+            .setFinalizeTime(Timestamp.newBuilder().build())
             .setContentType("contentType-389131437")
             .setCreateTime(Timestamp.newBuilder().build())
             .setComponentCount(-485073075)
@@ -1823,6 +1830,7 @@ public void updateObjectTest() throws Exception {
             .addAllAcl(new ArrayList())
             .setContentLanguage("contentLanguage810066673")
             .setDeleteTime(Timestamp.newBuilder().build())
+            .setFinalizeTime(Timestamp.newBuilder().build())
             .setContentType("contentType-389131437")
             .setCreateTime(Timestamp.newBuilder().build())
             .setComponentCount(-485073075)
@@ -2301,4 +2309,156 @@ public void queryWriteStatusExceptionTest() throws Exception {
       // Expected exception.
     }
   }
+
+  @Test
+  public void moveObjectTest() throws Exception {
+    Object expectedResponse =
+        Object.newBuilder()
+            .setName("name3373707")
+            .setBucket(BucketName.of("[PROJECT]", "[BUCKET]").toString())
+            .setEtag("etag3123477")
+            .setGeneration(305703192)
+            .setRestoreToken("restoreToken1638686731")
+            .setMetageneration(1048558813)
+            .setStorageClass("storageClass871353277")
+            .setSize(3530753)
+            .setContentEncoding("contentEncoding-160088852")
+            .setContentDisposition("contentDisposition1034341758")
+            .setCacheControl("cacheControl-1336592517")
+            .addAllAcl(new ArrayList())
+            .setContentLanguage("contentLanguage810066673")
+            .setDeleteTime(Timestamp.newBuilder().build())
+            .setFinalizeTime(Timestamp.newBuilder().build())
+            .setContentType("contentType-389131437")
+            .setCreateTime(Timestamp.newBuilder().build())
+            .setComponentCount(-485073075)
+            .setChecksums(ObjectChecksums.newBuilder().build())
+            .setUpdateTime(Timestamp.newBuilder().build())
+            .setKmsKey(
+                CryptoKeyName.of("[PROJECT]", "[LOCATION]", "[KEY_RING]", "[CRYPTO_KEY]")
+                    .toString())
+            .setUpdateStorageClassTime(Timestamp.newBuilder().build())
+            .setTemporaryHold(true)
+            .setRetentionExpireTime(Timestamp.newBuilder().build())
+            .putAllMetadata(new HashMap())
+            .setEventBasedHold(true)
+            .setOwner(Owner.newBuilder().build())
+            .setCustomerEncryption(CustomerEncryption.newBuilder().build())
+            .setCustomTime(Timestamp.newBuilder().build())
+            .setSoftDeleteTime(Timestamp.newBuilder().build())
+            .setHardDeleteTime(Timestamp.newBuilder().build())
+            .build();
+    mockStorage.addResponse(expectedResponse);
+
+    BucketName bucket = BucketName.of("[PROJECT]", "[BUCKET]");
+    String sourceObject = "sourceObject1196439354";
+    String destinationObject = "destinationObject-1761603347";
+
+    Object actualResponse = client.moveObject(bucket, sourceObject, destinationObject);
+    Assert.assertEquals(expectedResponse, actualResponse);
+
+    List actualRequests = mockStorage.getRequests();
+    Assert.assertEquals(1, actualRequests.size());
+    MoveObjectRequest actualRequest = ((MoveObjectRequest) actualRequests.get(0));
+
+    Assert.assertEquals(bucket.toString(), actualRequest.getBucket());
+    Assert.assertEquals(sourceObject, actualRequest.getSourceObject());
+    Assert.assertEquals(destinationObject, actualRequest.getDestinationObject());
+    Assert.assertTrue(
+        channelProvider.isHeaderSent(
+            ApiClientHeaderProvider.getDefaultApiClientHeaderKey(),
+            GaxGrpcProperties.getDefaultApiClientHeaderPattern()));
+  }
+
+  @Test
+  public void moveObjectExceptionTest() throws Exception {
+    StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT);
+    mockStorage.addException(exception);
+
+    try {
+      BucketName bucket = BucketName.of("[PROJECT]", "[BUCKET]");
+      String sourceObject = "sourceObject1196439354";
+      String destinationObject = "destinationObject-1761603347";
+      client.moveObject(bucket, sourceObject, destinationObject);
+      Assert.fail("No exception raised");
+    } catch (InvalidArgumentException e) {
+      // Expected exception.
+    }
+  }
+
+  @Test
+  public void moveObjectTest2() throws Exception {
+    Object expectedResponse =
+        Object.newBuilder()
+            .setName("name3373707")
+            .setBucket(BucketName.of("[PROJECT]", "[BUCKET]").toString())
+            .setEtag("etag3123477")
+            .setGeneration(305703192)
+            .setRestoreToken("restoreToken1638686731")
+            .setMetageneration(1048558813)
+            .setStorageClass("storageClass871353277")
+            .setSize(3530753)
+            .setContentEncoding("contentEncoding-160088852")
+            .setContentDisposition("contentDisposition1034341758")
+            .setCacheControl("cacheControl-1336592517")
+            .addAllAcl(new ArrayList())
+            .setContentLanguage("contentLanguage810066673")
+            .setDeleteTime(Timestamp.newBuilder().build())
+            .setFinalizeTime(Timestamp.newBuilder().build())
+            .setContentType("contentType-389131437")
+            .setCreateTime(Timestamp.newBuilder().build())
+            .setComponentCount(-485073075)
+            .setChecksums(ObjectChecksums.newBuilder().build())
+            .setUpdateTime(Timestamp.newBuilder().build())
+            .setKmsKey(
+                CryptoKeyName.of("[PROJECT]", "[LOCATION]", "[KEY_RING]", "[CRYPTO_KEY]")
+                    .toString())
+            .setUpdateStorageClassTime(Timestamp.newBuilder().build())
+            .setTemporaryHold(true)
+            .setRetentionExpireTime(Timestamp.newBuilder().build())
+            .putAllMetadata(new HashMap())
+            .setEventBasedHold(true)
+            .setOwner(Owner.newBuilder().build())
+            .setCustomerEncryption(CustomerEncryption.newBuilder().build())
+            .setCustomTime(Timestamp.newBuilder().build())
+            .setSoftDeleteTime(Timestamp.newBuilder().build())
+            .setHardDeleteTime(Timestamp.newBuilder().build())
+            .build();
+    mockStorage.addResponse(expectedResponse);
+
+    String bucket = "bucket-1378203158";
+    String sourceObject = "sourceObject1196439354";
+    String destinationObject = "destinationObject-1761603347";
+
+    Object actualResponse = client.moveObject(bucket, sourceObject, destinationObject);
+    Assert.assertEquals(expectedResponse, actualResponse);
+
+    List actualRequests = mockStorage.getRequests();
+    Assert.assertEquals(1, actualRequests.size());
+    MoveObjectRequest actualRequest = ((MoveObjectRequest) actualRequests.get(0));
+
+    Assert.assertEquals(bucket, actualRequest.getBucket());
+    Assert.assertEquals(sourceObject, actualRequest.getSourceObject());
+    Assert.assertEquals(destinationObject, actualRequest.getDestinationObject());
+    Assert.assertTrue(
+        channelProvider.isHeaderSent(
+            ApiClientHeaderProvider.getDefaultApiClientHeaderKey(),
+            GaxGrpcProperties.getDefaultApiClientHeaderPattern()));
+  }
+
+  @Test
+  public void moveObjectExceptionTest2() throws Exception {
+    StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT);
+    mockStorage.addException(exception);
+
+    try {
+      String bucket = "bucket-1378203158";
+      String sourceObject = "sourceObject1196439354";
+      String destinationObject = "destinationObject-1761603347";
+      client.moveObject(bucket, sourceObject, destinationObject);
+      Assert.fail("No exception raised");
+    } catch (InvalidArgumentException e) {
+      // Expected exception.
+    }
+  }
 }
diff --git a/grpc-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageGrpc.java b/grpc-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageGrpc.java
index 4db7e12745..8241072dcb 100644
--- a/grpc-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageGrpc.java
+++ b/grpc-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageGrpc.java
@@ -962,6 +962,45 @@ private StorageGrpc() {}
     return getQueryWriteStatusMethod;
   }
 
+  private static volatile io.grpc.MethodDescriptor<
+          com.google.storage.v2.MoveObjectRequest, com.google.storage.v2.Object>
+      getMoveObjectMethod;
+
+  @io.grpc.stub.annotations.RpcMethod(
+      fullMethodName = SERVICE_NAME + '/' + "MoveObject",
+      requestType = com.google.storage.v2.MoveObjectRequest.class,
+      responseType = com.google.storage.v2.Object.class,
+      methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
+  public static io.grpc.MethodDescriptor<
+          com.google.storage.v2.MoveObjectRequest, com.google.storage.v2.Object>
+      getMoveObjectMethod() {
+    io.grpc.MethodDescriptor
+        getMoveObjectMethod;
+    if ((getMoveObjectMethod = StorageGrpc.getMoveObjectMethod) == null) {
+      synchronized (StorageGrpc.class) {
+        if ((getMoveObjectMethod = StorageGrpc.getMoveObjectMethod) == null) {
+          StorageGrpc.getMoveObjectMethod =
+              getMoveObjectMethod =
+                  io.grpc.MethodDescriptor
+                      .
+                          newBuilder()
+                      .setType(io.grpc.MethodDescriptor.MethodType.UNARY)
+                      .setFullMethodName(generateFullMethodName(SERVICE_NAME, "MoveObject"))
+                      .setSampledToLocalTracing(true)
+                      .setRequestMarshaller(
+                          io.grpc.protobuf.ProtoUtils.marshaller(
+                              com.google.storage.v2.MoveObjectRequest.getDefaultInstance()))
+                      .setResponseMarshaller(
+                          io.grpc.protobuf.ProtoUtils.marshaller(
+                              com.google.storage.v2.Object.getDefaultInstance()))
+                      .setSchemaDescriptor(new StorageMethodDescriptorSupplier("MoveObject"))
+                      .build();
+        }
+      }
+    }
+    return getMoveObjectMethod;
+  }
+
   /** Creates a new async stub that supports all call types for the service */
   public static StorageStub newStub(io.grpc.Channel channel) {
     io.grpc.stub.AbstractStub.StubFactory factory =
@@ -1435,6 +1474,19 @@ default void queryWriteStatus(
       io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(
           getQueryWriteStatusMethod(), responseObserver);
     }
+
+    /**
+     *
+     *
+     * 
+     * Moves the source object to the destination object in the same bucket.
+     * 
+ */ + default void moveObject( + com.google.storage.v2.MoveObjectRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getMoveObjectMethod(), responseObserver); + } } /** @@ -1947,6 +1999,20 @@ public void queryWriteStatus( request, responseObserver); } + + /** + * + * + *
+     * Moves the source object to the destination object in the same bucket.
+     * 
+ */ + public void moveObject( + com.google.storage.v2.MoveObjectRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getMoveObjectMethod(), getCallOptions()), request, responseObserver); + } } /** @@ -2273,6 +2339,19 @@ public com.google.storage.v2.QueryWriteStatusResponse queryWriteStatus( return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getQueryWriteStatusMethod(), getCallOptions(), request); } + + /** + * + * + *
+     * Moves the source object to the destination object in the same bucket.
+     * 
+ */ + public com.google.storage.v2.Object moveObject( + com.google.storage.v2.MoveObjectRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getMoveObjectMethod(), getCallOptions(), request); + } } /** @@ -2596,6 +2675,19 @@ protected StorageFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions c return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getQueryWriteStatusMethod(), getCallOptions()), request); } + + /** + * + * + *
+     * Moves the source object to the destination object in the same bucket.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + moveObject(com.google.storage.v2.MoveObjectRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getMoveObjectMethod(), getCallOptions()), request); + } } private static final int METHODID_DELETE_BUCKET = 0; @@ -2618,8 +2710,9 @@ protected StorageFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions c private static final int METHODID_REWRITE_OBJECT = 17; private static final int METHODID_START_RESUMABLE_WRITE = 18; private static final int METHODID_QUERY_WRITE_STATUS = 19; - private static final int METHODID_WRITE_OBJECT = 20; - private static final int METHODID_BIDI_WRITE_OBJECT = 21; + private static final int METHODID_MOVE_OBJECT = 20; + private static final int METHODID_WRITE_OBJECT = 21; + private static final int METHODID_BIDI_WRITE_OBJECT = 22; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -2746,6 +2839,11 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_MOVE_OBJECT: + serviceImpl.moveObject( + (com.google.storage.v2.MoveObjectRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; default: throw new AssertionError(); } @@ -2909,6 +3007,12 @@ public static final io.grpc.ServerServiceDefinition bindService(AsyncService ser com.google.storage.v2.QueryWriteStatusRequest, com.google.storage.v2.QueryWriteStatusResponse>( service, METHODID_QUERY_WRITE_STATUS))) + .addMethod( + getMoveObjectMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.storage.v2.MoveObjectRequest, com.google.storage.v2.Object>( + service, METHODID_MOVE_OBJECT))) .build(); } @@ -2980,6 +3084,7 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getRewriteObjectMethod()) .addMethod(getStartResumableWriteMethod()) .addMethod(getQueryWriteStatusMethod()) + .addMethod(getMoveObjectMethod()) .build(); } } diff --git a/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/BidiWriteObjectRequest.java b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/BidiWriteObjectRequest.java index 1789c09e63..01b762d42a 100644 --- a/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/BidiWriteObjectRequest.java +++ b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/BidiWriteObjectRequest.java @@ -376,7 +376,8 @@ public com.google.storage.v2.ChecksummedDataOrBuilder getChecksummedDataOrBuilde *
    * Checksums for the complete object. If the checksums computed by the service
    * don't match the specified checksums the call will fail. May only be
-   * provided in last request (with finish_write set).
+   * provided in the first request or the
+   * last request (with finish_write set).
    * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -393,7 +394,8 @@ public boolean hasObjectChecksums() { *
    * Checksums for the complete object. If the checksums computed by the service
    * don't match the specified checksums the call will fail. May only be
-   * provided in last request (with finish_write set).
+   * provided in the first request or the
+   * last request (with finish_write set).
    * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -412,7 +414,8 @@ public com.google.storage.v2.ObjectChecksums getObjectChecksums() { *
    * Checksums for the complete object. If the checksums computed by the service
    * don't match the specified checksums the call will fail. May only be
-   * provided in last request (with finish_write set).
+   * provided in the first request or the
+   * last request (with finish_write set).
    * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -1870,7 +1873,8 @@ public com.google.storage.v2.ChecksummedDataOrBuilder getChecksummedDataOrBuilde *
      * Checksums for the complete object. If the checksums computed by the service
      * don't match the specified checksums the call will fail. May only be
-     * provided in last request (with finish_write set).
+     * provided in the first request or the
+     * last request (with finish_write set).
      * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -1886,7 +1890,8 @@ public boolean hasObjectChecksums() { *
      * Checksums for the complete object. If the checksums computed by the service
      * don't match the specified checksums the call will fail. May only be
-     * provided in last request (with finish_write set).
+     * provided in the first request or the
+     * last request (with finish_write set).
      * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -1908,7 +1913,8 @@ public com.google.storage.v2.ObjectChecksums getObjectChecksums() { *
      * Checksums for the complete object. If the checksums computed by the service
      * don't match the specified checksums the call will fail. May only be
-     * provided in last request (with finish_write set).
+     * provided in the first request or the
+     * last request (with finish_write set).
      * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -1932,7 +1938,8 @@ public Builder setObjectChecksums(com.google.storage.v2.ObjectChecksums value) { *
      * Checksums for the complete object. If the checksums computed by the service
      * don't match the specified checksums the call will fail. May only be
-     * provided in last request (with finish_write set).
+     * provided in the first request or the
+     * last request (with finish_write set).
      * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -1954,7 +1961,8 @@ public Builder setObjectChecksums( *
      * Checksums for the complete object. If the checksums computed by the service
      * don't match the specified checksums the call will fail. May only be
-     * provided in last request (with finish_write set).
+     * provided in the first request or the
+     * last request (with finish_write set).
      * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -1983,7 +1991,8 @@ public Builder mergeObjectChecksums(com.google.storage.v2.ObjectChecksums value) *
      * Checksums for the complete object. If the checksums computed by the service
      * don't match the specified checksums the call will fail. May only be
-     * provided in last request (with finish_write set).
+     * provided in the first request or the
+     * last request (with finish_write set).
      * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -2004,7 +2013,8 @@ public Builder clearObjectChecksums() { *
      * Checksums for the complete object. If the checksums computed by the service
      * don't match the specified checksums the call will fail. May only be
-     * provided in last request (with finish_write set).
+     * provided in the first request or the
+     * last request (with finish_write set).
      * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -2020,7 +2030,8 @@ public com.google.storage.v2.ObjectChecksums.Builder getObjectChecksumsBuilder() *
      * Checksums for the complete object. If the checksums computed by the service
      * don't match the specified checksums the call will fail. May only be
-     * provided in last request (with finish_write set).
+     * provided in the first request or the
+     * last request (with finish_write set).
      * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -2040,7 +2051,8 @@ public com.google.storage.v2.ObjectChecksumsOrBuilder getObjectChecksumsOrBuilde *
      * Checksums for the complete object. If the checksums computed by the service
      * don't match the specified checksums the call will fail. May only be
-     * provided in last request (with finish_write set).
+     * provided in the first request or the
+     * last request (with finish_write set).
      * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; diff --git a/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/BidiWriteObjectRequestOrBuilder.java b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/BidiWriteObjectRequestOrBuilder.java index f753ed4c97..dc4c7776b4 100644 --- a/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/BidiWriteObjectRequestOrBuilder.java +++ b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/BidiWriteObjectRequestOrBuilder.java @@ -171,7 +171,8 @@ public interface BidiWriteObjectRequestOrBuilder *
    * Checksums for the complete object. If the checksums computed by the service
    * don't match the specified checksums the call will fail. May only be
-   * provided in last request (with finish_write set).
+   * provided in the first request or the
+   * last request (with finish_write set).
    * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -185,7 +186,8 @@ public interface BidiWriteObjectRequestOrBuilder *
    * Checksums for the complete object. If the checksums computed by the service
    * don't match the specified checksums the call will fail. May only be
-   * provided in last request (with finish_write set).
+   * provided in the first request or the
+   * last request (with finish_write set).
    * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; @@ -199,7 +201,8 @@ public interface BidiWriteObjectRequestOrBuilder *
    * Checksums for the complete object. If the checksums computed by the service
    * don't match the specified checksums the call will fail. May only be
-   * provided in last request (with finish_write set).
+   * provided in the first request or the
+   * last request (with finish_write set).
    * 
* * .google.storage.v2.ObjectChecksums object_checksums = 6; diff --git a/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/MoveObjectRequest.java b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/MoveObjectRequest.java new file mode 100644 index 0000000000..aeb67cfa41 --- /dev/null +++ b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/MoveObjectRequest.java @@ -0,0 +1,2309 @@ +/* + * Copyright 2024 Google LLC + * + * 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 + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/storage/v2/storage.proto + +// Protobuf Java Version: 3.25.5 +package com.google.storage.v2; + +/** + * + * + *
+ * Request message for MoveObject.
+ * 
+ * + * Protobuf type {@code google.storage.v2.MoveObjectRequest} + */ +public final class MoveObjectRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.storage.v2.MoveObjectRequest) + MoveObjectRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use MoveObjectRequest.newBuilder() to construct. + private MoveObjectRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private MoveObjectRequest() { + bucket_ = ""; + sourceObject_ = ""; + destinationObject_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new MoveObjectRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.storage.v2.StorageProto + .internal_static_google_storage_v2_MoveObjectRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.storage.v2.StorageProto + .internal_static_google_storage_v2_MoveObjectRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.storage.v2.MoveObjectRequest.class, + com.google.storage.v2.MoveObjectRequest.Builder.class); + } + + private int bitField0_; + public static final int BUCKET_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object bucket_ = ""; + /** + * + * + *
+   * Required. Name of the bucket in which the object resides.
+   * 
+ * + * + * string bucket = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bucket. + */ + @java.lang.Override + public java.lang.String getBucket() { + java.lang.Object ref = bucket_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + bucket_ = s; + return s; + } + } + /** + * + * + *
+   * Required. Name of the bucket in which the object resides.
+   * 
+ * + * + * string bucket = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for bucket. + */ + @java.lang.Override + public com.google.protobuf.ByteString getBucketBytes() { + java.lang.Object ref = bucket_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + bucket_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SOURCE_OBJECT_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object sourceObject_ = ""; + /** + * + * + *
+   * Required. Name of the source object.
+   * 
+ * + * string source_object = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The sourceObject. + */ + @java.lang.Override + public java.lang.String getSourceObject() { + java.lang.Object ref = sourceObject_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sourceObject_ = s; + return s; + } + } + /** + * + * + *
+   * Required. Name of the source object.
+   * 
+ * + * string source_object = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for sourceObject. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSourceObjectBytes() { + java.lang.Object ref = sourceObject_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sourceObject_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESTINATION_OBJECT_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private volatile java.lang.Object destinationObject_ = ""; + /** + * + * + *
+   * Required. Name of the destination object.
+   * 
+ * + * string destination_object = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The destinationObject. + */ + @java.lang.Override + public java.lang.String getDestinationObject() { + java.lang.Object ref = destinationObject_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + destinationObject_ = s; + return s; + } + } + /** + * + * + *
+   * Required. Name of the destination object.
+   * 
+ * + * string destination_object = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for destinationObject. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDestinationObjectBytes() { + java.lang.Object ref = destinationObject_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + destinationObject_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int IF_SOURCE_GENERATION_MATCH_FIELD_NUMBER = 4; + private long ifSourceGenerationMatch_ = 0L; + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current generation matches the given value. `if_source_generation_match`
+   * and `if_source_generation_not_match` conditions are mutually exclusive:
+   * it's an error for both of them to be set in the request.
+   * 
+ * + * optional int64 if_source_generation_match = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifSourceGenerationMatch field is set. + */ + @java.lang.Override + public boolean hasIfSourceGenerationMatch() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current generation matches the given value. `if_source_generation_match`
+   * and `if_source_generation_not_match` conditions are mutually exclusive:
+   * it's an error for both of them to be set in the request.
+   * 
+ * + * optional int64 if_source_generation_match = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifSourceGenerationMatch. + */ + @java.lang.Override + public long getIfSourceGenerationMatch() { + return ifSourceGenerationMatch_; + } + + public static final int IF_SOURCE_GENERATION_NOT_MATCH_FIELD_NUMBER = 5; + private long ifSourceGenerationNotMatch_ = 0L; + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current generation does not match the given value.
+   * `if_source_generation_match` and `if_source_generation_not_match`
+   * conditions are mutually exclusive: it's an error for both of them to be set
+   * in the request.
+   * 
+ * + * + * optional int64 if_source_generation_not_match = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifSourceGenerationNotMatch field is set. + */ + @java.lang.Override + public boolean hasIfSourceGenerationNotMatch() { + return ((bitField0_ & 0x00000002) != 0); + } + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current generation does not match the given value.
+   * `if_source_generation_match` and `if_source_generation_not_match`
+   * conditions are mutually exclusive: it's an error for both of them to be set
+   * in the request.
+   * 
+ * + * + * optional int64 if_source_generation_not_match = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifSourceGenerationNotMatch. + */ + @java.lang.Override + public long getIfSourceGenerationNotMatch() { + return ifSourceGenerationNotMatch_; + } + + public static final int IF_SOURCE_METAGENERATION_MATCH_FIELD_NUMBER = 6; + private long ifSourceMetagenerationMatch_ = 0L; + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current metageneration matches the given value.
+   * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+   * conditions are mutually exclusive: it's an error for both of them to be set
+   * in the request.
+   * 
+ * + * + * optional int64 if_source_metageneration_match = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifSourceMetagenerationMatch field is set. + */ + @java.lang.Override + public boolean hasIfSourceMetagenerationMatch() { + return ((bitField0_ & 0x00000004) != 0); + } + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current metageneration matches the given value.
+   * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+   * conditions are mutually exclusive: it's an error for both of them to be set
+   * in the request.
+   * 
+ * + * + * optional int64 if_source_metageneration_match = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifSourceMetagenerationMatch. + */ + @java.lang.Override + public long getIfSourceMetagenerationMatch() { + return ifSourceMetagenerationMatch_; + } + + public static final int IF_SOURCE_METAGENERATION_NOT_MATCH_FIELD_NUMBER = 7; + private long ifSourceMetagenerationNotMatch_ = 0L; + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current metageneration does not match the given value.
+   * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+   * conditions are mutually exclusive: it's an error for both of them to be set
+   * in the request.
+   * 
+ * + * + * optional int64 if_source_metageneration_not_match = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifSourceMetagenerationNotMatch field is set. + */ + @java.lang.Override + public boolean hasIfSourceMetagenerationNotMatch() { + return ((bitField0_ & 0x00000008) != 0); + } + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current metageneration does not match the given value.
+   * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+   * conditions are mutually exclusive: it's an error for both of them to be set
+   * in the request.
+   * 
+ * + * + * optional int64 if_source_metageneration_not_match = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifSourceMetagenerationNotMatch. + */ + @java.lang.Override + public long getIfSourceMetagenerationNotMatch() { + return ifSourceMetagenerationNotMatch_; + } + + public static final int IF_GENERATION_MATCH_FIELD_NUMBER = 8; + private long ifGenerationMatch_ = 0L; + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current generation matches the given value. Setting to 0 makes the
+   * operation succeed only if there are no live versions of the object.
+   * `if_generation_match` and `if_generation_not_match` conditions are mutually
+   * exclusive: it's an error for both of them to be set in the request.
+   * 
+ * + * optional int64 if_generation_match = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the ifGenerationMatch field is set. + */ + @java.lang.Override + public boolean hasIfGenerationMatch() { + return ((bitField0_ & 0x00000010) != 0); + } + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current generation matches the given value. Setting to 0 makes the
+   * operation succeed only if there are no live versions of the object.
+   * `if_generation_match` and `if_generation_not_match` conditions are mutually
+   * exclusive: it's an error for both of them to be set in the request.
+   * 
+ * + * optional int64 if_generation_match = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The ifGenerationMatch. + */ + @java.lang.Override + public long getIfGenerationMatch() { + return ifGenerationMatch_; + } + + public static final int IF_GENERATION_NOT_MATCH_FIELD_NUMBER = 9; + private long ifGenerationNotMatch_ = 0L; + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current generation does not match the given value. If no live
+   * object exists, the precondition fails. Setting to 0 makes the operation
+   * succeed only if there is a live version of the object.
+   * `if_generation_match` and `if_generation_not_match` conditions are mutually
+   * exclusive: it's an error for both of them to be set in the request.
+   * 
+ * + * optional int64 if_generation_not_match = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifGenerationNotMatch field is set. + */ + @java.lang.Override + public boolean hasIfGenerationNotMatch() { + return ((bitField0_ & 0x00000020) != 0); + } + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current generation does not match the given value. If no live
+   * object exists, the precondition fails. Setting to 0 makes the operation
+   * succeed only if there is a live version of the object.
+   * `if_generation_match` and `if_generation_not_match` conditions are mutually
+   * exclusive: it's an error for both of them to be set in the request.
+   * 
+ * + * optional int64 if_generation_not_match = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifGenerationNotMatch. + */ + @java.lang.Override + public long getIfGenerationNotMatch() { + return ifGenerationNotMatch_; + } + + public static final int IF_METAGENERATION_MATCH_FIELD_NUMBER = 10; + private long ifMetagenerationMatch_ = 0L; + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current metageneration matches the given value.
+   * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+   * mutually exclusive: it's an error for both of them to be set in the
+   * request.
+   * 
+ * + * optional int64 if_metageneration_match = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifMetagenerationMatch field is set. + */ + @java.lang.Override + public boolean hasIfMetagenerationMatch() { + return ((bitField0_ & 0x00000040) != 0); + } + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current metageneration matches the given value.
+   * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+   * mutually exclusive: it's an error for both of them to be set in the
+   * request.
+   * 
+ * + * optional int64 if_metageneration_match = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifMetagenerationMatch. + */ + @java.lang.Override + public long getIfMetagenerationMatch() { + return ifMetagenerationMatch_; + } + + public static final int IF_METAGENERATION_NOT_MATCH_FIELD_NUMBER = 11; + private long ifMetagenerationNotMatch_ = 0L; + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current metageneration does not match the given value.
+   * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+   * mutually exclusive: it's an error for both of them to be set in the
+   * request.
+   * 
+ * + * + * optional int64 if_metageneration_not_match = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifMetagenerationNotMatch field is set. + */ + @java.lang.Override + public boolean hasIfMetagenerationNotMatch() { + return ((bitField0_ & 0x00000080) != 0); + } + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current metageneration does not match the given value.
+   * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+   * mutually exclusive: it's an error for both of them to be set in the
+   * request.
+   * 
+ * + * + * optional int64 if_metageneration_not_match = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifMetagenerationNotMatch. + */ + @java.lang.Override + public long getIfMetagenerationNotMatch() { + return ifMetagenerationNotMatch_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(bucket_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, bucket_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sourceObject_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, sourceObject_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(destinationObject_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, destinationObject_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeInt64(4, ifSourceGenerationMatch_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeInt64(5, ifSourceGenerationNotMatch_); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeInt64(6, ifSourceMetagenerationMatch_); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeInt64(7, ifSourceMetagenerationNotMatch_); + } + if (((bitField0_ & 0x00000010) != 0)) { + output.writeInt64(8, ifGenerationMatch_); + } + if (((bitField0_ & 0x00000020) != 0)) { + output.writeInt64(9, ifGenerationNotMatch_); + } + if (((bitField0_ & 0x00000040) != 0)) { + output.writeInt64(10, ifMetagenerationMatch_); + } + if (((bitField0_ & 0x00000080) != 0)) { + output.writeInt64(11, ifMetagenerationNotMatch_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(bucket_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, bucket_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sourceObject_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, sourceObject_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(destinationObject_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, destinationObject_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(4, ifSourceGenerationMatch_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeInt64Size(5, ifSourceGenerationNotMatch_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeInt64Size(6, ifSourceMetagenerationMatch_); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeInt64Size( + 7, ifSourceMetagenerationNotMatch_); + } + if (((bitField0_ & 0x00000010) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(8, ifGenerationMatch_); + } + if (((bitField0_ & 0x00000020) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(9, ifGenerationNotMatch_); + } + if (((bitField0_ & 0x00000040) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(10, ifMetagenerationMatch_); + } + if (((bitField0_ & 0x00000080) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(11, ifMetagenerationNotMatch_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.storage.v2.MoveObjectRequest)) { + return super.equals(obj); + } + com.google.storage.v2.MoveObjectRequest other = (com.google.storage.v2.MoveObjectRequest) obj; + + if (!getBucket().equals(other.getBucket())) return false; + if (!getSourceObject().equals(other.getSourceObject())) return false; + if (!getDestinationObject().equals(other.getDestinationObject())) return false; + if (hasIfSourceGenerationMatch() != other.hasIfSourceGenerationMatch()) return false; + if (hasIfSourceGenerationMatch()) { + if (getIfSourceGenerationMatch() != other.getIfSourceGenerationMatch()) return false; + } + if (hasIfSourceGenerationNotMatch() != other.hasIfSourceGenerationNotMatch()) return false; + if (hasIfSourceGenerationNotMatch()) { + if (getIfSourceGenerationNotMatch() != other.getIfSourceGenerationNotMatch()) return false; + } + if (hasIfSourceMetagenerationMatch() != other.hasIfSourceMetagenerationMatch()) return false; + if (hasIfSourceMetagenerationMatch()) { + if (getIfSourceMetagenerationMatch() != other.getIfSourceMetagenerationMatch()) return false; + } + if (hasIfSourceMetagenerationNotMatch() != other.hasIfSourceMetagenerationNotMatch()) + return false; + if (hasIfSourceMetagenerationNotMatch()) { + if (getIfSourceMetagenerationNotMatch() != other.getIfSourceMetagenerationNotMatch()) + return false; + } + if (hasIfGenerationMatch() != other.hasIfGenerationMatch()) return false; + if (hasIfGenerationMatch()) { + if (getIfGenerationMatch() != other.getIfGenerationMatch()) return false; + } + if (hasIfGenerationNotMatch() != other.hasIfGenerationNotMatch()) return false; + if (hasIfGenerationNotMatch()) { + if (getIfGenerationNotMatch() != other.getIfGenerationNotMatch()) return false; + } + if (hasIfMetagenerationMatch() != other.hasIfMetagenerationMatch()) return false; + if (hasIfMetagenerationMatch()) { + if (getIfMetagenerationMatch() != other.getIfMetagenerationMatch()) return false; + } + if (hasIfMetagenerationNotMatch() != other.hasIfMetagenerationNotMatch()) return false; + if (hasIfMetagenerationNotMatch()) { + if (getIfMetagenerationNotMatch() != other.getIfMetagenerationNotMatch()) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + BUCKET_FIELD_NUMBER; + hash = (53 * hash) + getBucket().hashCode(); + hash = (37 * hash) + SOURCE_OBJECT_FIELD_NUMBER; + hash = (53 * hash) + getSourceObject().hashCode(); + hash = (37 * hash) + DESTINATION_OBJECT_FIELD_NUMBER; + hash = (53 * hash) + getDestinationObject().hashCode(); + if (hasIfSourceGenerationMatch()) { + hash = (37 * hash) + IF_SOURCE_GENERATION_MATCH_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getIfSourceGenerationMatch()); + } + if (hasIfSourceGenerationNotMatch()) { + hash = (37 * hash) + IF_SOURCE_GENERATION_NOT_MATCH_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getIfSourceGenerationNotMatch()); + } + if (hasIfSourceMetagenerationMatch()) { + hash = (37 * hash) + IF_SOURCE_METAGENERATION_MATCH_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getIfSourceMetagenerationMatch()); + } + if (hasIfSourceMetagenerationNotMatch()) { + hash = (37 * hash) + IF_SOURCE_METAGENERATION_NOT_MATCH_FIELD_NUMBER; + hash = + (53 * hash) + com.google.protobuf.Internal.hashLong(getIfSourceMetagenerationNotMatch()); + } + if (hasIfGenerationMatch()) { + hash = (37 * hash) + IF_GENERATION_MATCH_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getIfGenerationMatch()); + } + if (hasIfGenerationNotMatch()) { + hash = (37 * hash) + IF_GENERATION_NOT_MATCH_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getIfGenerationNotMatch()); + } + if (hasIfMetagenerationMatch()) { + hash = (37 * hash) + IF_METAGENERATION_MATCH_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getIfMetagenerationMatch()); + } + if (hasIfMetagenerationNotMatch()) { + hash = (37 * hash) + IF_METAGENERATION_NOT_MATCH_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getIfMetagenerationNotMatch()); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.storage.v2.MoveObjectRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.storage.v2.MoveObjectRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.storage.v2.MoveObjectRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.storage.v2.MoveObjectRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.storage.v2.MoveObjectRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.storage.v2.MoveObjectRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.storage.v2.MoveObjectRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.storage.v2.MoveObjectRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.storage.v2.MoveObjectRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.storage.v2.MoveObjectRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.storage.v2.MoveObjectRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.storage.v2.MoveObjectRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.storage.v2.MoveObjectRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Request message for MoveObject.
+   * 
+ * + * Protobuf type {@code google.storage.v2.MoveObjectRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.storage.v2.MoveObjectRequest) + com.google.storage.v2.MoveObjectRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.storage.v2.StorageProto + .internal_static_google_storage_v2_MoveObjectRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.storage.v2.StorageProto + .internal_static_google_storage_v2_MoveObjectRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.storage.v2.MoveObjectRequest.class, + com.google.storage.v2.MoveObjectRequest.Builder.class); + } + + // Construct using com.google.storage.v2.MoveObjectRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + bucket_ = ""; + sourceObject_ = ""; + destinationObject_ = ""; + ifSourceGenerationMatch_ = 0L; + ifSourceGenerationNotMatch_ = 0L; + ifSourceMetagenerationMatch_ = 0L; + ifSourceMetagenerationNotMatch_ = 0L; + ifGenerationMatch_ = 0L; + ifGenerationNotMatch_ = 0L; + ifMetagenerationMatch_ = 0L; + ifMetagenerationNotMatch_ = 0L; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.storage.v2.StorageProto + .internal_static_google_storage_v2_MoveObjectRequest_descriptor; + } + + @java.lang.Override + public com.google.storage.v2.MoveObjectRequest getDefaultInstanceForType() { + return com.google.storage.v2.MoveObjectRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.storage.v2.MoveObjectRequest build() { + com.google.storage.v2.MoveObjectRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.storage.v2.MoveObjectRequest buildPartial() { + com.google.storage.v2.MoveObjectRequest result = + new com.google.storage.v2.MoveObjectRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.storage.v2.MoveObjectRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.bucket_ = bucket_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.sourceObject_ = sourceObject_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.destinationObject_ = destinationObject_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000008) != 0)) { + result.ifSourceGenerationMatch_ = ifSourceGenerationMatch_; + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.ifSourceGenerationNotMatch_ = ifSourceGenerationNotMatch_; + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.ifSourceMetagenerationMatch_ = ifSourceMetagenerationMatch_; + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.ifSourceMetagenerationNotMatch_ = ifSourceMetagenerationNotMatch_; + to_bitField0_ |= 0x00000008; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.ifGenerationMatch_ = ifGenerationMatch_; + to_bitField0_ |= 0x00000010; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.ifGenerationNotMatch_ = ifGenerationNotMatch_; + to_bitField0_ |= 0x00000020; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.ifMetagenerationMatch_ = ifMetagenerationMatch_; + to_bitField0_ |= 0x00000040; + } + if (((from_bitField0_ & 0x00000400) != 0)) { + result.ifMetagenerationNotMatch_ = ifMetagenerationNotMatch_; + to_bitField0_ |= 0x00000080; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.storage.v2.MoveObjectRequest) { + return mergeFrom((com.google.storage.v2.MoveObjectRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.storage.v2.MoveObjectRequest other) { + if (other == com.google.storage.v2.MoveObjectRequest.getDefaultInstance()) return this; + if (!other.getBucket().isEmpty()) { + bucket_ = other.bucket_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getSourceObject().isEmpty()) { + sourceObject_ = other.sourceObject_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.getDestinationObject().isEmpty()) { + destinationObject_ = other.destinationObject_; + bitField0_ |= 0x00000004; + onChanged(); + } + if (other.hasIfSourceGenerationMatch()) { + setIfSourceGenerationMatch(other.getIfSourceGenerationMatch()); + } + if (other.hasIfSourceGenerationNotMatch()) { + setIfSourceGenerationNotMatch(other.getIfSourceGenerationNotMatch()); + } + if (other.hasIfSourceMetagenerationMatch()) { + setIfSourceMetagenerationMatch(other.getIfSourceMetagenerationMatch()); + } + if (other.hasIfSourceMetagenerationNotMatch()) { + setIfSourceMetagenerationNotMatch(other.getIfSourceMetagenerationNotMatch()); + } + if (other.hasIfGenerationMatch()) { + setIfGenerationMatch(other.getIfGenerationMatch()); + } + if (other.hasIfGenerationNotMatch()) { + setIfGenerationNotMatch(other.getIfGenerationNotMatch()); + } + if (other.hasIfMetagenerationMatch()) { + setIfMetagenerationMatch(other.getIfMetagenerationMatch()); + } + if (other.hasIfMetagenerationNotMatch()) { + setIfMetagenerationNotMatch(other.getIfMetagenerationNotMatch()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + bucket_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + sourceObject_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + destinationObject_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 32: + { + ifSourceGenerationMatch_ = input.readInt64(); + bitField0_ |= 0x00000008; + break; + } // case 32 + case 40: + { + ifSourceGenerationNotMatch_ = input.readInt64(); + bitField0_ |= 0x00000010; + break; + } // case 40 + case 48: + { + ifSourceMetagenerationMatch_ = input.readInt64(); + bitField0_ |= 0x00000020; + break; + } // case 48 + case 56: + { + ifSourceMetagenerationNotMatch_ = input.readInt64(); + bitField0_ |= 0x00000040; + break; + } // case 56 + case 64: + { + ifGenerationMatch_ = input.readInt64(); + bitField0_ |= 0x00000080; + break; + } // case 64 + case 72: + { + ifGenerationNotMatch_ = input.readInt64(); + bitField0_ |= 0x00000100; + break; + } // case 72 + case 80: + { + ifMetagenerationMatch_ = input.readInt64(); + bitField0_ |= 0x00000200; + break; + } // case 80 + case 88: + { + ifMetagenerationNotMatch_ = input.readInt64(); + bitField0_ |= 0x00000400; + break; + } // case 88 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object bucket_ = ""; + /** + * + * + *
+     * Required. Name of the bucket in which the object resides.
+     * 
+ * + * + * string bucket = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bucket. + */ + public java.lang.String getBucket() { + java.lang.Object ref = bucket_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + bucket_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. Name of the bucket in which the object resides.
+     * 
+ * + * + * string bucket = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for bucket. + */ + public com.google.protobuf.ByteString getBucketBytes() { + java.lang.Object ref = bucket_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + bucket_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. Name of the bucket in which the object resides.
+     * 
+ * + * + * string bucket = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bucket to set. + * @return This builder for chaining. + */ + public Builder setBucket(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + bucket_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Name of the bucket in which the object resides.
+     * 
+ * + * + * string bucket = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearBucket() { + bucket_ = getDefaultInstance().getBucket(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Name of the bucket in which the object resides.
+     * 
+ * + * + * string bucket = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for bucket to set. + * @return This builder for chaining. + */ + public Builder setBucketBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + bucket_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + private java.lang.Object sourceObject_ = ""; + /** + * + * + *
+     * Required. Name of the source object.
+     * 
+ * + * string source_object = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The sourceObject. + */ + public java.lang.String getSourceObject() { + java.lang.Object ref = sourceObject_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sourceObject_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. Name of the source object.
+     * 
+ * + * string source_object = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for sourceObject. + */ + public com.google.protobuf.ByteString getSourceObjectBytes() { + java.lang.Object ref = sourceObject_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sourceObject_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. Name of the source object.
+     * 
+ * + * string source_object = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The sourceObject to set. + * @return This builder for chaining. + */ + public Builder setSourceObject(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sourceObject_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Name of the source object.
+     * 
+ * + * string source_object = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearSourceObject() { + sourceObject_ = getDefaultInstance().getSourceObject(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Name of the source object.
+     * 
+ * + * string source_object = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for sourceObject to set. + * @return This builder for chaining. + */ + public Builder setSourceObjectBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sourceObject_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private java.lang.Object destinationObject_ = ""; + /** + * + * + *
+     * Required. Name of the destination object.
+     * 
+ * + * string destination_object = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The destinationObject. + */ + public java.lang.String getDestinationObject() { + java.lang.Object ref = destinationObject_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + destinationObject_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. Name of the destination object.
+     * 
+ * + * string destination_object = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for destinationObject. + */ + public com.google.protobuf.ByteString getDestinationObjectBytes() { + java.lang.Object ref = destinationObject_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + destinationObject_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. Name of the destination object.
+     * 
+ * + * string destination_object = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The destinationObject to set. + * @return This builder for chaining. + */ + public Builder setDestinationObject(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + destinationObject_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Name of the destination object.
+     * 
+ * + * string destination_object = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDestinationObject() { + destinationObject_ = getDefaultInstance().getDestinationObject(); + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Name of the destination object.
+     * 
+ * + * string destination_object = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for destinationObject to set. + * @return This builder for chaining. + */ + public Builder setDestinationObjectBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + destinationObject_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + private long ifSourceGenerationMatch_; + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current generation matches the given value. `if_source_generation_match`
+     * and `if_source_generation_not_match` conditions are mutually exclusive:
+     * it's an error for both of them to be set in the request.
+     * 
+ * + * + * optional int64 if_source_generation_match = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifSourceGenerationMatch field is set. + */ + @java.lang.Override + public boolean hasIfSourceGenerationMatch() { + return ((bitField0_ & 0x00000008) != 0); + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current generation matches the given value. `if_source_generation_match`
+     * and `if_source_generation_not_match` conditions are mutually exclusive:
+     * it's an error for both of them to be set in the request.
+     * 
+ * + * + * optional int64 if_source_generation_match = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifSourceGenerationMatch. + */ + @java.lang.Override + public long getIfSourceGenerationMatch() { + return ifSourceGenerationMatch_; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current generation matches the given value. `if_source_generation_match`
+     * and `if_source_generation_not_match` conditions are mutually exclusive:
+     * it's an error for both of them to be set in the request.
+     * 
+ * + * + * optional int64 if_source_generation_match = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The ifSourceGenerationMatch to set. + * @return This builder for chaining. + */ + public Builder setIfSourceGenerationMatch(long value) { + + ifSourceGenerationMatch_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current generation matches the given value. `if_source_generation_match`
+     * and `if_source_generation_not_match` conditions are mutually exclusive:
+     * it's an error for both of them to be set in the request.
+     * 
+ * + * + * optional int64 if_source_generation_match = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIfSourceGenerationMatch() { + bitField0_ = (bitField0_ & ~0x00000008); + ifSourceGenerationMatch_ = 0L; + onChanged(); + return this; + } + + private long ifSourceGenerationNotMatch_; + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current generation does not match the given value.
+     * `if_source_generation_match` and `if_source_generation_not_match`
+     * conditions are mutually exclusive: it's an error for both of them to be set
+     * in the request.
+     * 
+ * + * + * optional int64 if_source_generation_not_match = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifSourceGenerationNotMatch field is set. + */ + @java.lang.Override + public boolean hasIfSourceGenerationNotMatch() { + return ((bitField0_ & 0x00000010) != 0); + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current generation does not match the given value.
+     * `if_source_generation_match` and `if_source_generation_not_match`
+     * conditions are mutually exclusive: it's an error for both of them to be set
+     * in the request.
+     * 
+ * + * + * optional int64 if_source_generation_not_match = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifSourceGenerationNotMatch. + */ + @java.lang.Override + public long getIfSourceGenerationNotMatch() { + return ifSourceGenerationNotMatch_; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current generation does not match the given value.
+     * `if_source_generation_match` and `if_source_generation_not_match`
+     * conditions are mutually exclusive: it's an error for both of them to be set
+     * in the request.
+     * 
+ * + * + * optional int64 if_source_generation_not_match = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The ifSourceGenerationNotMatch to set. + * @return This builder for chaining. + */ + public Builder setIfSourceGenerationNotMatch(long value) { + + ifSourceGenerationNotMatch_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current generation does not match the given value.
+     * `if_source_generation_match` and `if_source_generation_not_match`
+     * conditions are mutually exclusive: it's an error for both of them to be set
+     * in the request.
+     * 
+ * + * + * optional int64 if_source_generation_not_match = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIfSourceGenerationNotMatch() { + bitField0_ = (bitField0_ & ~0x00000010); + ifSourceGenerationNotMatch_ = 0L; + onChanged(); + return this; + } + + private long ifSourceMetagenerationMatch_; + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current metageneration matches the given value.
+     * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+     * conditions are mutually exclusive: it's an error for both of them to be set
+     * in the request.
+     * 
+ * + * + * optional int64 if_source_metageneration_match = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifSourceMetagenerationMatch field is set. + */ + @java.lang.Override + public boolean hasIfSourceMetagenerationMatch() { + return ((bitField0_ & 0x00000020) != 0); + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current metageneration matches the given value.
+     * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+     * conditions are mutually exclusive: it's an error for both of them to be set
+     * in the request.
+     * 
+ * + * + * optional int64 if_source_metageneration_match = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifSourceMetagenerationMatch. + */ + @java.lang.Override + public long getIfSourceMetagenerationMatch() { + return ifSourceMetagenerationMatch_; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current metageneration matches the given value.
+     * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+     * conditions are mutually exclusive: it's an error for both of them to be set
+     * in the request.
+     * 
+ * + * + * optional int64 if_source_metageneration_match = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The ifSourceMetagenerationMatch to set. + * @return This builder for chaining. + */ + public Builder setIfSourceMetagenerationMatch(long value) { + + ifSourceMetagenerationMatch_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current metageneration matches the given value.
+     * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+     * conditions are mutually exclusive: it's an error for both of them to be set
+     * in the request.
+     * 
+ * + * + * optional int64 if_source_metageneration_match = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIfSourceMetagenerationMatch() { + bitField0_ = (bitField0_ & ~0x00000020); + ifSourceMetagenerationMatch_ = 0L; + onChanged(); + return this; + } + + private long ifSourceMetagenerationNotMatch_; + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current metageneration does not match the given value.
+     * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+     * conditions are mutually exclusive: it's an error for both of them to be set
+     * in the request.
+     * 
+ * + * + * optional int64 if_source_metageneration_not_match = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifSourceMetagenerationNotMatch field is set. + */ + @java.lang.Override + public boolean hasIfSourceMetagenerationNotMatch() { + return ((bitField0_ & 0x00000040) != 0); + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current metageneration does not match the given value.
+     * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+     * conditions are mutually exclusive: it's an error for both of them to be set
+     * in the request.
+     * 
+ * + * + * optional int64 if_source_metageneration_not_match = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifSourceMetagenerationNotMatch. + */ + @java.lang.Override + public long getIfSourceMetagenerationNotMatch() { + return ifSourceMetagenerationNotMatch_; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current metageneration does not match the given value.
+     * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+     * conditions are mutually exclusive: it's an error for both of them to be set
+     * in the request.
+     * 
+ * + * + * optional int64 if_source_metageneration_not_match = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The ifSourceMetagenerationNotMatch to set. + * @return This builder for chaining. + */ + public Builder setIfSourceMetagenerationNotMatch(long value) { + + ifSourceMetagenerationNotMatch_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the source object's
+     * current metageneration does not match the given value.
+     * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+     * conditions are mutually exclusive: it's an error for both of them to be set
+     * in the request.
+     * 
+ * + * + * optional int64 if_source_metageneration_not_match = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIfSourceMetagenerationNotMatch() { + bitField0_ = (bitField0_ & ~0x00000040); + ifSourceMetagenerationNotMatch_ = 0L; + onChanged(); + return this; + } + + private long ifGenerationMatch_; + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current generation matches the given value. Setting to 0 makes the
+     * operation succeed only if there are no live versions of the object.
+     * `if_generation_match` and `if_generation_not_match` conditions are mutually
+     * exclusive: it's an error for both of them to be set in the request.
+     * 
+ * + * optional int64 if_generation_match = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifGenerationMatch field is set. + */ + @java.lang.Override + public boolean hasIfGenerationMatch() { + return ((bitField0_ & 0x00000080) != 0); + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current generation matches the given value. Setting to 0 makes the
+     * operation succeed only if there are no live versions of the object.
+     * `if_generation_match` and `if_generation_not_match` conditions are mutually
+     * exclusive: it's an error for both of them to be set in the request.
+     * 
+ * + * optional int64 if_generation_match = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifGenerationMatch. + */ + @java.lang.Override + public long getIfGenerationMatch() { + return ifGenerationMatch_; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current generation matches the given value. Setting to 0 makes the
+     * operation succeed only if there are no live versions of the object.
+     * `if_generation_match` and `if_generation_not_match` conditions are mutually
+     * exclusive: it's an error for both of them to be set in the request.
+     * 
+ * + * optional int64 if_generation_match = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The ifGenerationMatch to set. + * @return This builder for chaining. + */ + public Builder setIfGenerationMatch(long value) { + + ifGenerationMatch_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current generation matches the given value. Setting to 0 makes the
+     * operation succeed only if there are no live versions of the object.
+     * `if_generation_match` and `if_generation_not_match` conditions are mutually
+     * exclusive: it's an error for both of them to be set in the request.
+     * 
+ * + * optional int64 if_generation_match = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIfGenerationMatch() { + bitField0_ = (bitField0_ & ~0x00000080); + ifGenerationMatch_ = 0L; + onChanged(); + return this; + } + + private long ifGenerationNotMatch_; + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current generation does not match the given value. If no live
+     * object exists, the precondition fails. Setting to 0 makes the operation
+     * succeed only if there is a live version of the object.
+     * `if_generation_match` and `if_generation_not_match` conditions are mutually
+     * exclusive: it's an error for both of them to be set in the request.
+     * 
+ * + * optional int64 if_generation_not_match = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifGenerationNotMatch field is set. + */ + @java.lang.Override + public boolean hasIfGenerationNotMatch() { + return ((bitField0_ & 0x00000100) != 0); + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current generation does not match the given value. If no live
+     * object exists, the precondition fails. Setting to 0 makes the operation
+     * succeed only if there is a live version of the object.
+     * `if_generation_match` and `if_generation_not_match` conditions are mutually
+     * exclusive: it's an error for both of them to be set in the request.
+     * 
+ * + * optional int64 if_generation_not_match = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifGenerationNotMatch. + */ + @java.lang.Override + public long getIfGenerationNotMatch() { + return ifGenerationNotMatch_; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current generation does not match the given value. If no live
+     * object exists, the precondition fails. Setting to 0 makes the operation
+     * succeed only if there is a live version of the object.
+     * `if_generation_match` and `if_generation_not_match` conditions are mutually
+     * exclusive: it's an error for both of them to be set in the request.
+     * 
+ * + * optional int64 if_generation_not_match = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The ifGenerationNotMatch to set. + * @return This builder for chaining. + */ + public Builder setIfGenerationNotMatch(long value) { + + ifGenerationNotMatch_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current generation does not match the given value. If no live
+     * object exists, the precondition fails. Setting to 0 makes the operation
+     * succeed only if there is a live version of the object.
+     * `if_generation_match` and `if_generation_not_match` conditions are mutually
+     * exclusive: it's an error for both of them to be set in the request.
+     * 
+ * + * optional int64 if_generation_not_match = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIfGenerationNotMatch() { + bitField0_ = (bitField0_ & ~0x00000100); + ifGenerationNotMatch_ = 0L; + onChanged(); + return this; + } + + private long ifMetagenerationMatch_; + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current metageneration matches the given value.
+     * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+     * mutually exclusive: it's an error for both of them to be set in the
+     * request.
+     * 
+ * + * optional int64 if_metageneration_match = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifMetagenerationMatch field is set. + */ + @java.lang.Override + public boolean hasIfMetagenerationMatch() { + return ((bitField0_ & 0x00000200) != 0); + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current metageneration matches the given value.
+     * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+     * mutually exclusive: it's an error for both of them to be set in the
+     * request.
+     * 
+ * + * optional int64 if_metageneration_match = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifMetagenerationMatch. + */ + @java.lang.Override + public long getIfMetagenerationMatch() { + return ifMetagenerationMatch_; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current metageneration matches the given value.
+     * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+     * mutually exclusive: it's an error for both of them to be set in the
+     * request.
+     * 
+ * + * optional int64 if_metageneration_match = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The ifMetagenerationMatch to set. + * @return This builder for chaining. + */ + public Builder setIfMetagenerationMatch(long value) { + + ifMetagenerationMatch_ = value; + bitField0_ |= 0x00000200; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current metageneration matches the given value.
+     * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+     * mutually exclusive: it's an error for both of them to be set in the
+     * request.
+     * 
+ * + * optional int64 if_metageneration_match = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIfMetagenerationMatch() { + bitField0_ = (bitField0_ & ~0x00000200); + ifMetagenerationMatch_ = 0L; + onChanged(); + return this; + } + + private long ifMetagenerationNotMatch_; + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current metageneration does not match the given value.
+     * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+     * mutually exclusive: it's an error for both of them to be set in the
+     * request.
+     * 
+ * + * + * optional int64 if_metageneration_not_match = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifMetagenerationNotMatch field is set. + */ + @java.lang.Override + public boolean hasIfMetagenerationNotMatch() { + return ((bitField0_ & 0x00000400) != 0); + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current metageneration does not match the given value.
+     * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+     * mutually exclusive: it's an error for both of them to be set in the
+     * request.
+     * 
+ * + * + * optional int64 if_metageneration_not_match = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifMetagenerationNotMatch. + */ + @java.lang.Override + public long getIfMetagenerationNotMatch() { + return ifMetagenerationNotMatch_; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current metageneration does not match the given value.
+     * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+     * mutually exclusive: it's an error for both of them to be set in the
+     * request.
+     * 
+ * + * + * optional int64 if_metageneration_not_match = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The ifMetagenerationNotMatch to set. + * @return This builder for chaining. + */ + public Builder setIfMetagenerationNotMatch(long value) { + + ifMetagenerationNotMatch_ = value; + bitField0_ |= 0x00000400; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. Makes the operation conditional on whether the destination
+     * object's current metageneration does not match the given value.
+     * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+     * mutually exclusive: it's an error for both of them to be set in the
+     * request.
+     * 
+ * + * + * optional int64 if_metageneration_not_match = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearIfMetagenerationNotMatch() { + bitField0_ = (bitField0_ & ~0x00000400); + ifMetagenerationNotMatch_ = 0L; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.storage.v2.MoveObjectRequest) + } + + // @@protoc_insertion_point(class_scope:google.storage.v2.MoveObjectRequest) + private static final com.google.storage.v2.MoveObjectRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.storage.v2.MoveObjectRequest(); + } + + public static com.google.storage.v2.MoveObjectRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public MoveObjectRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.storage.v2.MoveObjectRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/MoveObjectRequestOrBuilder.java b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/MoveObjectRequestOrBuilder.java new file mode 100644 index 0000000000..1f2c3db622 --- /dev/null +++ b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/MoveObjectRequestOrBuilder.java @@ -0,0 +1,391 @@ +/* + * Copyright 2024 Google LLC + * + * 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 + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/storage/v2/storage.proto + +// Protobuf Java Version: 3.25.5 +package com.google.storage.v2; + +public interface MoveObjectRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.storage.v2.MoveObjectRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Name of the bucket in which the object resides.
+   * 
+ * + * + * string bucket = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bucket. + */ + java.lang.String getBucket(); + /** + * + * + *
+   * Required. Name of the bucket in which the object resides.
+   * 
+ * + * + * string bucket = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for bucket. + */ + com.google.protobuf.ByteString getBucketBytes(); + + /** + * + * + *
+   * Required. Name of the source object.
+   * 
+ * + * string source_object = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The sourceObject. + */ + java.lang.String getSourceObject(); + /** + * + * + *
+   * Required. Name of the source object.
+   * 
+ * + * string source_object = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for sourceObject. + */ + com.google.protobuf.ByteString getSourceObjectBytes(); + + /** + * + * + *
+   * Required. Name of the destination object.
+   * 
+ * + * string destination_object = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The destinationObject. + */ + java.lang.String getDestinationObject(); + /** + * + * + *
+   * Required. Name of the destination object.
+   * 
+ * + * string destination_object = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for destinationObject. + */ + com.google.protobuf.ByteString getDestinationObjectBytes(); + + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current generation matches the given value. `if_source_generation_match`
+   * and `if_source_generation_not_match` conditions are mutually exclusive:
+   * it's an error for both of them to be set in the request.
+   * 
+ * + * optional int64 if_source_generation_match = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifSourceGenerationMatch field is set. + */ + boolean hasIfSourceGenerationMatch(); + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current generation matches the given value. `if_source_generation_match`
+   * and `if_source_generation_not_match` conditions are mutually exclusive:
+   * it's an error for both of them to be set in the request.
+   * 
+ * + * optional int64 if_source_generation_match = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifSourceGenerationMatch. + */ + long getIfSourceGenerationMatch(); + + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current generation does not match the given value.
+   * `if_source_generation_match` and `if_source_generation_not_match`
+   * conditions are mutually exclusive: it's an error for both of them to be set
+   * in the request.
+   * 
+ * + * + * optional int64 if_source_generation_not_match = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifSourceGenerationNotMatch field is set. + */ + boolean hasIfSourceGenerationNotMatch(); + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current generation does not match the given value.
+   * `if_source_generation_match` and `if_source_generation_not_match`
+   * conditions are mutually exclusive: it's an error for both of them to be set
+   * in the request.
+   * 
+ * + * + * optional int64 if_source_generation_not_match = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifSourceGenerationNotMatch. + */ + long getIfSourceGenerationNotMatch(); + + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current metageneration matches the given value.
+   * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+   * conditions are mutually exclusive: it's an error for both of them to be set
+   * in the request.
+   * 
+ * + * + * optional int64 if_source_metageneration_match = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifSourceMetagenerationMatch field is set. + */ + boolean hasIfSourceMetagenerationMatch(); + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current metageneration matches the given value.
+   * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+   * conditions are mutually exclusive: it's an error for both of them to be set
+   * in the request.
+   * 
+ * + * + * optional int64 if_source_metageneration_match = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifSourceMetagenerationMatch. + */ + long getIfSourceMetagenerationMatch(); + + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current metageneration does not match the given value.
+   * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+   * conditions are mutually exclusive: it's an error for both of them to be set
+   * in the request.
+   * 
+ * + * + * optional int64 if_source_metageneration_not_match = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifSourceMetagenerationNotMatch field is set. + */ + boolean hasIfSourceMetagenerationNotMatch(); + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the source object's
+   * current metageneration does not match the given value.
+   * `if_source_metageneration_match` and `if_source_metageneration_not_match`
+   * conditions are mutually exclusive: it's an error for both of them to be set
+   * in the request.
+   * 
+ * + * + * optional int64 if_source_metageneration_not_match = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifSourceMetagenerationNotMatch. + */ + long getIfSourceMetagenerationNotMatch(); + + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current generation matches the given value. Setting to 0 makes the
+   * operation succeed only if there are no live versions of the object.
+   * `if_generation_match` and `if_generation_not_match` conditions are mutually
+   * exclusive: it's an error for both of them to be set in the request.
+   * 
+ * + * optional int64 if_generation_match = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the ifGenerationMatch field is set. + */ + boolean hasIfGenerationMatch(); + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current generation matches the given value. Setting to 0 makes the
+   * operation succeed only if there are no live versions of the object.
+   * `if_generation_match` and `if_generation_not_match` conditions are mutually
+   * exclusive: it's an error for both of them to be set in the request.
+   * 
+ * + * optional int64 if_generation_match = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The ifGenerationMatch. + */ + long getIfGenerationMatch(); + + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current generation does not match the given value. If no live
+   * object exists, the precondition fails. Setting to 0 makes the operation
+   * succeed only if there is a live version of the object.
+   * `if_generation_match` and `if_generation_not_match` conditions are mutually
+   * exclusive: it's an error for both of them to be set in the request.
+   * 
+ * + * optional int64 if_generation_not_match = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifGenerationNotMatch field is set. + */ + boolean hasIfGenerationNotMatch(); + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current generation does not match the given value. If no live
+   * object exists, the precondition fails. Setting to 0 makes the operation
+   * succeed only if there is a live version of the object.
+   * `if_generation_match` and `if_generation_not_match` conditions are mutually
+   * exclusive: it's an error for both of them to be set in the request.
+   * 
+ * + * optional int64 if_generation_not_match = 9 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifGenerationNotMatch. + */ + long getIfGenerationNotMatch(); + + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current metageneration matches the given value.
+   * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+   * mutually exclusive: it's an error for both of them to be set in the
+   * request.
+   * 
+ * + * optional int64 if_metageneration_match = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifMetagenerationMatch field is set. + */ + boolean hasIfMetagenerationMatch(); + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current metageneration matches the given value.
+   * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+   * mutually exclusive: it's an error for both of them to be set in the
+   * request.
+   * 
+ * + * optional int64 if_metageneration_match = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifMetagenerationMatch. + */ + long getIfMetagenerationMatch(); + + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current metageneration does not match the given value.
+   * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+   * mutually exclusive: it's an error for both of them to be set in the
+   * request.
+   * 
+ * + * + * optional int64 if_metageneration_not_match = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ifMetagenerationNotMatch field is set. + */ + boolean hasIfMetagenerationNotMatch(); + /** + * + * + *
+   * Optional. Makes the operation conditional on whether the destination
+   * object's current metageneration does not match the given value.
+   * `if_metageneration_match` and `if_metageneration_not_match` conditions are
+   * mutually exclusive: it's an error for both of them to be set in the
+   * request.
+   * 
+ * + * + * optional int64 if_metageneration_not_match = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ifMetagenerationNotMatch. + */ + long getIfMetagenerationNotMatch(); +} diff --git a/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/Object.java b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/Object.java index 73e9eb52c6..b45f5ee13c 100644 --- a/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/Object.java +++ b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/Object.java @@ -791,6 +791,62 @@ public com.google.protobuf.TimestampOrBuilder getDeleteTimeOrBuilder() { return deleteTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : deleteTime_; } + public static final int FINALIZE_TIME_FIELD_NUMBER = 36; + private com.google.protobuf.Timestamp finalizeTime_; + /** + * + * + *
+   * Output only. The time when the object was finalized.
+   * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the finalizeTime field is set. + */ + @java.lang.Override + public boolean hasFinalizeTime() { + return ((bitField0_ & 0x00000004) != 0); + } + /** + * + * + *
+   * Output only. The time when the object was finalized.
+   * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The finalizeTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getFinalizeTime() { + return finalizeTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : finalizeTime_; + } + /** + * + * + *
+   * Output only. The time when the object was finalized.
+   * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getFinalizeTimeOrBuilder() { + return finalizeTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : finalizeTime_; + } + public static final int CONTENT_TYPE_FIELD_NUMBER = 13; @SuppressWarnings("serial") @@ -864,7 +920,7 @@ public com.google.protobuf.ByteString getContentTypeBytes() { */ @java.lang.Override public boolean hasCreateTime() { - return ((bitField0_ & 0x00000004) != 0); + return ((bitField0_ & 0x00000008) != 0); } /** * @@ -937,7 +993,7 @@ public int getComponentCount() { */ @java.lang.Override public boolean hasChecksums() { - return ((bitField0_ & 0x00000008) != 0); + return ((bitField0_ & 0x00000010) != 0); } /** * @@ -1005,7 +1061,7 @@ public com.google.storage.v2.ObjectChecksumsOrBuilder getChecksumsOrBuilder() { */ @java.lang.Override public boolean hasUpdateTime() { - return ((bitField0_ & 0x00000010) != 0); + return ((bitField0_ & 0x00000020) != 0); } /** * @@ -1119,7 +1175,7 @@ public com.google.protobuf.ByteString getKmsKeyBytes() { */ @java.lang.Override public boolean hasUpdateStorageClassTime() { - return ((bitField0_ & 0x00000020) != 0); + return ((bitField0_ & 0x00000040) != 0); } /** * @@ -1203,7 +1259,7 @@ public boolean getTemporaryHold() { */ @java.lang.Override public boolean hasRetentionExpireTime() { - return ((bitField0_ & 0x00000040) != 0); + return ((bitField0_ & 0x00000080) != 0); } /** * @@ -1377,7 +1433,7 @@ public java.lang.String getMetadataOrThrow(java.lang.String key) { */ @java.lang.Override public boolean hasEventBasedHold() { - return ((bitField0_ & 0x00000080) != 0); + return ((bitField0_ & 0x00000100) != 0); } /** * @@ -1421,7 +1477,7 @@ public boolean getEventBasedHold() { */ @java.lang.Override public boolean hasOwner() { - return ((bitField0_ & 0x00000100) != 0); + return ((bitField0_ & 0x00000200) != 0); } /** * @@ -1470,7 +1526,7 @@ public com.google.storage.v2.OwnerOrBuilder getOwnerOrBuilder() { */ @java.lang.Override public boolean hasCustomerEncryption() { - return ((bitField0_ & 0x00000200) != 0); + return ((bitField0_ & 0x00000400) != 0); } /** * @@ -1522,7 +1578,7 @@ public com.google.storage.v2.CustomerEncryptionOrBuilder getCustomerEncryptionOr */ @java.lang.Override public boolean hasCustomTime() { - return ((bitField0_ & 0x00000400) != 0); + return ((bitField0_ & 0x00000800) != 0); } /** * @@ -1573,7 +1629,7 @@ public com.google.protobuf.TimestampOrBuilder getCustomTimeOrBuilder() { */ @java.lang.Override public boolean hasSoftDeleteTime() { - return ((bitField0_ & 0x00000800) != 0); + return ((bitField0_ & 0x00001000) != 0); } /** * @@ -1638,7 +1694,7 @@ public com.google.protobuf.TimestampOrBuilder getSoftDeleteTimeOrBuilder() { */ @java.lang.Override public boolean hasHardDeleteTime() { - return ((bitField0_ & 0x00001000) != 0); + return ((bitField0_ & 0x00002000) != 0); } /** * @@ -1736,56 +1792,59 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(contentType_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 13, contentType_); } - if (((bitField0_ & 0x00000004) != 0)) { + if (((bitField0_ & 0x00000008) != 0)) { output.writeMessage(14, getCreateTime()); } if (componentCount_ != 0) { output.writeInt32(15, componentCount_); } - if (((bitField0_ & 0x00000008) != 0)) { + if (((bitField0_ & 0x00000010) != 0)) { output.writeMessage(16, getChecksums()); } - if (((bitField0_ & 0x00000010) != 0)) { + if (((bitField0_ & 0x00000020) != 0)) { output.writeMessage(17, getUpdateTime()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKey_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 18, kmsKey_); } - if (((bitField0_ & 0x00000020) != 0)) { + if (((bitField0_ & 0x00000040) != 0)) { output.writeMessage(19, getUpdateStorageClassTime()); } if (temporaryHold_ != false) { output.writeBool(20, temporaryHold_); } - if (((bitField0_ & 0x00000040) != 0)) { + if (((bitField0_ & 0x00000080) != 0)) { output.writeMessage(21, getRetentionExpireTime()); } com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( output, internalGetMetadata(), MetadataDefaultEntryHolder.defaultEntry, 22); - if (((bitField0_ & 0x00000080) != 0)) { + if (((bitField0_ & 0x00000100) != 0)) { output.writeBool(23, eventBasedHold_); } - if (((bitField0_ & 0x00000100) != 0)) { + if (((bitField0_ & 0x00000200) != 0)) { output.writeMessage(24, getOwner()); } - if (((bitField0_ & 0x00000200) != 0)) { + if (((bitField0_ & 0x00000400) != 0)) { output.writeMessage(25, getCustomerEncryption()); } - if (((bitField0_ & 0x00000400) != 0)) { + if (((bitField0_ & 0x00000800) != 0)) { output.writeMessage(26, getCustomTime()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 27, etag_); } - if (((bitField0_ & 0x00000800) != 0)) { + if (((bitField0_ & 0x00001000) != 0)) { output.writeMessage(28, getSoftDeleteTime()); } - if (((bitField0_ & 0x00001000) != 0)) { + if (((bitField0_ & 0x00002000) != 0)) { output.writeMessage(29, getHardDeleteTime()); } if (((bitField0_ & 0x00000001) != 0)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 35, restoreToken_); } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(36, getFinalizeTime()); + } getUnknownFields().writeTo(output); } @@ -1834,29 +1893,29 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(contentType_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(13, contentType_); } - if (((bitField0_ & 0x00000004) != 0)) { + if (((bitField0_ & 0x00000008) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(14, getCreateTime()); } if (componentCount_ != 0) { size += com.google.protobuf.CodedOutputStream.computeInt32Size(15, componentCount_); } - if (((bitField0_ & 0x00000008) != 0)) { + if (((bitField0_ & 0x00000010) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(16, getChecksums()); } - if (((bitField0_ & 0x00000010) != 0)) { + if (((bitField0_ & 0x00000020) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(17, getUpdateTime()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKey_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(18, kmsKey_); } - if (((bitField0_ & 0x00000020) != 0)) { + if (((bitField0_ & 0x00000040) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(19, getUpdateStorageClassTime()); } if (temporaryHold_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(20, temporaryHold_); } - if (((bitField0_ & 0x00000040) != 0)) { + if (((bitField0_ & 0x00000080) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(21, getRetentionExpireTime()); } @@ -1870,30 +1929,33 @@ public int getSerializedSize() { .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(22, metadata__); } - if (((bitField0_ & 0x00000080) != 0)) { + if (((bitField0_ & 0x00000100) != 0)) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(23, eventBasedHold_); } - if (((bitField0_ & 0x00000100) != 0)) { + if (((bitField0_ & 0x00000200) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(24, getOwner()); } - if (((bitField0_ & 0x00000200) != 0)) { + if (((bitField0_ & 0x00000400) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(25, getCustomerEncryption()); } - if (((bitField0_ & 0x00000400) != 0)) { + if (((bitField0_ & 0x00000800) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(26, getCustomTime()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(27, etag_); } - if (((bitField0_ & 0x00000800) != 0)) { + if (((bitField0_ & 0x00001000) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(28, getSoftDeleteTime()); } - if (((bitField0_ & 0x00001000) != 0)) { + if (((bitField0_ & 0x00002000) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(29, getHardDeleteTime()); } if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(35, restoreToken_); } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(36, getFinalizeTime()); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -1929,6 +1991,10 @@ public boolean equals(final java.lang.Object obj) { if (hasDeleteTime()) { if (!getDeleteTime().equals(other.getDeleteTime())) return false; } + if (hasFinalizeTime() != other.hasFinalizeTime()) return false; + if (hasFinalizeTime()) { + if (!getFinalizeTime().equals(other.getFinalizeTime())) return false; + } if (!getContentType().equals(other.getContentType())) return false; if (hasCreateTime() != other.hasCreateTime()) return false; if (hasCreateTime()) { @@ -2023,6 +2089,10 @@ public int hashCode() { hash = (37 * hash) + DELETE_TIME_FIELD_NUMBER; hash = (53 * hash) + getDeleteTime().hashCode(); } + if (hasFinalizeTime()) { + hash = (37 * hash) + FINALIZE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getFinalizeTime().hashCode(); + } hash = (37 * hash) + CONTENT_TYPE_FIELD_NUMBER; hash = (53 * hash) + getContentType().hashCode(); if (hasCreateTime()) { @@ -2240,6 +2310,7 @@ private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { getAclFieldBuilder(); getDeleteTimeFieldBuilder(); + getFinalizeTimeFieldBuilder(); getCreateTimeFieldBuilder(); getChecksumsFieldBuilder(); getUpdateTimeFieldBuilder(); @@ -2281,6 +2352,11 @@ public Builder clear() { deleteTimeBuilder_.dispose(); deleteTimeBuilder_ = null; } + finalizeTime_ = null; + if (finalizeTimeBuilder_ != null) { + finalizeTimeBuilder_.dispose(); + finalizeTimeBuilder_ = null; + } contentType_ = ""; createTime_ = null; if (createTimeBuilder_ != null) { @@ -2427,75 +2503,80 @@ private void buildPartial0(com.google.storage.v2.Object result) { to_bitField0_ |= 0x00000002; } if (((from_bitField0_ & 0x00004000) != 0)) { - result.contentType_ = contentType_; + result.finalizeTime_ = + finalizeTimeBuilder_ == null ? finalizeTime_ : finalizeTimeBuilder_.build(); + to_bitField0_ |= 0x00000004; } if (((from_bitField0_ & 0x00008000) != 0)) { - result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); - to_bitField0_ |= 0x00000004; + result.contentType_ = contentType_; } if (((from_bitField0_ & 0x00010000) != 0)) { - result.componentCount_ = componentCount_; + result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build(); + to_bitField0_ |= 0x00000008; } if (((from_bitField0_ & 0x00020000) != 0)) { - result.checksums_ = checksumsBuilder_ == null ? checksums_ : checksumsBuilder_.build(); - to_bitField0_ |= 0x00000008; + result.componentCount_ = componentCount_; } if (((from_bitField0_ & 0x00040000) != 0)) { - result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); + result.checksums_ = checksumsBuilder_ == null ? checksums_ : checksumsBuilder_.build(); to_bitField0_ |= 0x00000010; } if (((from_bitField0_ & 0x00080000) != 0)) { - result.kmsKey_ = kmsKey_; + result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); + to_bitField0_ |= 0x00000020; } if (((from_bitField0_ & 0x00100000) != 0)) { + result.kmsKey_ = kmsKey_; + } + if (((from_bitField0_ & 0x00200000) != 0)) { result.updateStorageClassTime_ = updateStorageClassTimeBuilder_ == null ? updateStorageClassTime_ : updateStorageClassTimeBuilder_.build(); - to_bitField0_ |= 0x00000020; + to_bitField0_ |= 0x00000040; } - if (((from_bitField0_ & 0x00200000) != 0)) { + if (((from_bitField0_ & 0x00400000) != 0)) { result.temporaryHold_ = temporaryHold_; } - if (((from_bitField0_ & 0x00400000) != 0)) { + if (((from_bitField0_ & 0x00800000) != 0)) { result.retentionExpireTime_ = retentionExpireTimeBuilder_ == null ? retentionExpireTime_ : retentionExpireTimeBuilder_.build(); - to_bitField0_ |= 0x00000040; + to_bitField0_ |= 0x00000080; } - if (((from_bitField0_ & 0x00800000) != 0)) { + if (((from_bitField0_ & 0x01000000) != 0)) { result.metadata_ = internalGetMetadata(); result.metadata_.makeImmutable(); } - if (((from_bitField0_ & 0x01000000) != 0)) { - result.eventBasedHold_ = eventBasedHold_; - to_bitField0_ |= 0x00000080; - } if (((from_bitField0_ & 0x02000000) != 0)) { - result.owner_ = ownerBuilder_ == null ? owner_ : ownerBuilder_.build(); + result.eventBasedHold_ = eventBasedHold_; to_bitField0_ |= 0x00000100; } if (((from_bitField0_ & 0x04000000) != 0)) { + result.owner_ = ownerBuilder_ == null ? owner_ : ownerBuilder_.build(); + to_bitField0_ |= 0x00000200; + } + if (((from_bitField0_ & 0x08000000) != 0)) { result.customerEncryption_ = customerEncryptionBuilder_ == null ? customerEncryption_ : customerEncryptionBuilder_.build(); - to_bitField0_ |= 0x00000200; - } - if (((from_bitField0_ & 0x08000000) != 0)) { - result.customTime_ = customTimeBuilder_ == null ? customTime_ : customTimeBuilder_.build(); to_bitField0_ |= 0x00000400; } if (((from_bitField0_ & 0x10000000) != 0)) { - result.softDeleteTime_ = - softDeleteTimeBuilder_ == null ? softDeleteTime_ : softDeleteTimeBuilder_.build(); + result.customTime_ = customTimeBuilder_ == null ? customTime_ : customTimeBuilder_.build(); to_bitField0_ |= 0x00000800; } if (((from_bitField0_ & 0x20000000) != 0)) { + result.softDeleteTime_ = + softDeleteTimeBuilder_ == null ? softDeleteTime_ : softDeleteTimeBuilder_.build(); + to_bitField0_ |= 0x00001000; + } + if (((from_bitField0_ & 0x40000000) != 0)) { result.hardDeleteTime_ = hardDeleteTimeBuilder_ == null ? hardDeleteTime_ : hardDeleteTimeBuilder_.build(); - to_bitField0_ |= 0x00001000; + to_bitField0_ |= 0x00002000; } result.bitField0_ |= to_bitField0_; } @@ -2629,9 +2710,12 @@ public Builder mergeFrom(com.google.storage.v2.Object other) { if (other.hasDeleteTime()) { mergeDeleteTime(other.getDeleteTime()); } + if (other.hasFinalizeTime()) { + mergeFinalizeTime(other.getFinalizeTime()); + } if (!other.getContentType().isEmpty()) { contentType_ = other.contentType_; - bitField0_ |= 0x00004000; + bitField0_ |= 0x00008000; onChanged(); } if (other.hasCreateTime()) { @@ -2648,7 +2732,7 @@ public Builder mergeFrom(com.google.storage.v2.Object other) { } if (!other.getKmsKey().isEmpty()) { kmsKey_ = other.kmsKey_; - bitField0_ |= 0x00080000; + bitField0_ |= 0x00100000; onChanged(); } if (other.hasUpdateStorageClassTime()) { @@ -2661,7 +2745,7 @@ public Builder mergeFrom(com.google.storage.v2.Object other) { mergeRetentionExpireTime(other.getRetentionExpireTime()); } internalGetMutableMetadata().mergeFrom(other.internalGetMetadata()); - bitField0_ |= 0x00800000; + bitField0_ |= 0x01000000; if (other.hasEventBasedHold()) { setEventBasedHold(other.getEventBasedHold()); } @@ -2788,57 +2872,57 @@ public Builder mergeFrom( case 106: { contentType_ = input.readStringRequireUtf8(); - bitField0_ |= 0x00004000; + bitField0_ |= 0x00008000; break; } // case 106 case 114: { input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x00008000; + bitField0_ |= 0x00010000; break; } // case 114 case 120: { componentCount_ = input.readInt32(); - bitField0_ |= 0x00010000; + bitField0_ |= 0x00020000; break; } // case 120 case 130: { input.readMessage(getChecksumsFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x00020000; + bitField0_ |= 0x00040000; break; } // case 130 case 138: { input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x00040000; + bitField0_ |= 0x00080000; break; } // case 138 case 146: { kmsKey_ = input.readStringRequireUtf8(); - bitField0_ |= 0x00080000; + bitField0_ |= 0x00100000; break; } // case 146 case 154: { input.readMessage( getUpdateStorageClassTimeFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x00100000; + bitField0_ |= 0x00200000; break; } // case 154 case 160: { temporaryHold_ = input.readBool(); - bitField0_ |= 0x00200000; + bitField0_ |= 0x00400000; break; } // case 160 case 170: { input.readMessage( getRetentionExpireTimeFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x00400000; + bitField0_ |= 0x00800000; break; } // case 170 case 178: @@ -2850,32 +2934,32 @@ public Builder mergeFrom( internalGetMutableMetadata() .getMutableMap() .put(metadata__.getKey(), metadata__.getValue()); - bitField0_ |= 0x00800000; + bitField0_ |= 0x01000000; break; } // case 178 case 184: { eventBasedHold_ = input.readBool(); - bitField0_ |= 0x01000000; + bitField0_ |= 0x02000000; break; } // case 184 case 194: { input.readMessage(getOwnerFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; break; } // case 194 case 202: { input.readMessage( getCustomerEncryptionFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x04000000; + bitField0_ |= 0x08000000; break; } // case 202 case 210: { input.readMessage(getCustomTimeFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; break; } // case 210 case 218: @@ -2887,13 +2971,13 @@ public Builder mergeFrom( case 226: { input.readMessage(getSoftDeleteTimeFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; break; } // case 226 case 234: { input.readMessage(getHardDeleteTimeFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; break; } // case 234 case 282: @@ -2902,6 +2986,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000010; break; } // case 282 + case 290: + { + input.readMessage(getFinalizeTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00004000; + break; + } // case 290 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -4756,6 +4846,209 @@ public com.google.protobuf.TimestampOrBuilder getDeleteTimeOrBuilder() { return deleteTimeBuilder_; } + private com.google.protobuf.Timestamp finalizeTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + finalizeTimeBuilder_; + /** + * + * + *
+     * Output only. The time when the object was finalized.
+     * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the finalizeTime field is set. + */ + public boolean hasFinalizeTime() { + return ((bitField0_ & 0x00004000) != 0); + } + /** + * + * + *
+     * Output only. The time when the object was finalized.
+     * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The finalizeTime. + */ + public com.google.protobuf.Timestamp getFinalizeTime() { + if (finalizeTimeBuilder_ == null) { + return finalizeTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : finalizeTime_; + } else { + return finalizeTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Output only. The time when the object was finalized.
+     * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setFinalizeTime(com.google.protobuf.Timestamp value) { + if (finalizeTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + finalizeTime_ = value; + } else { + finalizeTimeBuilder_.setMessage(value); + } + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. The time when the object was finalized.
+     * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setFinalizeTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (finalizeTimeBuilder_ == null) { + finalizeTime_ = builderForValue.build(); + } else { + finalizeTimeBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00004000; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. The time when the object was finalized.
+     * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeFinalizeTime(com.google.protobuf.Timestamp value) { + if (finalizeTimeBuilder_ == null) { + if (((bitField0_ & 0x00004000) != 0) + && finalizeTime_ != null + && finalizeTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { + getFinalizeTimeBuilder().mergeFrom(value); + } else { + finalizeTime_ = value; + } + } else { + finalizeTimeBuilder_.mergeFrom(value); + } + if (finalizeTime_ != null) { + bitField0_ |= 0x00004000; + onChanged(); + } + return this; + } + /** + * + * + *
+     * Output only. The time when the object was finalized.
+     * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearFinalizeTime() { + bitField0_ = (bitField0_ & ~0x00004000); + finalizeTime_ = null; + if (finalizeTimeBuilder_ != null) { + finalizeTimeBuilder_.dispose(); + finalizeTimeBuilder_ = null; + } + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. The time when the object was finalized.
+     * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getFinalizeTimeBuilder() { + bitField0_ |= 0x00004000; + onChanged(); + return getFinalizeTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Output only. The time when the object was finalized.
+     * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getFinalizeTimeOrBuilder() { + if (finalizeTimeBuilder_ != null) { + return finalizeTimeBuilder_.getMessageOrBuilder(); + } else { + return finalizeTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : finalizeTime_; + } + } + /** + * + * + *
+     * Output only. The time when the object was finalized.
+     * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getFinalizeTimeFieldBuilder() { + if (finalizeTimeBuilder_ == null) { + finalizeTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getFinalizeTime(), getParentForChildren(), isClean()); + finalizeTime_ = null; + } + return finalizeTimeBuilder_; + } + private java.lang.Object contentType_ = ""; /** * @@ -4827,7 +5120,7 @@ public Builder setContentType(java.lang.String value) { throw new NullPointerException(); } contentType_ = value; - bitField0_ |= 0x00004000; + bitField0_ |= 0x00008000; onChanged(); return this; } @@ -4847,7 +5140,7 @@ public Builder setContentType(java.lang.String value) { */ public Builder clearContentType() { contentType_ = getDefaultInstance().getContentType(); - bitField0_ = (bitField0_ & ~0x00004000); + bitField0_ = (bitField0_ & ~0x00008000); onChanged(); return this; } @@ -4872,7 +5165,7 @@ public Builder setContentTypeBytes(com.google.protobuf.ByteString value) { } checkByteStringIsUtf8(value); contentType_ = value; - bitField0_ |= 0x00004000; + bitField0_ |= 0x00008000; onChanged(); return this; } @@ -4897,7 +5190,7 @@ public Builder setContentTypeBytes(com.google.protobuf.ByteString value) { * @return Whether the createTime field is set. */ public boolean hasCreateTime() { - return ((bitField0_ & 0x00008000) != 0); + return ((bitField0_ & 0x00010000) != 0); } /** * @@ -4941,7 +5234,7 @@ public Builder setCreateTime(com.google.protobuf.Timestamp value) { } else { createTimeBuilder_.setMessage(value); } - bitField0_ |= 0x00008000; + bitField0_ |= 0x00010000; onChanged(); return this; } @@ -4962,7 +5255,7 @@ public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForVal } else { createTimeBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x00008000; + bitField0_ |= 0x00010000; onChanged(); return this; } @@ -4979,7 +5272,7 @@ public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForVal */ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { - if (((bitField0_ & 0x00008000) != 0) + if (((bitField0_ & 0x00010000) != 0) && createTime_ != null && createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getCreateTimeBuilder().mergeFrom(value); @@ -4990,7 +5283,7 @@ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { createTimeBuilder_.mergeFrom(value); } if (createTime_ != null) { - bitField0_ |= 0x00008000; + bitField0_ |= 0x00010000; onChanged(); } return this; @@ -5007,7 +5300,7 @@ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { * */ public Builder clearCreateTime() { - bitField0_ = (bitField0_ & ~0x00008000); + bitField0_ = (bitField0_ & ~0x00010000); createTime_ = null; if (createTimeBuilder_ != null) { createTimeBuilder_.dispose(); @@ -5028,7 +5321,7 @@ public Builder clearCreateTime() { * */ public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - bitField0_ |= 0x00008000; + bitField0_ |= 0x00010000; onChanged(); return getCreateTimeFieldBuilder().getBuilder(); } @@ -5113,7 +5406,7 @@ public int getComponentCount() { public Builder setComponentCount(int value) { componentCount_ = value; - bitField0_ |= 0x00010000; + bitField0_ |= 0x00020000; onChanged(); return this; } @@ -5130,7 +5423,7 @@ public Builder setComponentCount(int value) { * @return This builder for chaining. */ public Builder clearComponentCount() { - bitField0_ = (bitField0_ & ~0x00010000); + bitField0_ = (bitField0_ & ~0x00020000); componentCount_ = 0; onChanged(); return this; @@ -5160,7 +5453,7 @@ public Builder clearComponentCount() { * @return Whether the checksums field is set. */ public boolean hasChecksums() { - return ((bitField0_ & 0x00020000) != 0); + return ((bitField0_ & 0x00040000) != 0); } /** * @@ -5212,7 +5505,7 @@ public Builder setChecksums(com.google.storage.v2.ObjectChecksums value) { } else { checksumsBuilder_.setMessage(value); } - bitField0_ |= 0x00020000; + bitField0_ |= 0x00040000; onChanged(); return this; } @@ -5237,7 +5530,7 @@ public Builder setChecksums(com.google.storage.v2.ObjectChecksums.Builder builde } else { checksumsBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x00020000; + bitField0_ |= 0x00040000; onChanged(); return this; } @@ -5258,7 +5551,7 @@ public Builder setChecksums(com.google.storage.v2.ObjectChecksums.Builder builde */ public Builder mergeChecksums(com.google.storage.v2.ObjectChecksums value) { if (checksumsBuilder_ == null) { - if (((bitField0_ & 0x00020000) != 0) + if (((bitField0_ & 0x00040000) != 0) && checksums_ != null && checksums_ != com.google.storage.v2.ObjectChecksums.getDefaultInstance()) { getChecksumsBuilder().mergeFrom(value); @@ -5269,7 +5562,7 @@ public Builder mergeChecksums(com.google.storage.v2.ObjectChecksums value) { checksumsBuilder_.mergeFrom(value); } if (checksums_ != null) { - bitField0_ |= 0x00020000; + bitField0_ |= 0x00040000; onChanged(); } return this; @@ -5290,7 +5583,7 @@ public Builder mergeChecksums(com.google.storage.v2.ObjectChecksums value) { * */ public Builder clearChecksums() { - bitField0_ = (bitField0_ & ~0x00020000); + bitField0_ = (bitField0_ & ~0x00040000); checksums_ = null; if (checksumsBuilder_ != null) { checksumsBuilder_.dispose(); @@ -5315,7 +5608,7 @@ public Builder clearChecksums() { * */ public com.google.storage.v2.ObjectChecksums.Builder getChecksumsBuilder() { - bitField0_ |= 0x00020000; + bitField0_ |= 0x00040000; onChanged(); return getChecksumsFieldBuilder().getBuilder(); } @@ -5400,7 +5693,7 @@ public com.google.storage.v2.ObjectChecksumsOrBuilder getChecksumsOrBuilder() { * @return Whether the updateTime field is set. */ public boolean hasUpdateTime() { - return ((bitField0_ & 0x00040000) != 0); + return ((bitField0_ & 0x00080000) != 0); } /** * @@ -5454,7 +5747,7 @@ public Builder setUpdateTime(com.google.protobuf.Timestamp value) { } else { updateTimeBuilder_.setMessage(value); } - bitField0_ |= 0x00040000; + bitField0_ |= 0x00080000; onChanged(); return this; } @@ -5480,7 +5773,7 @@ public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForVal } else { updateTimeBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x00040000; + bitField0_ |= 0x00080000; onChanged(); return this; } @@ -5502,7 +5795,7 @@ public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForVal */ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { if (updateTimeBuilder_ == null) { - if (((bitField0_ & 0x00040000) != 0) + if (((bitField0_ & 0x00080000) != 0) && updateTime_ != null && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getUpdateTimeBuilder().mergeFrom(value); @@ -5513,7 +5806,7 @@ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { updateTimeBuilder_.mergeFrom(value); } if (updateTime_ != null) { - bitField0_ |= 0x00040000; + bitField0_ |= 0x00080000; onChanged(); } return this; @@ -5535,7 +5828,7 @@ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { * */ public Builder clearUpdateTime() { - bitField0_ = (bitField0_ & ~0x00040000); + bitField0_ = (bitField0_ & ~0x00080000); updateTime_ = null; if (updateTimeBuilder_ != null) { updateTimeBuilder_.dispose(); @@ -5561,7 +5854,7 @@ public Builder clearUpdateTime() { * */ public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - bitField0_ |= 0x00040000; + bitField0_ |= 0x00080000; onChanged(); return getUpdateTimeFieldBuilder().getBuilder(); } @@ -5688,7 +5981,7 @@ public Builder setKmsKey(java.lang.String value) { throw new NullPointerException(); } kmsKey_ = value; - bitField0_ |= 0x00080000; + bitField0_ |= 0x00100000; onChanged(); return this; } @@ -5706,7 +5999,7 @@ public Builder setKmsKey(java.lang.String value) { */ public Builder clearKmsKey() { kmsKey_ = getDefaultInstance().getKmsKey(); - bitField0_ = (bitField0_ & ~0x00080000); + bitField0_ = (bitField0_ & ~0x00100000); onChanged(); return this; } @@ -5729,7 +6022,7 @@ public Builder setKmsKeyBytes(com.google.protobuf.ByteString value) { } checkByteStringIsUtf8(value); kmsKey_ = value; - bitField0_ |= 0x00080000; + bitField0_ |= 0x00100000; onChanged(); return this; } @@ -5755,7 +6048,7 @@ public Builder setKmsKeyBytes(com.google.protobuf.ByteString value) { * @return Whether the updateStorageClassTime field is set. */ public boolean hasUpdateStorageClassTime() { - return ((bitField0_ & 0x00100000) != 0); + return ((bitField0_ & 0x00200000) != 0); } /** * @@ -5801,7 +6094,7 @@ public Builder setUpdateStorageClassTime(com.google.protobuf.Timestamp value) { } else { updateStorageClassTimeBuilder_.setMessage(value); } - bitField0_ |= 0x00100000; + bitField0_ |= 0x00200000; onChanged(); return this; } @@ -5824,7 +6117,7 @@ public Builder setUpdateStorageClassTime( } else { updateStorageClassTimeBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x00100000; + bitField0_ |= 0x00200000; onChanged(); return this; } @@ -5842,7 +6135,7 @@ public Builder setUpdateStorageClassTime( */ public Builder mergeUpdateStorageClassTime(com.google.protobuf.Timestamp value) { if (updateStorageClassTimeBuilder_ == null) { - if (((bitField0_ & 0x00100000) != 0) + if (((bitField0_ & 0x00200000) != 0) && updateStorageClassTime_ != null && updateStorageClassTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getUpdateStorageClassTimeBuilder().mergeFrom(value); @@ -5853,7 +6146,7 @@ public Builder mergeUpdateStorageClassTime(com.google.protobuf.Timestamp value) updateStorageClassTimeBuilder_.mergeFrom(value); } if (updateStorageClassTime_ != null) { - bitField0_ |= 0x00100000; + bitField0_ |= 0x00200000; onChanged(); } return this; @@ -5871,7 +6164,7 @@ public Builder mergeUpdateStorageClassTime(com.google.protobuf.Timestamp value) * */ public Builder clearUpdateStorageClassTime() { - bitField0_ = (bitField0_ & ~0x00100000); + bitField0_ = (bitField0_ & ~0x00200000); updateStorageClassTime_ = null; if (updateStorageClassTimeBuilder_ != null) { updateStorageClassTimeBuilder_.dispose(); @@ -5893,7 +6186,7 @@ public Builder clearUpdateStorageClassTime() { * */ public com.google.protobuf.Timestamp.Builder getUpdateStorageClassTimeBuilder() { - bitField0_ |= 0x00100000; + bitField0_ |= 0x00200000; onChanged(); return getUpdateStorageClassTimeFieldBuilder().getBuilder(); } @@ -5986,7 +6279,7 @@ public boolean getTemporaryHold() { public Builder setTemporaryHold(boolean value) { temporaryHold_ = value; - bitField0_ |= 0x00200000; + bitField0_ |= 0x00400000; onChanged(); return this; } @@ -6006,7 +6299,7 @@ public Builder setTemporaryHold(boolean value) { * @return This builder for chaining. */ public Builder clearTemporaryHold() { - bitField0_ = (bitField0_ & ~0x00200000); + bitField0_ = (bitField0_ & ~0x00400000); temporaryHold_ = false; onChanged(); return this; @@ -6036,7 +6329,7 @@ public Builder clearTemporaryHold() { * @return Whether the retentionExpireTime field is set. */ public boolean hasRetentionExpireTime() { - return ((bitField0_ & 0x00400000) != 0); + return ((bitField0_ & 0x00800000) != 0); } /** * @@ -6088,7 +6381,7 @@ public Builder setRetentionExpireTime(com.google.protobuf.Timestamp value) { } else { retentionExpireTimeBuilder_.setMessage(value); } - bitField0_ |= 0x00400000; + bitField0_ |= 0x00800000; onChanged(); return this; } @@ -6113,7 +6406,7 @@ public Builder setRetentionExpireTime(com.google.protobuf.Timestamp.Builder buil } else { retentionExpireTimeBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x00400000; + bitField0_ |= 0x00800000; onChanged(); return this; } @@ -6134,7 +6427,7 @@ public Builder setRetentionExpireTime(com.google.protobuf.Timestamp.Builder buil */ public Builder mergeRetentionExpireTime(com.google.protobuf.Timestamp value) { if (retentionExpireTimeBuilder_ == null) { - if (((bitField0_ & 0x00400000) != 0) + if (((bitField0_ & 0x00800000) != 0) && retentionExpireTime_ != null && retentionExpireTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getRetentionExpireTimeBuilder().mergeFrom(value); @@ -6145,7 +6438,7 @@ public Builder mergeRetentionExpireTime(com.google.protobuf.Timestamp value) { retentionExpireTimeBuilder_.mergeFrom(value); } if (retentionExpireTime_ != null) { - bitField0_ |= 0x00400000; + bitField0_ |= 0x00800000; onChanged(); } return this; @@ -6166,7 +6459,7 @@ public Builder mergeRetentionExpireTime(com.google.protobuf.Timestamp value) { * .google.protobuf.Timestamp retention_expire_time = 21; */ public Builder clearRetentionExpireTime() { - bitField0_ = (bitField0_ & ~0x00400000); + bitField0_ = (bitField0_ & ~0x00800000); retentionExpireTime_ = null; if (retentionExpireTimeBuilder_ != null) { retentionExpireTimeBuilder_.dispose(); @@ -6191,7 +6484,7 @@ public Builder clearRetentionExpireTime() { * .google.protobuf.Timestamp retention_expire_time = 21; */ public com.google.protobuf.Timestamp.Builder getRetentionExpireTimeBuilder() { - bitField0_ |= 0x00400000; + bitField0_ |= 0x00800000; onChanged(); return getRetentionExpireTimeFieldBuilder().getBuilder(); } @@ -6269,7 +6562,7 @@ private com.google.protobuf.MapField interna if (!metadata_.isMutable()) { metadata_ = metadata_.copy(); } - bitField0_ |= 0x00800000; + bitField0_ |= 0x01000000; onChanged(); return metadata_; } @@ -6354,7 +6647,7 @@ public java.lang.String getMetadataOrThrow(java.lang.String key) { } public Builder clearMetadata() { - bitField0_ = (bitField0_ & ~0x00800000); + bitField0_ = (bitField0_ & ~0x01000000); internalGetMutableMetadata().getMutableMap().clear(); return this; } @@ -6377,7 +6670,7 @@ public Builder removeMetadata(java.lang.String key) { /** Use alternate mutation accessors instead. */ @java.lang.Deprecated public java.util.Map getMutableMetadata() { - bitField0_ |= 0x00800000; + bitField0_ |= 0x01000000; return internalGetMutableMetadata().getMutableMap(); } /** @@ -6397,7 +6690,7 @@ public Builder putMetadata(java.lang.String key, java.lang.String value) { throw new NullPointerException("map value"); } internalGetMutableMetadata().getMutableMap().put(key, value); - bitField0_ |= 0x00800000; + bitField0_ |= 0x01000000; return this; } /** @@ -6411,7 +6704,7 @@ public Builder putMetadata(java.lang.String key, java.lang.String value) { */ public Builder putAllMetadata(java.util.Map values) { internalGetMutableMetadata().getMutableMap().putAll(values); - bitField0_ |= 0x00800000; + bitField0_ |= 0x01000000; return this; } @@ -6439,7 +6732,7 @@ public Builder putAllMetadata(java.util.Map */ @java.lang.Override public boolean hasEventBasedHold() { - return ((bitField0_ & 0x01000000) != 0); + return ((bitField0_ & 0x02000000) != 0); } /** * @@ -6491,7 +6784,7 @@ public boolean getEventBasedHold() { public Builder setEventBasedHold(boolean value) { eventBasedHold_ = value; - bitField0_ |= 0x01000000; + bitField0_ |= 0x02000000; onChanged(); return this; } @@ -6517,7 +6810,7 @@ public Builder setEventBasedHold(boolean value) { * @return This builder for chaining. */ public Builder clearEventBasedHold() { - bitField0_ = (bitField0_ & ~0x01000000); + bitField0_ = (bitField0_ & ~0x02000000); eventBasedHold_ = false; onChanged(); return this; @@ -6543,7 +6836,7 @@ public Builder clearEventBasedHold() { * @return Whether the owner field is set. */ public boolean hasOwner() { - return ((bitField0_ & 0x02000000) != 0); + return ((bitField0_ & 0x04000000) != 0); } /** * @@ -6585,7 +6878,7 @@ public Builder setOwner(com.google.storage.v2.Owner value) { } else { ownerBuilder_.setMessage(value); } - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; onChanged(); return this; } @@ -6606,7 +6899,7 @@ public Builder setOwner(com.google.storage.v2.Owner.Builder builderForValue) { } else { ownerBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; onChanged(); return this; } @@ -6623,7 +6916,7 @@ public Builder setOwner(com.google.storage.v2.Owner.Builder builderForValue) { */ public Builder mergeOwner(com.google.storage.v2.Owner value) { if (ownerBuilder_ == null) { - if (((bitField0_ & 0x02000000) != 0) + if (((bitField0_ & 0x04000000) != 0) && owner_ != null && owner_ != com.google.storage.v2.Owner.getDefaultInstance()) { getOwnerBuilder().mergeFrom(value); @@ -6634,7 +6927,7 @@ public Builder mergeOwner(com.google.storage.v2.Owner value) { ownerBuilder_.mergeFrom(value); } if (owner_ != null) { - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; onChanged(); } return this; @@ -6651,7 +6944,7 @@ public Builder mergeOwner(com.google.storage.v2.Owner value) { * */ public Builder clearOwner() { - bitField0_ = (bitField0_ & ~0x02000000); + bitField0_ = (bitField0_ & ~0x04000000); owner_ = null; if (ownerBuilder_ != null) { ownerBuilder_.dispose(); @@ -6672,7 +6965,7 @@ public Builder clearOwner() { * */ public com.google.storage.v2.Owner.Builder getOwnerBuilder() { - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; onChanged(); return getOwnerFieldBuilder().getBuilder(); } @@ -6741,7 +7034,7 @@ public com.google.storage.v2.OwnerOrBuilder getOwnerOrBuilder() { * @return Whether the customerEncryption field is set. */ public boolean hasCustomerEncryption() { - return ((bitField0_ & 0x04000000) != 0); + return ((bitField0_ & 0x08000000) != 0); } /** * @@ -6783,7 +7076,7 @@ public Builder setCustomerEncryption(com.google.storage.v2.CustomerEncryption va } else { customerEncryptionBuilder_.setMessage(value); } - bitField0_ |= 0x04000000; + bitField0_ |= 0x08000000; onChanged(); return this; } @@ -6804,7 +7097,7 @@ public Builder setCustomerEncryption( } else { customerEncryptionBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x04000000; + bitField0_ |= 0x08000000; onChanged(); return this; } @@ -6820,7 +7113,7 @@ public Builder setCustomerEncryption( */ public Builder mergeCustomerEncryption(com.google.storage.v2.CustomerEncryption value) { if (customerEncryptionBuilder_ == null) { - if (((bitField0_ & 0x04000000) != 0) + if (((bitField0_ & 0x08000000) != 0) && customerEncryption_ != null && customerEncryption_ != com.google.storage.v2.CustomerEncryption.getDefaultInstance()) { @@ -6832,7 +7125,7 @@ public Builder mergeCustomerEncryption(com.google.storage.v2.CustomerEncryption customerEncryptionBuilder_.mergeFrom(value); } if (customerEncryption_ != null) { - bitField0_ |= 0x04000000; + bitField0_ |= 0x08000000; onChanged(); } return this; @@ -6848,7 +7141,7 @@ public Builder mergeCustomerEncryption(com.google.storage.v2.CustomerEncryption * .google.storage.v2.CustomerEncryption customer_encryption = 25; */ public Builder clearCustomerEncryption() { - bitField0_ = (bitField0_ & ~0x04000000); + bitField0_ = (bitField0_ & ~0x08000000); customerEncryption_ = null; if (customerEncryptionBuilder_ != null) { customerEncryptionBuilder_.dispose(); @@ -6868,7 +7161,7 @@ public Builder clearCustomerEncryption() { * .google.storage.v2.CustomerEncryption customer_encryption = 25; */ public com.google.storage.v2.CustomerEncryption.Builder getCustomerEncryptionBuilder() { - bitField0_ |= 0x04000000; + bitField0_ |= 0x08000000; onChanged(); return getCustomerEncryptionFieldBuilder().getBuilder(); } @@ -6936,7 +7229,7 @@ public com.google.storage.v2.CustomerEncryptionOrBuilder getCustomerEncryptionOr * @return Whether the customTime field is set. */ public boolean hasCustomTime() { - return ((bitField0_ & 0x08000000) != 0); + return ((bitField0_ & 0x10000000) != 0); } /** * @@ -6976,7 +7269,7 @@ public Builder setCustomTime(com.google.protobuf.Timestamp value) { } else { customTimeBuilder_.setMessage(value); } - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; onChanged(); return this; } @@ -6995,7 +7288,7 @@ public Builder setCustomTime(com.google.protobuf.Timestamp.Builder builderForVal } else { customTimeBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; onChanged(); return this; } @@ -7010,7 +7303,7 @@ public Builder setCustomTime(com.google.protobuf.Timestamp.Builder builderForVal */ public Builder mergeCustomTime(com.google.protobuf.Timestamp value) { if (customTimeBuilder_ == null) { - if (((bitField0_ & 0x08000000) != 0) + if (((bitField0_ & 0x10000000) != 0) && customTime_ != null && customTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getCustomTimeBuilder().mergeFrom(value); @@ -7021,7 +7314,7 @@ public Builder mergeCustomTime(com.google.protobuf.Timestamp value) { customTimeBuilder_.mergeFrom(value); } if (customTime_ != null) { - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; onChanged(); } return this; @@ -7036,7 +7329,7 @@ public Builder mergeCustomTime(com.google.protobuf.Timestamp value) { * .google.protobuf.Timestamp custom_time = 26; */ public Builder clearCustomTime() { - bitField0_ = (bitField0_ & ~0x08000000); + bitField0_ = (bitField0_ & ~0x10000000); customTime_ = null; if (customTimeBuilder_ != null) { customTimeBuilder_.dispose(); @@ -7055,7 +7348,7 @@ public Builder clearCustomTime() { * .google.protobuf.Timestamp custom_time = 26; */ public com.google.protobuf.Timestamp.Builder getCustomTimeBuilder() { - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; onChanged(); return getCustomTimeFieldBuilder().getBuilder(); } @@ -7126,7 +7419,7 @@ public com.google.protobuf.TimestampOrBuilder getCustomTimeOrBuilder() { * @return Whether the softDeleteTime field is set. */ public boolean hasSoftDeleteTime() { - return ((bitField0_ & 0x10000000) != 0); + return ((bitField0_ & 0x20000000) != 0); } /** * @@ -7176,7 +7469,7 @@ public Builder setSoftDeleteTime(com.google.protobuf.Timestamp value) { } else { softDeleteTimeBuilder_.setMessage(value); } - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; onChanged(); return this; } @@ -7200,7 +7493,7 @@ public Builder setSoftDeleteTime(com.google.protobuf.Timestamp.Builder builderFo } else { softDeleteTimeBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; onChanged(); return this; } @@ -7220,7 +7513,7 @@ public Builder setSoftDeleteTime(com.google.protobuf.Timestamp.Builder builderFo */ public Builder mergeSoftDeleteTime(com.google.protobuf.Timestamp value) { if (softDeleteTimeBuilder_ == null) { - if (((bitField0_ & 0x10000000) != 0) + if (((bitField0_ & 0x20000000) != 0) && softDeleteTime_ != null && softDeleteTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getSoftDeleteTimeBuilder().mergeFrom(value); @@ -7231,7 +7524,7 @@ public Builder mergeSoftDeleteTime(com.google.protobuf.Timestamp value) { softDeleteTimeBuilder_.mergeFrom(value); } if (softDeleteTime_ != null) { - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; onChanged(); } return this; @@ -7251,7 +7544,7 @@ public Builder mergeSoftDeleteTime(com.google.protobuf.Timestamp value) { * */ public Builder clearSoftDeleteTime() { - bitField0_ = (bitField0_ & ~0x10000000); + bitField0_ = (bitField0_ & ~0x20000000); softDeleteTime_ = null; if (softDeleteTimeBuilder_ != null) { softDeleteTimeBuilder_.dispose(); @@ -7275,7 +7568,7 @@ public Builder clearSoftDeleteTime() { * */ public com.google.protobuf.Timestamp.Builder getSoftDeleteTimeBuilder() { - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; onChanged(); return getSoftDeleteTimeFieldBuilder().getBuilder(); } @@ -7356,7 +7649,7 @@ public com.google.protobuf.TimestampOrBuilder getSoftDeleteTimeOrBuilder() { * @return Whether the hardDeleteTime field is set. */ public boolean hasHardDeleteTime() { - return ((bitField0_ & 0x20000000) != 0); + return ((bitField0_ & 0x40000000) != 0); } /** * @@ -7406,7 +7699,7 @@ public Builder setHardDeleteTime(com.google.protobuf.Timestamp value) { } else { hardDeleteTimeBuilder_.setMessage(value); } - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; onChanged(); return this; } @@ -7430,7 +7723,7 @@ public Builder setHardDeleteTime(com.google.protobuf.Timestamp.Builder builderFo } else { hardDeleteTimeBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; onChanged(); return this; } @@ -7450,7 +7743,7 @@ public Builder setHardDeleteTime(com.google.protobuf.Timestamp.Builder builderFo */ public Builder mergeHardDeleteTime(com.google.protobuf.Timestamp value) { if (hardDeleteTimeBuilder_ == null) { - if (((bitField0_ & 0x20000000) != 0) + if (((bitField0_ & 0x40000000) != 0) && hardDeleteTime_ != null && hardDeleteTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getHardDeleteTimeBuilder().mergeFrom(value); @@ -7461,7 +7754,7 @@ public Builder mergeHardDeleteTime(com.google.protobuf.Timestamp value) { hardDeleteTimeBuilder_.mergeFrom(value); } if (hardDeleteTime_ != null) { - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; onChanged(); } return this; @@ -7481,7 +7774,7 @@ public Builder mergeHardDeleteTime(com.google.protobuf.Timestamp value) { * */ public Builder clearHardDeleteTime() { - bitField0_ = (bitField0_ & ~0x20000000); + bitField0_ = (bitField0_ & ~0x40000000); hardDeleteTime_ = null; if (hardDeleteTimeBuilder_ != null) { hardDeleteTimeBuilder_.dispose(); @@ -7505,7 +7798,7 @@ public Builder clearHardDeleteTime() { * */ public com.google.protobuf.Timestamp.Builder getHardDeleteTimeBuilder() { - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; onChanged(); return getHardDeleteTimeFieldBuilder().getBuilder(); } diff --git a/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/ObjectOrBuilder.java b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/ObjectOrBuilder.java index b2b3c42258..ddbcba78f0 100644 --- a/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/ObjectOrBuilder.java +++ b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/ObjectOrBuilder.java @@ -448,6 +448,47 @@ public interface ObjectOrBuilder */ com.google.protobuf.TimestampOrBuilder getDeleteTimeOrBuilder(); + /** + * + * + *
+   * Output only. The time when the object was finalized.
+   * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the finalizeTime field is set. + */ + boolean hasFinalizeTime(); + /** + * + * + *
+   * Output only. The time when the object was finalized.
+   * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The finalizeTime. + */ + com.google.protobuf.Timestamp getFinalizeTime(); + /** + * + * + *
+   * Output only. The time when the object was finalized.
+   * 
+ * + * + * .google.protobuf.Timestamp finalize_time = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getFinalizeTimeOrBuilder(); + /** * * diff --git a/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageProto.java b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageProto.java index d037495f96..035b6da8d3 100644 --- a/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageProto.java +++ b/proto-google-cloud-storage-v2/src/main/java/com/google/storage/v2/StorageProto.java @@ -136,6 +136,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_storage_v2_RewriteResponse_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_storage_v2_RewriteResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_storage_v2_MoveObjectRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_storage_v2_MoveObjectRequest_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_storage_v2_StartResumableWriteRequest_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -503,292 +507,316 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "onse\022\035\n\025total_bytes_rewritten\030\001 \001(\003\022\023\n\013o" + "bject_size\030\002 \001(\003\022\014\n\004done\030\003 \001(\010\022\025\n\rrewrit" + "e_token\030\004 \001(\t\022+\n\010resource\030\005 \001(\0132\031.google" - + ".storage.v2.Object\"\362\001\n\032StartResumableWri" - + "teRequest\022B\n\021write_object_spec\030\001 \001(\0132\".g" - + "oogle.storage.v2.WriteObjectSpecB\003\340A\002\022R\n" - + "\034common_object_request_params\030\003 \001(\0132,.go" - + "ogle.storage.v2.CommonObjectRequestParam" - + "s\022<\n\020object_checksums\030\005 \001(\0132\".google.sto" - + "rage.v2.ObjectChecksums\"0\n\033StartResumabl" - + "eWriteResponse\022\021\n\tupload_id\030\001 \001(\t\"\357\003\n\023Up" - + "dateObjectRequest\022.\n\006object\030\001 \001(\0132\031.goog" - + "le.storage.v2.ObjectB\003\340A\002\022 \n\023if_generati" - + "on_match\030\002 \001(\003H\000\210\001\001\022$\n\027if_generation_not" - + "_match\030\003 \001(\003H\001\210\001\001\022$\n\027if_metageneration_m" - + "atch\030\004 \001(\003H\002\210\001\001\022(\n\033if_metageneration_not" - + "_match\030\005 \001(\003H\003\210\001\001\022\026\n\016predefined_acl\030\n \001(" - + "\t\0224\n\013update_mask\030\007 \001(\0132\032.google.protobuf" - + ".FieldMaskB\003\340A\002\022R\n\034common_object_request" - + "_params\030\010 \001(\0132,.google.storage.v2.Common" - + "ObjectRequestParamsB\026\n\024_if_generation_ma" - + "tchB\032\n\030_if_generation_not_matchB\032\n\030_if_m" - + "etageneration_matchB\036\n\034_if_metageneratio" - + "n_not_match\"|\n\031CommonObjectRequestParams" - + "\022\034\n\024encryption_algorithm\030\001 \001(\t\022\034\n\024encryp" - + "tion_key_bytes\030\004 \001(\014\022#\n\033encryption_key_s" - + "ha256_bytes\030\005 \001(\014\"\312\005\n\020ServiceConstants\"\265" - + "\005\n\006Values\022\026\n\022VALUES_UNSPECIFIED\020\000\022\033\n\024MAX" - + "_READ_CHUNK_BYTES\020\200\200\200\001\022\034\n\025MAX_WRITE_CHUN" - + "K_BYTES\020\200\200\200\001\022\031\n\022MAX_OBJECT_SIZE_MB\020\200\200\300\002\022" - + ")\n$MAX_CUSTOM_METADATA_FIELD_NAME_BYTES\020" - + "\200\010\022*\n%MAX_CUSTOM_METADATA_FIELD_VALUE_BY" - + "TES\020\200 \022)\n$MAX_CUSTOM_METADATA_TOTAL_SIZE" - + "_BYTES\020\200@\022*\n$MAX_BUCKET_METADATA_TOTAL_S" - + "IZE_BYTES\020\200\240\001\022\'\n#MAX_NOTIFICATION_CONFIG" - + "S_PER_BUCKET\020d\022\"\n\036MAX_LIFECYCLE_RULES_PE" - + "R_BUCKET\020d\022&\n\"MAX_NOTIFICATION_CUSTOM_AT" - + "TRIBUTES\020\005\0221\n,MAX_NOTIFICATION_CUSTOM_AT" - + "TRIBUTE_KEY_LENGTH\020\200\002\0223\n.MAX_NOTIFICATIO" - + "N_CUSTOM_ATTRIBUTE_VALUE_LENGTH\020\200\010\022\034\n\030MA" - + "X_LABELS_ENTRIES_COUNT\020@\022\037\n\033MAX_LABELS_K" - + "EY_VALUE_LENGTH\020?\022\037\n\032MAX_LABELS_KEY_VALU" - + "E_BYTES\020\200\001\022.\n)MAX_OBJECT_IDS_PER_DELETE_" - + "OBJECTS_REQUEST\020\350\007\022\036\n\032SPLIT_TOKEN_MAX_VA" - + "LID_DAYS\020\016\032\002\020\001\"\243\034\n\006Bucket\022\021\n\004name\030\001 \001(\tB" - + "\003\340A\005\022\026\n\tbucket_id\030\002 \001(\tB\003\340A\003\022\014\n\004etag\030\035 \001" - + "(\t\022D\n\007project\030\003 \001(\tB3\340A\005\372A-\n+cloudresour" - + "cemanager.googleapis.com/Project\022\033\n\016meta" - + "generation\030\004 \001(\003B\003\340A\003\022\025\n\010location\030\005 \001(\tB" - + "\003\340A\005\022\032\n\rlocation_type\030\006 \001(\tB\003\340A\003\022\025\n\rstor" - + "age_class\030\007 \001(\t\022\013\n\003rpo\030\033 \001(\t\0223\n\003acl\030\010 \003(" - + "\0132&.google.storage.v2.BucketAccessContro" - + "l\022B\n\022default_object_acl\030\t \003(\0132&.google.s" - + "torage.v2.ObjectAccessControl\0226\n\tlifecyc" - + "le\030\n \001(\0132#.google.storage.v2.Bucket.Life" - + "cycle\0224\n\013create_time\030\013 \001(\0132\032.google.prot" - + "obuf.TimestampB\003\340A\003\022,\n\004cors\030\014 \003(\0132\036.goog" - + "le.storage.v2.Bucket.Cors\0224\n\013update_time" - + "\030\r \001(\0132\032.google.protobuf.TimestampB\003\340A\003\022" - + " \n\030default_event_based_hold\030\016 \001(\010\0225\n\006lab" - + "els\030\017 \003(\0132%.google.storage.v2.Bucket.Lab" - + "elsEntry\0222\n\007website\030\020 \001(\0132!.google.stora" - + "ge.v2.Bucket.Website\0228\n\nversioning\030\021 \001(\013" - + "2$.google.storage.v2.Bucket.Versioning\0222" - + "\n\007logging\030\022 \001(\0132!.google.storage.v2.Buck" - + "et.Logging\022,\n\005owner\030\023 \001(\0132\030.google.stora" - + "ge.v2.OwnerB\003\340A\003\0228\n\nencryption\030\024 \001(\0132$.g" - + "oogle.storage.v2.Bucket.Encryption\0222\n\007bi" - + "lling\030\025 \001(\0132!.google.storage.v2.Bucket.B" - + "illing\022C\n\020retention_policy\030\026 \001(\0132).googl" - + "e.storage.v2.Bucket.RetentionPolicy\0227\n\ni" - + "am_config\030\027 \001(\0132#.google.storage.v2.Buck" - + "et.IamConfig\022\025\n\rsatisfies_pzs\030\031 \001(\010\022P\n\027c" - + "ustom_placement_config\030\032 \001(\0132/.google.st" - + "orage.v2.Bucket.CustomPlacementConfig\0226\n" - + "\tautoclass\030\034 \001(\0132#.google.storage.v2.Buc" - + "ket.Autoclass\022T\n\026hierarchical_namespace\030" - + " \001(\0132/.google.storage.v2.Bucket.Hierarc" - + "hicalNamespaceB\003\340A\001\022K\n\022soft_delete_polic" - + "y\030\037 \001(\0132*.google.storage.v2.Bucket.SoftD" - + "eletePolicyB\003\340A\001\032!\n\007Billing\022\026\n\016requester" - + "_pays\030\001 \001(\010\032X\n\004Cors\022\016\n\006origin\030\001 \003(\t\022\016\n\006m" - + "ethod\030\002 \003(\t\022\027\n\017response_header\030\003 \003(\t\022\027\n\017" - + "max_age_seconds\030\004 \001(\005\032M\n\nEncryption\022?\n\017d" - + "efault_kms_key\030\001 \001(\tB&\372A#\n!cloudkms.goog" - + "leapis.com/CryptoKey\032\354\001\n\tIamConfig\022a\n\033un" - + "iform_bucket_level_access\030\001 \001(\0132<.google" - + ".storage.v2.Bucket.IamConfig.UniformBuck" - + "etLevelAccess\022 \n\030public_access_preventio" - + "n\030\003 \001(\t\032Z\n\030UniformBucketLevelAccess\022\017\n\007e" - + "nabled\030\001 \001(\010\022-\n\tlock_time\030\002 \001(\0132\032.google" - + ".protobuf.Timestamp\032\363\005\n\tLifecycle\0226\n\004rul" - + "e\030\001 \003(\0132(.google.storage.v2.Bucket.Lifec" - + "ycle.Rule\032\255\005\n\004Rule\022?\n\006action\030\001 \001(\0132/.goo" - + "gle.storage.v2.Bucket.Lifecycle.Rule.Act" - + "ion\022E\n\tcondition\030\002 \001(\01322.google.storage." - + "v2.Bucket.Lifecycle.Rule.Condition\032-\n\006Ac" - + "tion\022\014\n\004type\030\001 \001(\t\022\025\n\rstorage_class\030\002 \001(" - + "\t\032\355\003\n\tCondition\022\025\n\010age_days\030\001 \001(\005H\000\210\001\001\022)" - + "\n\016created_before\030\002 \001(\0132\021.google.type.Dat" - + "e\022\024\n\007is_live\030\003 \001(\010H\001\210\001\001\022\037\n\022num_newer_ver" - + "sions\030\004 \001(\005H\002\210\001\001\022\035\n\025matches_storage_clas" - + "s\030\005 \003(\t\022#\n\026days_since_custom_time\030\007 \001(\005H" - + "\003\210\001\001\022-\n\022custom_time_before\030\010 \001(\0132\021.googl" - + "e.type.Date\022\'\n\032days_since_noncurrent_tim" - + "e\030\t \001(\005H\004\210\001\001\0221\n\026noncurrent_time_before\030\n" - + " \001(\0132\021.google.type.Date\022\026\n\016matches_prefi" - + "x\030\013 \003(\t\022\026\n\016matches_suffix\030\014 \003(\tB\013\n\t_age_" - + "daysB\n\n\010_is_liveB\025\n\023_num_newer_versionsB" - + "\031\n\027_days_since_custom_timeB\035\n\033_days_sinc" - + "e_noncurrent_time\0328\n\007Logging\022\022\n\nlog_buck" - + "et\030\001 \001(\t\022\031\n\021log_object_prefix\030\002 \001(\t\032\217\001\n\017" - + "RetentionPolicy\0222\n\016effective_time\030\001 \001(\0132" - + "\032.google.protobuf.Timestamp\022\021\n\tis_locked" - + "\030\002 \001(\010\0225\n\022retention_duration\030\004 \001(\0132\031.goo" - + "gle.protobuf.Duration\032\261\001\n\020SoftDeletePoli" - + "cy\022:\n\022retention_duration\030\001 \001(\0132\031.google." - + "protobuf.DurationH\000\210\001\001\0227\n\016effective_time" - + "\030\002 \001(\0132\032.google.protobuf.TimestampH\001\210\001\001B" - + "\025\n\023_retention_durationB\021\n\017_effective_tim" - + "e\032\035\n\nVersioning\022\017\n\007enabled\030\001 \001(\010\032;\n\007Webs" - + "ite\022\030\n\020main_page_suffix\030\001 \001(\t\022\026\n\016not_fou" - + "nd_page\030\002 \001(\t\032/\n\025CustomPlacementConfig\022\026" - + "\n\016data_locations\030\001 \003(\t\032\213\002\n\tAutoclass\022\017\n\007" - + "enabled\030\001 \001(\010\0224\n\013toggle_time\030\002 \001(\0132\032.goo" - + "gle.protobuf.TimestampB\003\340A\003\022#\n\026terminal_" - + "storage_class\030\003 \001(\tH\000\210\001\001\022P\n\"terminal_sto" - + "rage_class_update_time\030\004 \001(\0132\032.google.pr" - + "otobuf.TimestampB\003\340A\003H\001\210\001\001B\031\n\027_terminal_" - + "storage_classB%\n#_terminal_storage_class" - + "_update_time\032-\n\025HierarchicalNamespace\022\024\n" - + "\007enabled\030\001 \001(\010B\003\340A\001\032-\n\013LabelsEntry\022\013\n\003ke" - + "y\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001:X\352AU\n\035storage" - + ".googleapis.com/Bucket\022#projects/{projec" - + "t}/buckets/{bucket}*\007buckets2\006bucket\"\316\001\n" - + "\023BucketAccessControl\022\014\n\004role\030\001 \001(\t\022\n\n\002id" - + "\030\002 \001(\t\022\016\n\006entity\030\003 \001(\t\022\027\n\nentity_alt\030\t \001" - + "(\tB\003\340A\003\022\021\n\tentity_id\030\004 \001(\t\022\014\n\004etag\030\010 \001(\t" - + "\022\r\n\005email\030\005 \001(\t\022\016\n\006domain\030\006 \001(\t\0224\n\014proje" - + "ct_team\030\007 \001(\0132\036.google.storage.v2.Projec" - + "tTeam\"I\n\017ChecksummedData\022\026\n\007content\030\001 \001(" - + "\014B\005\010\001\340A\001\022\023\n\006crc32c\030\002 \001(\007H\000\210\001\001B\t\n\007_crc32c" - + "\"C\n\017ObjectChecksums\022\023\n\006crc32c\030\001 \001(\007H\000\210\001\001" - + "\022\020\n\010md5_hash\030\002 \001(\014B\t\n\007_crc32c\"L\n\022Custome" - + "rEncryption\022\034\n\024encryption_algorithm\030\001 \001(" - + "\t\022\030\n\020key_sha256_bytes\030\003 \001(\014\"\337\n\n\006Object\022\021" - + "\n\004name\030\001 \001(\tB\003\340A\005\0225\n\006bucket\030\002 \001(\tB%\340A\005\372A" - + "\037\n\035storage.googleapis.com/Bucket\022\014\n\004etag" - + "\030\033 \001(\t\022\027\n\ngeneration\030\003 \001(\003B\003\340A\005\022\037\n\rresto" - + "re_token\030# \001(\tB\003\340A\003H\000\210\001\001\022\033\n\016metagenerati" - + "on\030\004 \001(\003B\003\340A\003\022\025\n\rstorage_class\030\005 \001(\t\022\021\n\004" - + "size\030\006 \001(\003B\003\340A\003\022\030\n\020content_encoding\030\007 \001(" - + "\t\022\033\n\023content_disposition\030\010 \001(\t\022\025\n\rcache_" - + "control\030\t \001(\t\0223\n\003acl\030\n \003(\0132&.google.stor" - + "age.v2.ObjectAccessControl\022\030\n\020content_la" - + "nguage\030\013 \001(\t\0224\n\013delete_time\030\014 \001(\0132\032.goog" - + "le.protobuf.TimestampB\003\340A\003\022\024\n\014content_ty" - + "pe\030\r \001(\t\0224\n\013create_time\030\016 \001(\0132\032.google.p" - + "rotobuf.TimestampB\003\340A\003\022\034\n\017component_coun" - + "t\030\017 \001(\005B\003\340A\003\022:\n\tchecksums\030\020 \001(\0132\".google" - + ".storage.v2.ObjectChecksumsB\003\340A\003\0224\n\013upda" - + "te_time\030\021 \001(\0132\032.google.protobuf.Timestam" - + "pB\003\340A\003\0227\n\007kms_key\030\022 \001(\tB&\372A#\n!cloudkms.g" - + "oogleapis.com/CryptoKey\022B\n\031update_storag" - + "e_class_time\030\023 \001(\0132\032.google.protobuf.Tim" - + "estampB\003\340A\003\022\026\n\016temporary_hold\030\024 \001(\010\0229\n\025r" - + "etention_expire_time\030\025 \001(\0132\032.google.prot" - + "obuf.Timestamp\0229\n\010metadata\030\026 \003(\0132\'.googl" - + "e.storage.v2.Object.MetadataEntry\022\035\n\020eve" - + "nt_based_hold\030\027 \001(\010H\001\210\001\001\022,\n\005owner\030\030 \001(\0132" - + "\030.google.storage.v2.OwnerB\003\340A\003\022B\n\023custom" - + "er_encryption\030\031 \001(\0132%.google.storage.v2." - + "CustomerEncryption\022/\n\013custom_time\030\032 \001(\0132" - + "\032.google.protobuf.Timestamp\022>\n\020soft_dele" - + "te_time\030\034 \001(\0132\032.google.protobuf.Timestam" - + "pB\003\340A\003H\002\210\001\001\022>\n\020hard_delete_time\030\035 \001(\0132\032." - + "google.protobuf.TimestampB\003\340A\003H\003\210\001\001\032/\n\rM" - + "etadataEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t" - + ":\0028\001B\020\n\016_restore_tokenB\023\n\021_event_based_h" - + "oldB\023\n\021_soft_delete_timeB\023\n\021_hard_delete" - + "_time\"\316\001\n\023ObjectAccessControl\022\014\n\004role\030\001 " - + "\001(\t\022\n\n\002id\030\002 \001(\t\022\016\n\006entity\030\003 \001(\t\022\027\n\nentit" - + "y_alt\030\t \001(\tB\003\340A\003\022\021\n\tentity_id\030\004 \001(\t\022\014\n\004e" - + "tag\030\010 \001(\t\022\r\n\005email\030\005 \001(\t\022\016\n\006domain\030\006 \001(\t" - + "\0224\n\014project_team\030\007 \001(\0132\036.google.storage.", - "v2.ProjectTeam\"l\n\023ListObjectsResponse\022*\n" - + "\007objects\030\001 \003(\0132\031.google.storage.v2.Objec" - + "t\022\020\n\010prefixes\030\002 \003(\t\022\027\n\017next_page_token\030\003" - + " \001(\t\"3\n\013ProjectTeam\022\026\n\016project_number\030\001 " - + "\001(\t\022\014\n\004team\030\002 \001(\t\"*\n\005Owner\022\016\n\006entity\030\001 \001" - + "(\t\022\021\n\tentity_id\030\002 \001(\t\"C\n\014ContentRange\022\r\n" - + "\005start\030\001 \001(\003\022\013\n\003end\030\002 \001(\003\022\027\n\017complete_le" - + "ngth\030\003 \001(\0032\214\034\n\007Storage\022r\n\014DeleteBucket\022&" - + ".google.storage.v2.DeleteBucketRequest\032\026" - + ".google.protobuf.Empty\"\"\332A\004name\212\323\344\223\002\025\022\023\n" - + "\004name\022\013{bucket=**}\022o\n\tGetBucket\022#.google" - + ".storage.v2.GetBucketRequest\032\031.google.st" - + "orage.v2.Bucket\"\"\332A\004name\212\323\344\223\002\025\022\023\n\004name\022\013" - + "{bucket=**}\022\253\001\n\014CreateBucket\022&.google.st" - + "orage.v2.CreateBucketRequest\032\031.google.st" - + "orage.v2.Bucket\"X\332A\027parent,bucket,bucket" - + "_id\212\323\344\223\0028\022\026\n\006parent\022\014{project=**}\022\036\n\016buc" - + "ket.project\022\014{project=**}\022\205\001\n\013ListBucket" - + "s\022%.google.storage.v2.ListBucketsRequest" - + "\032&.google.storage.v2.ListBucketsResponse" - + "\"\'\332A\006parent\212\323\344\223\002\030\022\026\n\006parent\022\014{project=**" - + "}\022\223\001\n\031LockBucketRetentionPolicy\0223.google" - + ".storage.v2.LockBucketRetentionPolicyReq" - + "uest\032\031.google.storage.v2.Bucket\"&\332A\006buck" - + "et\212\323\344\223\002\027\022\025\n\006bucket\022\013{bucket=**}\022u\n\014GetIa" - + "mPolicy\022\".google.iam.v1.GetIamPolicyRequ" - + "est\032\025.google.iam.v1.Policy\"*\332A\010resource\212" - + "\323\344\223\002\031\022\027\n\010resource\022\013{bucket=**}\022|\n\014SetIam" - + "Policy\022\".google.iam.v1.SetIamPolicyReque" - + "st\032\025.google.iam.v1.Policy\"1\332A\017resource,p" - + "olicy\212\323\344\223\002\031\022\027\n\010resource\022\013{bucket=**}\022\226\002\n" - + "\022TestIamPermissions\022(.google.iam.v1.Test" - + "IamPermissionsRequest\032).google.iam.v1.Te" - + "stIamPermissionsResponse\"\252\001\332A\024resource,p" - + "ermissions\212\323\344\223\002\214\001\022\027\n\010resource\022\013{bucket=*" - + "*}\0224\n\010resource\022({bucket=projects/*/bucke" - + "ts/*}/objects/**\022;\n\010resource\022/{bucket=pr" - + "ojects/*/buckets/*}/managedFolders/**\022\212\001" - + "\n\014UpdateBucket\022&.google.storage.v2.Updat" - + "eBucketRequest\032\031.google.storage.v2.Bucke" - + "t\"7\332A\022bucket,update_mask\212\323\344\223\002\034\022\032\n\013bucket" - + ".name\022\013{bucket=**}\022~\n\rComposeObject\022\'.go" - + "ogle.storage.v2.ComposeObjectRequest\032\031.g" - + "oogle.storage.v2.Object\")\212\323\344\223\002#\022!\n\022desti" - + "nation.bucket\022\013{bucket=**}\022\230\001\n\014DeleteObj" - + "ect\022&.google.storage.v2.DeleteObjectRequ" - + "est\032\026.google.protobuf.Empty\"H\332A\rbucket,o" - + "bject\332A\030bucket,object,generation\212\323\344\223\002\027\022\025" - + "\n\006bucket\022\013{bucket=**}\022\215\001\n\rRestoreObject\022" - + "\'.google.storage.v2.RestoreObjectRequest" - + "\032\031.google.storage.v2.Object\"8\332A\030bucket,o" - + "bject,generation\212\323\344\223\002\027\022\025\n\006bucket\022\013{bucke" - + "t=**}\022\272\001\n\024CancelResumableWrite\022..google." - + "storage.v2.CancelResumableWriteRequest\032/" - + ".google.storage.v2.CancelResumableWriteR" - + "esponse\"A\332A\tupload_id\212\323\344\223\002/\022-\n\tupload_id" - + "\022 {bucket=projects/*/buckets/*}/**\022\225\001\n\tG" - + "etObject\022#.google.storage.v2.GetObjectRe" - + "quest\032\031.google.storage.v2.Object\"H\332A\rbuc" - + "ket,object\332A\030bucket,object,generation\212\323\344" - + "\223\002\027\022\025\n\006bucket\022\013{bucket=**}\022\245\001\n\nReadObjec" - + "t\022$.google.storage.v2.ReadObjectRequest\032" - + "%.google.storage.v2.ReadObjectResponse\"H" - + "\332A\rbucket,object\332A\030bucket,object,generat" - + "ion\212\323\344\223\002\027\022\025\n\006bucket\022\013{bucket=**}0\001\022\214\001\n\014U" - + "pdateObject\022&.google.storage.v2.UpdateOb" - + "jectRequest\032\031.google.storage.v2.Object\"9" - + "\332A\022object,update_mask\212\323\344\223\002\036\022\034\n\robject.bu" - + "cket\022\013{bucket=**}\022`\n\013WriteObject\022%.googl" - + "e.storage.v2.WriteObjectRequest\032&.google" - + ".storage.v2.WriteObjectResponse\"\000(\001\022n\n\017B" - + "idiWriteObject\022).google.storage.v2.BidiW" - + "riteObjectRequest\032*.google.storage.v2.Bi" - + "diWriteObjectResponse\"\000(\0010\001\022\204\001\n\013ListObje" - + "cts\022%.google.storage.v2.ListObjectsReque" - + "st\032&.google.storage.v2.ListObjectsRespon" - + "se\"&\332A\006parent\212\323\344\223\002\027\022\025\n\006parent\022\013{bucket=*" - + "*}\022\230\001\n\rRewriteObject\022\'.google.storage.v2" - + ".RewriteObjectRequest\032\".google.storage.v" - + "2.RewriteResponse\":\212\323\344\223\0024\022\017\n\rsource_buck" - + "et\022!\n\022destination_bucket\022\013{bucket=**}\022\256\001" - + "\n\023StartResumableWrite\022-.google.storage.v" - + "2.StartResumableWriteRequest\032..google.st" - + "orage.v2.StartResumableWriteResponse\"8\212\323" - + "\344\223\0022\0220\n!write_object_spec.resource.bucke" - + "t\022\013{bucket=**}\022\256\001\n\020QueryWriteStatus\022*.go" - + "ogle.storage.v2.QueryWriteStatusRequest\032" - + "+.google.storage.v2.QueryWriteStatusResp" - + "onse\"A\332A\tupload_id\212\323\344\223\002/\022-\n\tupload_id\022 {" - + "bucket=projects/*/buckets/*}/**\032\247\002\312A\026sto" - + "rage.googleapis.com\322A\212\002https://www.googl" - + "eapis.com/auth/cloud-platform,https://ww" - + "w.googleapis.com/auth/cloud-platform.rea" - + "d-only,https://www.googleapis.com/auth/d" - + "evstorage.full_control,https://www.googl" - + "eapis.com/auth/devstorage.read_only,http" - + "s://www.googleapis.com/auth/devstorage.r" - + "ead_writeB\342\001\n\025com.google.storage.v2B\014Sto" - + "rageProtoP\001Z>cloud.google.com/go/storage" - + "/internal/apiv2/storagepb;storagepb\352Ax\n!" - + "cloudkms.googleapis.com/CryptoKey\022Sproje" - + "cts/{project}/locations/{location}/keyRi" - + "ngs/{key_ring}/cryptoKeys/{crypto_key}b\006" - + "proto3" + + ".storage.v2.Object\"\367\005\n\021MoveObjectRequest" + + "\0225\n\006bucket\030\001 \001(\tB%\340A\002\372A\037\n\035storage.google" + + "apis.com/Bucket\022\032\n\rsource_object\030\002 \001(\tB\003" + + "\340A\002\022\037\n\022destination_object\030\003 \001(\tB\003\340A\002\022,\n\032" + + "if_source_generation_match\030\004 \001(\003B\003\340A\001H\000\210" + + "\001\001\0220\n\036if_source_generation_not_match\030\005 \001" + + "(\003B\003\340A\001H\001\210\001\001\0220\n\036if_source_metageneration" + + "_match\030\006 \001(\003B\003\340A\001H\002\210\001\001\0224\n\"if_source_meta" + + "generation_not_match\030\007 \001(\003B\003\340A\001H\003\210\001\001\022%\n\023" + + "if_generation_match\030\010 \001(\003B\003\340A\001H\004\210\001\001\022)\n\027i" + + "f_generation_not_match\030\t \001(\003B\003\340A\001H\005\210\001\001\022)" + + "\n\027if_metageneration_match\030\n \001(\003B\003\340A\001H\006\210\001" + + "\001\022-\n\033if_metageneration_not_match\030\013 \001(\003B\003" + + "\340A\001H\007\210\001\001B\035\n\033_if_source_generation_matchB" + + "!\n\037_if_source_generation_not_matchB!\n\037_i" + + "f_source_metageneration_matchB%\n#_if_sou" + + "rce_metageneration_not_matchB\026\n\024_if_gene" + + "ration_matchB\032\n\030_if_generation_not_match" + + "B\032\n\030_if_metageneration_matchB\036\n\034_if_meta" + + "generation_not_match\"\362\001\n\032StartResumableW" + + "riteRequest\022B\n\021write_object_spec\030\001 \001(\0132\"" + + ".google.storage.v2.WriteObjectSpecB\003\340A\002\022" + + "R\n\034common_object_request_params\030\003 \001(\0132,." + + "google.storage.v2.CommonObjectRequestPar" + + "ams\022<\n\020object_checksums\030\005 \001(\0132\".google.s" + + "torage.v2.ObjectChecksums\"0\n\033StartResuma" + + "bleWriteResponse\022\021\n\tupload_id\030\001 \001(\t\"\357\003\n\023" + + "UpdateObjectRequest\022.\n\006object\030\001 \001(\0132\031.go" + + "ogle.storage.v2.ObjectB\003\340A\002\022 \n\023if_genera" + + "tion_match\030\002 \001(\003H\000\210\001\001\022$\n\027if_generation_n" + + "ot_match\030\003 \001(\003H\001\210\001\001\022$\n\027if_metageneration" + + "_match\030\004 \001(\003H\002\210\001\001\022(\n\033if_metageneration_n" + + "ot_match\030\005 \001(\003H\003\210\001\001\022\026\n\016predefined_acl\030\n " + + "\001(\t\0224\n\013update_mask\030\007 \001(\0132\032.google.protob" + + "uf.FieldMaskB\003\340A\002\022R\n\034common_object_reque" + + "st_params\030\010 \001(\0132,.google.storage.v2.Comm" + + "onObjectRequestParamsB\026\n\024_if_generation_" + + "matchB\032\n\030_if_generation_not_matchB\032\n\030_if" + + "_metageneration_matchB\036\n\034_if_metagenerat" + + "ion_not_match\"|\n\031CommonObjectRequestPara" + + "ms\022\034\n\024encryption_algorithm\030\001 \001(\t\022\034\n\024encr" + + "yption_key_bytes\030\004 \001(\014\022#\n\033encryption_key" + + "_sha256_bytes\030\005 \001(\014\"\312\005\n\020ServiceConstants" + + "\"\265\005\n\006Values\022\026\n\022VALUES_UNSPECIFIED\020\000\022\033\n\024M" + + "AX_READ_CHUNK_BYTES\020\200\200\200\001\022\034\n\025MAX_WRITE_CH" + + "UNK_BYTES\020\200\200\200\001\022\031\n\022MAX_OBJECT_SIZE_MB\020\200\200\300" + + "\002\022)\n$MAX_CUSTOM_METADATA_FIELD_NAME_BYTE" + + "S\020\200\010\022*\n%MAX_CUSTOM_METADATA_FIELD_VALUE_" + + "BYTES\020\200 \022)\n$MAX_CUSTOM_METADATA_TOTAL_SI" + + "ZE_BYTES\020\200@\022*\n$MAX_BUCKET_METADATA_TOTAL" + + "_SIZE_BYTES\020\200\240\001\022\'\n#MAX_NOTIFICATION_CONF" + + "IGS_PER_BUCKET\020d\022\"\n\036MAX_LIFECYCLE_RULES_" + + "PER_BUCKET\020d\022&\n\"MAX_NOTIFICATION_CUSTOM_" + + "ATTRIBUTES\020\005\0221\n,MAX_NOTIFICATION_CUSTOM_" + + "ATTRIBUTE_KEY_LENGTH\020\200\002\0223\n.MAX_NOTIFICAT" + + "ION_CUSTOM_ATTRIBUTE_VALUE_LENGTH\020\200\010\022\034\n\030" + + "MAX_LABELS_ENTRIES_COUNT\020@\022\037\n\033MAX_LABELS" + + "_KEY_VALUE_LENGTH\020?\022\037\n\032MAX_LABELS_KEY_VA" + + "LUE_BYTES\020\200\001\022.\n)MAX_OBJECT_IDS_PER_DELET" + + "E_OBJECTS_REQUEST\020\350\007\022\036\n\032SPLIT_TOKEN_MAX_" + + "VALID_DAYS\020\016\032\002\020\001\"\243\034\n\006Bucket\022\021\n\004name\030\001 \001(" + + "\tB\003\340A\005\022\026\n\tbucket_id\030\002 \001(\tB\003\340A\003\022\014\n\004etag\030\035" + + " \001(\t\022D\n\007project\030\003 \001(\tB3\340A\005\372A-\n+cloudreso" + + "urcemanager.googleapis.com/Project\022\033\n\016me" + + "tageneration\030\004 \001(\003B\003\340A\003\022\025\n\010location\030\005 \001(" + + "\tB\003\340A\005\022\032\n\rlocation_type\030\006 \001(\tB\003\340A\003\022\025\n\rst" + + "orage_class\030\007 \001(\t\022\013\n\003rpo\030\033 \001(\t\0223\n\003acl\030\010 " + + "\003(\0132&.google.storage.v2.BucketAccessCont" + + "rol\022B\n\022default_object_acl\030\t \003(\0132&.google" + + ".storage.v2.ObjectAccessControl\0226\n\tlifec" + + "ycle\030\n \001(\0132#.google.storage.v2.Bucket.Li" + + "fecycle\0224\n\013create_time\030\013 \001(\0132\032.google.pr" + + "otobuf.TimestampB\003\340A\003\022,\n\004cors\030\014 \003(\0132\036.go" + + "ogle.storage.v2.Bucket.Cors\0224\n\013update_ti" + + "me\030\r \001(\0132\032.google.protobuf.TimestampB\003\340A" + + "\003\022 \n\030default_event_based_hold\030\016 \001(\010\0225\n\006l" + + "abels\030\017 \003(\0132%.google.storage.v2.Bucket.L" + + "abelsEntry\0222\n\007website\030\020 \001(\0132!.google.sto" + + "rage.v2.Bucket.Website\0228\n\nversioning\030\021 \001" + + "(\0132$.google.storage.v2.Bucket.Versioning" + + "\0222\n\007logging\030\022 \001(\0132!.google.storage.v2.Bu" + + "cket.Logging\022,\n\005owner\030\023 \001(\0132\030.google.sto" + + "rage.v2.OwnerB\003\340A\003\0228\n\nencryption\030\024 \001(\0132$" + + ".google.storage.v2.Bucket.Encryption\0222\n\007" + + "billing\030\025 \001(\0132!.google.storage.v2.Bucket" + + ".Billing\022C\n\020retention_policy\030\026 \001(\0132).goo" + + "gle.storage.v2.Bucket.RetentionPolicy\0227\n" + + "\niam_config\030\027 \001(\0132#.google.storage.v2.Bu" + + "cket.IamConfig\022\025\n\rsatisfies_pzs\030\031 \001(\010\022P\n" + + "\027custom_placement_config\030\032 \001(\0132/.google." + + "storage.v2.Bucket.CustomPlacementConfig\022" + + "6\n\tautoclass\030\034 \001(\0132#.google.storage.v2.B" + + "ucket.Autoclass\022T\n\026hierarchical_namespac" + + "e\030 \001(\0132/.google.storage.v2.Bucket.Hiera" + + "rchicalNamespaceB\003\340A\001\022K\n\022soft_delete_pol" + + "icy\030\037 \001(\0132*.google.storage.v2.Bucket.Sof" + + "tDeletePolicyB\003\340A\001\032!\n\007Billing\022\026\n\016request" + + "er_pays\030\001 \001(\010\032X\n\004Cors\022\016\n\006origin\030\001 \003(\t\022\016\n" + + "\006method\030\002 \003(\t\022\027\n\017response_header\030\003 \003(\t\022\027" + + "\n\017max_age_seconds\030\004 \001(\005\032M\n\nEncryption\022?\n" + + "\017default_kms_key\030\001 \001(\tB&\372A#\n!cloudkms.go" + + "ogleapis.com/CryptoKey\032\354\001\n\tIamConfig\022a\n\033" + + "uniform_bucket_level_access\030\001 \001(\0132<.goog" + + "le.storage.v2.Bucket.IamConfig.UniformBu" + + "cketLevelAccess\022 \n\030public_access_prevent" + + "ion\030\003 \001(\t\032Z\n\030UniformBucketLevelAccess\022\017\n" + + "\007enabled\030\001 \001(\010\022-\n\tlock_time\030\002 \001(\0132\032.goog" + + "le.protobuf.Timestamp\032\363\005\n\tLifecycle\0226\n\004r" + + "ule\030\001 \003(\0132(.google.storage.v2.Bucket.Lif" + + "ecycle.Rule\032\255\005\n\004Rule\022?\n\006action\030\001 \001(\0132/.g" + + "oogle.storage.v2.Bucket.Lifecycle.Rule.A" + + "ction\022E\n\tcondition\030\002 \001(\01322.google.storag" + + "e.v2.Bucket.Lifecycle.Rule.Condition\032-\n\006" + + "Action\022\014\n\004type\030\001 \001(\t\022\025\n\rstorage_class\030\002 " + + "\001(\t\032\355\003\n\tCondition\022\025\n\010age_days\030\001 \001(\005H\000\210\001\001" + + "\022)\n\016created_before\030\002 \001(\0132\021.google.type.D" + + "ate\022\024\n\007is_live\030\003 \001(\010H\001\210\001\001\022\037\n\022num_newer_v" + + "ersions\030\004 \001(\005H\002\210\001\001\022\035\n\025matches_storage_cl" + + "ass\030\005 \003(\t\022#\n\026days_since_custom_time\030\007 \001(" + + "\005H\003\210\001\001\022-\n\022custom_time_before\030\010 \001(\0132\021.goo" + + "gle.type.Date\022\'\n\032days_since_noncurrent_t" + + "ime\030\t \001(\005H\004\210\001\001\0221\n\026noncurrent_time_before" + + "\030\n \001(\0132\021.google.type.Date\022\026\n\016matches_pre" + + "fix\030\013 \003(\t\022\026\n\016matches_suffix\030\014 \003(\tB\013\n\t_ag" + + "e_daysB\n\n\010_is_liveB\025\n\023_num_newer_version" + + "sB\031\n\027_days_since_custom_timeB\035\n\033_days_si" + + "nce_noncurrent_time\0328\n\007Logging\022\022\n\nlog_bu" + + "cket\030\001 \001(\t\022\031\n\021log_object_prefix\030\002 \001(\t\032\217\001" + + "\n\017RetentionPolicy\0222\n\016effective_time\030\001 \001(" + + "\0132\032.google.protobuf.Timestamp\022\021\n\tis_lock" + + "ed\030\002 \001(\010\0225\n\022retention_duration\030\004 \001(\0132\031.g" + + "oogle.protobuf.Duration\032\261\001\n\020SoftDeletePo" + + "licy\022:\n\022retention_duration\030\001 \001(\0132\031.googl" + + "e.protobuf.DurationH\000\210\001\001\0227\n\016effective_ti" + + "me\030\002 \001(\0132\032.google.protobuf.TimestampH\001\210\001" + + "\001B\025\n\023_retention_durationB\021\n\017_effective_t" + + "ime\032\035\n\nVersioning\022\017\n\007enabled\030\001 \001(\010\032;\n\007We" + + "bsite\022\030\n\020main_page_suffix\030\001 \001(\t\022\026\n\016not_f" + + "ound_page\030\002 \001(\t\032/\n\025CustomPlacementConfig" + + "\022\026\n\016data_locations\030\001 \003(\t\032\213\002\n\tAutoclass\022\017" + + "\n\007enabled\030\001 \001(\010\0224\n\013toggle_time\030\002 \001(\0132\032.g" + + "oogle.protobuf.TimestampB\003\340A\003\022#\n\026termina" + + "l_storage_class\030\003 \001(\tH\000\210\001\001\022P\n\"terminal_s" + + "torage_class_update_time\030\004 \001(\0132\032.google." + + "protobuf.TimestampB\003\340A\003H\001\210\001\001B\031\n\027_termina" + + "l_storage_classB%\n#_terminal_storage_cla" + + "ss_update_time\032-\n\025HierarchicalNamespace\022" + + "\024\n\007enabled\030\001 \001(\010B\003\340A\001\032-\n\013LabelsEntry\022\013\n\003" + + "key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001:X\352AU\n\035stora" + + "ge.googleapis.com/Bucket\022#projects/{proj" + + "ect}/buckets/{bucket}*\007buckets2\006bucket\"\316" + + "\001\n\023BucketAccessControl\022\014\n\004role\030\001 \001(\t\022\n\n\002" + + "id\030\002 \001(\t\022\016\n\006entity\030\003 \001(\t\022\027\n\nentity_alt\030\t" + + " \001(\tB\003\340A\003\022\021\n\tentity_id\030\004 \001(\t\022\014\n\004etag\030\010 \001" + + "(\t\022\r\n\005email\030\005 \001(\t\022\016\n\006domain\030\006 \001(\t\0224\n\014pro" + + "ject_team\030\007 \001(\0132\036.google.storage.v2.Proj" + + "ectTeam\"I\n\017ChecksummedData\022\026\n\007content\030\001 " + + "\001(\014B\005\010\001\340A\001\022\023\n\006crc32c\030\002 \001(\007H\000\210\001\001B\t\n\007_crc3" + + "2c\"C\n\017ObjectChecksums\022\023\n\006crc32c\030\001 \001(\007H\000\210" + + "\001\001\022\020\n\010md5_hash\030\002 \001(\014B\t\n\007_crc32c\"L\n\022Custo" + + "merEncryption\022\034\n\024encryption_algorithm\030\001 " + + "\001(\t\022\030\n\020key_sha256_bytes\030\003 \001(\014\"\227\013\n\006Object" + + "\022\021\n\004name\030\001 \001(\tB\003\340A\005\0225\n\006bucket\030\002 \001(\tB%\340A\005" + + "\372A\037\n\035storage.googleapis.com/Bucket\022\014\n\004et" + + "ag\030\033 \001(\t\022\027\n\ngeneration\030\003 \001(\003B\003\340A\005\022\037\n\rres" + + "tore_token\030# \001(\tB\003\340A\003H\000\210\001\001\022\033\n\016metagenera" + + "tion\030\004 \001(\003B\003\340A\003\022\025\n\rstorage_class\030\005 \001(\t\022\021" + + "\n\004size\030\006 \001(\003B\003\340A\003\022\030\n\020content_encoding\030\007 " + + "\001(\t\022\033\n\023content_disposition\030\010 \001(\t\022\025\n\rcach" + + "e_control\030\t \001(\t\0223\n\003acl\030\n \003(\0132&.google.st" + + "orage.v2.ObjectAccessControl\022\030\n\020content_" + + "language\030\013 \001(\t\0224\n\013delete_time\030\014 \001(\0132\032.go" + + "ogle.protobuf.TimestampB\003\340A\003\0226\n\rfinalize" + + "_time\030$ \001(\0132\032.google.protobuf.TimestampB" + + "\003\340A\003\022\024\n\014content_type\030\r \001(\t\0224\n\013create_tim" + + "e\030\016 \001(\0132\032.google.protobuf.TimestampB\003\340A\003" + + "\022\034\n\017component_count\030\017 \001(\005B\003\340A\003\022:\n\tchecks" + + "ums\030\020 \001(\0132\".google.storage.v2.ObjectChec" + + "ksumsB\003\340A\003\0224\n\013update_time\030\021 \001(\0132\032.google" + + ".protobuf.TimestampB\003\340A\003\0227\n\007kms_key\030\022 \001(" + + "\tB&\372A#\n!cloudkms.googleapis.com/CryptoKe" + + "y\022B\n\031update_storage_class_time\030\023 \001(\0132\032.g", + "oogle.protobuf.TimestampB\003\340A\003\022\026\n\016tempora" + + "ry_hold\030\024 \001(\010\0229\n\025retention_expire_time\030\025" + + " \001(\0132\032.google.protobuf.Timestamp\0229\n\010meta" + + "data\030\026 \003(\0132\'.google.storage.v2.Object.Me" + + "tadataEntry\022\035\n\020event_based_hold\030\027 \001(\010H\001\210" + + "\001\001\022,\n\005owner\030\030 \001(\0132\030.google.storage.v2.Ow" + + "nerB\003\340A\003\022B\n\023customer_encryption\030\031 \001(\0132%." + + "google.storage.v2.CustomerEncryption\022/\n\013" + + "custom_time\030\032 \001(\0132\032.google.protobuf.Time" + + "stamp\022>\n\020soft_delete_time\030\034 \001(\0132\032.google" + + ".protobuf.TimestampB\003\340A\003H\002\210\001\001\022>\n\020hard_de" + + "lete_time\030\035 \001(\0132\032.google.protobuf.Timest" + + "ampB\003\340A\003H\003\210\001\001\032/\n\rMetadataEntry\022\013\n\003key\030\001 " + + "\001(\t\022\r\n\005value\030\002 \001(\t:\0028\001B\020\n\016_restore_token" + + "B\023\n\021_event_based_holdB\023\n\021_soft_delete_ti" + + "meB\023\n\021_hard_delete_time\"\316\001\n\023ObjectAccess" + + "Control\022\014\n\004role\030\001 \001(\t\022\n\n\002id\030\002 \001(\t\022\016\n\006ent" + + "ity\030\003 \001(\t\022\027\n\nentity_alt\030\t \001(\tB\003\340A\003\022\021\n\ten" + + "tity_id\030\004 \001(\t\022\014\n\004etag\030\010 \001(\t\022\r\n\005email\030\005 \001" + + "(\t\022\016\n\006domain\030\006 \001(\t\0224\n\014project_team\030\007 \001(\013" + + "2\036.google.storage.v2.ProjectTeam\"l\n\023List" + + "ObjectsResponse\022*\n\007objects\030\001 \003(\0132\031.googl" + + "e.storage.v2.Object\022\020\n\010prefixes\030\002 \003(\t\022\027\n" + + "\017next_page_token\030\003 \001(\t\"3\n\013ProjectTeam\022\026\n" + + "\016project_number\030\001 \001(\t\022\014\n\004team\030\002 \001(\t\"*\n\005O" + + "wner\022\016\n\006entity\030\001 \001(\t\022\021\n\tentity_id\030\002 \001(\t\"" + + "C\n\014ContentRange\022\r\n\005start\030\001 \001(\003\022\013\n\003end\030\002 " + + "\001(\003\022\027\n\017complete_length\030\003 \001(\0032\245\035\n\007Storage" + + "\022r\n\014DeleteBucket\022&.google.storage.v2.Del" + + "eteBucketRequest\032\026.google.protobuf.Empty" + + "\"\"\332A\004name\212\323\344\223\002\025\022\023\n\004name\022\013{bucket=**}\022o\n\t" + + "GetBucket\022#.google.storage.v2.GetBucketR" + + "equest\032\031.google.storage.v2.Bucket\"\"\332A\004na" + + "me\212\323\344\223\002\025\022\023\n\004name\022\013{bucket=**}\022\253\001\n\014Create" + + "Bucket\022&.google.storage.v2.CreateBucketR" + + "equest\032\031.google.storage.v2.Bucket\"X\332A\027pa" + + "rent,bucket,bucket_id\212\323\344\223\0028\022\026\n\006parent\022\014{" + + "project=**}\022\036\n\016bucket.project\022\014{project=" + + "**}\022\205\001\n\013ListBuckets\022%.google.storage.v2." + + "ListBucketsRequest\032&.google.storage.v2.L" + + "istBucketsResponse\"\'\332A\006parent\212\323\344\223\002\030\022\026\n\006p" + + "arent\022\014{project=**}\022\223\001\n\031LockBucketRetent" + + "ionPolicy\0223.google.storage.v2.LockBucket" + + "RetentionPolicyRequest\032\031.google.storage." + + "v2.Bucket\"&\332A\006bucket\212\323\344\223\002\027\022\025\n\006bucket\022\013{b" + + "ucket=**}\022u\n\014GetIamPolicy\022\".google.iam.v" + + "1.GetIamPolicyRequest\032\025.google.iam.v1.Po" + + "licy\"*\332A\010resource\212\323\344\223\002\031\022\027\n\010resource\022\013{bu" + + "cket=**}\022|\n\014SetIamPolicy\022\".google.iam.v1" + + ".SetIamPolicyRequest\032\025.google.iam.v1.Pol" + + "icy\"1\332A\017resource,policy\212\323\344\223\002\031\022\027\n\010resourc" + + "e\022\013{bucket=**}\022\226\002\n\022TestIamPermissions\022(." + + "google.iam.v1.TestIamPermissionsRequest\032" + + ").google.iam.v1.TestIamPermissionsRespon" + + "se\"\252\001\332A\024resource,permissions\212\323\344\223\002\214\001\022\027\n\010r" + + "esource\022\013{bucket=**}\0224\n\010resource\022({bucke" + + "t=projects/*/buckets/*}/objects/**\022;\n\010re" + + "source\022/{bucket=projects/*/buckets/*}/ma" + + "nagedFolders/**\022\212\001\n\014UpdateBucket\022&.googl" + + "e.storage.v2.UpdateBucketRequest\032\031.googl" + + "e.storage.v2.Bucket\"7\332A\022bucket,update_ma" + + "sk\212\323\344\223\002\034\022\032\n\013bucket.name\022\013{bucket=**}\022~\n\r" + + "ComposeObject\022\'.google.storage.v2.Compos" + + "eObjectRequest\032\031.google.storage.v2.Objec" + + "t\")\212\323\344\223\002#\022!\n\022destination.bucket\022\013{bucket" + + "=**}\022\230\001\n\014DeleteObject\022&.google.storage.v" + + "2.DeleteObjectRequest\032\026.google.protobuf." + + "Empty\"H\332A\rbucket,object\332A\030bucket,object," + + "generation\212\323\344\223\002\027\022\025\n\006bucket\022\013{bucket=**}\022" + + "\215\001\n\rRestoreObject\022\'.google.storage.v2.Re" + + "storeObjectRequest\032\031.google.storage.v2.O" + + "bject\"8\332A\030bucket,object,generation\212\323\344\223\002\027" + + "\022\025\n\006bucket\022\013{bucket=**}\022\272\001\n\024CancelResuma" + + "bleWrite\022..google.storage.v2.CancelResum" + + "ableWriteRequest\032/.google.storage.v2.Can" + + "celResumableWriteResponse\"A\332A\tupload_id\212" + + "\323\344\223\002/\022-\n\tupload_id\022 {bucket=projects/*/b" + + "uckets/*}/**\022\225\001\n\tGetObject\022#.google.stor" + + "age.v2.GetObjectRequest\032\031.google.storage" + + ".v2.Object\"H\332A\rbucket,object\332A\030bucket,ob" + + "ject,generation\212\323\344\223\002\027\022\025\n\006bucket\022\013{bucket" + + "=**}\022\245\001\n\nReadObject\022$.google.storage.v2." + + "ReadObjectRequest\032%.google.storage.v2.Re" + + "adObjectResponse\"H\332A\rbucket,object\332A\030buc" + + "ket,object,generation\212\323\344\223\002\027\022\025\n\006bucket\022\013{" + + "bucket=**}0\001\022\214\001\n\014UpdateObject\022&.google.s" + + "torage.v2.UpdateObjectRequest\032\031.google.s" + + "torage.v2.Object\"9\332A\022object,update_mask\212" + + "\323\344\223\002\036\022\034\n\robject.bucket\022\013{bucket=**}\022`\n\013W" + + "riteObject\022%.google.storage.v2.WriteObje" + + "ctRequest\032&.google.storage.v2.WriteObjec" + + "tResponse\"\000(\001\022n\n\017BidiWriteObject\022).googl" + + "e.storage.v2.BidiWriteObjectRequest\032*.go" + + "ogle.storage.v2.BidiWriteObjectResponse\"" + + "\000(\0010\001\022\204\001\n\013ListObjects\022%.google.storage.v" + + "2.ListObjectsRequest\032&.google.storage.v2" + + ".ListObjectsResponse\"&\332A\006parent\212\323\344\223\002\027\022\025\n" + + "\006parent\022\013{bucket=**}\022\230\001\n\rRewriteObject\022\'" + + ".google.storage.v2.RewriteObjectRequest\032" + + "\".google.storage.v2.RewriteResponse\":\212\323\344" + + "\223\0024\022\017\n\rsource_bucket\022!\n\022destination_buck" + + "et\022\013{bucket=**}\022\256\001\n\023StartResumableWrite\022" + + "-.google.storage.v2.StartResumableWriteR" + + "equest\032..google.storage.v2.StartResumabl" + + "eWriteResponse\"8\212\323\344\223\0022\0220\n!write_object_s" + + "pec.resource.bucket\022\013{bucket=**}\022\256\001\n\020Que" + + "ryWriteStatus\022*.google.storage.v2.QueryW" + + "riteStatusRequest\032+.google.storage.v2.Qu" + + "eryWriteStatusResponse\"A\332A\tupload_id\212\323\344\223" + + "\002/\022-\n\tupload_id\022 {bucket=projects/*/buck" + + "ets/*}/**\022\226\001\n\nMoveObject\022$.google.storag" + + "e.v2.MoveObjectRequest\032\031.google.storage." + + "v2.Object\"G\332A\'bucket,source_object,desti" + + "nation_object\212\323\344\223\002\027\022\025\n\006bucket\022\013{bucket=*" + + "*}\032\247\002\312A\026storage.googleapis.com\322A\212\002https:" + + "//www.googleapis.com/auth/cloud-platform" + + ",https://www.googleapis.com/auth/cloud-p" + + "latform.read-only,https://www.googleapis" + + ".com/auth/devstorage.full_control,https:" + + "//www.googleapis.com/auth/devstorage.rea" + + "d_only,https://www.googleapis.com/auth/d" + + "evstorage.read_writeB\342\001\n\025com.google.stor" + + "age.v2B\014StorageProtoP\001Z>cloud.google.com" + + "/go/storage/internal/apiv2/storagepb;sto" + + "ragepb\352Ax\n!cloudkms.googleapis.com/Crypt" + + "oKey\022Sprojects/{project}/locations/{loca" + + "tion}/keyRings/{key_ring}/cryptoKeys/{cr" + + "ypto_key}b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -1128,8 +1156,26 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "TotalBytesRewritten", "ObjectSize", "Done", "RewriteToken", "Resource", }); - internal_static_google_storage_v2_StartResumableWriteRequest_descriptor = + internal_static_google_storage_v2_MoveObjectRequest_descriptor = getDescriptor().getMessageTypes().get(25); + internal_static_google_storage_v2_MoveObjectRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_storage_v2_MoveObjectRequest_descriptor, + new java.lang.String[] { + "Bucket", + "SourceObject", + "DestinationObject", + "IfSourceGenerationMatch", + "IfSourceGenerationNotMatch", + "IfSourceMetagenerationMatch", + "IfSourceMetagenerationNotMatch", + "IfGenerationMatch", + "IfGenerationNotMatch", + "IfMetagenerationMatch", + "IfMetagenerationNotMatch", + }); + internal_static_google_storage_v2_StartResumableWriteRequest_descriptor = + getDescriptor().getMessageTypes().get(26); internal_static_google_storage_v2_StartResumableWriteRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_StartResumableWriteRequest_descriptor, @@ -1137,7 +1183,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "WriteObjectSpec", "CommonObjectRequestParams", "ObjectChecksums", }); internal_static_google_storage_v2_StartResumableWriteResponse_descriptor = - getDescriptor().getMessageTypes().get(26); + getDescriptor().getMessageTypes().get(27); internal_static_google_storage_v2_StartResumableWriteResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_StartResumableWriteResponse_descriptor, @@ -1145,7 +1191,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "UploadId", }); internal_static_google_storage_v2_UpdateObjectRequest_descriptor = - getDescriptor().getMessageTypes().get(27); + getDescriptor().getMessageTypes().get(28); internal_static_google_storage_v2_UpdateObjectRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_UpdateObjectRequest_descriptor, @@ -1160,7 +1206,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CommonObjectRequestParams", }); internal_static_google_storage_v2_CommonObjectRequestParams_descriptor = - getDescriptor().getMessageTypes().get(28); + getDescriptor().getMessageTypes().get(29); internal_static_google_storage_v2_CommonObjectRequestParams_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_CommonObjectRequestParams_descriptor, @@ -1168,12 +1214,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "EncryptionAlgorithm", "EncryptionKeyBytes", "EncryptionKeySha256Bytes", }); internal_static_google_storage_v2_ServiceConstants_descriptor = - getDescriptor().getMessageTypes().get(29); + getDescriptor().getMessageTypes().get(30); internal_static_google_storage_v2_ServiceConstants_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_ServiceConstants_descriptor, new java.lang.String[] {}); - internal_static_google_storage_v2_Bucket_descriptor = getDescriptor().getMessageTypes().get(30); + internal_static_google_storage_v2_Bucket_descriptor = getDescriptor().getMessageTypes().get(31); internal_static_google_storage_v2_Bucket_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_Bucket_descriptor, @@ -1364,7 +1410,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Key", "Value", }); internal_static_google_storage_v2_BucketAccessControl_descriptor = - getDescriptor().getMessageTypes().get(31); + getDescriptor().getMessageTypes().get(32); internal_static_google_storage_v2_BucketAccessControl_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_BucketAccessControl_descriptor, @@ -1380,7 +1426,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ProjectTeam", }); internal_static_google_storage_v2_ChecksummedData_descriptor = - getDescriptor().getMessageTypes().get(32); + getDescriptor().getMessageTypes().get(33); internal_static_google_storage_v2_ChecksummedData_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_ChecksummedData_descriptor, @@ -1388,7 +1434,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Content", "Crc32C", }); internal_static_google_storage_v2_ObjectChecksums_descriptor = - getDescriptor().getMessageTypes().get(33); + getDescriptor().getMessageTypes().get(34); internal_static_google_storage_v2_ObjectChecksums_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_ObjectChecksums_descriptor, @@ -1396,14 +1442,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Crc32C", "Md5Hash", }); internal_static_google_storage_v2_CustomerEncryption_descriptor = - getDescriptor().getMessageTypes().get(34); + getDescriptor().getMessageTypes().get(35); internal_static_google_storage_v2_CustomerEncryption_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_CustomerEncryption_descriptor, new java.lang.String[] { "EncryptionAlgorithm", "KeySha256Bytes", }); - internal_static_google_storage_v2_Object_descriptor = getDescriptor().getMessageTypes().get(35); + internal_static_google_storage_v2_Object_descriptor = getDescriptor().getMessageTypes().get(36); internal_static_google_storage_v2_Object_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_Object_descriptor, @@ -1422,6 +1468,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Acl", "ContentLanguage", "DeleteTime", + "FinalizeTime", "ContentType", "CreateTime", "ComponentCount", @@ -1448,7 +1495,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Key", "Value", }); internal_static_google_storage_v2_ObjectAccessControl_descriptor = - getDescriptor().getMessageTypes().get(36); + getDescriptor().getMessageTypes().get(37); internal_static_google_storage_v2_ObjectAccessControl_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_ObjectAccessControl_descriptor, @@ -1464,7 +1511,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ProjectTeam", }); internal_static_google_storage_v2_ListObjectsResponse_descriptor = - getDescriptor().getMessageTypes().get(37); + getDescriptor().getMessageTypes().get(38); internal_static_google_storage_v2_ListObjectsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_ListObjectsResponse_descriptor, @@ -1472,14 +1519,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Objects", "Prefixes", "NextPageToken", }); internal_static_google_storage_v2_ProjectTeam_descriptor = - getDescriptor().getMessageTypes().get(38); + getDescriptor().getMessageTypes().get(39); internal_static_google_storage_v2_ProjectTeam_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_ProjectTeam_descriptor, new java.lang.String[] { "ProjectNumber", "Team", }); - internal_static_google_storage_v2_Owner_descriptor = getDescriptor().getMessageTypes().get(39); + internal_static_google_storage_v2_Owner_descriptor = getDescriptor().getMessageTypes().get(40); internal_static_google_storage_v2_Owner_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_Owner_descriptor, @@ -1487,7 +1534,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Entity", "EntityId", }); internal_static_google_storage_v2_ContentRange_descriptor = - getDescriptor().getMessageTypes().get(40); + getDescriptor().getMessageTypes().get(41); internal_static_google_storage_v2_ContentRange_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_storage_v2_ContentRange_descriptor, diff --git a/proto-google-cloud-storage-v2/src/main/proto/google/storage/v2/storage.proto b/proto-google-cloud-storage-v2/src/main/proto/google/storage/v2/storage.proto index c7229d4e96..2671acbc4a 100644 --- a/proto-google-cloud-storage-v2/src/main/proto/google/storage/v2/storage.proto +++ b/proto-google-cloud-storage-v2/src/main/proto/google/storage/v2/storage.proto @@ -379,6 +379,15 @@ service Storage { }; option (google.api.method_signature) = "upload_id"; } + + // Moves the source object to the destination object in the same bucket. + rpc MoveObject(MoveObjectRequest) returns (Object) { + option (google.api.routing) = { + routing_parameters { field: "bucket" path_template: "{bucket=**}" } + }; + option (google.api.method_signature) = + "bucket,source_object,destination_object"; + } } // Request message for DeleteBucket. @@ -990,7 +999,8 @@ message BidiWriteObjectRequest { // Checksums for the complete object. If the checksums computed by the service // don't match the specified checksums the call will fail. May only be - // provided in last request (with finish_write set). + // provided in the first request or the + // last request (with finish_write set). ObjectChecksums object_checksums = 6; // For each BidiWriteObjectRequest where state_lookup is `true` or the client @@ -1299,6 +1309,85 @@ message RewriteResponse { Object resource = 5; } +// Request message for MoveObject. +message MoveObjectRequest { + // Required. Name of the bucket in which the object resides. + string bucket = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { type: "storage.googleapis.com/Bucket" } + ]; + + // Required. Name of the source object. + string source_object = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. Name of the destination object. + string destination_object = 3 [(google.api.field_behavior) = REQUIRED]; + + // Optional. Makes the operation conditional on whether the source object's + // current generation matches the given value. `if_source_generation_match` + // and `if_source_generation_not_match` conditions are mutually exclusive: + // it's an error for both of them to be set in the request. + optional int64 if_source_generation_match = 4 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Makes the operation conditional on whether the source object's + // current generation does not match the given value. + // `if_source_generation_match` and `if_source_generation_not_match` + // conditions are mutually exclusive: it's an error for both of them to be set + // in the request. + optional int64 if_source_generation_not_match = 5 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Makes the operation conditional on whether the source object's + // current metageneration matches the given value. + // `if_source_metageneration_match` and `if_source_metageneration_not_match` + // conditions are mutually exclusive: it's an error for both of them to be set + // in the request. + optional int64 if_source_metageneration_match = 6 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Makes the operation conditional on whether the source object's + // current metageneration does not match the given value. + // `if_source_metageneration_match` and `if_source_metageneration_not_match` + // conditions are mutually exclusive: it's an error for both of them to be set + // in the request. + optional int64 if_source_metageneration_not_match = 7 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Makes the operation conditional on whether the destination + // object's current generation matches the given value. Setting to 0 makes the + // operation succeed only if there are no live versions of the object. + // `if_generation_match` and `if_generation_not_match` conditions are mutually + // exclusive: it's an error for both of them to be set in the request. + optional int64 if_generation_match = 8 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Makes the operation conditional on whether the destination + // object's current generation does not match the given value. If no live + // object exists, the precondition fails. Setting to 0 makes the operation + // succeed only if there is a live version of the object. + // `if_generation_match` and `if_generation_not_match` conditions are mutually + // exclusive: it's an error for both of them to be set in the request. + optional int64 if_generation_not_match = 9 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Makes the operation conditional on whether the destination + // object's current metageneration matches the given value. + // `if_metageneration_match` and `if_metageneration_not_match` conditions are + // mutually exclusive: it's an error for both of them to be set in the + // request. + optional int64 if_metageneration_match = 10 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Makes the operation conditional on whether the destination + // object's current metageneration does not match the given value. + // `if_metageneration_match` and `if_metageneration_not_match` conditions are + // mutually exclusive: it's an error for both of them to be set in the + // request. + optional int64 if_metageneration_not_match = 11 + [(google.api.field_behavior) = OPTIONAL]; +} + // Request message StartResumableWrite. message StartResumableWriteRequest { // Required. The destination bucket, object, and metadata, as well as any @@ -2055,6 +2144,10 @@ message Object { google.protobuf.Timestamp delete_time = 12 [(google.api.field_behavior) = OUTPUT_ONLY]; + // Output only. The time when the object was finalized. + google.protobuf.Timestamp finalize_time = 36 + [(google.api.field_behavior) = OUTPUT_ONLY]; + // Content-Type of the object data, matching // [https://tools.ietf.org/html/rfc7231#section-3.1.1.5][RFC 7231 ยง3.1.1.5]. // If an object is stored without a Content-Type, it is served as