Class VmwareEngineClient

  • All Implemented Interfaces:
    com.google.api.gax.core.BackgroundResource, AutoCloseable

    @Generated("by gapic-generator-java")
    public class VmwareEngineClient
    extends Object
    implements com.google.api.gax.core.BackgroundResource
    Service Description: VMwareEngine manages VMware's private clusters in the Cloud.

    This class provides the ability to make remote calls to the backing service through method calls that map to API methods. Sample code to get started:

    
     // 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
       PrivateCloudName name = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
       PrivateCloud response = vmwareEngineClient.getPrivateCloud(name);
     }
     

    Note: close() needs to be called on the VmwareEngineClient object to clean up resources such as threads. In the example above, try-with-resources is used, which automatically calls close().

    The surface of this class includes several types of Java methods for each of the API's methods:

    1. A "flattened" method. With this type of method, the fields of the request type have been converted into function parameters. It may be the case that not all fields are available as parameters, and not every API method will have a flattened method entry point.
    2. A "request object" method. This type of method only takes one parameter, a request object, which must be constructed before the call. Not every API method will have a request object method.
    3. A "callable" method. This type of method takes no parameters and returns an immutable API callable object, which can be used to initiate calls to the service.

    See the individual methods for example code.

    Many parameters require resource names to be formatted in a particular way. To assist with these names, this class includes a format method for each type of name, and additionally a parse method to extract the individual identifiers contained within names that are returned.

    This class can be customized by passing in a custom instance of VmwareEngineSettings to create(). For example:

    To customize credentials:

    
     // 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
     VmwareEngineSettings vmwareEngineSettings =
         VmwareEngineSettings.newBuilder()
             .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
             .build();
     VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create(vmwareEngineSettings);
     

    To customize the endpoint:

    
     // 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
     VmwareEngineSettings vmwareEngineSettings =
         VmwareEngineSettings.newBuilder().setEndpoint(myEndpoint).build();
     VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create(vmwareEngineSettings);
     

    To use REST (HTTP1.1/JSON) transport (instead of gRPC) for sending and receiving requests over the wire:

    
     // 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
     VmwareEngineSettings vmwareEngineSettings = VmwareEngineSettings.newHttpJsonBuilder().build();
     VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create(vmwareEngineSettings);
     

    Please refer to the GitHub repository's samples for more quickstart code snippets.

    • Constructor Detail

      • VmwareEngineClient

        protected VmwareEngineClient​(VmwareEngineSettings settings)
                              throws IOException
        Constructs an instance of VmwareEngineClient, using the given settings. This is protected so that it is easy to make a subclass, but otherwise, the static factory methods should be preferred.
        Throws:
        IOException
    • Method Detail

      • create

        public static final VmwareEngineClient create​(VmwareEngineSettings settings)
                                               throws IOException
        Constructs an instance of VmwareEngineClient, using the given settings. The channels are created based on the settings passed in, or defaults for any settings that are not set.
        Throws:
        IOException
      • create

        public static final VmwareEngineClient create​(VmwareEngineStub stub)
        Constructs an instance of VmwareEngineClient, using the given stub for making calls. This is for advanced usage - prefer using create(VmwareEngineSettings).
      • getOperationsClient

        public final com.google.longrunning.OperationsClient getOperationsClient()
        Returns the OperationsClient that can be used to query the status of a long-running operation returned by another API method call.
      • getHttpJsonOperationsClient

        @BetaApi
        public final com.google.api.gax.httpjson.longrunning.OperationsClient getHttpJsonOperationsClient()
        Returns the OperationsClient that can be used to query the status of a long-running operation returned by another API method call.
      • listPrivateClouds

        public final VmwareEngineClient.ListPrivateCloudsPagedResponse listPrivateClouds​(LocationName parent)
        Lists `PrivateCloud` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           for (PrivateCloud element : vmwareEngineClient.listPrivateClouds(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the private cloud to be queried for clusters. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listPrivateClouds

        public final VmwareEngineClient.ListPrivateCloudsPagedResponse listPrivateClouds​(String parent)
        Lists `PrivateCloud` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           for (PrivateCloud element : vmwareEngineClient.listPrivateClouds(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the private cloud to be queried for clusters. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listPrivateClouds

        public final VmwareEngineClient.ListPrivateCloudsPagedResponse listPrivateClouds​(ListPrivateCloudsRequest request)
        Lists `PrivateCloud` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListPrivateCloudsRequest request =
               ListPrivateCloudsRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           for (PrivateCloud element : vmwareEngineClient.listPrivateClouds(request).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        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
      • listPrivateCloudsPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListPrivateCloudsRequest,​VmwareEngineClient.ListPrivateCloudsPagedResponse> listPrivateCloudsPagedCallable()
        Lists `PrivateCloud` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListPrivateCloudsRequest request =
               ListPrivateCloudsRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           ApiFuture<PrivateCloud> future =
               vmwareEngineClient.listPrivateCloudsPagedCallable().futureCall(request);
           // Do something.
           for (PrivateCloud element : future.get().iterateAll()) {
             // doThingsWith(element);
           }
         }
         
      • listPrivateCloudsCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListPrivateCloudsRequest,​ListPrivateCloudsResponse> listPrivateCloudsCallable()
        Lists `PrivateCloud` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListPrivateCloudsRequest request =
               ListPrivateCloudsRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           while (true) {
             ListPrivateCloudsResponse response =
                 vmwareEngineClient.listPrivateCloudsCallable().call(request);
             for (PrivateCloud element : response.getPrivateCloudsList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • getPrivateCloud

        public final PrivateCloud getPrivateCloud​(PrivateCloudName name)
        Retrieves a `PrivateCloud` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloudName name = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
           PrivateCloud response = vmwareEngineClient.getPrivateCloud(name);
         }
         
        Parameters:
        name - Required. The resource name of the private cloud to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getPrivateCloud

        public final PrivateCloud getPrivateCloud​(String name)
        Retrieves a `PrivateCloud` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString();
           PrivateCloud response = vmwareEngineClient.getPrivateCloud(name);
         }
         
        Parameters:
        name - Required. The resource name of the private cloud to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getPrivateCloud

        public final PrivateCloud getPrivateCloud​(GetPrivateCloudRequest request)
        Retrieves a `PrivateCloud` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetPrivateCloudRequest request =
               GetPrivateCloudRequest.newBuilder()
                   .setName(PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .build();
           PrivateCloud response = vmwareEngineClient.getPrivateCloud(request);
         }
         
        Parameters:
        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
      • getPrivateCloudCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetPrivateCloudRequest,​PrivateCloud> getPrivateCloudCallable()
        Retrieves a `PrivateCloud` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetPrivateCloudRequest request =
               GetPrivateCloudRequest.newBuilder()
                   .setName(PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .build();
           ApiFuture<PrivateCloud> future =
               vmwareEngineClient.getPrivateCloudCallable().futureCall(request);
           // Do something.
           PrivateCloud response = future.get();
         }
         
      • createPrivateCloudAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> createPrivateCloudAsync​(LocationName parent,
                                                                                                                                  PrivateCloud privateCloud,
                                                                                                                                  String privateCloudId)
        Creates a new `PrivateCloud` resource in a given project and location. Private clouds can only be created in zones, regional private clouds are not supported.

        Creating a private cloud also creates a [management cluster](https://cloud.google.com/vmware-engine/docs/concepts-vmware-components) for that private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           PrivateCloud privateCloud = PrivateCloud.newBuilder().build();
           String privateCloudId = "privateCloudId573896493";
           PrivateCloud response =
               vmwareEngineClient.createPrivateCloudAsync(parent, privateCloud, privateCloudId).get();
         }
         
        Parameters:
        parent - Required. The resource name of the location to create the new private cloud in. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a`
        privateCloud - Required. The initial description of the new private cloud.
        privateCloudId - Required. The user-provided identifier of the private cloud to be created. This identifier must be unique among each `PrivateCloud` within the parent and becomes the final token in the name URI. The identifier must meet the following requirements:
        • Only contains 1-63 alphanumeric characters and hyphens
        • Begins with an alphabetical character
        • Ends with a non-hyphen character
        • Not formatted as a UUID
        • Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5)
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createPrivateCloudAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> createPrivateCloudAsync​(String parent,
                                                                                                                                  PrivateCloud privateCloud,
                                                                                                                                  String privateCloudId)
        Creates a new `PrivateCloud` resource in a given project and location. Private clouds can only be created in zones, regional private clouds are not supported.

        Creating a private cloud also creates a [management cluster](https://cloud.google.com/vmware-engine/docs/concepts-vmware-components) for that private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           PrivateCloud privateCloud = PrivateCloud.newBuilder().build();
           String privateCloudId = "privateCloudId573896493";
           PrivateCloud response =
               vmwareEngineClient.createPrivateCloudAsync(parent, privateCloud, privateCloudId).get();
         }
         
        Parameters:
        parent - Required. The resource name of the location to create the new private cloud in. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a`
        privateCloud - Required. The initial description of the new private cloud.
        privateCloudId - Required. The user-provided identifier of the private cloud to be created. This identifier must be unique among each `PrivateCloud` within the parent and becomes the final token in the name URI. The identifier must meet the following requirements:
        • Only contains 1-63 alphanumeric characters and hyphens
        • Begins with an alphabetical character
        • Ends with a non-hyphen character
        • Not formatted as a UUID
        • Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5)
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createPrivateCloudAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> createPrivateCloudAsync​(CreatePrivateCloudRequest request)
        Creates a new `PrivateCloud` resource in a given project and location. Private clouds can only be created in zones, regional private clouds are not supported.

        Creating a private cloud also creates a [management cluster](https://cloud.google.com/vmware-engine/docs/concepts-vmware-components) for that private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreatePrivateCloudRequest request =
               CreatePrivateCloudRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPrivateCloudId("privateCloudId573896493")
                   .setPrivateCloud(PrivateCloud.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .setValidateOnly(true)
                   .build();
           PrivateCloud response = vmwareEngineClient.createPrivateCloudAsync(request).get();
         }
         
        Parameters:
        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
      • createPrivateCloudOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<CreatePrivateCloudRequest,​PrivateCloud,​OperationMetadata> createPrivateCloudOperationCallable()
        Creates a new `PrivateCloud` resource in a given project and location. Private clouds can only be created in zones, regional private clouds are not supported.

        Creating a private cloud also creates a [management cluster](https://cloud.google.com/vmware-engine/docs/concepts-vmware-components) for that private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreatePrivateCloudRequest request =
               CreatePrivateCloudRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPrivateCloudId("privateCloudId573896493")
                   .setPrivateCloud(PrivateCloud.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .setValidateOnly(true)
                   .build();
           OperationFuture<PrivateCloud, OperationMetadata> future =
               vmwareEngineClient.createPrivateCloudOperationCallable().futureCall(request);
           // Do something.
           PrivateCloud response = future.get();
         }
         
      • createPrivateCloudCallable

        public final com.google.api.gax.rpc.UnaryCallable<CreatePrivateCloudRequest,​com.google.longrunning.Operation> createPrivateCloudCallable()
        Creates a new `PrivateCloud` resource in a given project and location. Private clouds can only be created in zones, regional private clouds are not supported.

        Creating a private cloud also creates a [management cluster](https://cloud.google.com/vmware-engine/docs/concepts-vmware-components) for that private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreatePrivateCloudRequest request =
               CreatePrivateCloudRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPrivateCloudId("privateCloudId573896493")
                   .setPrivateCloud(PrivateCloud.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .setValidateOnly(true)
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.createPrivateCloudCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • updatePrivateCloudAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> updatePrivateCloudAsync​(PrivateCloud privateCloud,
                                                                                                                                  com.google.protobuf.FieldMask updateMask)
        Modifies a `PrivateCloud` resource. Only the following fields can be updated: `description`. Only fields specified in `updateMask` are applied.

        During operation processing, the resource is temporarily in the `ACTIVE` state before the operation fully completes. For that period of time, you can't update the resource. Use the operation status to determine when the processing fully completes.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloud privateCloud = PrivateCloud.newBuilder().build();
           FieldMask updateMask = FieldMask.newBuilder().build();
           PrivateCloud response =
               vmwareEngineClient.updatePrivateCloudAsync(privateCloud, updateMask).get();
         }
         
        Parameters:
        privateCloud - Required. Private cloud description.
        updateMask - Required. Field mask is used to specify the fields to be overwritten in the `PrivateCloud` resource by the update. The fields specified in `updateMask` are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • updatePrivateCloudAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> updatePrivateCloudAsync​(UpdatePrivateCloudRequest request)
        Modifies a `PrivateCloud` resource. Only the following fields can be updated: `description`. Only fields specified in `updateMask` are applied.

        During operation processing, the resource is temporarily in the `ACTIVE` state before the operation fully completes. For that period of time, you can't update the resource. Use the operation status to determine when the processing fully completes.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdatePrivateCloudRequest request =
               UpdatePrivateCloudRequest.newBuilder()
                   .setPrivateCloud(PrivateCloud.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           PrivateCloud response = vmwareEngineClient.updatePrivateCloudAsync(request).get();
         }
         
        Parameters:
        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
      • updatePrivateCloudOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UpdatePrivateCloudRequest,​PrivateCloud,​OperationMetadata> updatePrivateCloudOperationCallable()
        Modifies a `PrivateCloud` resource. Only the following fields can be updated: `description`. Only fields specified in `updateMask` are applied.

        During operation processing, the resource is temporarily in the `ACTIVE` state before the operation fully completes. For that period of time, you can't update the resource. Use the operation status to determine when the processing fully completes.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdatePrivateCloudRequest request =
               UpdatePrivateCloudRequest.newBuilder()
                   .setPrivateCloud(PrivateCloud.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<PrivateCloud, OperationMetadata> future =
               vmwareEngineClient.updatePrivateCloudOperationCallable().futureCall(request);
           // Do something.
           PrivateCloud response = future.get();
         }
         
      • updatePrivateCloudCallable

        public final com.google.api.gax.rpc.UnaryCallable<UpdatePrivateCloudRequest,​com.google.longrunning.Operation> updatePrivateCloudCallable()
        Modifies a `PrivateCloud` resource. Only the following fields can be updated: `description`. Only fields specified in `updateMask` are applied.

        During operation processing, the resource is temporarily in the `ACTIVE` state before the operation fully completes. For that period of time, you can't update the resource. Use the operation status to determine when the processing fully completes.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdatePrivateCloudRequest request =
               UpdatePrivateCloudRequest.newBuilder()
                   .setPrivateCloud(PrivateCloud.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.updatePrivateCloudCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • deletePrivateCloudAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> deletePrivateCloudAsync​(PrivateCloudName name)
        Schedules a `PrivateCloud` resource for deletion.

        A `PrivateCloud` resource scheduled for deletion has `PrivateCloud.state` set to `DELETED` and `expireTime` set to the time when deletion is final and can no longer be reversed. The delete operation is marked as done as soon as the `PrivateCloud` is successfully scheduled for deletion (this also applies when `delayHours` is set to zero), and the operation is not kept in pending state until `PrivateCloud` is purged. `PrivateCloud` can be restored using `UndeletePrivateCloud` method before the `expireTime` elapses. When `expireTime` is reached, deletion is final and all private cloud resources are irreversibly removed and billing stops. During the final removal process, `PrivateCloud.state` is set to `PURGING`. `PrivateCloud` can be polled using standard `GET` method for the whole period of deletion and purging. It will not be returned only when it is completely purged.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloudName name = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
           PrivateCloud response = vmwareEngineClient.deletePrivateCloudAsync(name).get();
         }
         
        Parameters:
        name - Required. The resource name of the private cloud to delete. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deletePrivateCloudAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> deletePrivateCloudAsync​(String name)
        Schedules a `PrivateCloud` resource for deletion.

        A `PrivateCloud` resource scheduled for deletion has `PrivateCloud.state` set to `DELETED` and `expireTime` set to the time when deletion is final and can no longer be reversed. The delete operation is marked as done as soon as the `PrivateCloud` is successfully scheduled for deletion (this also applies when `delayHours` is set to zero), and the operation is not kept in pending state until `PrivateCloud` is purged. `PrivateCloud` can be restored using `UndeletePrivateCloud` method before the `expireTime` elapses. When `expireTime` is reached, deletion is final and all private cloud resources are irreversibly removed and billing stops. During the final removal process, `PrivateCloud.state` is set to `PURGING`. `PrivateCloud` can be polled using standard `GET` method for the whole period of deletion and purging. It will not be returned only when it is completely purged.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString();
           PrivateCloud response = vmwareEngineClient.deletePrivateCloudAsync(name).get();
         }
         
        Parameters:
        name - Required. The resource name of the private cloud to delete. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deletePrivateCloudAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> deletePrivateCloudAsync​(DeletePrivateCloudRequest request)
        Schedules a `PrivateCloud` resource for deletion.

        A `PrivateCloud` resource scheduled for deletion has `PrivateCloud.state` set to `DELETED` and `expireTime` set to the time when deletion is final and can no longer be reversed. The delete operation is marked as done as soon as the `PrivateCloud` is successfully scheduled for deletion (this also applies when `delayHours` is set to zero), and the operation is not kept in pending state until `PrivateCloud` is purged. `PrivateCloud` can be restored using `UndeletePrivateCloud` method before the `expireTime` elapses. When `expireTime` is reached, deletion is final and all private cloud resources are irreversibly removed and billing stops. During the final removal process, `PrivateCloud.state` is set to `PURGING`. `PrivateCloud` can be polled using standard `GET` method for the whole period of deletion and purging. It will not be returned only when it is completely purged.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeletePrivateCloudRequest request =
               DeletePrivateCloudRequest.newBuilder()
                   .setName(PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setRequestId("requestId693933066")
                   .setForce(true)
                   .setDelayHours(475821395)
                   .build();
           PrivateCloud response = vmwareEngineClient.deletePrivateCloudAsync(request).get();
         }
         
        Parameters:
        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
      • deletePrivateCloudOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<DeletePrivateCloudRequest,​PrivateCloud,​OperationMetadata> deletePrivateCloudOperationCallable()
        Schedules a `PrivateCloud` resource for deletion.

        A `PrivateCloud` resource scheduled for deletion has `PrivateCloud.state` set to `DELETED` and `expireTime` set to the time when deletion is final and can no longer be reversed. The delete operation is marked as done as soon as the `PrivateCloud` is successfully scheduled for deletion (this also applies when `delayHours` is set to zero), and the operation is not kept in pending state until `PrivateCloud` is purged. `PrivateCloud` can be restored using `UndeletePrivateCloud` method before the `expireTime` elapses. When `expireTime` is reached, deletion is final and all private cloud resources are irreversibly removed and billing stops. During the final removal process, `PrivateCloud.state` is set to `PURGING`. `PrivateCloud` can be polled using standard `GET` method for the whole period of deletion and purging. It will not be returned only when it is completely purged.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeletePrivateCloudRequest request =
               DeletePrivateCloudRequest.newBuilder()
                   .setName(PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setRequestId("requestId693933066")
                   .setForce(true)
                   .setDelayHours(475821395)
                   .build();
           OperationFuture<PrivateCloud, OperationMetadata> future =
               vmwareEngineClient.deletePrivateCloudOperationCallable().futureCall(request);
           // Do something.
           PrivateCloud response = future.get();
         }
         
      • deletePrivateCloudCallable

        public final com.google.api.gax.rpc.UnaryCallable<DeletePrivateCloudRequest,​com.google.longrunning.Operation> deletePrivateCloudCallable()
        Schedules a `PrivateCloud` resource for deletion.

        A `PrivateCloud` resource scheduled for deletion has `PrivateCloud.state` set to `DELETED` and `expireTime` set to the time when deletion is final and can no longer be reversed. The delete operation is marked as done as soon as the `PrivateCloud` is successfully scheduled for deletion (this also applies when `delayHours` is set to zero), and the operation is not kept in pending state until `PrivateCloud` is purged. `PrivateCloud` can be restored using `UndeletePrivateCloud` method before the `expireTime` elapses. When `expireTime` is reached, deletion is final and all private cloud resources are irreversibly removed and billing stops. During the final removal process, `PrivateCloud.state` is set to `PURGING`. `PrivateCloud` can be polled using standard `GET` method for the whole period of deletion and purging. It will not be returned only when it is completely purged.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeletePrivateCloudRequest request =
               DeletePrivateCloudRequest.newBuilder()
                   .setName(PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setRequestId("requestId693933066")
                   .setForce(true)
                   .setDelayHours(475821395)
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.deletePrivateCloudCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • undeletePrivateCloudAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> undeletePrivateCloudAsync​(PrivateCloudName name)
        Restores a private cloud that was previously scheduled for deletion by `DeletePrivateCloud`. A `PrivateCloud` resource scheduled for deletion has `PrivateCloud.state` set to `DELETED` and `PrivateCloud.expireTime` set to the time when deletion can no longer be reversed.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloudName name = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
           PrivateCloud response = vmwareEngineClient.undeletePrivateCloudAsync(name).get();
         }
         
        Parameters:
        name - Required. The resource name of the private cloud scheduled for deletion. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • undeletePrivateCloudAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> undeletePrivateCloudAsync​(String name)
        Restores a private cloud that was previously scheduled for deletion by `DeletePrivateCloud`. A `PrivateCloud` resource scheduled for deletion has `PrivateCloud.state` set to `DELETED` and `PrivateCloud.expireTime` set to the time when deletion can no longer be reversed.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString();
           PrivateCloud response = vmwareEngineClient.undeletePrivateCloudAsync(name).get();
         }
         
        Parameters:
        name - Required. The resource name of the private cloud scheduled for deletion. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • undeletePrivateCloudAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> undeletePrivateCloudAsync​(UndeletePrivateCloudRequest request)
        Restores a private cloud that was previously scheduled for deletion by `DeletePrivateCloud`. A `PrivateCloud` resource scheduled for deletion has `PrivateCloud.state` set to `DELETED` and `PrivateCloud.expireTime` set to the time when deletion can no longer be reversed.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UndeletePrivateCloudRequest request =
               UndeletePrivateCloudRequest.newBuilder()
                   .setName(PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setRequestId("requestId693933066")
                   .build();
           PrivateCloud response = vmwareEngineClient.undeletePrivateCloudAsync(request).get();
         }
         
        Parameters:
        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
      • undeletePrivateCloudOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UndeletePrivateCloudRequest,​PrivateCloud,​OperationMetadata> undeletePrivateCloudOperationCallable()
        Restores a private cloud that was previously scheduled for deletion by `DeletePrivateCloud`. A `PrivateCloud` resource scheduled for deletion has `PrivateCloud.state` set to `DELETED` and `PrivateCloud.expireTime` set to the time when deletion can no longer be reversed.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UndeletePrivateCloudRequest request =
               UndeletePrivateCloudRequest.newBuilder()
                   .setName(PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<PrivateCloud, OperationMetadata> future =
               vmwareEngineClient.undeletePrivateCloudOperationCallable().futureCall(request);
           // Do something.
           PrivateCloud response = future.get();
         }
         
      • undeletePrivateCloudCallable

        public final com.google.api.gax.rpc.UnaryCallable<UndeletePrivateCloudRequest,​com.google.longrunning.Operation> undeletePrivateCloudCallable()
        Restores a private cloud that was previously scheduled for deletion by `DeletePrivateCloud`. A `PrivateCloud` resource scheduled for deletion has `PrivateCloud.state` set to `DELETED` and `PrivateCloud.expireTime` set to the time when deletion can no longer be reversed.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UndeletePrivateCloudRequest request =
               UndeletePrivateCloudRequest.newBuilder()
                   .setName(PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.undeletePrivateCloudCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • listClusters

        public final VmwareEngineClient.ListClustersPagedResponse listClusters​(PrivateCloudName parent)
        Lists `Cluster` resources in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloudName parent = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
           for (Cluster element : vmwareEngineClient.listClusters(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the private cloud to query for clusters. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listClusters

        public final VmwareEngineClient.ListClustersPagedResponse listClusters​(String parent)
        Lists `Cluster` resources in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString();
           for (Cluster element : vmwareEngineClient.listClusters(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the private cloud to query for clusters. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listClusters

        public final VmwareEngineClient.ListClustersPagedResponse listClusters​(ListClustersRequest request)
        Lists `Cluster` resources in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListClustersRequest request =
               ListClustersRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           for (Cluster element : vmwareEngineClient.listClusters(request).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        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
      • listClustersPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListClustersRequest,​VmwareEngineClient.ListClustersPagedResponse> listClustersPagedCallable()
        Lists `Cluster` resources in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListClustersRequest request =
               ListClustersRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           ApiFuture<Cluster> future =
               vmwareEngineClient.listClustersPagedCallable().futureCall(request);
           // Do something.
           for (Cluster element : future.get().iterateAll()) {
             // doThingsWith(element);
           }
         }
         
      • listClustersCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListClustersRequest,​ListClustersResponse> listClustersCallable()
        Lists `Cluster` resources in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListClustersRequest request =
               ListClustersRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           while (true) {
             ListClustersResponse response = vmwareEngineClient.listClustersCallable().call(request);
             for (Cluster element : response.getClustersList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • getCluster

        public final Cluster getCluster​(ClusterName name)
        Retrieves a `Cluster` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ClusterName name = ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]");
           Cluster response = vmwareEngineClient.getCluster(name);
         }
         
        Parameters:
        name - Required. The cluster resource name to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getCluster

        public final Cluster getCluster​(String name)
        Retrieves a `Cluster` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name =
               ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]").toString();
           Cluster response = vmwareEngineClient.getCluster(name);
         }
         
        Parameters:
        name - Required. The cluster resource name to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getCluster

        public final Cluster getCluster​(GetClusterRequest request)
        Retrieves a `Cluster` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetClusterRequest request =
               GetClusterRequest.newBuilder()
                   .setName(
                       ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]")
                           .toString())
                   .build();
           Cluster response = vmwareEngineClient.getCluster(request);
         }
         
        Parameters:
        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
      • getClusterCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetClusterRequest,​Cluster> getClusterCallable()
        Retrieves a `Cluster` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetClusterRequest request =
               GetClusterRequest.newBuilder()
                   .setName(
                       ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]")
                           .toString())
                   .build();
           ApiFuture<Cluster> future = vmwareEngineClient.getClusterCallable().futureCall(request);
           // Do something.
           Cluster response = future.get();
         }
         
      • createClusterAsync

        public final com.google.api.gax.longrunning.OperationFuture<Cluster,​OperationMetadata> createClusterAsync​(PrivateCloudName parent,
                                                                                                                        Cluster cluster,
                                                                                                                        String clusterId)
        Creates a new cluster in a given private cloud. Creating a new cluster provides additional nodes for use in the parent private cloud and requires sufficient [node quota](https://cloud.google.com/vmware-engine/quotas).

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloudName parent = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
           Cluster cluster = Cluster.newBuilder().build();
           String clusterId = "clusterId561939637";
           Cluster response = vmwareEngineClient.createClusterAsync(parent, cluster, clusterId).get();
         }
         
        Parameters:
        parent - Required. The resource name of the private cloud to create a new cluster in. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        cluster - Required. The initial description of the new cluster.
        clusterId - Required. The user-provided identifier of the new `Cluster`. This identifier must be unique among clusters within the parent and becomes the final token in the name URI. The identifier must meet the following requirements:
        • Only contains 1-63 alphanumeric characters and hyphens
        • Begins with an alphabetical character
        • Ends with a non-hyphen character
        • Not formatted as a UUID
        • Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5)
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createClusterAsync

        public final com.google.api.gax.longrunning.OperationFuture<Cluster,​OperationMetadata> createClusterAsync​(String parent,
                                                                                                                        Cluster cluster,
                                                                                                                        String clusterId)
        Creates a new cluster in a given private cloud. Creating a new cluster provides additional nodes for use in the parent private cloud and requires sufficient [node quota](https://cloud.google.com/vmware-engine/quotas).

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString();
           Cluster cluster = Cluster.newBuilder().build();
           String clusterId = "clusterId561939637";
           Cluster response = vmwareEngineClient.createClusterAsync(parent, cluster, clusterId).get();
         }
         
        Parameters:
        parent - Required. The resource name of the private cloud to create a new cluster in. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        cluster - Required. The initial description of the new cluster.
        clusterId - Required. The user-provided identifier of the new `Cluster`. This identifier must be unique among clusters within the parent and becomes the final token in the name URI. The identifier must meet the following requirements:
        • Only contains 1-63 alphanumeric characters and hyphens
        • Begins with an alphabetical character
        • Ends with a non-hyphen character
        • Not formatted as a UUID
        • Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5)
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createClusterAsync

        public final com.google.api.gax.longrunning.OperationFuture<Cluster,​OperationMetadata> createClusterAsync​(CreateClusterRequest request)
        Creates a new cluster in a given private cloud. Creating a new cluster provides additional nodes for use in the parent private cloud and requires sufficient [node quota](https://cloud.google.com/vmware-engine/quotas).

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreateClusterRequest request =
               CreateClusterRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setClusterId("clusterId561939637")
                   .setCluster(Cluster.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .setValidateOnly(true)
                   .build();
           Cluster response = vmwareEngineClient.createClusterAsync(request).get();
         }
         
        Parameters:
        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
      • createClusterOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<CreateClusterRequest,​Cluster,​OperationMetadata> createClusterOperationCallable()
        Creates a new cluster in a given private cloud. Creating a new cluster provides additional nodes for use in the parent private cloud and requires sufficient [node quota](https://cloud.google.com/vmware-engine/quotas).

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreateClusterRequest request =
               CreateClusterRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setClusterId("clusterId561939637")
                   .setCluster(Cluster.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .setValidateOnly(true)
                   .build();
           OperationFuture<Cluster, OperationMetadata> future =
               vmwareEngineClient.createClusterOperationCallable().futureCall(request);
           // Do something.
           Cluster response = future.get();
         }
         
      • createClusterCallable

        public final com.google.api.gax.rpc.UnaryCallable<CreateClusterRequest,​com.google.longrunning.Operation> createClusterCallable()
        Creates a new cluster in a given private cloud. Creating a new cluster provides additional nodes for use in the parent private cloud and requires sufficient [node quota](https://cloud.google.com/vmware-engine/quotas).

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreateClusterRequest request =
               CreateClusterRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setClusterId("clusterId561939637")
                   .setCluster(Cluster.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .setValidateOnly(true)
                   .build();
           ApiFuture<Operation> future = vmwareEngineClient.createClusterCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • updateClusterAsync

        public final com.google.api.gax.longrunning.OperationFuture<Cluster,​OperationMetadata> updateClusterAsync​(Cluster cluster,
                                                                                                                        com.google.protobuf.FieldMask updateMask)
        Modifies a `Cluster` resource. Only the following fields can be updated: `node_type_configs.*.node_count`. Only fields specified in `updateMask` are applied.

        During operation processing, the resource is temporarily in the `ACTIVE` state before the operation fully completes. For that period of time, you can't update the resource. Use the operation status to determine when the processing fully completes.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           Cluster cluster = Cluster.newBuilder().build();
           FieldMask updateMask = FieldMask.newBuilder().build();
           Cluster response = vmwareEngineClient.updateClusterAsync(cluster, updateMask).get();
         }
         
        Parameters:
        cluster - Required. The description of the cluster.
        updateMask - Required. Field mask is used to specify the fields to be overwritten in the `Cluster` resource by the update. The fields specified in the `updateMask` are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • updateClusterAsync

        public final com.google.api.gax.longrunning.OperationFuture<Cluster,​OperationMetadata> updateClusterAsync​(UpdateClusterRequest request)
        Modifies a `Cluster` resource. Only the following fields can be updated: `node_type_configs.*.node_count`. Only fields specified in `updateMask` are applied.

        During operation processing, the resource is temporarily in the `ACTIVE` state before the operation fully completes. For that period of time, you can't update the resource. Use the operation status to determine when the processing fully completes.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdateClusterRequest request =
               UpdateClusterRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setCluster(Cluster.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .setValidateOnly(true)
                   .build();
           Cluster response = vmwareEngineClient.updateClusterAsync(request).get();
         }
         
        Parameters:
        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
      • updateClusterOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UpdateClusterRequest,​Cluster,​OperationMetadata> updateClusterOperationCallable()
        Modifies a `Cluster` resource. Only the following fields can be updated: `node_type_configs.*.node_count`. Only fields specified in `updateMask` are applied.

        During operation processing, the resource is temporarily in the `ACTIVE` state before the operation fully completes. For that period of time, you can't update the resource. Use the operation status to determine when the processing fully completes.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdateClusterRequest request =
               UpdateClusterRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setCluster(Cluster.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .setValidateOnly(true)
                   .build();
           OperationFuture<Cluster, OperationMetadata> future =
               vmwareEngineClient.updateClusterOperationCallable().futureCall(request);
           // Do something.
           Cluster response = future.get();
         }
         
      • updateClusterCallable

        public final com.google.api.gax.rpc.UnaryCallable<UpdateClusterRequest,​com.google.longrunning.Operation> updateClusterCallable()
        Modifies a `Cluster` resource. Only the following fields can be updated: `node_type_configs.*.node_count`. Only fields specified in `updateMask` are applied.

        During operation processing, the resource is temporarily in the `ACTIVE` state before the operation fully completes. For that period of time, you can't update the resource. Use the operation status to determine when the processing fully completes.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdateClusterRequest request =
               UpdateClusterRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setCluster(Cluster.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .setValidateOnly(true)
                   .build();
           ApiFuture<Operation> future = vmwareEngineClient.updateClusterCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • deleteClusterAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteClusterAsync​(ClusterName name)
        Deletes a `Cluster` resource. To avoid unintended data loss, migrate or gracefully shut down any workloads running on the cluster before deletion. You cannot delete the management cluster of a private cloud using this method.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ClusterName name = ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]");
           vmwareEngineClient.deleteClusterAsync(name).get();
         }
         
        Parameters:
        name - Required. The resource name of the cluster to delete. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteClusterAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteClusterAsync​(String name)
        Deletes a `Cluster` resource. To avoid unintended data loss, migrate or gracefully shut down any workloads running on the cluster before deletion. You cannot delete the management cluster of a private cloud using this method.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name =
               ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]").toString();
           vmwareEngineClient.deleteClusterAsync(name).get();
         }
         
        Parameters:
        name - Required. The resource name of the cluster to delete. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteClusterAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteClusterAsync​(DeleteClusterRequest request)
        Deletes a `Cluster` resource. To avoid unintended data loss, migrate or gracefully shut down any workloads running on the cluster before deletion. You cannot delete the management cluster of a private cloud using this method.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeleteClusterRequest request =
               DeleteClusterRequest.newBuilder()
                   .setName(
                       ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]")
                           .toString())
                   .setRequestId("requestId693933066")
                   .build();
           vmwareEngineClient.deleteClusterAsync(request).get();
         }
         
        Parameters:
        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
      • deleteClusterOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<DeleteClusterRequest,​com.google.protobuf.Empty,​OperationMetadata> deleteClusterOperationCallable()
        Deletes a `Cluster` resource. To avoid unintended data loss, migrate or gracefully shut down any workloads running on the cluster before deletion. You cannot delete the management cluster of a private cloud using this method.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeleteClusterRequest request =
               DeleteClusterRequest.newBuilder()
                   .setName(
                       ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]")
                           .toString())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<Empty, OperationMetadata> future =
               vmwareEngineClient.deleteClusterOperationCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • deleteClusterCallable

        public final com.google.api.gax.rpc.UnaryCallable<DeleteClusterRequest,​com.google.longrunning.Operation> deleteClusterCallable()
        Deletes a `Cluster` resource. To avoid unintended data loss, migrate or gracefully shut down any workloads running on the cluster before deletion. You cannot delete the management cluster of a private cloud using this method.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeleteClusterRequest request =
               DeleteClusterRequest.newBuilder()
                   .setName(
                       ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]")
                           .toString())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future = vmwareEngineClient.deleteClusterCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • listSubnets

        public final VmwareEngineClient.ListSubnetsPagedResponse listSubnets​(PrivateCloudName parent)
        Lists subnets in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloudName parent = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
           for (Subnet element : vmwareEngineClient.listSubnets(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the private cloud to be queried for subnets. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listSubnets

        public final VmwareEngineClient.ListSubnetsPagedResponse listSubnets​(String parent)
        Lists subnets in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString();
           for (Subnet element : vmwareEngineClient.listSubnets(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the private cloud to be queried for subnets. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listSubnets

        public final VmwareEngineClient.ListSubnetsPagedResponse listSubnets​(ListSubnetsRequest request)
        Lists subnets in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListSubnetsRequest request =
               ListSubnetsRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           for (Subnet element : vmwareEngineClient.listSubnets(request).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        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
      • listSubnetsPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListSubnetsRequest,​VmwareEngineClient.ListSubnetsPagedResponse> listSubnetsPagedCallable()
        Lists subnets in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListSubnetsRequest request =
               ListSubnetsRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           ApiFuture<Subnet> future = vmwareEngineClient.listSubnetsPagedCallable().futureCall(request);
           // Do something.
           for (Subnet element : future.get().iterateAll()) {
             // doThingsWith(element);
           }
         }
         
      • listSubnetsCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListSubnetsRequest,​ListSubnetsResponse> listSubnetsCallable()
        Lists subnets in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListSubnetsRequest request =
               ListSubnetsRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           while (true) {
             ListSubnetsResponse response = vmwareEngineClient.listSubnetsCallable().call(request);
             for (Subnet element : response.getSubnetsList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • getSubnet

        public final Subnet getSubnet​(SubnetName name)
        Gets details of a single subnet.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           SubnetName name = SubnetName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[SUBNET]");
           Subnet response = vmwareEngineClient.getSubnet(name);
         }
         
        Parameters:
        name - Required. The resource name of the subnet to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getSubnet

        public final Subnet getSubnet​(String name)
        Gets details of a single subnet.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name =
               SubnetName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[SUBNET]").toString();
           Subnet response = vmwareEngineClient.getSubnet(name);
         }
         
        Parameters:
        name - Required. The resource name of the subnet to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getSubnet

        public final Subnet getSubnet​(GetSubnetRequest request)
        Gets details of a single subnet.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetSubnetRequest request =
               GetSubnetRequest.newBuilder()
                   .setName(
                       SubnetName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[SUBNET]")
                           .toString())
                   .build();
           Subnet response = vmwareEngineClient.getSubnet(request);
         }
         
        Parameters:
        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
      • getSubnetCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetSubnetRequest,​Subnet> getSubnetCallable()
        Gets details of a single subnet.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetSubnetRequest request =
               GetSubnetRequest.newBuilder()
                   .setName(
                       SubnetName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[SUBNET]")
                           .toString())
                   .build();
           ApiFuture<Subnet> future = vmwareEngineClient.getSubnetCallable().futureCall(request);
           // Do something.
           Subnet response = future.get();
         }
         
      • updateSubnetAsync

        public final com.google.api.gax.longrunning.OperationFuture<Subnet,​OperationMetadata> updateSubnetAsync​(Subnet subnet,
                                                                                                                      com.google.protobuf.FieldMask updateMask)
        Updates the parameters of a single subnet. Only fields specified in `update_mask` are applied.

        *Note*: This API is synchronous and always returns a successful `google.longrunning.Operation` (LRO). The returned LRO will only have `done` and `response` fields.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           Subnet subnet = Subnet.newBuilder().build();
           FieldMask updateMask = FieldMask.newBuilder().build();
           Subnet response = vmwareEngineClient.updateSubnetAsync(subnet, updateMask).get();
         }
         
        Parameters:
        subnet - Required. Subnet description.
        updateMask - Required. Field mask is used to specify the fields to be overwritten in the `Subnet` resource by the update. The fields specified in the `update_mask` are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • updateSubnetAsync

        public final com.google.api.gax.longrunning.OperationFuture<Subnet,​OperationMetadata> updateSubnetAsync​(UpdateSubnetRequest request)
        Updates the parameters of a single subnet. Only fields specified in `update_mask` are applied.

        *Note*: This API is synchronous and always returns a successful `google.longrunning.Operation` (LRO). The returned LRO will only have `done` and `response` fields.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdateSubnetRequest request =
               UpdateSubnetRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setSubnet(Subnet.newBuilder().build())
                   .build();
           Subnet response = vmwareEngineClient.updateSubnetAsync(request).get();
         }
         
        Parameters:
        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
      • updateSubnetOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UpdateSubnetRequest,​Subnet,​OperationMetadata> updateSubnetOperationCallable()
        Updates the parameters of a single subnet. Only fields specified in `update_mask` are applied.

        *Note*: This API is synchronous and always returns a successful `google.longrunning.Operation` (LRO). The returned LRO will only have `done` and `response` fields.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdateSubnetRequest request =
               UpdateSubnetRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setSubnet(Subnet.newBuilder().build())
                   .build();
           OperationFuture<Subnet, OperationMetadata> future =
               vmwareEngineClient.updateSubnetOperationCallable().futureCall(request);
           // Do something.
           Subnet response = future.get();
         }
         
      • updateSubnetCallable

        public final com.google.api.gax.rpc.UnaryCallable<UpdateSubnetRequest,​com.google.longrunning.Operation> updateSubnetCallable()
        Updates the parameters of a single subnet. Only fields specified in `update_mask` are applied.

        *Note*: This API is synchronous and always returns a successful `google.longrunning.Operation` (LRO). The returned LRO will only have `done` and `response` fields.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdateSubnetRequest request =
               UpdateSubnetRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setSubnet(Subnet.newBuilder().build())
                   .build();
           ApiFuture<Operation> future = vmwareEngineClient.updateSubnetCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • listNodeTypes

        public final VmwareEngineClient.ListNodeTypesPagedResponse listNodeTypes​(LocationName parent)
        Lists node types

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           for (NodeType element : vmwareEngineClient.listNodeTypes(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the location to be queried for node types. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listNodeTypes

        public final VmwareEngineClient.ListNodeTypesPagedResponse listNodeTypes​(String parent)
        Lists node types

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           for (NodeType element : vmwareEngineClient.listNodeTypes(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the location to be queried for node types. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listNodeTypes

        public final VmwareEngineClient.ListNodeTypesPagedResponse listNodeTypes​(ListNodeTypesRequest request)
        Lists node types

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListNodeTypesRequest request =
               ListNodeTypesRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .build();
           for (NodeType element : vmwareEngineClient.listNodeTypes(request).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        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
      • listNodeTypesPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListNodeTypesRequest,​VmwareEngineClient.ListNodeTypesPagedResponse> listNodeTypesPagedCallable()
        Lists node types

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListNodeTypesRequest request =
               ListNodeTypesRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .build();
           ApiFuture<NodeType> future =
               vmwareEngineClient.listNodeTypesPagedCallable().futureCall(request);
           // Do something.
           for (NodeType element : future.get().iterateAll()) {
             // doThingsWith(element);
           }
         }
         
      • listNodeTypesCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListNodeTypesRequest,​ListNodeTypesResponse> listNodeTypesCallable()
        Lists node types

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListNodeTypesRequest request =
               ListNodeTypesRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .build();
           while (true) {
             ListNodeTypesResponse response = vmwareEngineClient.listNodeTypesCallable().call(request);
             for (NodeType element : response.getNodeTypesList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • getNodeType

        public final NodeType getNodeType​(NodeTypeName name)
        Gets details of a single `NodeType`.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           NodeTypeName name = NodeTypeName.of("[PROJECT]", "[LOCATION]", "[NODE_TYPE]");
           NodeType response = vmwareEngineClient.getNodeType(name);
         }
         
        Parameters:
        name - Required. The resource name of the node type to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getNodeType

        public final NodeType getNodeType​(String name)
        Gets details of a single `NodeType`.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name = NodeTypeName.of("[PROJECT]", "[LOCATION]", "[NODE_TYPE]").toString();
           NodeType response = vmwareEngineClient.getNodeType(name);
         }
         
        Parameters:
        name - Required. The resource name of the node type to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getNodeType

        public final NodeType getNodeType​(GetNodeTypeRequest request)
        Gets details of a single `NodeType`.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetNodeTypeRequest request =
               GetNodeTypeRequest.newBuilder()
                   .setName(NodeTypeName.of("[PROJECT]", "[LOCATION]", "[NODE_TYPE]").toString())
                   .build();
           NodeType response = vmwareEngineClient.getNodeType(request);
         }
         
        Parameters:
        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
      • getNodeTypeCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetNodeTypeRequest,​NodeType> getNodeTypeCallable()
        Gets details of a single `NodeType`.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetNodeTypeRequest request =
               GetNodeTypeRequest.newBuilder()
                   .setName(NodeTypeName.of("[PROJECT]", "[LOCATION]", "[NODE_TYPE]").toString())
                   .build();
           ApiFuture<NodeType> future = vmwareEngineClient.getNodeTypeCallable().futureCall(request);
           // Do something.
           NodeType response = future.get();
         }
         
      • showNsxCredentials

        public final Credentials showNsxCredentials​(PrivateCloudName privateCloud)
        Gets details of credentials for NSX appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloudName privateCloud =
               PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
           Credentials response = vmwareEngineClient.showNsxCredentials(privateCloud);
         }
         
        Parameters:
        privateCloud - Required. The resource name of the private cloud to be queried for credentials. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • showNsxCredentials

        public final Credentials showNsxCredentials​(String privateCloud)
        Gets details of credentials for NSX appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String privateCloud =
               PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString();
           Credentials response = vmwareEngineClient.showNsxCredentials(privateCloud);
         }
         
        Parameters:
        privateCloud - Required. The resource name of the private cloud to be queried for credentials. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • showNsxCredentials

        public final Credentials showNsxCredentials​(ShowNsxCredentialsRequest request)
        Gets details of credentials for NSX appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ShowNsxCredentialsRequest request =
               ShowNsxCredentialsRequest.newBuilder()
                   .setPrivateCloud(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .build();
           Credentials response = vmwareEngineClient.showNsxCredentials(request);
         }
         
        Parameters:
        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
      • showNsxCredentialsCallable

        public final com.google.api.gax.rpc.UnaryCallable<ShowNsxCredentialsRequest,​Credentials> showNsxCredentialsCallable()
        Gets details of credentials for NSX appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ShowNsxCredentialsRequest request =
               ShowNsxCredentialsRequest.newBuilder()
                   .setPrivateCloud(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .build();
           ApiFuture<Credentials> future =
               vmwareEngineClient.showNsxCredentialsCallable().futureCall(request);
           // Do something.
           Credentials response = future.get();
         }
         
      • showVcenterCredentials

        public final Credentials showVcenterCredentials​(PrivateCloudName privateCloud)
        Gets details of credentials for Vcenter appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloudName privateCloud =
               PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
           Credentials response = vmwareEngineClient.showVcenterCredentials(privateCloud);
         }
         
        Parameters:
        privateCloud - Required. The resource name of the private cloud to be queried for credentials. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • showVcenterCredentials

        public final Credentials showVcenterCredentials​(String privateCloud)
        Gets details of credentials for Vcenter appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String privateCloud =
               PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString();
           Credentials response = vmwareEngineClient.showVcenterCredentials(privateCloud);
         }
         
        Parameters:
        privateCloud - Required. The resource name of the private cloud to be queried for credentials. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • showVcenterCredentials

        public final Credentials showVcenterCredentials​(ShowVcenterCredentialsRequest request)
        Gets details of credentials for Vcenter appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ShowVcenterCredentialsRequest request =
               ShowVcenterCredentialsRequest.newBuilder()
                   .setPrivateCloud(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .build();
           Credentials response = vmwareEngineClient.showVcenterCredentials(request);
         }
         
        Parameters:
        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
      • showVcenterCredentialsCallable

        public final com.google.api.gax.rpc.UnaryCallable<ShowVcenterCredentialsRequest,​Credentials> showVcenterCredentialsCallable()
        Gets details of credentials for Vcenter appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ShowVcenterCredentialsRequest request =
               ShowVcenterCredentialsRequest.newBuilder()
                   .setPrivateCloud(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .build();
           ApiFuture<Credentials> future =
               vmwareEngineClient.showVcenterCredentialsCallable().futureCall(request);
           // Do something.
           Credentials response = future.get();
         }
         
      • resetNsxCredentialsAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> resetNsxCredentialsAsync​(PrivateCloudName privateCloud)
        Resets credentials of the NSX appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloudName privateCloud =
               PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
           PrivateCloud response = vmwareEngineClient.resetNsxCredentialsAsync(privateCloud).get();
         }
         
        Parameters:
        privateCloud - Required. The resource name of the private cloud to reset credentials for. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • resetNsxCredentialsAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> resetNsxCredentialsAsync​(String privateCloud)
        Resets credentials of the NSX appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String privateCloud =
               PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString();
           PrivateCloud response = vmwareEngineClient.resetNsxCredentialsAsync(privateCloud).get();
         }
         
        Parameters:
        privateCloud - Required. The resource name of the private cloud to reset credentials for. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • resetNsxCredentialsAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> resetNsxCredentialsAsync​(ResetNsxCredentialsRequest request)
        Resets credentials of the NSX appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ResetNsxCredentialsRequest request =
               ResetNsxCredentialsRequest.newBuilder()
                   .setPrivateCloud(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setRequestId("requestId693933066")
                   .build();
           PrivateCloud response = vmwareEngineClient.resetNsxCredentialsAsync(request).get();
         }
         
        Parameters:
        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
      • resetNsxCredentialsOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<ResetNsxCredentialsRequest,​PrivateCloud,​OperationMetadata> resetNsxCredentialsOperationCallable()
        Resets credentials of the NSX appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ResetNsxCredentialsRequest request =
               ResetNsxCredentialsRequest.newBuilder()
                   .setPrivateCloud(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<PrivateCloud, OperationMetadata> future =
               vmwareEngineClient.resetNsxCredentialsOperationCallable().futureCall(request);
           // Do something.
           PrivateCloud response = future.get();
         }
         
      • resetNsxCredentialsCallable

        public final com.google.api.gax.rpc.UnaryCallable<ResetNsxCredentialsRequest,​com.google.longrunning.Operation> resetNsxCredentialsCallable()
        Resets credentials of the NSX appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ResetNsxCredentialsRequest request =
               ResetNsxCredentialsRequest.newBuilder()
                   .setPrivateCloud(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.resetNsxCredentialsCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • resetVcenterCredentialsAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> resetVcenterCredentialsAsync​(PrivateCloudName privateCloud)
        Resets credentials of the Vcenter appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloudName privateCloud =
               PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
           PrivateCloud response = vmwareEngineClient.resetVcenterCredentialsAsync(privateCloud).get();
         }
         
        Parameters:
        privateCloud - Required. The resource name of the private cloud to reset credentials for. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • resetVcenterCredentialsAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> resetVcenterCredentialsAsync​(String privateCloud)
        Resets credentials of the Vcenter appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String privateCloud =
               PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString();
           PrivateCloud response = vmwareEngineClient.resetVcenterCredentialsAsync(privateCloud).get();
         }
         
        Parameters:
        privateCloud - Required. The resource name of the private cloud to reset credentials for. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • resetVcenterCredentialsAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateCloud,​OperationMetadata> resetVcenterCredentialsAsync​(ResetVcenterCredentialsRequest request)
        Resets credentials of the Vcenter appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ResetVcenterCredentialsRequest request =
               ResetVcenterCredentialsRequest.newBuilder()
                   .setPrivateCloud(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setRequestId("requestId693933066")
                   .build();
           PrivateCloud response = vmwareEngineClient.resetVcenterCredentialsAsync(request).get();
         }
         
        Parameters:
        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
      • resetVcenterCredentialsOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<ResetVcenterCredentialsRequest,​PrivateCloud,​OperationMetadata> resetVcenterCredentialsOperationCallable()
        Resets credentials of the Vcenter appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ResetVcenterCredentialsRequest request =
               ResetVcenterCredentialsRequest.newBuilder()
                   .setPrivateCloud(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<PrivateCloud, OperationMetadata> future =
               vmwareEngineClient.resetVcenterCredentialsOperationCallable().futureCall(request);
           // Do something.
           PrivateCloud response = future.get();
         }
         
      • resetVcenterCredentialsCallable

        public final com.google.api.gax.rpc.UnaryCallable<ResetVcenterCredentialsRequest,​com.google.longrunning.Operation> resetVcenterCredentialsCallable()
        Resets credentials of the Vcenter appliance.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ResetVcenterCredentialsRequest request =
               ResetVcenterCredentialsRequest.newBuilder()
                   .setPrivateCloud(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.resetVcenterCredentialsCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • createHcxActivationKeyAsync

        public final com.google.api.gax.longrunning.OperationFuture<HcxActivationKey,​OperationMetadata> createHcxActivationKeyAsync​(PrivateCloudName parent,
                                                                                                                                          HcxActivationKey hcxActivationKey,
                                                                                                                                          String hcxActivationKeyId)
        Creates a new HCX activation key in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloudName parent = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
           HcxActivationKey hcxActivationKey = HcxActivationKey.newBuilder().build();
           String hcxActivationKeyId = "hcxActivationKeyId-645871673";
           HcxActivationKey response =
               vmwareEngineClient
                   .createHcxActivationKeyAsync(parent, hcxActivationKey, hcxActivationKeyId)
                   .get();
         }
         
        Parameters:
        parent - Required. The resource name of the private cloud to create the key for. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/privateClouds/my-cloud`
        hcxActivationKey - Required. The initial description of a new HCX activation key. When creating a new key, this field must be an empty object.
        hcxActivationKeyId - Required. The user-provided identifier of the `HcxActivationKey` to be created. This identifier must be unique among `HcxActivationKey` resources within the parent and becomes the final token in the name URI. The identifier must meet the following requirements:
        • Only contains 1-63 alphanumeric characters and hyphens
        • Begins with an alphabetical character
        • Ends with a non-hyphen character
        • Not formatted as a UUID
        • Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5)
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createHcxActivationKeyAsync

        public final com.google.api.gax.longrunning.OperationFuture<HcxActivationKey,​OperationMetadata> createHcxActivationKeyAsync​(String parent,
                                                                                                                                          HcxActivationKey hcxActivationKey,
                                                                                                                                          String hcxActivationKeyId)
        Creates a new HCX activation key in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString();
           HcxActivationKey hcxActivationKey = HcxActivationKey.newBuilder().build();
           String hcxActivationKeyId = "hcxActivationKeyId-645871673";
           HcxActivationKey response =
               vmwareEngineClient
                   .createHcxActivationKeyAsync(parent, hcxActivationKey, hcxActivationKeyId)
                   .get();
         }
         
        Parameters:
        parent - Required. The resource name of the private cloud to create the key for. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/privateClouds/my-cloud`
        hcxActivationKey - Required. The initial description of a new HCX activation key. When creating a new key, this field must be an empty object.
        hcxActivationKeyId - Required. The user-provided identifier of the `HcxActivationKey` to be created. This identifier must be unique among `HcxActivationKey` resources within the parent and becomes the final token in the name URI. The identifier must meet the following requirements:
        • Only contains 1-63 alphanumeric characters and hyphens
        • Begins with an alphabetical character
        • Ends with a non-hyphen character
        • Not formatted as a UUID
        • Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5)
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createHcxActivationKeyAsync

        public final com.google.api.gax.longrunning.OperationFuture<HcxActivationKey,​OperationMetadata> createHcxActivationKeyAsync​(CreateHcxActivationKeyRequest request)
        Creates a new HCX activation key in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreateHcxActivationKeyRequest request =
               CreateHcxActivationKeyRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setHcxActivationKey(HcxActivationKey.newBuilder().build())
                   .setHcxActivationKeyId("hcxActivationKeyId-645871673")
                   .setRequestId("requestId693933066")
                   .build();
           HcxActivationKey response = vmwareEngineClient.createHcxActivationKeyAsync(request).get();
         }
         
        Parameters:
        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
      • createHcxActivationKeyOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<CreateHcxActivationKeyRequest,​HcxActivationKey,​OperationMetadata> createHcxActivationKeyOperationCallable()
        Creates a new HCX activation key in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreateHcxActivationKeyRequest request =
               CreateHcxActivationKeyRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setHcxActivationKey(HcxActivationKey.newBuilder().build())
                   .setHcxActivationKeyId("hcxActivationKeyId-645871673")
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<HcxActivationKey, OperationMetadata> future =
               vmwareEngineClient.createHcxActivationKeyOperationCallable().futureCall(request);
           // Do something.
           HcxActivationKey response = future.get();
         }
         
      • createHcxActivationKeyCallable

        public final com.google.api.gax.rpc.UnaryCallable<CreateHcxActivationKeyRequest,​com.google.longrunning.Operation> createHcxActivationKeyCallable()
        Creates a new HCX activation key in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreateHcxActivationKeyRequest request =
               CreateHcxActivationKeyRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setHcxActivationKey(HcxActivationKey.newBuilder().build())
                   .setHcxActivationKeyId("hcxActivationKeyId-645871673")
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.createHcxActivationKeyCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • listHcxActivationKeys

        public final VmwareEngineClient.ListHcxActivationKeysPagedResponse listHcxActivationKeys​(PrivateCloudName parent)
        Lists `HcxActivationKey` resources in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateCloudName parent = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]");
           for (HcxActivationKey element :
               vmwareEngineClient.listHcxActivationKeys(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the private cloud to be queried for HCX activation keys. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listHcxActivationKeys

        public final VmwareEngineClient.ListHcxActivationKeysPagedResponse listHcxActivationKeys​(String parent)
        Lists `HcxActivationKey` resources in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString();
           for (HcxActivationKey element :
               vmwareEngineClient.listHcxActivationKeys(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the private cloud to be queried for HCX activation keys. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/privateClouds/my-cloud`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listHcxActivationKeys

        public final VmwareEngineClient.ListHcxActivationKeysPagedResponse listHcxActivationKeys​(ListHcxActivationKeysRequest request)
        Lists `HcxActivationKey` resources in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListHcxActivationKeysRequest request =
               ListHcxActivationKeysRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           for (HcxActivationKey element :
               vmwareEngineClient.listHcxActivationKeys(request).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        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
      • listHcxActivationKeysPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListHcxActivationKeysRequest,​VmwareEngineClient.ListHcxActivationKeysPagedResponse> listHcxActivationKeysPagedCallable()
        Lists `HcxActivationKey` resources in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListHcxActivationKeysRequest request =
               ListHcxActivationKeysRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           ApiFuture<HcxActivationKey> future =
               vmwareEngineClient.listHcxActivationKeysPagedCallable().futureCall(request);
           // Do something.
           for (HcxActivationKey element : future.get().iterateAll()) {
             // doThingsWith(element);
           }
         }
         
      • listHcxActivationKeysCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListHcxActivationKeysRequest,​ListHcxActivationKeysResponse> listHcxActivationKeysCallable()
        Lists `HcxActivationKey` resources in a given private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListHcxActivationKeysRequest request =
               ListHcxActivationKeysRequest.newBuilder()
                   .setParent(
                       PrivateCloudName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           while (true) {
             ListHcxActivationKeysResponse response =
                 vmwareEngineClient.listHcxActivationKeysCallable().call(request);
             for (HcxActivationKey element : response.getHcxActivationKeysList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • getHcxActivationKey

        public final HcxActivationKey getHcxActivationKey​(HcxActivationKeyName name)
        Retrieves a `HcxActivationKey` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           HcxActivationKeyName name =
               HcxActivationKeyName.of(
                   "[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[HCX_ACTIVATION_KEY]");
           HcxActivationKey response = vmwareEngineClient.getHcxActivationKey(name);
         }
         
        Parameters:
        name - Required. The resource name of the HCX activation key to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getHcxActivationKey

        public final HcxActivationKey getHcxActivationKey​(String name)
        Retrieves a `HcxActivationKey` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name =
               HcxActivationKeyName.of(
                       "[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[HCX_ACTIVATION_KEY]")
                   .toString();
           HcxActivationKey response = vmwareEngineClient.getHcxActivationKey(name);
         }
         
        Parameters:
        name - Required. The resource name of the HCX activation key to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getHcxActivationKey

        public final HcxActivationKey getHcxActivationKey​(GetHcxActivationKeyRequest request)
        Retrieves a `HcxActivationKey` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetHcxActivationKeyRequest request =
               GetHcxActivationKeyRequest.newBuilder()
                   .setName(
                       HcxActivationKeyName.of(
                               "[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[HCX_ACTIVATION_KEY]")
                           .toString())
                   .build();
           HcxActivationKey response = vmwareEngineClient.getHcxActivationKey(request);
         }
         
        Parameters:
        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
      • getHcxActivationKeyCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetHcxActivationKeyRequest,​HcxActivationKey> getHcxActivationKeyCallable()
        Retrieves a `HcxActivationKey` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetHcxActivationKeyRequest request =
               GetHcxActivationKeyRequest.newBuilder()
                   .setName(
                       HcxActivationKeyName.of(
                               "[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[HCX_ACTIVATION_KEY]")
                           .toString())
                   .build();
           ApiFuture<HcxActivationKey> future =
               vmwareEngineClient.getHcxActivationKeyCallable().futureCall(request);
           // Do something.
           HcxActivationKey response = future.get();
         }
         
      • getNetworkPolicy

        public final NetworkPolicy getNetworkPolicy​(NetworkPolicyName name)
        Retrieves a `NetworkPolicy` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           NetworkPolicyName name = NetworkPolicyName.of("[PROJECT]", "[LOCATION]", "[NETWORK_POLICY]");
           NetworkPolicy response = vmwareEngineClient.getNetworkPolicy(name);
         }
         
        Parameters:
        name - Required. The resource name of the network policy to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/networkPolicies/my-network-policy`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getNetworkPolicy

        public final NetworkPolicy getNetworkPolicy​(String name)
        Retrieves a `NetworkPolicy` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name = NetworkPolicyName.of("[PROJECT]", "[LOCATION]", "[NETWORK_POLICY]").toString();
           NetworkPolicy response = vmwareEngineClient.getNetworkPolicy(name);
         }
         
        Parameters:
        name - Required. The resource name of the network policy to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/networkPolicies/my-network-policy`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getNetworkPolicy

        public final NetworkPolicy getNetworkPolicy​(GetNetworkPolicyRequest request)
        Retrieves a `NetworkPolicy` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetNetworkPolicyRequest request =
               GetNetworkPolicyRequest.newBuilder()
                   .setName(
                       NetworkPolicyName.of("[PROJECT]", "[LOCATION]", "[NETWORK_POLICY]").toString())
                   .build();
           NetworkPolicy response = vmwareEngineClient.getNetworkPolicy(request);
         }
         
        Parameters:
        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
      • getNetworkPolicyCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetNetworkPolicyRequest,​NetworkPolicy> getNetworkPolicyCallable()
        Retrieves a `NetworkPolicy` resource by its resource name.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetNetworkPolicyRequest request =
               GetNetworkPolicyRequest.newBuilder()
                   .setName(
                       NetworkPolicyName.of("[PROJECT]", "[LOCATION]", "[NETWORK_POLICY]").toString())
                   .build();
           ApiFuture<NetworkPolicy> future =
               vmwareEngineClient.getNetworkPolicyCallable().futureCall(request);
           // Do something.
           NetworkPolicy response = future.get();
         }
         
      • listNetworkPolicies

        public final VmwareEngineClient.ListNetworkPoliciesPagedResponse listNetworkPolicies​(LocationName parent)
        Lists `NetworkPolicy` resources in a specified project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           for (NetworkPolicy element : vmwareEngineClient.listNetworkPolicies(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the location (region) to query for network policies. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listNetworkPolicies

        public final VmwareEngineClient.ListNetworkPoliciesPagedResponse listNetworkPolicies​(String parent)
        Lists `NetworkPolicy` resources in a specified project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           for (NetworkPolicy element : vmwareEngineClient.listNetworkPolicies(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the location (region) to query for network policies. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listNetworkPolicies

        public final VmwareEngineClient.ListNetworkPoliciesPagedResponse listNetworkPolicies​(ListNetworkPoliciesRequest request)
        Lists `NetworkPolicy` resources in a specified project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListNetworkPoliciesRequest request =
               ListNetworkPoliciesRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           for (NetworkPolicy element : vmwareEngineClient.listNetworkPolicies(request).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        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
      • listNetworkPoliciesPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListNetworkPoliciesRequest,​VmwareEngineClient.ListNetworkPoliciesPagedResponse> listNetworkPoliciesPagedCallable()
        Lists `NetworkPolicy` resources in a specified project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListNetworkPoliciesRequest request =
               ListNetworkPoliciesRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           ApiFuture<NetworkPolicy> future =
               vmwareEngineClient.listNetworkPoliciesPagedCallable().futureCall(request);
           // Do something.
           for (NetworkPolicy element : future.get().iterateAll()) {
             // doThingsWith(element);
           }
         }
         
      • listNetworkPoliciesCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListNetworkPoliciesRequest,​ListNetworkPoliciesResponse> listNetworkPoliciesCallable()
        Lists `NetworkPolicy` resources in a specified project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListNetworkPoliciesRequest request =
               ListNetworkPoliciesRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           while (true) {
             ListNetworkPoliciesResponse response =
                 vmwareEngineClient.listNetworkPoliciesCallable().call(request);
             for (NetworkPolicy element : response.getNetworkPoliciesList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • createNetworkPolicyAsync

        public final com.google.api.gax.longrunning.OperationFuture<NetworkPolicy,​OperationMetadata> createNetworkPolicyAsync​(LocationName parent,
                                                                                                                                    NetworkPolicy networkPolicy,
                                                                                                                                    String networkPolicyId)
        Creates a new network policy in a given VMware Engine network of a project and location (region). A new network policy cannot be created if another network policy already exists in the same scope.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           NetworkPolicy networkPolicy = NetworkPolicy.newBuilder().build();
           String networkPolicyId = "networkPolicyId-727262661";
           NetworkPolicy response =
               vmwareEngineClient.createNetworkPolicyAsync(parent, networkPolicy, networkPolicyId).get();
         }
         
        Parameters:
        parent - Required. The resource name of the location (region) to create the new network policy in. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1`
        networkPolicy - Required. The network policy configuration to use in the request.
        networkPolicyId - Required. The user-provided identifier of the network policy to be created. This identifier must be unique within parent `projects/{my-project}/locations/{us-central1}/networkPolicies` and becomes the final token in the name URI. The identifier must meet the following requirements:
        • Only contains 1-63 alphanumeric characters and hyphens
        • Begins with an alphabetical character
        • Ends with a non-hyphen character
        • Not formatted as a UUID
        • Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5)
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createNetworkPolicyAsync

        public final com.google.api.gax.longrunning.OperationFuture<NetworkPolicy,​OperationMetadata> createNetworkPolicyAsync​(String parent,
                                                                                                                                    NetworkPolicy networkPolicy,
                                                                                                                                    String networkPolicyId)
        Creates a new network policy in a given VMware Engine network of a project and location (region). A new network policy cannot be created if another network policy already exists in the same scope.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           NetworkPolicy networkPolicy = NetworkPolicy.newBuilder().build();
           String networkPolicyId = "networkPolicyId-727262661";
           NetworkPolicy response =
               vmwareEngineClient.createNetworkPolicyAsync(parent, networkPolicy, networkPolicyId).get();
         }
         
        Parameters:
        parent - Required. The resource name of the location (region) to create the new network policy in. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1`
        networkPolicy - Required. The network policy configuration to use in the request.
        networkPolicyId - Required. The user-provided identifier of the network policy to be created. This identifier must be unique within parent `projects/{my-project}/locations/{us-central1}/networkPolicies` and becomes the final token in the name URI. The identifier must meet the following requirements:
        • Only contains 1-63 alphanumeric characters and hyphens
        • Begins with an alphabetical character
        • Ends with a non-hyphen character
        • Not formatted as a UUID
        • Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5)
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createNetworkPolicyAsync

        public final com.google.api.gax.longrunning.OperationFuture<NetworkPolicy,​OperationMetadata> createNetworkPolicyAsync​(CreateNetworkPolicyRequest request)
        Creates a new network policy in a given VMware Engine network of a project and location (region). A new network policy cannot be created if another network policy already exists in the same scope.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreateNetworkPolicyRequest request =
               CreateNetworkPolicyRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setNetworkPolicyId("networkPolicyId-727262661")
                   .setNetworkPolicy(NetworkPolicy.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           NetworkPolicy response = vmwareEngineClient.createNetworkPolicyAsync(request).get();
         }
         
        Parameters:
        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
      • createNetworkPolicyOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<CreateNetworkPolicyRequest,​NetworkPolicy,​OperationMetadata> createNetworkPolicyOperationCallable()
        Creates a new network policy in a given VMware Engine network of a project and location (region). A new network policy cannot be created if another network policy already exists in the same scope.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreateNetworkPolicyRequest request =
               CreateNetworkPolicyRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setNetworkPolicyId("networkPolicyId-727262661")
                   .setNetworkPolicy(NetworkPolicy.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<NetworkPolicy, OperationMetadata> future =
               vmwareEngineClient.createNetworkPolicyOperationCallable().futureCall(request);
           // Do something.
           NetworkPolicy response = future.get();
         }
         
      • createNetworkPolicyCallable

        public final com.google.api.gax.rpc.UnaryCallable<CreateNetworkPolicyRequest,​com.google.longrunning.Operation> createNetworkPolicyCallable()
        Creates a new network policy in a given VMware Engine network of a project and location (region). A new network policy cannot be created if another network policy already exists in the same scope.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreateNetworkPolicyRequest request =
               CreateNetworkPolicyRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setNetworkPolicyId("networkPolicyId-727262661")
                   .setNetworkPolicy(NetworkPolicy.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.createNetworkPolicyCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • updateNetworkPolicyAsync

        public final com.google.api.gax.longrunning.OperationFuture<NetworkPolicy,​OperationMetadata> updateNetworkPolicyAsync​(NetworkPolicy networkPolicy,
                                                                                                                                    com.google.protobuf.FieldMask updateMask)
        Modifies a `NetworkPolicy` resource. Only the following fields can be updated: `internet_access`, `external_ip`, `edge_services_cidr`. Only fields specified in `updateMask` are applied. When updating a network policy, the external IP network service can only be disabled if there are no external IP addresses present in the scope of the policy. Also, a `NetworkService` cannot be updated when `NetworkService.state` is set to `RECONCILING`.

        During operation processing, the resource is temporarily in the `ACTIVE` state before the operation fully completes. For that period of time, you can't update the resource. Use the operation status to determine when the processing fully completes.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           NetworkPolicy networkPolicy = NetworkPolicy.newBuilder().build();
           FieldMask updateMask = FieldMask.newBuilder().build();
           NetworkPolicy response =
               vmwareEngineClient.updateNetworkPolicyAsync(networkPolicy, updateMask).get();
         }
         
        Parameters:
        networkPolicy - Required. Network policy description.
        updateMask - Required. Field mask is used to specify the fields to be overwritten in the `NetworkPolicy` resource by the update. The fields specified in the `update_mask` are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • updateNetworkPolicyAsync

        public final com.google.api.gax.longrunning.OperationFuture<NetworkPolicy,​OperationMetadata> updateNetworkPolicyAsync​(UpdateNetworkPolicyRequest request)
        Modifies a `NetworkPolicy` resource. Only the following fields can be updated: `internet_access`, `external_ip`, `edge_services_cidr`. Only fields specified in `updateMask` are applied. When updating a network policy, the external IP network service can only be disabled if there are no external IP addresses present in the scope of the policy. Also, a `NetworkService` cannot be updated when `NetworkService.state` is set to `RECONCILING`.

        During operation processing, the resource is temporarily in the `ACTIVE` state before the operation fully completes. For that period of time, you can't update the resource. Use the operation status to determine when the processing fully completes.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdateNetworkPolicyRequest request =
               UpdateNetworkPolicyRequest.newBuilder()
                   .setNetworkPolicy(NetworkPolicy.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           NetworkPolicy response = vmwareEngineClient.updateNetworkPolicyAsync(request).get();
         }
         
        Parameters:
        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
      • updateNetworkPolicyOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UpdateNetworkPolicyRequest,​NetworkPolicy,​OperationMetadata> updateNetworkPolicyOperationCallable()
        Modifies a `NetworkPolicy` resource. Only the following fields can be updated: `internet_access`, `external_ip`, `edge_services_cidr`. Only fields specified in `updateMask` are applied. When updating a network policy, the external IP network service can only be disabled if there are no external IP addresses present in the scope of the policy. Also, a `NetworkService` cannot be updated when `NetworkService.state` is set to `RECONCILING`.

        During operation processing, the resource is temporarily in the `ACTIVE` state before the operation fully completes. For that period of time, you can't update the resource. Use the operation status to determine when the processing fully completes.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdateNetworkPolicyRequest request =
               UpdateNetworkPolicyRequest.newBuilder()
                   .setNetworkPolicy(NetworkPolicy.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<NetworkPolicy, OperationMetadata> future =
               vmwareEngineClient.updateNetworkPolicyOperationCallable().futureCall(request);
           // Do something.
           NetworkPolicy response = future.get();
         }
         
      • updateNetworkPolicyCallable

        public final com.google.api.gax.rpc.UnaryCallable<UpdateNetworkPolicyRequest,​com.google.longrunning.Operation> updateNetworkPolicyCallable()
        Modifies a `NetworkPolicy` resource. Only the following fields can be updated: `internet_access`, `external_ip`, `edge_services_cidr`. Only fields specified in `updateMask` are applied. When updating a network policy, the external IP network service can only be disabled if there are no external IP addresses present in the scope of the policy. Also, a `NetworkService` cannot be updated when `NetworkService.state` is set to `RECONCILING`.

        During operation processing, the resource is temporarily in the `ACTIVE` state before the operation fully completes. For that period of time, you can't update the resource. Use the operation status to determine when the processing fully completes.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdateNetworkPolicyRequest request =
               UpdateNetworkPolicyRequest.newBuilder()
                   .setNetworkPolicy(NetworkPolicy.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.updateNetworkPolicyCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • deleteNetworkPolicyAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteNetworkPolicyAsync​(NetworkPolicyName name)
        Deletes a `NetworkPolicy` resource. A network policy cannot be deleted when `NetworkService.state` is set to `RECONCILING` for either its external IP or internet access service.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           NetworkPolicyName name = NetworkPolicyName.of("[PROJECT]", "[LOCATION]", "[NETWORK_POLICY]");
           vmwareEngineClient.deleteNetworkPolicyAsync(name).get();
         }
         
        Parameters:
        name - Required. The resource name of the network policy to delete. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/networkPolicies/my-network-policy`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteNetworkPolicyAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteNetworkPolicyAsync​(String name)
        Deletes a `NetworkPolicy` resource. A network policy cannot be deleted when `NetworkService.state` is set to `RECONCILING` for either its external IP or internet access service.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name = NetworkPolicyName.of("[PROJECT]", "[LOCATION]", "[NETWORK_POLICY]").toString();
           vmwareEngineClient.deleteNetworkPolicyAsync(name).get();
         }
         
        Parameters:
        name - Required. The resource name of the network policy to delete. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/networkPolicies/my-network-policy`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteNetworkPolicyAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteNetworkPolicyAsync​(DeleteNetworkPolicyRequest request)
        Deletes a `NetworkPolicy` resource. A network policy cannot be deleted when `NetworkService.state` is set to `RECONCILING` for either its external IP or internet access service.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeleteNetworkPolicyRequest request =
               DeleteNetworkPolicyRequest.newBuilder()
                   .setName(
                       NetworkPolicyName.of("[PROJECT]", "[LOCATION]", "[NETWORK_POLICY]").toString())
                   .setRequestId("requestId693933066")
                   .build();
           vmwareEngineClient.deleteNetworkPolicyAsync(request).get();
         }
         
        Parameters:
        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
      • deleteNetworkPolicyOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<DeleteNetworkPolicyRequest,​com.google.protobuf.Empty,​OperationMetadata> deleteNetworkPolicyOperationCallable()
        Deletes a `NetworkPolicy` resource. A network policy cannot be deleted when `NetworkService.state` is set to `RECONCILING` for either its external IP or internet access service.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeleteNetworkPolicyRequest request =
               DeleteNetworkPolicyRequest.newBuilder()
                   .setName(
                       NetworkPolicyName.of("[PROJECT]", "[LOCATION]", "[NETWORK_POLICY]").toString())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<Empty, OperationMetadata> future =
               vmwareEngineClient.deleteNetworkPolicyOperationCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • deleteNetworkPolicyCallable

        public final com.google.api.gax.rpc.UnaryCallable<DeleteNetworkPolicyRequest,​com.google.longrunning.Operation> deleteNetworkPolicyCallable()
        Deletes a `NetworkPolicy` resource. A network policy cannot be deleted when `NetworkService.state` is set to `RECONCILING` for either its external IP or internet access service.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeleteNetworkPolicyRequest request =
               DeleteNetworkPolicyRequest.newBuilder()
                   .setName(
                       NetworkPolicyName.of("[PROJECT]", "[LOCATION]", "[NETWORK_POLICY]").toString())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.deleteNetworkPolicyCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • createVmwareEngineNetworkAsync

        public final com.google.api.gax.longrunning.OperationFuture<VmwareEngineNetwork,​OperationMetadata> createVmwareEngineNetworkAsync​(LocationName parent,
                                                                                                                                                VmwareEngineNetwork vmwareEngineNetwork,
                                                                                                                                                String vmwareEngineNetworkId)
        Creates a new VMware Engine network that can be used by a private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           VmwareEngineNetwork vmwareEngineNetwork = VmwareEngineNetwork.newBuilder().build();
           String vmwareEngineNetworkId = "vmwareEngineNetworkId532532083";
           VmwareEngineNetwork response =
               vmwareEngineClient
                   .createVmwareEngineNetworkAsync(parent, vmwareEngineNetwork, vmwareEngineNetworkId)
                   .get();
         }
         
        Parameters:
        parent - Required. The resource name of the location to create the new VMware Engine network in. A VMware Engine network of type `LEGACY` is a regional resource, and a VMware Engine network of type `STANDARD` is a global resource. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/global`
        vmwareEngineNetwork - Required. The initial description of the new VMware Engine network.
        vmwareEngineNetworkId - Required. The user-provided identifier of the new VMware Engine network. This identifier must be unique among VMware Engine network resources within the parent and becomes the final token in the name URI. The identifier must meet the following requirements:
        • For networks of type LEGACY, adheres to the format: `{region-id}-default`. Replace `{region-id}` with the region where you want to create the VMware Engine network. For example, "us-central1-default".
        • Only contains 1-63 alphanumeric characters and hyphens
        • Begins with an alphabetical character
        • Ends with a non-hyphen character
        • Not formatted as a UUID
        • Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5)
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createVmwareEngineNetworkAsync

        public final com.google.api.gax.longrunning.OperationFuture<VmwareEngineNetwork,​OperationMetadata> createVmwareEngineNetworkAsync​(String parent,
                                                                                                                                                VmwareEngineNetwork vmwareEngineNetwork,
                                                                                                                                                String vmwareEngineNetworkId)
        Creates a new VMware Engine network that can be used by a private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           VmwareEngineNetwork vmwareEngineNetwork = VmwareEngineNetwork.newBuilder().build();
           String vmwareEngineNetworkId = "vmwareEngineNetworkId532532083";
           VmwareEngineNetwork response =
               vmwareEngineClient
                   .createVmwareEngineNetworkAsync(parent, vmwareEngineNetwork, vmwareEngineNetworkId)
                   .get();
         }
         
        Parameters:
        parent - Required. The resource name of the location to create the new VMware Engine network in. A VMware Engine network of type `LEGACY` is a regional resource, and a VMware Engine network of type `STANDARD` is a global resource. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/global`
        vmwareEngineNetwork - Required. The initial description of the new VMware Engine network.
        vmwareEngineNetworkId - Required. The user-provided identifier of the new VMware Engine network. This identifier must be unique among VMware Engine network resources within the parent and becomes the final token in the name URI. The identifier must meet the following requirements:
        • For networks of type LEGACY, adheres to the format: `{region-id}-default`. Replace `{region-id}` with the region where you want to create the VMware Engine network. For example, "us-central1-default".
        • Only contains 1-63 alphanumeric characters and hyphens
        • Begins with an alphabetical character
        • Ends with a non-hyphen character
        • Not formatted as a UUID
        • Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5)
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createVmwareEngineNetworkAsync

        public final com.google.api.gax.longrunning.OperationFuture<VmwareEngineNetwork,​OperationMetadata> createVmwareEngineNetworkAsync​(CreateVmwareEngineNetworkRequest request)
        Creates a new VMware Engine network that can be used by a private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreateVmwareEngineNetworkRequest request =
               CreateVmwareEngineNetworkRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setVmwareEngineNetworkId("vmwareEngineNetworkId532532083")
                   .setVmwareEngineNetwork(VmwareEngineNetwork.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           VmwareEngineNetwork response =
               vmwareEngineClient.createVmwareEngineNetworkAsync(request).get();
         }
         
        Parameters:
        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
      • createVmwareEngineNetworkOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<CreateVmwareEngineNetworkRequest,​VmwareEngineNetwork,​OperationMetadata> createVmwareEngineNetworkOperationCallable()
        Creates a new VMware Engine network that can be used by a private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreateVmwareEngineNetworkRequest request =
               CreateVmwareEngineNetworkRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setVmwareEngineNetworkId("vmwareEngineNetworkId532532083")
                   .setVmwareEngineNetwork(VmwareEngineNetwork.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<VmwareEngineNetwork, OperationMetadata> future =
               vmwareEngineClient.createVmwareEngineNetworkOperationCallable().futureCall(request);
           // Do something.
           VmwareEngineNetwork response = future.get();
         }
         
      • createVmwareEngineNetworkCallable

        public final com.google.api.gax.rpc.UnaryCallable<CreateVmwareEngineNetworkRequest,​com.google.longrunning.Operation> createVmwareEngineNetworkCallable()
        Creates a new VMware Engine network that can be used by a private cloud.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreateVmwareEngineNetworkRequest request =
               CreateVmwareEngineNetworkRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setVmwareEngineNetworkId("vmwareEngineNetworkId532532083")
                   .setVmwareEngineNetwork(VmwareEngineNetwork.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.createVmwareEngineNetworkCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • updateVmwareEngineNetworkAsync

        public final com.google.api.gax.longrunning.OperationFuture<VmwareEngineNetwork,​OperationMetadata> updateVmwareEngineNetworkAsync​(VmwareEngineNetwork vmwareEngineNetwork,
                                                                                                                                                com.google.protobuf.FieldMask updateMask)
        Modifies a VMware Engine network resource. Only the following fields can be updated: `description`. Only fields specified in `updateMask` are applied.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           VmwareEngineNetwork vmwareEngineNetwork = VmwareEngineNetwork.newBuilder().build();
           FieldMask updateMask = FieldMask.newBuilder().build();
           VmwareEngineNetwork response =
               vmwareEngineClient.updateVmwareEngineNetworkAsync(vmwareEngineNetwork, updateMask).get();
         }
         
        Parameters:
        vmwareEngineNetwork - Required. VMware Engine network description.
        updateMask - Required. Field mask is used to specify the fields to be overwritten in the VMware Engine network resource by the update. The fields specified in the `update_mask` are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten. Only the following fields can be updated: `description`.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • updateVmwareEngineNetworkAsync

        public final com.google.api.gax.longrunning.OperationFuture<VmwareEngineNetwork,​OperationMetadata> updateVmwareEngineNetworkAsync​(UpdateVmwareEngineNetworkRequest request)
        Modifies a VMware Engine network resource. Only the following fields can be updated: `description`. Only fields specified in `updateMask` are applied.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdateVmwareEngineNetworkRequest request =
               UpdateVmwareEngineNetworkRequest.newBuilder()
                   .setVmwareEngineNetwork(VmwareEngineNetwork.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           VmwareEngineNetwork response =
               vmwareEngineClient.updateVmwareEngineNetworkAsync(request).get();
         }
         
        Parameters:
        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
      • updateVmwareEngineNetworkOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UpdateVmwareEngineNetworkRequest,​VmwareEngineNetwork,​OperationMetadata> updateVmwareEngineNetworkOperationCallable()
        Modifies a VMware Engine network resource. Only the following fields can be updated: `description`. Only fields specified in `updateMask` are applied.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdateVmwareEngineNetworkRequest request =
               UpdateVmwareEngineNetworkRequest.newBuilder()
                   .setVmwareEngineNetwork(VmwareEngineNetwork.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<VmwareEngineNetwork, OperationMetadata> future =
               vmwareEngineClient.updateVmwareEngineNetworkOperationCallable().futureCall(request);
           // Do something.
           VmwareEngineNetwork response = future.get();
         }
         
      • updateVmwareEngineNetworkCallable

        public final com.google.api.gax.rpc.UnaryCallable<UpdateVmwareEngineNetworkRequest,​com.google.longrunning.Operation> updateVmwareEngineNetworkCallable()
        Modifies a VMware Engine network resource. Only the following fields can be updated: `description`. Only fields specified in `updateMask` are applied.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdateVmwareEngineNetworkRequest request =
               UpdateVmwareEngineNetworkRequest.newBuilder()
                   .setVmwareEngineNetwork(VmwareEngineNetwork.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.updateVmwareEngineNetworkCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • deleteVmwareEngineNetworkAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteVmwareEngineNetworkAsync​(VmwareEngineNetworkName name)
        Deletes a `VmwareEngineNetwork` resource. You can only delete a VMware Engine network after all resources that refer to it are deleted. For example, a private cloud, a network peering, and a network policy can all refer to the same VMware Engine network.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           VmwareEngineNetworkName name =
               VmwareEngineNetworkName.of("[PROJECT]", "[LOCATION]", "[VMWARE_ENGINE_NETWORK]");
           vmwareEngineClient.deleteVmwareEngineNetworkAsync(name).get();
         }
         
        Parameters:
        name - Required. The resource name of the VMware Engine network to be deleted. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/global/vmwareEngineNetworks/my-network`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteVmwareEngineNetworkAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteVmwareEngineNetworkAsync​(String name)
        Deletes a `VmwareEngineNetwork` resource. You can only delete a VMware Engine network after all resources that refer to it are deleted. For example, a private cloud, a network peering, and a network policy can all refer to the same VMware Engine network.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name =
               VmwareEngineNetworkName.of("[PROJECT]", "[LOCATION]", "[VMWARE_ENGINE_NETWORK]")
                   .toString();
           vmwareEngineClient.deleteVmwareEngineNetworkAsync(name).get();
         }
         
        Parameters:
        name - Required. The resource name of the VMware Engine network to be deleted. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/global/vmwareEngineNetworks/my-network`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteVmwareEngineNetworkAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteVmwareEngineNetworkAsync​(DeleteVmwareEngineNetworkRequest request)
        Deletes a `VmwareEngineNetwork` resource. You can only delete a VMware Engine network after all resources that refer to it are deleted. For example, a private cloud, a network peering, and a network policy can all refer to the same VMware Engine network.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeleteVmwareEngineNetworkRequest request =
               DeleteVmwareEngineNetworkRequest.newBuilder()
                   .setName(
                       VmwareEngineNetworkName.of("[PROJECT]", "[LOCATION]", "[VMWARE_ENGINE_NETWORK]")
                           .toString())
                   .setRequestId("requestId693933066")
                   .setEtag("etag3123477")
                   .build();
           vmwareEngineClient.deleteVmwareEngineNetworkAsync(request).get();
         }
         
        Parameters:
        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
      • deleteVmwareEngineNetworkOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<DeleteVmwareEngineNetworkRequest,​com.google.protobuf.Empty,​OperationMetadata> deleteVmwareEngineNetworkOperationCallable()
        Deletes a `VmwareEngineNetwork` resource. You can only delete a VMware Engine network after all resources that refer to it are deleted. For example, a private cloud, a network peering, and a network policy can all refer to the same VMware Engine network.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeleteVmwareEngineNetworkRequest request =
               DeleteVmwareEngineNetworkRequest.newBuilder()
                   .setName(
                       VmwareEngineNetworkName.of("[PROJECT]", "[LOCATION]", "[VMWARE_ENGINE_NETWORK]")
                           .toString())
                   .setRequestId("requestId693933066")
                   .setEtag("etag3123477")
                   .build();
           OperationFuture<Empty, OperationMetadata> future =
               vmwareEngineClient.deleteVmwareEngineNetworkOperationCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • deleteVmwareEngineNetworkCallable

        public final com.google.api.gax.rpc.UnaryCallable<DeleteVmwareEngineNetworkRequest,​com.google.longrunning.Operation> deleteVmwareEngineNetworkCallable()
        Deletes a `VmwareEngineNetwork` resource. You can only delete a VMware Engine network after all resources that refer to it are deleted. For example, a private cloud, a network peering, and a network policy can all refer to the same VMware Engine network.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeleteVmwareEngineNetworkRequest request =
               DeleteVmwareEngineNetworkRequest.newBuilder()
                   .setName(
                       VmwareEngineNetworkName.of("[PROJECT]", "[LOCATION]", "[VMWARE_ENGINE_NETWORK]")
                           .toString())
                   .setRequestId("requestId693933066")
                   .setEtag("etag3123477")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.deleteVmwareEngineNetworkCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • getVmwareEngineNetwork

        public final VmwareEngineNetwork getVmwareEngineNetwork​(VmwareEngineNetworkName name)
        Retrieves a `VmwareEngineNetwork` resource by its resource name. The resource contains details of the VMware Engine network, such as its VMware Engine network type, peered networks in a service project, and state (for example, `CREATING`, `ACTIVE`, `DELETING`).

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           VmwareEngineNetworkName name =
               VmwareEngineNetworkName.of("[PROJECT]", "[LOCATION]", "[VMWARE_ENGINE_NETWORK]");
           VmwareEngineNetwork response = vmwareEngineClient.getVmwareEngineNetwork(name);
         }
         
        Parameters:
        name - Required. The resource name of the VMware Engine network to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/global/vmwareEngineNetworks/my-network`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getVmwareEngineNetwork

        public final VmwareEngineNetwork getVmwareEngineNetwork​(String name)
        Retrieves a `VmwareEngineNetwork` resource by its resource name. The resource contains details of the VMware Engine network, such as its VMware Engine network type, peered networks in a service project, and state (for example, `CREATING`, `ACTIVE`, `DELETING`).

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name =
               VmwareEngineNetworkName.of("[PROJECT]", "[LOCATION]", "[VMWARE_ENGINE_NETWORK]")
                   .toString();
           VmwareEngineNetwork response = vmwareEngineClient.getVmwareEngineNetwork(name);
         }
         
        Parameters:
        name - Required. The resource name of the VMware Engine network to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/global/vmwareEngineNetworks/my-network`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getVmwareEngineNetwork

        public final VmwareEngineNetwork getVmwareEngineNetwork​(GetVmwareEngineNetworkRequest request)
        Retrieves a `VmwareEngineNetwork` resource by its resource name. The resource contains details of the VMware Engine network, such as its VMware Engine network type, peered networks in a service project, and state (for example, `CREATING`, `ACTIVE`, `DELETING`).

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetVmwareEngineNetworkRequest request =
               GetVmwareEngineNetworkRequest.newBuilder()
                   .setName(
                       VmwareEngineNetworkName.of("[PROJECT]", "[LOCATION]", "[VMWARE_ENGINE_NETWORK]")
                           .toString())
                   .build();
           VmwareEngineNetwork response = vmwareEngineClient.getVmwareEngineNetwork(request);
         }
         
        Parameters:
        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
      • getVmwareEngineNetworkCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetVmwareEngineNetworkRequest,​VmwareEngineNetwork> getVmwareEngineNetworkCallable()
        Retrieves a `VmwareEngineNetwork` resource by its resource name. The resource contains details of the VMware Engine network, such as its VMware Engine network type, peered networks in a service project, and state (for example, `CREATING`, `ACTIVE`, `DELETING`).

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetVmwareEngineNetworkRequest request =
               GetVmwareEngineNetworkRequest.newBuilder()
                   .setName(
                       VmwareEngineNetworkName.of("[PROJECT]", "[LOCATION]", "[VMWARE_ENGINE_NETWORK]")
                           .toString())
                   .build();
           ApiFuture<VmwareEngineNetwork> future =
               vmwareEngineClient.getVmwareEngineNetworkCallable().futureCall(request);
           // Do something.
           VmwareEngineNetwork response = future.get();
         }
         
      • listVmwareEngineNetworks

        public final VmwareEngineClient.ListVmwareEngineNetworksPagedResponse listVmwareEngineNetworks​(LocationName parent)
        Lists `VmwareEngineNetwork` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           for (VmwareEngineNetwork element :
               vmwareEngineClient.listVmwareEngineNetworks(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the location to query for VMware Engine networks. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/global`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listVmwareEngineNetworks

        public final VmwareEngineClient.ListVmwareEngineNetworksPagedResponse listVmwareEngineNetworks​(String parent)
        Lists `VmwareEngineNetwork` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           for (VmwareEngineNetwork element :
               vmwareEngineClient.listVmwareEngineNetworks(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the location to query for VMware Engine networks. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/global`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listVmwareEngineNetworks

        public final VmwareEngineClient.ListVmwareEngineNetworksPagedResponse listVmwareEngineNetworks​(ListVmwareEngineNetworksRequest request)
        Lists `VmwareEngineNetwork` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListVmwareEngineNetworksRequest request =
               ListVmwareEngineNetworksRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           for (VmwareEngineNetwork element :
               vmwareEngineClient.listVmwareEngineNetworks(request).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        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
      • listVmwareEngineNetworksPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListVmwareEngineNetworksRequest,​VmwareEngineClient.ListVmwareEngineNetworksPagedResponse> listVmwareEngineNetworksPagedCallable()
        Lists `VmwareEngineNetwork` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListVmwareEngineNetworksRequest request =
               ListVmwareEngineNetworksRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           ApiFuture<VmwareEngineNetwork> future =
               vmwareEngineClient.listVmwareEngineNetworksPagedCallable().futureCall(request);
           // Do something.
           for (VmwareEngineNetwork element : future.get().iterateAll()) {
             // doThingsWith(element);
           }
         }
         
      • listVmwareEngineNetworksCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListVmwareEngineNetworksRequest,​ListVmwareEngineNetworksResponse> listVmwareEngineNetworksCallable()
        Lists `VmwareEngineNetwork` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListVmwareEngineNetworksRequest request =
               ListVmwareEngineNetworksRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           while (true) {
             ListVmwareEngineNetworksResponse response =
                 vmwareEngineClient.listVmwareEngineNetworksCallable().call(request);
             for (VmwareEngineNetwork element : response.getVmwareEngineNetworksList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • createPrivateConnectionAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateConnection,​OperationMetadata> createPrivateConnectionAsync​(LocationName parent,
                                                                                                                                            PrivateConnection privateConnection,
                                                                                                                                            String privateConnectionId)
        Creates a new private connection that can be used for accessing private Clouds.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           PrivateConnection privateConnection = PrivateConnection.newBuilder().build();
           String privateConnectionId = "privateConnectionId-1926654532";
           PrivateConnection response =
               vmwareEngineClient
                   .createPrivateConnectionAsync(parent, privateConnection, privateConnectionId)
                   .get();
         }
         
        Parameters:
        parent - Required. The resource name of the location to create the new private connection in. Private connection is a regional resource. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1`
        privateConnection - Required. The initial description of the new private connection.
        privateConnectionId - Required. The user-provided identifier of the new private connection. This identifier must be unique among private connection resources within the parent and becomes the final token in the name URI. The identifier must meet the following requirements:
        • Only contains 1-63 alphanumeric characters and hyphens
        • Begins with an alphabetical character
        • Ends with a non-hyphen character
        • Not formatted as a UUID
        • Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5)
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createPrivateConnectionAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateConnection,​OperationMetadata> createPrivateConnectionAsync​(String parent,
                                                                                                                                            PrivateConnection privateConnection,
                                                                                                                                            String privateConnectionId)
        Creates a new private connection that can be used for accessing private Clouds.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           PrivateConnection privateConnection = PrivateConnection.newBuilder().build();
           String privateConnectionId = "privateConnectionId-1926654532";
           PrivateConnection response =
               vmwareEngineClient
                   .createPrivateConnectionAsync(parent, privateConnection, privateConnectionId)
                   .get();
         }
         
        Parameters:
        parent - Required. The resource name of the location to create the new private connection in. Private connection is a regional resource. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1`
        privateConnection - Required. The initial description of the new private connection.
        privateConnectionId - Required. The user-provided identifier of the new private connection. This identifier must be unique among private connection resources within the parent and becomes the final token in the name URI. The identifier must meet the following requirements:
        • Only contains 1-63 alphanumeric characters and hyphens
        • Begins with an alphabetical character
        • Ends with a non-hyphen character
        • Not formatted as a UUID
        • Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5)
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createPrivateConnectionAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateConnection,​OperationMetadata> createPrivateConnectionAsync​(CreatePrivateConnectionRequest request)
        Creates a new private connection that can be used for accessing private Clouds.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreatePrivateConnectionRequest request =
               CreatePrivateConnectionRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPrivateConnectionId("privateConnectionId-1926654532")
                   .setPrivateConnection(PrivateConnection.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           PrivateConnection response = vmwareEngineClient.createPrivateConnectionAsync(request).get();
         }
         
        Parameters:
        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
      • createPrivateConnectionOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<CreatePrivateConnectionRequest,​PrivateConnection,​OperationMetadata> createPrivateConnectionOperationCallable()
        Creates a new private connection that can be used for accessing private Clouds.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreatePrivateConnectionRequest request =
               CreatePrivateConnectionRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPrivateConnectionId("privateConnectionId-1926654532")
                   .setPrivateConnection(PrivateConnection.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<PrivateConnection, OperationMetadata> future =
               vmwareEngineClient.createPrivateConnectionOperationCallable().futureCall(request);
           // Do something.
           PrivateConnection response = future.get();
         }
         
      • createPrivateConnectionCallable

        public final com.google.api.gax.rpc.UnaryCallable<CreatePrivateConnectionRequest,​com.google.longrunning.Operation> createPrivateConnectionCallable()
        Creates a new private connection that can be used for accessing private Clouds.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           CreatePrivateConnectionRequest request =
               CreatePrivateConnectionRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPrivateConnectionId("privateConnectionId-1926654532")
                   .setPrivateConnection(PrivateConnection.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.createPrivateConnectionCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • getPrivateConnection

        public final PrivateConnection getPrivateConnection​(PrivateConnectionName name)
        Retrieves a `PrivateConnection` resource by its resource name. The resource contains details of the private connection, such as connected network, routing mode and state.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateConnectionName name =
               PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]");
           PrivateConnection response = vmwareEngineClient.getPrivateConnection(name);
         }
         
        Parameters:
        name - Required. The resource name of the private connection to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/privateConnections/my-connection`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getPrivateConnection

        public final PrivateConnection getPrivateConnection​(String name)
        Retrieves a `PrivateConnection` resource by its resource name. The resource contains details of the private connection, such as connected network, routing mode and state.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name =
               PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]").toString();
           PrivateConnection response = vmwareEngineClient.getPrivateConnection(name);
         }
         
        Parameters:
        name - Required. The resource name of the private connection to retrieve. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/privateConnections/my-connection`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getPrivateConnection

        public final PrivateConnection getPrivateConnection​(GetPrivateConnectionRequest request)
        Retrieves a `PrivateConnection` resource by its resource name. The resource contains details of the private connection, such as connected network, routing mode and state.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetPrivateConnectionRequest request =
               GetPrivateConnectionRequest.newBuilder()
                   .setName(
                       PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]")
                           .toString())
                   .build();
           PrivateConnection response = vmwareEngineClient.getPrivateConnection(request);
         }
         
        Parameters:
        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
      • getPrivateConnectionCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetPrivateConnectionRequest,​PrivateConnection> getPrivateConnectionCallable()
        Retrieves a `PrivateConnection` resource by its resource name. The resource contains details of the private connection, such as connected network, routing mode and state.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetPrivateConnectionRequest request =
               GetPrivateConnectionRequest.newBuilder()
                   .setName(
                       PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]")
                           .toString())
                   .build();
           ApiFuture<PrivateConnection> future =
               vmwareEngineClient.getPrivateConnectionCallable().futureCall(request);
           // Do something.
           PrivateConnection response = future.get();
         }
         
      • listPrivateConnections

        public final VmwareEngineClient.ListPrivateConnectionsPagedResponse listPrivateConnections​(LocationName parent)
        Lists `PrivateConnection` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           for (PrivateConnection element :
               vmwareEngineClient.listPrivateConnections(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the location to query for private connections. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listPrivateConnections

        public final VmwareEngineClient.ListPrivateConnectionsPagedResponse listPrivateConnections​(String parent)
        Lists `PrivateConnection` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           for (PrivateConnection element :
               vmwareEngineClient.listPrivateConnections(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the location to query for private connections. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listPrivateConnections

        public final VmwareEngineClient.ListPrivateConnectionsPagedResponse listPrivateConnections​(ListPrivateConnectionsRequest request)
        Lists `PrivateConnection` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListPrivateConnectionsRequest request =
               ListPrivateConnectionsRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           for (PrivateConnection element :
               vmwareEngineClient.listPrivateConnections(request).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        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
      • listPrivateConnectionsPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListPrivateConnectionsRequest,​VmwareEngineClient.ListPrivateConnectionsPagedResponse> listPrivateConnectionsPagedCallable()
        Lists `PrivateConnection` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListPrivateConnectionsRequest request =
               ListPrivateConnectionsRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           ApiFuture<PrivateConnection> future =
               vmwareEngineClient.listPrivateConnectionsPagedCallable().futureCall(request);
           // Do something.
           for (PrivateConnection element : future.get().iterateAll()) {
             // doThingsWith(element);
           }
         }
         
      • listPrivateConnectionsCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListPrivateConnectionsRequest,​ListPrivateConnectionsResponse> listPrivateConnectionsCallable()
        Lists `PrivateConnection` resources in a given project and location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListPrivateConnectionsRequest request =
               ListPrivateConnectionsRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           while (true) {
             ListPrivateConnectionsResponse response =
                 vmwareEngineClient.listPrivateConnectionsCallable().call(request);
             for (PrivateConnection element : response.getPrivateConnectionsList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • updatePrivateConnectionAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateConnection,​OperationMetadata> updatePrivateConnectionAsync​(PrivateConnection privateConnection,
                                                                                                                                            com.google.protobuf.FieldMask updateMask)
        Modifies a `PrivateConnection` resource. Only `description` and `routing_mode` fields can be updated. Only fields specified in `updateMask` are applied.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateConnection privateConnection = PrivateConnection.newBuilder().build();
           FieldMask updateMask = FieldMask.newBuilder().build();
           PrivateConnection response =
               vmwareEngineClient.updatePrivateConnectionAsync(privateConnection, updateMask).get();
         }
         
        Parameters:
        privateConnection - Required. Private connection description.
        updateMask - Required. Field mask is used to specify the fields to be overwritten in the `PrivateConnection` resource by the update. The fields specified in the `update_mask` are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • updatePrivateConnectionAsync

        public final com.google.api.gax.longrunning.OperationFuture<PrivateConnection,​OperationMetadata> updatePrivateConnectionAsync​(UpdatePrivateConnectionRequest request)
        Modifies a `PrivateConnection` resource. Only `description` and `routing_mode` fields can be updated. Only fields specified in `updateMask` are applied.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdatePrivateConnectionRequest request =
               UpdatePrivateConnectionRequest.newBuilder()
                   .setPrivateConnection(PrivateConnection.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           PrivateConnection response = vmwareEngineClient.updatePrivateConnectionAsync(request).get();
         }
         
        Parameters:
        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
      • updatePrivateConnectionOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UpdatePrivateConnectionRequest,​PrivateConnection,​OperationMetadata> updatePrivateConnectionOperationCallable()
        Modifies a `PrivateConnection` resource. Only `description` and `routing_mode` fields can be updated. Only fields specified in `updateMask` are applied.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdatePrivateConnectionRequest request =
               UpdatePrivateConnectionRequest.newBuilder()
                   .setPrivateConnection(PrivateConnection.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<PrivateConnection, OperationMetadata> future =
               vmwareEngineClient.updatePrivateConnectionOperationCallable().futureCall(request);
           // Do something.
           PrivateConnection response = future.get();
         }
         
      • updatePrivateConnectionCallable

        public final com.google.api.gax.rpc.UnaryCallable<UpdatePrivateConnectionRequest,​com.google.longrunning.Operation> updatePrivateConnectionCallable()
        Modifies a `PrivateConnection` resource. Only `description` and `routing_mode` fields can be updated. Only fields specified in `updateMask` are applied.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           UpdatePrivateConnectionRequest request =
               UpdatePrivateConnectionRequest.newBuilder()
                   .setPrivateConnection(PrivateConnection.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.updatePrivateConnectionCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • deletePrivateConnectionAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deletePrivateConnectionAsync​(PrivateConnectionName name)
        Deletes a `PrivateConnection` resource. When a private connection is deleted for a VMware Engine network, the connected network becomes inaccessible to that VMware Engine network.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateConnectionName name =
               PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]");
           vmwareEngineClient.deletePrivateConnectionAsync(name).get();
         }
         
        Parameters:
        name - Required. The resource name of the private connection to be deleted. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/privateConnections/my-connection`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deletePrivateConnectionAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deletePrivateConnectionAsync​(String name)
        Deletes a `PrivateConnection` resource. When a private connection is deleted for a VMware Engine network, the connected network becomes inaccessible to that VMware Engine network.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String name =
               PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]").toString();
           vmwareEngineClient.deletePrivateConnectionAsync(name).get();
         }
         
        Parameters:
        name - Required. The resource name of the private connection to be deleted. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1/privateConnections/my-connection`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deletePrivateConnectionAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deletePrivateConnectionAsync​(DeletePrivateConnectionRequest request)
        Deletes a `PrivateConnection` resource. When a private connection is deleted for a VMware Engine network, the connected network becomes inaccessible to that VMware Engine network.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeletePrivateConnectionRequest request =
               DeletePrivateConnectionRequest.newBuilder()
                   .setName(
                       PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]")
                           .toString())
                   .setRequestId("requestId693933066")
                   .build();
           vmwareEngineClient.deletePrivateConnectionAsync(request).get();
         }
         
        Parameters:
        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
      • deletePrivateConnectionOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<DeletePrivateConnectionRequest,​com.google.protobuf.Empty,​OperationMetadata> deletePrivateConnectionOperationCallable()
        Deletes a `PrivateConnection` resource. When a private connection is deleted for a VMware Engine network, the connected network becomes inaccessible to that VMware Engine network.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeletePrivateConnectionRequest request =
               DeletePrivateConnectionRequest.newBuilder()
                   .setName(
                       PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]")
                           .toString())
                   .setRequestId("requestId693933066")
                   .build();
           OperationFuture<Empty, OperationMetadata> future =
               vmwareEngineClient.deletePrivateConnectionOperationCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • deletePrivateConnectionCallable

        public final com.google.api.gax.rpc.UnaryCallable<DeletePrivateConnectionRequest,​com.google.longrunning.Operation> deletePrivateConnectionCallable()
        Deletes a `PrivateConnection` resource. When a private connection is deleted for a VMware Engine network, the connected network becomes inaccessible to that VMware Engine network.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           DeletePrivateConnectionRequest request =
               DeletePrivateConnectionRequest.newBuilder()
                   .setName(
                       PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]")
                           .toString())
                   .setRequestId("requestId693933066")
                   .build();
           ApiFuture<Operation> future =
               vmwareEngineClient.deletePrivateConnectionCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • listPrivateConnectionPeeringRoutes

        public final VmwareEngineClient.ListPrivateConnectionPeeringRoutesPagedResponse listPrivateConnectionPeeringRoutes​(PrivateConnectionName parent)
        Lists the private connection routes exchanged over a peering connection.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           PrivateConnectionName parent =
               PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]");
           for (PeeringRoute element :
               vmwareEngineClient.listPrivateConnectionPeeringRoutes(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the private connection to retrieve peering routes from. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-west1/privateConnections/my-connection`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listPrivateConnectionPeeringRoutes

        public final VmwareEngineClient.ListPrivateConnectionPeeringRoutesPagedResponse listPrivateConnectionPeeringRoutes​(String parent)
        Lists the private connection routes exchanged over a peering connection.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           String parent =
               PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]").toString();
           for (PeeringRoute element :
               vmwareEngineClient.listPrivateConnectionPeeringRoutes(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The resource name of the private connection to retrieve peering routes from. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-west1/privateConnections/my-connection`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listPrivateConnectionPeeringRoutes

        public final VmwareEngineClient.ListPrivateConnectionPeeringRoutesPagedResponse listPrivateConnectionPeeringRoutes​(ListPrivateConnectionPeeringRoutesRequest request)
        Lists the private connection routes exchanged over a peering connection.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListPrivateConnectionPeeringRoutesRequest request =
               ListPrivateConnectionPeeringRoutesRequest.newBuilder()
                   .setParent(
                       PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]")
                           .toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           for (PeeringRoute element :
               vmwareEngineClient.listPrivateConnectionPeeringRoutes(request).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        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
      • listPrivateConnectionPeeringRoutesPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListPrivateConnectionPeeringRoutesRequest,​VmwareEngineClient.ListPrivateConnectionPeeringRoutesPagedResponse> listPrivateConnectionPeeringRoutesPagedCallable()
        Lists the private connection routes exchanged over a peering connection.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListPrivateConnectionPeeringRoutesRequest request =
               ListPrivateConnectionPeeringRoutesRequest.newBuilder()
                   .setParent(
                       PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]")
                           .toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           ApiFuture<PeeringRoute> future =
               vmwareEngineClient.listPrivateConnectionPeeringRoutesPagedCallable().futureCall(request);
           // Do something.
           for (PeeringRoute element : future.get().iterateAll()) {
             // doThingsWith(element);
           }
         }
         
      • listPrivateConnectionPeeringRoutesCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListPrivateConnectionPeeringRoutesRequest,​ListPrivateConnectionPeeringRoutesResponse> listPrivateConnectionPeeringRoutesCallable()
        Lists the private connection routes exchanged over a peering connection.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListPrivateConnectionPeeringRoutesRequest request =
               ListPrivateConnectionPeeringRoutesRequest.newBuilder()
                   .setParent(
                       PrivateConnectionName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CONNECTION]")
                           .toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           while (true) {
             ListPrivateConnectionPeeringRoutesResponse response =
                 vmwareEngineClient.listPrivateConnectionPeeringRoutesCallable().call(request);
             for (PeeringRoute element : response.getPeeringRoutesList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • listLocations

        public final VmwareEngineClient.ListLocationsPagedResponse listLocations​(com.google.cloud.location.ListLocationsRequest request)
        Lists information about the supported locations for this service.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListLocationsRequest request =
               ListLocationsRequest.newBuilder()
                   .setName("name3373707")
                   .setFilter("filter-1274492040")
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           for (Location element : vmwareEngineClient.listLocations(request).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        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
      • listLocationsPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<com.google.cloud.location.ListLocationsRequest,​VmwareEngineClient.ListLocationsPagedResponse> listLocationsPagedCallable()
        Lists information about the supported locations for this service.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListLocationsRequest request =
               ListLocationsRequest.newBuilder()
                   .setName("name3373707")
                   .setFilter("filter-1274492040")
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           ApiFuture<Location> future =
               vmwareEngineClient.listLocationsPagedCallable().futureCall(request);
           // Do something.
           for (Location element : future.get().iterateAll()) {
             // doThingsWith(element);
           }
         }
         
      • listLocationsCallable

        public final com.google.api.gax.rpc.UnaryCallable<com.google.cloud.location.ListLocationsRequest,​com.google.cloud.location.ListLocationsResponse> listLocationsCallable()
        Lists information about the supported locations for this service.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           ListLocationsRequest request =
               ListLocationsRequest.newBuilder()
                   .setName("name3373707")
                   .setFilter("filter-1274492040")
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           while (true) {
             ListLocationsResponse response = vmwareEngineClient.listLocationsCallable().call(request);
             for (Location element : response.getLocationsList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • getLocation

        public final com.google.cloud.location.Location getLocation​(com.google.cloud.location.GetLocationRequest request)
        Gets information about a location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
           Location response = vmwareEngineClient.getLocation(request);
         }
         
        Parameters:
        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
      • getLocationCallable

        public final com.google.api.gax.rpc.UnaryCallable<com.google.cloud.location.GetLocationRequest,​com.google.cloud.location.Location> getLocationCallable()
        Gets information about a location.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
           ApiFuture<Location> future = vmwareEngineClient.getLocationCallable().futureCall(request);
           // Do something.
           Location response = future.get();
         }
         
      • setIamPolicy

        public final com.google.iam.v1.Policy setIamPolicy​(com.google.iam.v1.SetIamPolicyRequest request)
        Sets the access control policy on the specified resource. Replacesany existing policy.

        Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED`errors.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           SetIamPolicyRequest request =
               SetIamPolicyRequest.newBuilder()
                   .setResource(
                       ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]")
                           .toString())
                   .setPolicy(Policy.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .build();
           Policy response = vmwareEngineClient.setIamPolicy(request);
         }
         
        Parameters:
        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
      • setIamPolicyCallable

        public final com.google.api.gax.rpc.UnaryCallable<com.google.iam.v1.SetIamPolicyRequest,​com.google.iam.v1.Policy> setIamPolicyCallable()
        Sets the access control policy on the specified resource. Replacesany existing policy.

        Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED`errors.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           SetIamPolicyRequest request =
               SetIamPolicyRequest.newBuilder()
                   .setResource(
                       ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]")
                           .toString())
                   .setPolicy(Policy.newBuilder().build())
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .build();
           ApiFuture<Policy> future = vmwareEngineClient.setIamPolicyCallable().futureCall(request);
           // Do something.
           Policy response = future.get();
         }
         
      • getIamPolicy

        public final com.google.iam.v1.Policy getIamPolicy​(com.google.iam.v1.GetIamPolicyRequest request)
        Gets the access control policy for a resource. Returns an empty policyif the resource exists and does not have a policy set.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetIamPolicyRequest request =
               GetIamPolicyRequest.newBuilder()
                   .setResource(
                       ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]")
                           .toString())
                   .setOptions(GetPolicyOptions.newBuilder().build())
                   .build();
           Policy response = vmwareEngineClient.getIamPolicy(request);
         }
         
        Parameters:
        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
      • getIamPolicyCallable

        public final com.google.api.gax.rpc.UnaryCallable<com.google.iam.v1.GetIamPolicyRequest,​com.google.iam.v1.Policy> getIamPolicyCallable()
        Gets the access control policy for a resource. Returns an empty policyif the resource exists and does not have a policy set.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           GetIamPolicyRequest request =
               GetIamPolicyRequest.newBuilder()
                   .setResource(
                       ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]")
                           .toString())
                   .setOptions(GetPolicyOptions.newBuilder().build())
                   .build();
           ApiFuture<Policy> future = vmwareEngineClient.getIamPolicyCallable().futureCall(request);
           // Do something.
           Policy response = future.get();
         }
         
      • testIamPermissions

        public final com.google.iam.v1.TestIamPermissionsResponse testIamPermissions​(com.google.iam.v1.TestIamPermissionsRequest request)
        Returns permissions that a caller has on the specified resource. If theresource does not exist, this will return an empty set ofpermissions, not a `NOT_FOUND` error.

        Note: This operation is designed to be used for buildingpermission-aware UIs and command-line tools, not for authorizationchecking. This operation may "fail open" without warning.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           TestIamPermissionsRequest request =
               TestIamPermissionsRequest.newBuilder()
                   .setResource(
                       ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]")
                           .toString())
                   .addAllPermissions(new ArrayList<String>())
                   .build();
           TestIamPermissionsResponse response = vmwareEngineClient.testIamPermissions(request);
         }
         
        Parameters:
        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
      • testIamPermissionsCallable

        public final com.google.api.gax.rpc.UnaryCallable<com.google.iam.v1.TestIamPermissionsRequest,​com.google.iam.v1.TestIamPermissionsResponse> testIamPermissionsCallable()
        Returns permissions that a caller has on the specified resource. If theresource does not exist, this will return an empty set ofpermissions, not a `NOT_FOUND` error.

        Note: This operation is designed to be used for buildingpermission-aware UIs and command-line tools, not for authorizationchecking. This operation may "fail open" without warning.

        Sample 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 (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
           TestIamPermissionsRequest request =
               TestIamPermissionsRequest.newBuilder()
                   .setResource(
                       ClusterName.of("[PROJECT]", "[LOCATION]", "[PRIVATE_CLOUD]", "[CLUSTER]")
                           .toString())
                   .addAllPermissions(new ArrayList<String>())
                   .build();
           ApiFuture<TestIamPermissionsResponse> future =
               vmwareEngineClient.testIamPermissionsCallable().futureCall(request);
           // Do something.
           TestIamPermissionsResponse response = future.get();
         }
         
      • shutdown

        public void shutdown()
        Specified by:
        shutdown in interface com.google.api.gax.core.BackgroundResource
      • isShutdown

        public boolean isShutdown()
        Specified by:
        isShutdown in interface com.google.api.gax.core.BackgroundResource
      • isTerminated

        public boolean isTerminated()
        Specified by:
        isTerminated in interface com.google.api.gax.core.BackgroundResource
      • shutdownNow

        public void shutdownNow()
        Specified by:
        shutdownNow in interface com.google.api.gax.core.BackgroundResource