Skip to content

Commit

Permalink
feat: [compute] Update Compute Engine API to revision 20220831 (#729) (
Browse files Browse the repository at this point in the history
…#8401)

* feat: Update Compute Engine API to revision 20220831 (#729)

Source-Link: googleapis/googleapis@63c3007

Source-Link: https://github.com/googleapis/googleapis-gen/commit/b6582231ae7b7f5cd18f7d142c65421773cca5de
Copy-Tag: eyJwIjoiamF2YS1jb21wdXRlLy5Pd2xCb3QueWFtbCIsImgiOiJiNjU4MjIzMWFlN2I3ZjVjZDE4ZjdkMTQyYzY1NDIxNzczY2NhNWRlIn0=

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
  • Loading branch information
gcf-owl-bot[bot] and gcf-owl-bot[bot] authored Sep 20, 2022
1 parent 4fe4dcd commit 25ca88b
Show file tree
Hide file tree
Showing 195 changed files with 74,358 additions and 15,735 deletions.
4 changes: 2 additions & 2 deletions java-compute/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,13 @@ If you are using Maven, add this to your pom.xml file:
If you are using Gradle without BOM, add this to your dependencies:

```Groovy
implementation 'com.google.cloud:google-cloud-compute:1.12.0'
implementation 'com.google.cloud:google-cloud-compute:1.12.1'
```

If you are using SBT, add this to your dependencies:

```Scala
libraryDependencies += "com.google.cloud" % "google-cloud-compute" % "1.12.0"
libraryDependencies += "com.google.cloud" % "google-cloud-compute" % "1.12.1"
```

## Authentication
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -808,6 +808,155 @@ public final UnaryCallable<ListAddressesRequest, AddressList> listCallable() {
return stub.listCallable();
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Sets the labels on an Address. To learn more about labels, read the Labeling Resources
* documentation.
*
* <p>Sample code:
*
* <pre>{@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 (AddressesClient addressesClient = AddressesClient.create()) {
* String project = "project-309310695";
* String region = "region-934795532";
* String resource = "resource-341064690";
* RegionSetLabelsRequest regionSetLabelsRequestResource =
* RegionSetLabelsRequest.newBuilder().build();
* Operation response =
* addressesClient
* .setLabelsAsync(project, region, resource, regionSetLabelsRequestResource)
* .get();
* }
* }</pre>
*
* @param project Project ID for this request.
* @param region The region for this request.
* @param resource Name or id of the resource for this request.
* @param regionSetLabelsRequestResource The body resource for this request
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
public final OperationFuture<Operation, Operation> setLabelsAsync(
String project,
String region,
String resource,
RegionSetLabelsRequest regionSetLabelsRequestResource) {
SetLabelsAddressRequest request =
SetLabelsAddressRequest.newBuilder()
.setProject(project)
.setRegion(region)
.setResource(resource)
.setRegionSetLabelsRequestResource(regionSetLabelsRequestResource)
.build();
return setLabelsAsync(request);
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Sets the labels on an Address. To learn more about labels, read the Labeling Resources
* documentation.
*
* <p>Sample code:
*
* <pre>{@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 (AddressesClient addressesClient = AddressesClient.create()) {
* SetLabelsAddressRequest request =
* SetLabelsAddressRequest.newBuilder()
* .setProject("project-309310695")
* .setRegion("region-934795532")
* .setRegionSetLabelsRequestResource(RegionSetLabelsRequest.newBuilder().build())
* .setRequestId("requestId693933066")
* .setResource("resource-341064690")
* .build();
* Operation response = addressesClient.setLabelsAsync(request).get();
* }
* }</pre>
*
* @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
*/
@BetaApi(
"The surface for long-running operations is not stable yet and may change in the future.")
public final OperationFuture<Operation, Operation> setLabelsAsync(
SetLabelsAddressRequest request) {
return setLabelsOperationCallable().futureCall(request);
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Sets the labels on an Address. To learn more about labels, read the Labeling Resources
* documentation.
*
* <p>Sample code:
*
* <pre>{@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 (AddressesClient addressesClient = AddressesClient.create()) {
* SetLabelsAddressRequest request =
* SetLabelsAddressRequest.newBuilder()
* .setProject("project-309310695")
* .setRegion("region-934795532")
* .setRegionSetLabelsRequestResource(RegionSetLabelsRequest.newBuilder().build())
* .setRequestId("requestId693933066")
* .setResource("resource-341064690")
* .build();
* OperationFuture<Operation, Operation> future =
* addressesClient.setLabelsOperationCallable().futureCall(request);
* // Do something.
* Operation response = future.get();
* }
* }</pre>
*/
public final OperationCallable<SetLabelsAddressRequest, Operation, Operation>
setLabelsOperationCallable() {
return stub.setLabelsOperationCallable();
}

// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
* Sets the labels on an Address. To learn more about labels, read the Labeling Resources
* documentation.
*
* <p>Sample code:
*
* <pre>{@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 (AddressesClient addressesClient = AddressesClient.create()) {
* SetLabelsAddressRequest request =
* SetLabelsAddressRequest.newBuilder()
* .setProject("project-309310695")
* .setRegion("region-934795532")
* .setRegionSetLabelsRequestResource(RegionSetLabelsRequest.newBuilder().build())
* .setRequestId("requestId693933066")
* .setResource("resource-341064690")
* .build();
* ApiFuture<Operation> future = addressesClient.setLabelsCallable().futureCall(request);
* // Do something.
* Operation response = future.get();
* }
* }</pre>
*/
public final UnaryCallable<SetLabelsAddressRequest, Operation> setLabelsCallable() {
return stub.setLabelsCallable();
}

@Override
public final void close() {
stub.close();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,17 @@ public PagedCallSettings<ListAddressesRequest, AddressList, ListPagedResponse> l
return ((AddressesStubSettings) getStubSettings()).listSettings();
}

/** Returns the object with the settings used for calls to setLabels. */
public UnaryCallSettings<SetLabelsAddressRequest, Operation> setLabelsSettings() {
return ((AddressesStubSettings) getStubSettings()).setLabelsSettings();
}

/** Returns the object with the settings used for calls to setLabels. */
public OperationCallSettings<SetLabelsAddressRequest, Operation, Operation>
setLabelsOperationSettings() {
return ((AddressesStubSettings) getStubSettings()).setLabelsOperationSettings();
}

public static final AddressesSettings create(AddressesStubSettings stub) throws IOException {
return new AddressesSettings.Builder(stub.toBuilder()).build();
}
Expand Down Expand Up @@ -248,6 +259,17 @@ public UnaryCallSettings.Builder<InsertAddressRequest, Operation> insertSettings
return getStubSettingsBuilder().listSettings();
}

/** Returns the builder for the settings used for calls to setLabels. */
public UnaryCallSettings.Builder<SetLabelsAddressRequest, Operation> setLabelsSettings() {
return getStubSettingsBuilder().setLabelsSettings();
}

/** Returns the builder for the settings used for calls to setLabels. */
public OperationCallSettings.Builder<SetLabelsAddressRequest, Operation, Operation>
setLabelsOperationSettings() {
return getStubSettingsBuilder().setLabelsOperationSettings();
}

@Override
public AddressesSettings build() throws IOException {
return new AddressesSettings(this);
Expand Down
Loading

0 comments on commit 25ca88b

Please sign in to comment.