Class NetAppClient

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

    @Generated("by gapic-generator-java")
    public class NetAppClient
    extends Object
    implements com.google.api.gax.core.BackgroundResource
    Service Description: NetApp Files Google Cloud Service

    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 (NetAppClient netAppClient = NetAppClient.create()) {
       StoragePoolName name = StoragePoolName.of("[PROJECT]", "[LOCATION]", "[STORAGE_POOL]");
       StoragePool response = netAppClient.getStoragePool(name);
     }
     

    Note: close() needs to be called on the NetAppClient 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 NetAppSettings 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
     NetAppSettings netAppSettings =
         NetAppSettings.newBuilder()
             .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
             .build();
     NetAppClient netAppClient = NetAppClient.create(netAppSettings);
     

    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
     NetAppSettings netAppSettings = NetAppSettings.newBuilder().setEndpoint(myEndpoint).build();
     NetAppClient netAppClient = NetAppClient.create(netAppSettings);
     

    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
     NetAppSettings netAppSettings = NetAppSettings.newHttpJsonBuilder().build();
     NetAppClient netAppClient = NetAppClient.create(netAppSettings);
     

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

    • Constructor Detail

      • NetAppClient

        protected NetAppClient​(NetAppSettings settings)
                        throws IOException
        Constructs an instance of NetAppClient, 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
      • NetAppClient

        protected NetAppClient​(NetAppStub stub)
    • Method Detail

      • create

        public static final NetAppClient create​(NetAppSettings settings)
                                         throws IOException
        Constructs an instance of NetAppClient, 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 NetAppClient create​(NetAppStub stub)
        Constructs an instance of NetAppClient, using the given stub for making calls. This is for advanced usage - prefer using create(NetAppSettings).
      • 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.
      • listStoragePools

        public final NetAppClient.ListStoragePoolsPagedResponse listStoragePools​(LocationName parent)
        Returns descriptions of all storage pools owned by the caller.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           for (StoragePool element : netAppClient.listStoragePools(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. Parent value
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listStoragePools

        public final NetAppClient.ListStoragePoolsPagedResponse listStoragePools​(String parent)
        Returns descriptions of all storage pools owned by the caller.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           for (StoragePool element : netAppClient.listStoragePools(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. Parent value
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listStoragePools

        public final NetAppClient.ListStoragePoolsPagedResponse listStoragePools​(ListStoragePoolsRequest request)
        Returns descriptions of all storage pools owned by the caller.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListStoragePoolsRequest request =
               ListStoragePoolsRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setOrderBy("orderBy-1207110587")
                   .setFilter("filter-1274492040")
                   .build();
           for (StoragePool element : netAppClient.listStoragePools(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
      • listStoragePoolsPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListStoragePoolsRequest,​NetAppClient.ListStoragePoolsPagedResponse> listStoragePoolsPagedCallable()
        Returns descriptions of all storage pools owned by the caller.

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

        public final com.google.api.gax.rpc.UnaryCallable<ListStoragePoolsRequest,​ListStoragePoolsResponse> listStoragePoolsCallable()
        Returns descriptions of all storage pools owned by the caller.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListStoragePoolsRequest request =
               ListStoragePoolsRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setOrderBy("orderBy-1207110587")
                   .setFilter("filter-1274492040")
                   .build();
           while (true) {
             ListStoragePoolsResponse response = netAppClient.listStoragePoolsCallable().call(request);
             for (StoragePool element : response.getStoragePoolsList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • createStoragePoolAsync

        public final com.google.api.gax.longrunning.OperationFuture<StoragePool,​OperationMetadata> createStoragePoolAsync​(LocationName parent,
                                                                                                                                StoragePool storagePool,
                                                                                                                                String storagePoolId)
        Creates a new storage pool.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           StoragePool storagePool = StoragePool.newBuilder().build();
           String storagePoolId = "storagePoolId1617506482";
           StoragePool response =
               netAppClient.createStoragePoolAsync(parent, storagePool, storagePoolId).get();
         }
         
        Parameters:
        parent - Required. Value for parent.
        storagePool - Required. The required parameters to create a new storage pool.
        storagePoolId - Required. Id of the requesting storage pool If auto-generating Id server-side, remove this field and id from the method_signature of Create RPC
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createStoragePoolAsync

        public final com.google.api.gax.longrunning.OperationFuture<StoragePool,​OperationMetadata> createStoragePoolAsync​(String parent,
                                                                                                                                StoragePool storagePool,
                                                                                                                                String storagePoolId)
        Creates a new storage pool.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           StoragePool storagePool = StoragePool.newBuilder().build();
           String storagePoolId = "storagePoolId1617506482";
           StoragePool response =
               netAppClient.createStoragePoolAsync(parent, storagePool, storagePoolId).get();
         }
         
        Parameters:
        parent - Required. Value for parent.
        storagePool - Required. The required parameters to create a new storage pool.
        storagePoolId - Required. Id of the requesting storage pool If auto-generating Id server-side, remove this field and id from the method_signature of Create RPC
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createStoragePoolAsync

        public final com.google.api.gax.longrunning.OperationFuture<StoragePool,​OperationMetadata> createStoragePoolAsync​(CreateStoragePoolRequest request)
        Creates a new storage pool.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateStoragePoolRequest request =
               CreateStoragePoolRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setStoragePoolId("storagePoolId1617506482")
                   .setStoragePool(StoragePool.newBuilder().build())
                   .build();
           StoragePool response = netAppClient.createStoragePoolAsync(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
      • createStoragePoolOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<CreateStoragePoolRequest,​StoragePool,​OperationMetadata> createStoragePoolOperationCallable()
        Creates a new storage pool.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateStoragePoolRequest request =
               CreateStoragePoolRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setStoragePoolId("storagePoolId1617506482")
                   .setStoragePool(StoragePool.newBuilder().build())
                   .build();
           OperationFuture<StoragePool, OperationMetadata> future =
               netAppClient.createStoragePoolOperationCallable().futureCall(request);
           // Do something.
           StoragePool response = future.get();
         }
         
      • createStoragePoolCallable

        public final com.google.api.gax.rpc.UnaryCallable<CreateStoragePoolRequest,​com.google.longrunning.Operation> createStoragePoolCallable()
        Creates a new storage pool.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateStoragePoolRequest request =
               CreateStoragePoolRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setStoragePoolId("storagePoolId1617506482")
                   .setStoragePool(StoragePool.newBuilder().build())
                   .build();
           ApiFuture<Operation> future = netAppClient.createStoragePoolCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • getStoragePool

        public final StoragePool getStoragePool​(StoragePoolName name)
        Returns the description of the specified storage pool by poolId.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           StoragePoolName name = StoragePoolName.of("[PROJECT]", "[LOCATION]", "[STORAGE_POOL]");
           StoragePool response = netAppClient.getStoragePool(name);
         }
         
        Parameters:
        name - Required. Name of the storage pool
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getStoragePool

        public final StoragePool getStoragePool​(String name)
        Returns the description of the specified storage pool by poolId.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String name = StoragePoolName.of("[PROJECT]", "[LOCATION]", "[STORAGE_POOL]").toString();
           StoragePool response = netAppClient.getStoragePool(name);
         }
         
        Parameters:
        name - Required. Name of the storage pool
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getStoragePool

        public final StoragePool getStoragePool​(GetStoragePoolRequest request)
        Returns the description of the specified storage pool by poolId.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetStoragePoolRequest request =
               GetStoragePoolRequest.newBuilder()
                   .setName(StoragePoolName.of("[PROJECT]", "[LOCATION]", "[STORAGE_POOL]").toString())
                   .build();
           StoragePool response = netAppClient.getStoragePool(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
      • getStoragePoolCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetStoragePoolRequest,​StoragePool> getStoragePoolCallable()
        Returns the description of the specified storage pool by poolId.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetStoragePoolRequest request =
               GetStoragePoolRequest.newBuilder()
                   .setName(StoragePoolName.of("[PROJECT]", "[LOCATION]", "[STORAGE_POOL]").toString())
                   .build();
           ApiFuture<StoragePool> future = netAppClient.getStoragePoolCallable().futureCall(request);
           // Do something.
           StoragePool response = future.get();
         }
         
      • updateStoragePoolAsync

        public final com.google.api.gax.longrunning.OperationFuture<StoragePool,​OperationMetadata> updateStoragePoolAsync​(StoragePool storagePool,
                                                                                                                                com.google.protobuf.FieldMask updateMask)
        Updates the storage pool properties with the full spec

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           StoragePool storagePool = StoragePool.newBuilder().build();
           FieldMask updateMask = FieldMask.newBuilder().build();
           StoragePool response = netAppClient.updateStoragePoolAsync(storagePool, updateMask).get();
         }
         
        Parameters:
        storagePool - Required. The pool being updated
        updateMask - Required. Field mask is used to specify the fields to be overwritten in the StoragePool 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
      • updateStoragePoolAsync

        public final com.google.api.gax.longrunning.OperationFuture<StoragePool,​OperationMetadata> updateStoragePoolAsync​(UpdateStoragePoolRequest request)
        Updates the storage pool properties with the full spec

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateStoragePoolRequest request =
               UpdateStoragePoolRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setStoragePool(StoragePool.newBuilder().build())
                   .build();
           StoragePool response = netAppClient.updateStoragePoolAsync(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
      • updateStoragePoolOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UpdateStoragePoolRequest,​StoragePool,​OperationMetadata> updateStoragePoolOperationCallable()
        Updates the storage pool properties with the full spec

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateStoragePoolRequest request =
               UpdateStoragePoolRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setStoragePool(StoragePool.newBuilder().build())
                   .build();
           OperationFuture<StoragePool, OperationMetadata> future =
               netAppClient.updateStoragePoolOperationCallable().futureCall(request);
           // Do something.
           StoragePool response = future.get();
         }
         
      • updateStoragePoolCallable

        public final com.google.api.gax.rpc.UnaryCallable<UpdateStoragePoolRequest,​com.google.longrunning.Operation> updateStoragePoolCallable()
        Updates the storage pool properties with the full spec

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateStoragePoolRequest request =
               UpdateStoragePoolRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setStoragePool(StoragePool.newBuilder().build())
                   .build();
           ApiFuture<Operation> future = netAppClient.updateStoragePoolCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • deleteStoragePoolAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteStoragePoolAsync​(StoragePoolName name)
        Warning! This operation will permanently delete the storage pool.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           StoragePoolName name = StoragePoolName.of("[PROJECT]", "[LOCATION]", "[STORAGE_POOL]");
           netAppClient.deleteStoragePoolAsync(name).get();
         }
         
        Parameters:
        name - Required. Name of the storage pool
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteStoragePoolAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteStoragePoolAsync​(String name)
        Warning! This operation will permanently delete the storage pool.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String name = StoragePoolName.of("[PROJECT]", "[LOCATION]", "[STORAGE_POOL]").toString();
           netAppClient.deleteStoragePoolAsync(name).get();
         }
         
        Parameters:
        name - Required. Name of the storage pool
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteStoragePoolAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteStoragePoolAsync​(DeleteStoragePoolRequest request)
        Warning! This operation will permanently delete the storage pool.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteStoragePoolRequest request =
               DeleteStoragePoolRequest.newBuilder()
                   .setName(StoragePoolName.of("[PROJECT]", "[LOCATION]", "[STORAGE_POOL]").toString())
                   .build();
           netAppClient.deleteStoragePoolAsync(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
      • deleteStoragePoolOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<DeleteStoragePoolRequest,​com.google.protobuf.Empty,​OperationMetadata> deleteStoragePoolOperationCallable()
        Warning! This operation will permanently delete the storage pool.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteStoragePoolRequest request =
               DeleteStoragePoolRequest.newBuilder()
                   .setName(StoragePoolName.of("[PROJECT]", "[LOCATION]", "[STORAGE_POOL]").toString())
                   .build();
           OperationFuture<Empty, OperationMetadata> future =
               netAppClient.deleteStoragePoolOperationCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • deleteStoragePoolCallable

        public final com.google.api.gax.rpc.UnaryCallable<DeleteStoragePoolRequest,​com.google.longrunning.Operation> deleteStoragePoolCallable()
        Warning! This operation will permanently delete the storage pool.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteStoragePoolRequest request =
               DeleteStoragePoolRequest.newBuilder()
                   .setName(StoragePoolName.of("[PROJECT]", "[LOCATION]", "[STORAGE_POOL]").toString())
                   .build();
           ApiFuture<Operation> future = netAppClient.deleteStoragePoolCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • listVolumes

        public final NetAppClient.ListVolumesPagedResponse listVolumes​(LocationName parent)
        Lists Volumes in a given project.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           for (Volume element : netAppClient.listVolumes(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. Parent value for ListVolumesRequest
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listVolumes

        public final NetAppClient.ListVolumesPagedResponse listVolumes​(String parent)
        Lists Volumes in a given project.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           for (Volume element : netAppClient.listVolumes(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. Parent value for ListVolumesRequest
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listVolumes

        public final NetAppClient.ListVolumesPagedResponse listVolumes​(ListVolumesRequest request)
        Lists Volumes in a given project.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListVolumesRequest request =
               ListVolumesRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           for (Volume element : netAppClient.listVolumes(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
      • listVolumesPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListVolumesRequest,​NetAppClient.ListVolumesPagedResponse> listVolumesPagedCallable()
        Lists Volumes in a given project.

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

        public final com.google.api.gax.rpc.UnaryCallable<ListVolumesRequest,​ListVolumesResponse> listVolumesCallable()
        Lists Volumes in a given project.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListVolumesRequest request =
               ListVolumesRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           while (true) {
             ListVolumesResponse response = netAppClient.listVolumesCallable().call(request);
             for (Volume element : response.getVolumesList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • getVolume

        public final Volume getVolume​(VolumeName name)
        Gets details of a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           VolumeName name = VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]");
           Volume response = netAppClient.getVolume(name);
         }
         
        Parameters:
        name - Required. Name of the volume
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getVolume

        public final Volume getVolume​(String name)
        Gets details of a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String name = VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString();
           Volume response = netAppClient.getVolume(name);
         }
         
        Parameters:
        name - Required. Name of the volume
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getVolume

        public final Volume getVolume​(GetVolumeRequest request)
        Gets details of a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetVolumeRequest request =
               GetVolumeRequest.newBuilder()
                   .setName(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .build();
           Volume response = netAppClient.getVolume(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
      • getVolumeCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetVolumeRequest,​Volume> getVolumeCallable()
        Gets details of a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetVolumeRequest request =
               GetVolumeRequest.newBuilder()
                   .setName(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .build();
           ApiFuture<Volume> future = netAppClient.getVolumeCallable().futureCall(request);
           // Do something.
           Volume response = future.get();
         }
         
      • createVolumeAsync

        public final com.google.api.gax.longrunning.OperationFuture<Volume,​OperationMetadata> createVolumeAsync​(LocationName parent,
                                                                                                                      Volume volume,
                                                                                                                      String volumeId)
        Creates a new Volume 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 (NetAppClient netAppClient = NetAppClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           Volume volume = Volume.newBuilder().build();
           String volumeId = "volumeId-1869770283";
           Volume response = netAppClient.createVolumeAsync(parent, volume, volumeId).get();
         }
         
        Parameters:
        parent - Required. Value for parent.
        volume - Required. The volume being created.
        volumeId - Required. Id of the requesting volume If auto-generating Id server-side, remove this field and Id from the method_signature of Create RPC
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createVolumeAsync

        public final com.google.api.gax.longrunning.OperationFuture<Volume,​OperationMetadata> createVolumeAsync​(String parent,
                                                                                                                      Volume volume,
                                                                                                                      String volumeId)
        Creates a new Volume 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 (NetAppClient netAppClient = NetAppClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           Volume volume = Volume.newBuilder().build();
           String volumeId = "volumeId-1869770283";
           Volume response = netAppClient.createVolumeAsync(parent, volume, volumeId).get();
         }
         
        Parameters:
        parent - Required. Value for parent.
        volume - Required. The volume being created.
        volumeId - Required. Id of the requesting volume If auto-generating Id server-side, remove this field and Id from the method_signature of Create RPC
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createVolumeAsync

        public final com.google.api.gax.longrunning.OperationFuture<Volume,​OperationMetadata> createVolumeAsync​(CreateVolumeRequest request)
        Creates a new Volume 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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateVolumeRequest request =
               CreateVolumeRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setVolumeId("volumeId-1869770283")
                   .setVolume(Volume.newBuilder().build())
                   .build();
           Volume response = netAppClient.createVolumeAsync(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
      • createVolumeOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<CreateVolumeRequest,​Volume,​OperationMetadata> createVolumeOperationCallable()
        Creates a new Volume 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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateVolumeRequest request =
               CreateVolumeRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setVolumeId("volumeId-1869770283")
                   .setVolume(Volume.newBuilder().build())
                   .build();
           OperationFuture<Volume, OperationMetadata> future =
               netAppClient.createVolumeOperationCallable().futureCall(request);
           // Do something.
           Volume response = future.get();
         }
         
      • createVolumeCallable

        public final com.google.api.gax.rpc.UnaryCallable<CreateVolumeRequest,​com.google.longrunning.Operation> createVolumeCallable()
        Creates a new Volume 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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateVolumeRequest request =
               CreateVolumeRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setVolumeId("volumeId-1869770283")
                   .setVolume(Volume.newBuilder().build())
                   .build();
           ApiFuture<Operation> future = netAppClient.createVolumeCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • updateVolumeAsync

        public final com.google.api.gax.longrunning.OperationFuture<Volume,​OperationMetadata> updateVolumeAsync​(Volume volume,
                                                                                                                      com.google.protobuf.FieldMask updateMask)
        Updates the parameters of a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           Volume volume = Volume.newBuilder().build();
           FieldMask updateMask = FieldMask.newBuilder().build();
           Volume response = netAppClient.updateVolumeAsync(volume, updateMask).get();
         }
         
        Parameters:
        volume - Required. The volume being updated
        updateMask - Required. Field mask is used to specify the fields to be overwritten in the Volume 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
      • updateVolumeAsync

        public final com.google.api.gax.longrunning.OperationFuture<Volume,​OperationMetadata> updateVolumeAsync​(UpdateVolumeRequest request)
        Updates the parameters of a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateVolumeRequest request =
               UpdateVolumeRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setVolume(Volume.newBuilder().build())
                   .build();
           Volume response = netAppClient.updateVolumeAsync(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
      • updateVolumeOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UpdateVolumeRequest,​Volume,​OperationMetadata> updateVolumeOperationCallable()
        Updates the parameters of a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateVolumeRequest request =
               UpdateVolumeRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setVolume(Volume.newBuilder().build())
                   .build();
           OperationFuture<Volume, OperationMetadata> future =
               netAppClient.updateVolumeOperationCallable().futureCall(request);
           // Do something.
           Volume response = future.get();
         }
         
      • updateVolumeCallable

        public final com.google.api.gax.rpc.UnaryCallable<UpdateVolumeRequest,​com.google.longrunning.Operation> updateVolumeCallable()
        Updates the parameters of a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateVolumeRequest request =
               UpdateVolumeRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setVolume(Volume.newBuilder().build())
                   .build();
           ApiFuture<Operation> future = netAppClient.updateVolumeCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • deleteVolumeAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteVolumeAsync​(VolumeName name)
        Deletes a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           VolumeName name = VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]");
           netAppClient.deleteVolumeAsync(name).get();
         }
         
        Parameters:
        name - Required. Name of the volume
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteVolumeAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteVolumeAsync​(String name)
        Deletes a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String name = VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString();
           netAppClient.deleteVolumeAsync(name).get();
         }
         
        Parameters:
        name - Required. Name of the volume
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteVolumeAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteVolumeAsync​(DeleteVolumeRequest request)
        Deletes a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteVolumeRequest request =
               DeleteVolumeRequest.newBuilder()
                   .setName(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setForce(true)
                   .build();
           netAppClient.deleteVolumeAsync(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
      • deleteVolumeOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<DeleteVolumeRequest,​com.google.protobuf.Empty,​OperationMetadata> deleteVolumeOperationCallable()
        Deletes a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteVolumeRequest request =
               DeleteVolumeRequest.newBuilder()
                   .setName(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setForce(true)
                   .build();
           OperationFuture<Empty, OperationMetadata> future =
               netAppClient.deleteVolumeOperationCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • deleteVolumeCallable

        public final com.google.api.gax.rpc.UnaryCallable<DeleteVolumeRequest,​com.google.longrunning.Operation> deleteVolumeCallable()
        Deletes a single Volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteVolumeRequest request =
               DeleteVolumeRequest.newBuilder()
                   .setName(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setForce(true)
                   .build();
           ApiFuture<Operation> future = netAppClient.deleteVolumeCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • revertVolumeAsync

        public final com.google.api.gax.longrunning.OperationFuture<Volume,​OperationMetadata> revertVolumeAsync​(RevertVolumeRequest request)
        Revert an existing volume to a specified snapshot. Warning! This operation will permanently revert all changes made after the snapshot was created.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           RevertVolumeRequest request =
               RevertVolumeRequest.newBuilder()
                   .setName(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setSnapshotId("snapshotId-1113817601")
                   .build();
           Volume response = netAppClient.revertVolumeAsync(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
      • revertVolumeOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<RevertVolumeRequest,​Volume,​OperationMetadata> revertVolumeOperationCallable()
        Revert an existing volume to a specified snapshot. Warning! This operation will permanently revert all changes made after the snapshot was created.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           RevertVolumeRequest request =
               RevertVolumeRequest.newBuilder()
                   .setName(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setSnapshotId("snapshotId-1113817601")
                   .build();
           OperationFuture<Volume, OperationMetadata> future =
               netAppClient.revertVolumeOperationCallable().futureCall(request);
           // Do something.
           Volume response = future.get();
         }
         
      • revertVolumeCallable

        public final com.google.api.gax.rpc.UnaryCallable<RevertVolumeRequest,​com.google.longrunning.Operation> revertVolumeCallable()
        Revert an existing volume to a specified snapshot. Warning! This operation will permanently revert all changes made after the snapshot was created.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           RevertVolumeRequest request =
               RevertVolumeRequest.newBuilder()
                   .setName(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setSnapshotId("snapshotId-1113817601")
                   .build();
           ApiFuture<Operation> future = netAppClient.revertVolumeCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • listSnapshots

        public final NetAppClient.ListSnapshotsPagedResponse listSnapshots​(VolumeName parent)
        Returns descriptions of all snapshots for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           VolumeName parent = VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]");
           for (Snapshot element : netAppClient.listSnapshots(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The volume for which to retrieve snapshot information, in the format `projects/{project_id}/locations/{location}/volumes/{volume_id}`.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listSnapshots

        public final NetAppClient.ListSnapshotsPagedResponse listSnapshots​(String parent)
        Returns descriptions of all snapshots for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String parent = VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString();
           for (Snapshot element : netAppClient.listSnapshots(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The volume for which to retrieve snapshot information, in the format `projects/{project_id}/locations/{location}/volumes/{volume_id}`.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listSnapshots

        public final NetAppClient.ListSnapshotsPagedResponse listSnapshots​(ListSnapshotsRequest request)
        Returns descriptions of all snapshots for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListSnapshotsRequest request =
               ListSnapshotsRequest.newBuilder()
                   .setParent(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setOrderBy("orderBy-1207110587")
                   .setFilter("filter-1274492040")
                   .build();
           for (Snapshot element : netAppClient.listSnapshots(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
      • listSnapshotsPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListSnapshotsRequest,​NetAppClient.ListSnapshotsPagedResponse> listSnapshotsPagedCallable()
        Returns descriptions of all snapshots for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListSnapshotsRequest request =
               ListSnapshotsRequest.newBuilder()
                   .setParent(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setOrderBy("orderBy-1207110587")
                   .setFilter("filter-1274492040")
                   .build();
           ApiFuture<Snapshot> future = netAppClient.listSnapshotsPagedCallable().futureCall(request);
           // Do something.
           for (Snapshot element : future.get().iterateAll()) {
             // doThingsWith(element);
           }
         }
         
      • listSnapshotsCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListSnapshotsRequest,​ListSnapshotsResponse> listSnapshotsCallable()
        Returns descriptions of all snapshots for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListSnapshotsRequest request =
               ListSnapshotsRequest.newBuilder()
                   .setParent(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setOrderBy("orderBy-1207110587")
                   .setFilter("filter-1274492040")
                   .build();
           while (true) {
             ListSnapshotsResponse response = netAppClient.listSnapshotsCallable().call(request);
             for (Snapshot element : response.getSnapshotsList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • getSnapshot

        public final Snapshot getSnapshot​(SnapshotName name)
        Describe a snapshot for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           SnapshotName name = SnapshotName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[SNAPSHOT]");
           Snapshot response = netAppClient.getSnapshot(name);
         }
         
        Parameters:
        name - Required. The snapshot resource name, in the format `projects/{project_id}/locations/{location}/volumes/{volume_id}/snapshots/{snapshot_id}`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getSnapshot

        public final Snapshot getSnapshot​(String name)
        Describe a snapshot for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String name = SnapshotName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[SNAPSHOT]").toString();
           Snapshot response = netAppClient.getSnapshot(name);
         }
         
        Parameters:
        name - Required. The snapshot resource name, in the format `projects/{project_id}/locations/{location}/volumes/{volume_id}/snapshots/{snapshot_id}`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getSnapshot

        public final Snapshot getSnapshot​(GetSnapshotRequest request)
        Describe a snapshot for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetSnapshotRequest request =
               GetSnapshotRequest.newBuilder()
                   .setName(
                       SnapshotName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[SNAPSHOT]").toString())
                   .build();
           Snapshot response = netAppClient.getSnapshot(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
      • getSnapshotCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetSnapshotRequest,​Snapshot> getSnapshotCallable()
        Describe a snapshot for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetSnapshotRequest request =
               GetSnapshotRequest.newBuilder()
                   .setName(
                       SnapshotName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[SNAPSHOT]").toString())
                   .build();
           ApiFuture<Snapshot> future = netAppClient.getSnapshotCallable().futureCall(request);
           // Do something.
           Snapshot response = future.get();
         }
         
      • createSnapshotAsync

        public final com.google.api.gax.longrunning.OperationFuture<Snapshot,​OperationMetadata> createSnapshotAsync​(VolumeName parent,
                                                                                                                          Snapshot snapshot,
                                                                                                                          String snapshotId)
        Create a new snapshot for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           VolumeName parent = VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]");
           Snapshot snapshot = Snapshot.newBuilder().build();
           String snapshotId = "snapshotId-1113817601";
           Snapshot response = netAppClient.createSnapshotAsync(parent, snapshot, snapshotId).get();
         }
         
        Parameters:
        parent - Required. The NetApp volume to create the snapshots of, in the format `projects/{project_id}/locations/{location}/volumes/{volume_id}`
        snapshot - Required. A snapshot resource
        snapshotId - Required. ID of the snapshot to create. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createSnapshotAsync

        public final com.google.api.gax.longrunning.OperationFuture<Snapshot,​OperationMetadata> createSnapshotAsync​(String parent,
                                                                                                                          Snapshot snapshot,
                                                                                                                          String snapshotId)
        Create a new snapshot for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String parent = VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString();
           Snapshot snapshot = Snapshot.newBuilder().build();
           String snapshotId = "snapshotId-1113817601";
           Snapshot response = netAppClient.createSnapshotAsync(parent, snapshot, snapshotId).get();
         }
         
        Parameters:
        parent - Required. The NetApp volume to create the snapshots of, in the format `projects/{project_id}/locations/{location}/volumes/{volume_id}`
        snapshot - Required. A snapshot resource
        snapshotId - Required. ID of the snapshot to create. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createSnapshotAsync

        public final com.google.api.gax.longrunning.OperationFuture<Snapshot,​OperationMetadata> createSnapshotAsync​(CreateSnapshotRequest request)
        Create a new snapshot for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateSnapshotRequest request =
               CreateSnapshotRequest.newBuilder()
                   .setParent(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setSnapshot(Snapshot.newBuilder().build())
                   .setSnapshotId("snapshotId-1113817601")
                   .build();
           Snapshot response = netAppClient.createSnapshotAsync(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
      • createSnapshotOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<CreateSnapshotRequest,​Snapshot,​OperationMetadata> createSnapshotOperationCallable()
        Create a new snapshot for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateSnapshotRequest request =
               CreateSnapshotRequest.newBuilder()
                   .setParent(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setSnapshot(Snapshot.newBuilder().build())
                   .setSnapshotId("snapshotId-1113817601")
                   .build();
           OperationFuture<Snapshot, OperationMetadata> future =
               netAppClient.createSnapshotOperationCallable().futureCall(request);
           // Do something.
           Snapshot response = future.get();
         }
         
      • createSnapshotCallable

        public final com.google.api.gax.rpc.UnaryCallable<CreateSnapshotRequest,​com.google.longrunning.Operation> createSnapshotCallable()
        Create a new snapshot for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateSnapshotRequest request =
               CreateSnapshotRequest.newBuilder()
                   .setParent(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setSnapshot(Snapshot.newBuilder().build())
                   .setSnapshotId("snapshotId-1113817601")
                   .build();
           ApiFuture<Operation> future = netAppClient.createSnapshotCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • deleteSnapshotAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteSnapshotAsync​(SnapshotName name)
        Deletes a snapshot.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           SnapshotName name = SnapshotName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[SNAPSHOT]");
           netAppClient.deleteSnapshotAsync(name).get();
         }
         
        Parameters:
        name - Required. The snapshot resource name, in the format `projects/*/locations/*/volumes/*/snapshots/{snapshot_id}`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteSnapshotAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteSnapshotAsync​(String name)
        Deletes a snapshot.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String name = SnapshotName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[SNAPSHOT]").toString();
           netAppClient.deleteSnapshotAsync(name).get();
         }
         
        Parameters:
        name - Required. The snapshot resource name, in the format `projects/*/locations/*/volumes/*/snapshots/{snapshot_id}`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteSnapshotAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteSnapshotAsync​(DeleteSnapshotRequest request)
        Deletes a snapshot.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteSnapshotRequest request =
               DeleteSnapshotRequest.newBuilder()
                   .setName(
                       SnapshotName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[SNAPSHOT]").toString())
                   .build();
           netAppClient.deleteSnapshotAsync(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
      • deleteSnapshotOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<DeleteSnapshotRequest,​com.google.protobuf.Empty,​OperationMetadata> deleteSnapshotOperationCallable()
        Deletes a snapshot.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteSnapshotRequest request =
               DeleteSnapshotRequest.newBuilder()
                   .setName(
                       SnapshotName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[SNAPSHOT]").toString())
                   .build();
           OperationFuture<Empty, OperationMetadata> future =
               netAppClient.deleteSnapshotOperationCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • deleteSnapshotCallable

        public final com.google.api.gax.rpc.UnaryCallable<DeleteSnapshotRequest,​com.google.longrunning.Operation> deleteSnapshotCallable()
        Deletes a snapshot.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteSnapshotRequest request =
               DeleteSnapshotRequest.newBuilder()
                   .setName(
                       SnapshotName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[SNAPSHOT]").toString())
                   .build();
           ApiFuture<Operation> future = netAppClient.deleteSnapshotCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • updateSnapshotAsync

        public final com.google.api.gax.longrunning.OperationFuture<Snapshot,​OperationMetadata> updateSnapshotAsync​(Snapshot snapshot,
                                                                                                                          com.google.protobuf.FieldMask updateMask)
        Updates the settings of a specific snapshot.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           Snapshot snapshot = Snapshot.newBuilder().build();
           FieldMask updateMask = FieldMask.newBuilder().build();
           Snapshot response = netAppClient.updateSnapshotAsync(snapshot, updateMask).get();
         }
         
        Parameters:
        snapshot - Required. A snapshot resource
        updateMask - Required. Mask of fields to update. At least one path must be supplied in this field.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • updateSnapshotAsync

        public final com.google.api.gax.longrunning.OperationFuture<Snapshot,​OperationMetadata> updateSnapshotAsync​(UpdateSnapshotRequest request)
        Updates the settings of a specific snapshot.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateSnapshotRequest request =
               UpdateSnapshotRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setSnapshot(Snapshot.newBuilder().build())
                   .build();
           Snapshot response = netAppClient.updateSnapshotAsync(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
      • updateSnapshotOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UpdateSnapshotRequest,​Snapshot,​OperationMetadata> updateSnapshotOperationCallable()
        Updates the settings of a specific snapshot.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateSnapshotRequest request =
               UpdateSnapshotRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setSnapshot(Snapshot.newBuilder().build())
                   .build();
           OperationFuture<Snapshot, OperationMetadata> future =
               netAppClient.updateSnapshotOperationCallable().futureCall(request);
           // Do something.
           Snapshot response = future.get();
         }
         
      • updateSnapshotCallable

        public final com.google.api.gax.rpc.UnaryCallable<UpdateSnapshotRequest,​com.google.longrunning.Operation> updateSnapshotCallable()
        Updates the settings of a specific snapshot.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateSnapshotRequest request =
               UpdateSnapshotRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setSnapshot(Snapshot.newBuilder().build())
                   .build();
           ApiFuture<Operation> future = netAppClient.updateSnapshotCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • listActiveDirectories

        public final NetAppClient.ListActiveDirectoriesPagedResponse listActiveDirectories​(LocationName parent)
        Lists active directories.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           for (ActiveDirectory element : netAppClient.listActiveDirectories(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. Parent value for ListActiveDirectoriesRequest
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listActiveDirectories

        public final NetAppClient.ListActiveDirectoriesPagedResponse listActiveDirectories​(String parent)
        Lists active directories.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           for (ActiveDirectory element : netAppClient.listActiveDirectories(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. Parent value for ListActiveDirectoriesRequest
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listActiveDirectories

        public final NetAppClient.ListActiveDirectoriesPagedResponse listActiveDirectories​(ListActiveDirectoriesRequest request)
        Lists active directories.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListActiveDirectoriesRequest request =
               ListActiveDirectoriesRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           for (ActiveDirectory element : netAppClient.listActiveDirectories(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
      • listActiveDirectoriesPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListActiveDirectoriesRequest,​NetAppClient.ListActiveDirectoriesPagedResponse> listActiveDirectoriesPagedCallable()
        Lists active directories.

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

        public final com.google.api.gax.rpc.UnaryCallable<ListActiveDirectoriesRequest,​ListActiveDirectoriesResponse> listActiveDirectoriesCallable()
        Lists active directories.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListActiveDirectoriesRequest request =
               ListActiveDirectoriesRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setFilter("filter-1274492040")
                   .setOrderBy("orderBy-1207110587")
                   .build();
           while (true) {
             ListActiveDirectoriesResponse response =
                 netAppClient.listActiveDirectoriesCallable().call(request);
             for (ActiveDirectory element : response.getActiveDirectoriesList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • getActiveDirectory

        public final ActiveDirectory getActiveDirectory​(ActiveDirectoryName name)
        Describes a specified active directory.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ActiveDirectoryName name =
               ActiveDirectoryName.of("[PROJECT]", "[LOCATION]", "[ACTIVE_DIRECTORY]");
           ActiveDirectory response = netAppClient.getActiveDirectory(name);
         }
         
        Parameters:
        name - Required. Name of the active directory.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getActiveDirectory

        public final ActiveDirectory getActiveDirectory​(String name)
        Describes a specified active directory.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String name =
               ActiveDirectoryName.of("[PROJECT]", "[LOCATION]", "[ACTIVE_DIRECTORY]").toString();
           ActiveDirectory response = netAppClient.getActiveDirectory(name);
         }
         
        Parameters:
        name - Required. Name of the active directory.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getActiveDirectory

        public final ActiveDirectory getActiveDirectory​(GetActiveDirectoryRequest request)
        Describes a specified active directory.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetActiveDirectoryRequest request =
               GetActiveDirectoryRequest.newBuilder()
                   .setName(
                       ActiveDirectoryName.of("[PROJECT]", "[LOCATION]", "[ACTIVE_DIRECTORY]")
                           .toString())
                   .build();
           ActiveDirectory response = netAppClient.getActiveDirectory(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
      • getActiveDirectoryCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetActiveDirectoryRequest,​ActiveDirectory> getActiveDirectoryCallable()
        Describes a specified active directory.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetActiveDirectoryRequest request =
               GetActiveDirectoryRequest.newBuilder()
                   .setName(
                       ActiveDirectoryName.of("[PROJECT]", "[LOCATION]", "[ACTIVE_DIRECTORY]")
                           .toString())
                   .build();
           ApiFuture<ActiveDirectory> future =
               netAppClient.getActiveDirectoryCallable().futureCall(request);
           // Do something.
           ActiveDirectory response = future.get();
         }
         
      • createActiveDirectoryAsync

        public final com.google.api.gax.longrunning.OperationFuture<ActiveDirectory,​OperationMetadata> createActiveDirectoryAsync​(LocationName parent,
                                                                                                                                        ActiveDirectory activeDirectory,
                                                                                                                                        String activeDirectoryId)
        CreateActiveDirectory Creates the active directory specified in the request.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           ActiveDirectory activeDirectory = ActiveDirectory.newBuilder().build();
           String activeDirectoryId = "activeDirectoryId589359490";
           ActiveDirectory response =
               netAppClient.createActiveDirectoryAsync(parent, activeDirectory, activeDirectoryId).get();
         }
         
        Parameters:
        parent - Required. Value for parent.
        activeDirectory - Required. Fields of the to be created active directory.
        activeDirectoryId - Required. ID of the active directory to create.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createActiveDirectoryAsync

        public final com.google.api.gax.longrunning.OperationFuture<ActiveDirectory,​OperationMetadata> createActiveDirectoryAsync​(String parent,
                                                                                                                                        ActiveDirectory activeDirectory,
                                                                                                                                        String activeDirectoryId)
        CreateActiveDirectory Creates the active directory specified in the request.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           ActiveDirectory activeDirectory = ActiveDirectory.newBuilder().build();
           String activeDirectoryId = "activeDirectoryId589359490";
           ActiveDirectory response =
               netAppClient.createActiveDirectoryAsync(parent, activeDirectory, activeDirectoryId).get();
         }
         
        Parameters:
        parent - Required. Value for parent.
        activeDirectory - Required. Fields of the to be created active directory.
        activeDirectoryId - Required. ID of the active directory to create.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createActiveDirectoryAsync

        public final com.google.api.gax.longrunning.OperationFuture<ActiveDirectory,​OperationMetadata> createActiveDirectoryAsync​(CreateActiveDirectoryRequest request)
        CreateActiveDirectory Creates the active directory specified in the request.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateActiveDirectoryRequest request =
               CreateActiveDirectoryRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setActiveDirectory(ActiveDirectory.newBuilder().build())
                   .setActiveDirectoryId("activeDirectoryId589359490")
                   .build();
           ActiveDirectory response = netAppClient.createActiveDirectoryAsync(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
      • createActiveDirectoryOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<CreateActiveDirectoryRequest,​ActiveDirectory,​OperationMetadata> createActiveDirectoryOperationCallable()
        CreateActiveDirectory Creates the active directory specified in the request.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateActiveDirectoryRequest request =
               CreateActiveDirectoryRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setActiveDirectory(ActiveDirectory.newBuilder().build())
                   .setActiveDirectoryId("activeDirectoryId589359490")
                   .build();
           OperationFuture<ActiveDirectory, OperationMetadata> future =
               netAppClient.createActiveDirectoryOperationCallable().futureCall(request);
           // Do something.
           ActiveDirectory response = future.get();
         }
         
      • createActiveDirectoryCallable

        public final com.google.api.gax.rpc.UnaryCallable<CreateActiveDirectoryRequest,​com.google.longrunning.Operation> createActiveDirectoryCallable()
        CreateActiveDirectory Creates the active directory specified in the request.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateActiveDirectoryRequest request =
               CreateActiveDirectoryRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setActiveDirectory(ActiveDirectory.newBuilder().build())
                   .setActiveDirectoryId("activeDirectoryId589359490")
                   .build();
           ApiFuture<Operation> future =
               netAppClient.createActiveDirectoryCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • updateActiveDirectoryAsync

        public final com.google.api.gax.longrunning.OperationFuture<ActiveDirectory,​OperationMetadata> updateActiveDirectoryAsync​(ActiveDirectory activeDirectory,
                                                                                                                                        com.google.protobuf.FieldMask updateMask)
        Update the parameters of an active directories.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ActiveDirectory activeDirectory = ActiveDirectory.newBuilder().build();
           FieldMask updateMask = FieldMask.newBuilder().build();
           ActiveDirectory response =
               netAppClient.updateActiveDirectoryAsync(activeDirectory, updateMask).get();
         }
         
        Parameters:
        activeDirectory - Required. The volume being updated
        updateMask - Required. Field mask is used to specify the fields to be overwritten in the Active Directory 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
      • updateActiveDirectoryAsync

        public final com.google.api.gax.longrunning.OperationFuture<ActiveDirectory,​OperationMetadata> updateActiveDirectoryAsync​(UpdateActiveDirectoryRequest request)
        Update the parameters of an active directories.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateActiveDirectoryRequest request =
               UpdateActiveDirectoryRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setActiveDirectory(ActiveDirectory.newBuilder().build())
                   .build();
           ActiveDirectory response = netAppClient.updateActiveDirectoryAsync(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
      • updateActiveDirectoryOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UpdateActiveDirectoryRequest,​ActiveDirectory,​OperationMetadata> updateActiveDirectoryOperationCallable()
        Update the parameters of an active directories.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateActiveDirectoryRequest request =
               UpdateActiveDirectoryRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setActiveDirectory(ActiveDirectory.newBuilder().build())
                   .build();
           OperationFuture<ActiveDirectory, OperationMetadata> future =
               netAppClient.updateActiveDirectoryOperationCallable().futureCall(request);
           // Do something.
           ActiveDirectory response = future.get();
         }
         
      • updateActiveDirectoryCallable

        public final com.google.api.gax.rpc.UnaryCallable<UpdateActiveDirectoryRequest,​com.google.longrunning.Operation> updateActiveDirectoryCallable()
        Update the parameters of an active directories.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateActiveDirectoryRequest request =
               UpdateActiveDirectoryRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setActiveDirectory(ActiveDirectory.newBuilder().build())
                   .build();
           ApiFuture<Operation> future =
               netAppClient.updateActiveDirectoryCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • deleteActiveDirectoryAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteActiveDirectoryAsync​(ActiveDirectoryName name)
        Delete the active directory specified in the request.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ActiveDirectoryName name =
               ActiveDirectoryName.of("[PROJECT]", "[LOCATION]", "[ACTIVE_DIRECTORY]");
           netAppClient.deleteActiveDirectoryAsync(name).get();
         }
         
        Parameters:
        name - Required. Name of the active directory.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteActiveDirectoryAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteActiveDirectoryAsync​(String name)
        Delete the active directory specified in the request.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String name =
               ActiveDirectoryName.of("[PROJECT]", "[LOCATION]", "[ACTIVE_DIRECTORY]").toString();
           netAppClient.deleteActiveDirectoryAsync(name).get();
         }
         
        Parameters:
        name - Required. Name of the active directory.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteActiveDirectoryAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteActiveDirectoryAsync​(DeleteActiveDirectoryRequest request)
        Delete the active directory specified in the request.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteActiveDirectoryRequest request =
               DeleteActiveDirectoryRequest.newBuilder()
                   .setName(
                       ActiveDirectoryName.of("[PROJECT]", "[LOCATION]", "[ACTIVE_DIRECTORY]")
                           .toString())
                   .build();
           netAppClient.deleteActiveDirectoryAsync(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
      • deleteActiveDirectoryOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<DeleteActiveDirectoryRequest,​com.google.protobuf.Empty,​OperationMetadata> deleteActiveDirectoryOperationCallable()
        Delete the active directory specified in the request.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteActiveDirectoryRequest request =
               DeleteActiveDirectoryRequest.newBuilder()
                   .setName(
                       ActiveDirectoryName.of("[PROJECT]", "[LOCATION]", "[ACTIVE_DIRECTORY]")
                           .toString())
                   .build();
           OperationFuture<Empty, OperationMetadata> future =
               netAppClient.deleteActiveDirectoryOperationCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • deleteActiveDirectoryCallable

        public final com.google.api.gax.rpc.UnaryCallable<DeleteActiveDirectoryRequest,​com.google.longrunning.Operation> deleteActiveDirectoryCallable()
        Delete the active directory specified in the request.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteActiveDirectoryRequest request =
               DeleteActiveDirectoryRequest.newBuilder()
                   .setName(
                       ActiveDirectoryName.of("[PROJECT]", "[LOCATION]", "[ACTIVE_DIRECTORY]")
                           .toString())
                   .build();
           ApiFuture<Operation> future =
               netAppClient.deleteActiveDirectoryCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • listKmsConfigs

        public final NetAppClient.ListKmsConfigsPagedResponse listKmsConfigs​(LocationName parent)
        Returns descriptions of all KMS configs owned by the caller.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           for (KmsConfig element : netAppClient.listKmsConfigs(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. Parent value
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listKmsConfigs

        public final NetAppClient.ListKmsConfigsPagedResponse listKmsConfigs​(String parent)
        Returns descriptions of all KMS configs owned by the caller.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           for (KmsConfig element : netAppClient.listKmsConfigs(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. Parent value
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listKmsConfigs

        public final NetAppClient.ListKmsConfigsPagedResponse listKmsConfigs​(ListKmsConfigsRequest request)
        Returns descriptions of all KMS configs owned by the caller.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListKmsConfigsRequest request =
               ListKmsConfigsRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setOrderBy("orderBy-1207110587")
                   .setFilter("filter-1274492040")
                   .build();
           for (KmsConfig element : netAppClient.listKmsConfigs(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
      • listKmsConfigsPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListKmsConfigsRequest,​NetAppClient.ListKmsConfigsPagedResponse> listKmsConfigsPagedCallable()
        Returns descriptions of all KMS configs owned by the caller.

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

        public final com.google.api.gax.rpc.UnaryCallable<ListKmsConfigsRequest,​ListKmsConfigsResponse> listKmsConfigsCallable()
        Returns descriptions of all KMS configs owned by the caller.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListKmsConfigsRequest request =
               ListKmsConfigsRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setOrderBy("orderBy-1207110587")
                   .setFilter("filter-1274492040")
                   .build();
           while (true) {
             ListKmsConfigsResponse response = netAppClient.listKmsConfigsCallable().call(request);
             for (KmsConfig element : response.getKmsConfigsList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • createKmsConfigAsync

        public final com.google.api.gax.longrunning.OperationFuture<KmsConfig,​OperationMetadata> createKmsConfigAsync​(LocationName parent,
                                                                                                                            KmsConfig kmsConfig,
                                                                                                                            String kmsConfigId)
        Creates a new KMS config.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
           KmsConfig kmsConfig = KmsConfig.newBuilder().build();
           String kmsConfigId = "kmsConfigId-1159731602";
           KmsConfig response = netAppClient.createKmsConfigAsync(parent, kmsConfig, kmsConfigId).get();
         }
         
        Parameters:
        parent - Required. Value for parent.
        kmsConfig - Required. The required parameters to create a new KmsConfig.
        kmsConfigId - Required. Id of the requesting KmsConfig If auto-generating Id server-side, remove this field and id from the method_signature of Create RPC
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createKmsConfigAsync

        public final com.google.api.gax.longrunning.OperationFuture<KmsConfig,​OperationMetadata> createKmsConfigAsync​(String parent,
                                                                                                                            KmsConfig kmsConfig,
                                                                                                                            String kmsConfigId)
        Creates a new KMS config.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
           KmsConfig kmsConfig = KmsConfig.newBuilder().build();
           String kmsConfigId = "kmsConfigId-1159731602";
           KmsConfig response = netAppClient.createKmsConfigAsync(parent, kmsConfig, kmsConfigId).get();
         }
         
        Parameters:
        parent - Required. Value for parent.
        kmsConfig - Required. The required parameters to create a new KmsConfig.
        kmsConfigId - Required. Id of the requesting KmsConfig If auto-generating Id server-side, remove this field and id from the method_signature of Create RPC
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createKmsConfigAsync

        public final com.google.api.gax.longrunning.OperationFuture<KmsConfig,​OperationMetadata> createKmsConfigAsync​(CreateKmsConfigRequest request)
        Creates a new KMS config.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateKmsConfigRequest request =
               CreateKmsConfigRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setKmsConfigId("kmsConfigId-1159731602")
                   .setKmsConfig(KmsConfig.newBuilder().build())
                   .build();
           KmsConfig response = netAppClient.createKmsConfigAsync(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
      • createKmsConfigOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<CreateKmsConfigRequest,​KmsConfig,​OperationMetadata> createKmsConfigOperationCallable()
        Creates a new KMS config.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateKmsConfigRequest request =
               CreateKmsConfigRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setKmsConfigId("kmsConfigId-1159731602")
                   .setKmsConfig(KmsConfig.newBuilder().build())
                   .build();
           OperationFuture<KmsConfig, OperationMetadata> future =
               netAppClient.createKmsConfigOperationCallable().futureCall(request);
           // Do something.
           KmsConfig response = future.get();
         }
         
      • createKmsConfigCallable

        public final com.google.api.gax.rpc.UnaryCallable<CreateKmsConfigRequest,​com.google.longrunning.Operation> createKmsConfigCallable()
        Creates a new KMS config.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateKmsConfigRequest request =
               CreateKmsConfigRequest.newBuilder()
                   .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
                   .setKmsConfigId("kmsConfigId-1159731602")
                   .setKmsConfig(KmsConfig.newBuilder().build())
                   .build();
           ApiFuture<Operation> future = netAppClient.createKmsConfigCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • getKmsConfig

        public final KmsConfig getKmsConfig​(KmsConfigName name)
        Returns the description of the specified KMS config by kms_config_id.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           KmsConfigName name = KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]");
           KmsConfig response = netAppClient.getKmsConfig(name);
         }
         
        Parameters:
        name - Required. Name of the KmsConfig
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getKmsConfig

        public final KmsConfig getKmsConfig​(String name)
        Returns the description of the specified KMS config by kms_config_id.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String name = KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]").toString();
           KmsConfig response = netAppClient.getKmsConfig(name);
         }
         
        Parameters:
        name - Required. Name of the KmsConfig
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getKmsConfig

        public final KmsConfig getKmsConfig​(GetKmsConfigRequest request)
        Returns the description of the specified KMS config by kms_config_id.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetKmsConfigRequest request =
               GetKmsConfigRequest.newBuilder()
                   .setName(KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]").toString())
                   .build();
           KmsConfig response = netAppClient.getKmsConfig(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
      • getKmsConfigCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetKmsConfigRequest,​KmsConfig> getKmsConfigCallable()
        Returns the description of the specified KMS config by kms_config_id.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetKmsConfigRequest request =
               GetKmsConfigRequest.newBuilder()
                   .setName(KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]").toString())
                   .build();
           ApiFuture<KmsConfig> future = netAppClient.getKmsConfigCallable().futureCall(request);
           // Do something.
           KmsConfig response = future.get();
         }
         
      • updateKmsConfigAsync

        public final com.google.api.gax.longrunning.OperationFuture<KmsConfig,​OperationMetadata> updateKmsConfigAsync​(KmsConfig kmsConfig,
                                                                                                                            com.google.protobuf.FieldMask updateMask)
        Updates the Kms config properties with the full spec

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           KmsConfig kmsConfig = KmsConfig.newBuilder().build();
           FieldMask updateMask = FieldMask.newBuilder().build();
           KmsConfig response = netAppClient.updateKmsConfigAsync(kmsConfig, updateMask).get();
         }
         
        Parameters:
        kmsConfig - Required. The KmsConfig being updated
        updateMask - Required. Field mask is used to specify the fields to be overwritten in the KmsConfig 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
      • updateKmsConfigAsync

        public final com.google.api.gax.longrunning.OperationFuture<KmsConfig,​OperationMetadata> updateKmsConfigAsync​(UpdateKmsConfigRequest request)
        Updates the Kms config properties with the full spec

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateKmsConfigRequest request =
               UpdateKmsConfigRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setKmsConfig(KmsConfig.newBuilder().build())
                   .build();
           KmsConfig response = netAppClient.updateKmsConfigAsync(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
      • updateKmsConfigOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UpdateKmsConfigRequest,​KmsConfig,​OperationMetadata> updateKmsConfigOperationCallable()
        Updates the Kms config properties with the full spec

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateKmsConfigRequest request =
               UpdateKmsConfigRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setKmsConfig(KmsConfig.newBuilder().build())
                   .build();
           OperationFuture<KmsConfig, OperationMetadata> future =
               netAppClient.updateKmsConfigOperationCallable().futureCall(request);
           // Do something.
           KmsConfig response = future.get();
         }
         
      • updateKmsConfigCallable

        public final com.google.api.gax.rpc.UnaryCallable<UpdateKmsConfigRequest,​com.google.longrunning.Operation> updateKmsConfigCallable()
        Updates the Kms config properties with the full spec

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateKmsConfigRequest request =
               UpdateKmsConfigRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setKmsConfig(KmsConfig.newBuilder().build())
                   .build();
           ApiFuture<Operation> future = netAppClient.updateKmsConfigCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • encryptVolumesAsync

        public final com.google.api.gax.longrunning.OperationFuture<KmsConfig,​OperationMetadata> encryptVolumesAsync​(EncryptVolumesRequest request)
        Encrypt the existing volumes without CMEK encryption with the desired the KMS config for the whole region.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           EncryptVolumesRequest request =
               EncryptVolumesRequest.newBuilder()
                   .setName(KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]").toString())
                   .build();
           KmsConfig response = netAppClient.encryptVolumesAsync(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
      • encryptVolumesOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<EncryptVolumesRequest,​KmsConfig,​OperationMetadata> encryptVolumesOperationCallable()
        Encrypt the existing volumes without CMEK encryption with the desired the KMS config for the whole region.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           EncryptVolumesRequest request =
               EncryptVolumesRequest.newBuilder()
                   .setName(KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]").toString())
                   .build();
           OperationFuture<KmsConfig, OperationMetadata> future =
               netAppClient.encryptVolumesOperationCallable().futureCall(request);
           // Do something.
           KmsConfig response = future.get();
         }
         
      • encryptVolumesCallable

        public final com.google.api.gax.rpc.UnaryCallable<EncryptVolumesRequest,​com.google.longrunning.Operation> encryptVolumesCallable()
        Encrypt the existing volumes without CMEK encryption with the desired the KMS config for the whole region.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           EncryptVolumesRequest request =
               EncryptVolumesRequest.newBuilder()
                   .setName(KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]").toString())
                   .build();
           ApiFuture<Operation> future = netAppClient.encryptVolumesCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • verifyKmsConfig

        public final VerifyKmsConfigResponse verifyKmsConfig​(VerifyKmsConfigRequest request)
        Verifies KMS config reachability.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           VerifyKmsConfigRequest request =
               VerifyKmsConfigRequest.newBuilder()
                   .setName(KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]").toString())
                   .build();
           VerifyKmsConfigResponse response = netAppClient.verifyKmsConfig(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
      • verifyKmsConfigCallable

        public final com.google.api.gax.rpc.UnaryCallable<VerifyKmsConfigRequest,​VerifyKmsConfigResponse> verifyKmsConfigCallable()
        Verifies KMS config reachability.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           VerifyKmsConfigRequest request =
               VerifyKmsConfigRequest.newBuilder()
                   .setName(KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]").toString())
                   .build();
           ApiFuture<VerifyKmsConfigResponse> future =
               netAppClient.verifyKmsConfigCallable().futureCall(request);
           // Do something.
           VerifyKmsConfigResponse response = future.get();
         }
         
      • deleteKmsConfigAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteKmsConfigAsync​(KmsConfigName name)
        Warning! This operation will permanently delete the Kms config.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           KmsConfigName name = KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]");
           netAppClient.deleteKmsConfigAsync(name).get();
         }
         
        Parameters:
        name - Required. Name of the KmsConfig.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteKmsConfigAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteKmsConfigAsync​(String name)
        Warning! This operation will permanently delete the Kms config.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String name = KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]").toString();
           netAppClient.deleteKmsConfigAsync(name).get();
         }
         
        Parameters:
        name - Required. Name of the KmsConfig.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteKmsConfigAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteKmsConfigAsync​(DeleteKmsConfigRequest request)
        Warning! This operation will permanently delete the Kms config.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteKmsConfigRequest request =
               DeleteKmsConfigRequest.newBuilder()
                   .setName(KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]").toString())
                   .build();
           netAppClient.deleteKmsConfigAsync(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
      • deleteKmsConfigOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<DeleteKmsConfigRequest,​com.google.protobuf.Empty,​OperationMetadata> deleteKmsConfigOperationCallable()
        Warning! This operation will permanently delete the Kms config.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteKmsConfigRequest request =
               DeleteKmsConfigRequest.newBuilder()
                   .setName(KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]").toString())
                   .build();
           OperationFuture<Empty, OperationMetadata> future =
               netAppClient.deleteKmsConfigOperationCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • deleteKmsConfigCallable

        public final com.google.api.gax.rpc.UnaryCallable<DeleteKmsConfigRequest,​com.google.longrunning.Operation> deleteKmsConfigCallable()
        Warning! This operation will permanently delete the Kms config.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteKmsConfigRequest request =
               DeleteKmsConfigRequest.newBuilder()
                   .setName(KmsConfigName.of("[PROJECT]", "[LOCATION]", "[KMS_CONFIG]").toString())
                   .build();
           ApiFuture<Operation> future = netAppClient.deleteKmsConfigCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • listReplications

        public final NetAppClient.ListReplicationsPagedResponse listReplications​(VolumeName parent)
        Returns descriptions of all replications for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           VolumeName parent = VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]");
           for (Replication element : netAppClient.listReplications(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The volume for which to retrieve replication information, in the format `projects/{project_id}/locations/{location}/volumes/{volume_id}`.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listReplications

        public final NetAppClient.ListReplicationsPagedResponse listReplications​(String parent)
        Returns descriptions of all replications for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String parent = VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString();
           for (Replication element : netAppClient.listReplications(parent).iterateAll()) {
             // doThingsWith(element);
           }
         }
         
        Parameters:
        parent - Required. The volume for which to retrieve replication information, in the format `projects/{project_id}/locations/{location}/volumes/{volume_id}`.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • listReplications

        public final NetAppClient.ListReplicationsPagedResponse listReplications​(ListReplicationsRequest request)
        Returns descriptions of all replications for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListReplicationsRequest request =
               ListReplicationsRequest.newBuilder()
                   .setParent(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setOrderBy("orderBy-1207110587")
                   .setFilter("filter-1274492040")
                   .build();
           for (Replication element : netAppClient.listReplications(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
      • listReplicationsPagedCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListReplicationsRequest,​NetAppClient.ListReplicationsPagedResponse> listReplicationsPagedCallable()
        Returns descriptions of all replications for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListReplicationsRequest request =
               ListReplicationsRequest.newBuilder()
                   .setParent(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setOrderBy("orderBy-1207110587")
                   .setFilter("filter-1274492040")
                   .build();
           ApiFuture<Replication> future =
               netAppClient.listReplicationsPagedCallable().futureCall(request);
           // Do something.
           for (Replication element : future.get().iterateAll()) {
             // doThingsWith(element);
           }
         }
         
      • listReplicationsCallable

        public final com.google.api.gax.rpc.UnaryCallable<ListReplicationsRequest,​ListReplicationsResponse> listReplicationsCallable()
        Returns descriptions of all replications for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListReplicationsRequest request =
               ListReplicationsRequest.newBuilder()
                   .setParent(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .setOrderBy("orderBy-1207110587")
                   .setFilter("filter-1274492040")
                   .build();
           while (true) {
             ListReplicationsResponse response = netAppClient.listReplicationsCallable().call(request);
             for (Replication element : response.getReplicationsList()) {
               // doThingsWith(element);
             }
             String nextPageToken = response.getNextPageToken();
             if (!Strings.isNullOrEmpty(nextPageToken)) {
               request = request.toBuilder().setPageToken(nextPageToken).build();
             } else {
               break;
             }
           }
         }
         
      • getReplication

        public final Replication getReplication​(ReplicationName name)
        Describe a replication for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ReplicationName name =
               ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]");
           Replication response = netAppClient.getReplication(name);
         }
         
        Parameters:
        name - Required. The replication resource name, in the format `projects/{project_id}/locations/{location}/volumes/{volume_id}/replications/{replication_id}`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getReplication

        public final Replication getReplication​(String name)
        Describe a replication for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String name =
               ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]").toString();
           Replication response = netAppClient.getReplication(name);
         }
         
        Parameters:
        name - Required. The replication resource name, in the format `projects/{project_id}/locations/{location}/volumes/{volume_id}/replications/{replication_id}`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • getReplication

        public final Replication getReplication​(GetReplicationRequest request)
        Describe a replication for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetReplicationRequest request =
               GetReplicationRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .build();
           Replication response = netAppClient.getReplication(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
      • getReplicationCallable

        public final com.google.api.gax.rpc.UnaryCallable<GetReplicationRequest,​Replication> getReplicationCallable()
        Describe a replication for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetReplicationRequest request =
               GetReplicationRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .build();
           ApiFuture<Replication> future = netAppClient.getReplicationCallable().futureCall(request);
           // Do something.
           Replication response = future.get();
         }
         
      • createReplicationAsync

        public final com.google.api.gax.longrunning.OperationFuture<Replication,​OperationMetadata> createReplicationAsync​(VolumeName parent,
                                                                                                                                Replication replication,
                                                                                                                                String replicationId)
        Create a new replication for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           VolumeName parent = VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]");
           Replication replication = Replication.newBuilder().build();
           String replicationId = "replicationId1170820615";
           Replication response =
               netAppClient.createReplicationAsync(parent, replication, replicationId).get();
         }
         
        Parameters:
        parent - Required. The NetApp volume to create the replications of, in the format `projects/{project_id}/locations/{location}/volumes/{volume_id}`
        replication - Required. A replication resource
        replicationId - Required. ID of the replication to create. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createReplicationAsync

        public final com.google.api.gax.longrunning.OperationFuture<Replication,​OperationMetadata> createReplicationAsync​(String parent,
                                                                                                                                Replication replication,
                                                                                                                                String replicationId)
        Create a new replication for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String parent = VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString();
           Replication replication = Replication.newBuilder().build();
           String replicationId = "replicationId1170820615";
           Replication response =
               netAppClient.createReplicationAsync(parent, replication, replicationId).get();
         }
         
        Parameters:
        parent - Required. The NetApp volume to create the replications of, in the format `projects/{project_id}/locations/{location}/volumes/{volume_id}`
        replication - Required. A replication resource
        replicationId - Required. ID of the replication to create. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • createReplicationAsync

        public final com.google.api.gax.longrunning.OperationFuture<Replication,​OperationMetadata> createReplicationAsync​(CreateReplicationRequest request)
        Create a new replication for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateReplicationRequest request =
               CreateReplicationRequest.newBuilder()
                   .setParent(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setReplication(Replication.newBuilder().build())
                   .setReplicationId("replicationId1170820615")
                   .build();
           Replication response = netAppClient.createReplicationAsync(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
      • createReplicationOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<CreateReplicationRequest,​Replication,​OperationMetadata> createReplicationOperationCallable()
        Create a new replication for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateReplicationRequest request =
               CreateReplicationRequest.newBuilder()
                   .setParent(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setReplication(Replication.newBuilder().build())
                   .setReplicationId("replicationId1170820615")
                   .build();
           OperationFuture<Replication, OperationMetadata> future =
               netAppClient.createReplicationOperationCallable().futureCall(request);
           // Do something.
           Replication response = future.get();
         }
         
      • createReplicationCallable

        public final com.google.api.gax.rpc.UnaryCallable<CreateReplicationRequest,​com.google.longrunning.Operation> createReplicationCallable()
        Create a new replication for a volume.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           CreateReplicationRequest request =
               CreateReplicationRequest.newBuilder()
                   .setParent(VolumeName.of("[PROJECT]", "[LOCATION]", "[VOLUME]").toString())
                   .setReplication(Replication.newBuilder().build())
                   .setReplicationId("replicationId1170820615")
                   .build();
           ApiFuture<Operation> future = netAppClient.createReplicationCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • deleteReplicationAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteReplicationAsync​(ReplicationName name)
        Deletes a replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ReplicationName name =
               ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]");
           netAppClient.deleteReplicationAsync(name).get();
         }
         
        Parameters:
        name - Required. The replication resource name, in the format `projects/*/locations/*/volumes/*/replications/{replication_id}`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteReplicationAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteReplicationAsync​(String name)
        Deletes a replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           String name =
               ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]").toString();
           netAppClient.deleteReplicationAsync(name).get();
         }
         
        Parameters:
        name - Required. The replication resource name, in the format `projects/*/locations/*/volumes/*/replications/{replication_id}`
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • deleteReplicationAsync

        public final com.google.api.gax.longrunning.OperationFuture<com.google.protobuf.Empty,​OperationMetadata> deleteReplicationAsync​(DeleteReplicationRequest request)
        Deletes a replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteReplicationRequest request =
               DeleteReplicationRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .build();
           netAppClient.deleteReplicationAsync(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
      • deleteReplicationOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<DeleteReplicationRequest,​com.google.protobuf.Empty,​OperationMetadata> deleteReplicationOperationCallable()
        Deletes a replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteReplicationRequest request =
               DeleteReplicationRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .build();
           OperationFuture<Empty, OperationMetadata> future =
               netAppClient.deleteReplicationOperationCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • deleteReplicationCallable

        public final com.google.api.gax.rpc.UnaryCallable<DeleteReplicationRequest,​com.google.longrunning.Operation> deleteReplicationCallable()
        Deletes a replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           DeleteReplicationRequest request =
               DeleteReplicationRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .build();
           ApiFuture<Operation> future = netAppClient.deleteReplicationCallable().futureCall(request);
           // Do something.
           future.get();
         }
         
      • updateReplicationAsync

        public final com.google.api.gax.longrunning.OperationFuture<Replication,​OperationMetadata> updateReplicationAsync​(Replication replication,
                                                                                                                                com.google.protobuf.FieldMask updateMask)
        Updates the settings of a specific replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           Replication replication = Replication.newBuilder().build();
           FieldMask updateMask = FieldMask.newBuilder().build();
           Replication response = netAppClient.updateReplicationAsync(replication, updateMask).get();
         }
         
        Parameters:
        replication - Required. A replication resource
        updateMask - Required. Mask of fields to update. At least one path must be supplied in this field.
        Throws:
        com.google.api.gax.rpc.ApiException - if the remote call fails
      • updateReplicationAsync

        public final com.google.api.gax.longrunning.OperationFuture<Replication,​OperationMetadata> updateReplicationAsync​(UpdateReplicationRequest request)
        Updates the settings of a specific replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateReplicationRequest request =
               UpdateReplicationRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setReplication(Replication.newBuilder().build())
                   .build();
           Replication response = netAppClient.updateReplicationAsync(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
      • updateReplicationOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<UpdateReplicationRequest,​Replication,​OperationMetadata> updateReplicationOperationCallable()
        Updates the settings of a specific replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateReplicationRequest request =
               UpdateReplicationRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setReplication(Replication.newBuilder().build())
                   .build();
           OperationFuture<Replication, OperationMetadata> future =
               netAppClient.updateReplicationOperationCallable().futureCall(request);
           // Do something.
           Replication response = future.get();
         }
         
      • updateReplicationCallable

        public final com.google.api.gax.rpc.UnaryCallable<UpdateReplicationRequest,​com.google.longrunning.Operation> updateReplicationCallable()
        Updates the settings of a specific replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           UpdateReplicationRequest request =
               UpdateReplicationRequest.newBuilder()
                   .setUpdateMask(FieldMask.newBuilder().build())
                   .setReplication(Replication.newBuilder().build())
                   .build();
           ApiFuture<Operation> future = netAppClient.updateReplicationCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • stopReplicationAsync

        public final com.google.api.gax.longrunning.OperationFuture<Replication,​OperationMetadata> stopReplicationAsync​(StopReplicationRequest request)
        Stop Cross Region Replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           StopReplicationRequest request =
               StopReplicationRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .setForce(true)
                   .build();
           Replication response = netAppClient.stopReplicationAsync(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
      • stopReplicationOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<StopReplicationRequest,​Replication,​OperationMetadata> stopReplicationOperationCallable()
        Stop Cross Region Replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           StopReplicationRequest request =
               StopReplicationRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .setForce(true)
                   .build();
           OperationFuture<Replication, OperationMetadata> future =
               netAppClient.stopReplicationOperationCallable().futureCall(request);
           // Do something.
           Replication response = future.get();
         }
         
      • stopReplicationCallable

        public final com.google.api.gax.rpc.UnaryCallable<StopReplicationRequest,​com.google.longrunning.Operation> stopReplicationCallable()
        Stop Cross Region Replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           StopReplicationRequest request =
               StopReplicationRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .setForce(true)
                   .build();
           ApiFuture<Operation> future = netAppClient.stopReplicationCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • resumeReplicationAsync

        public final com.google.api.gax.longrunning.OperationFuture<Replication,​OperationMetadata> resumeReplicationAsync​(ResumeReplicationRequest request)
        Resume Cross Region Replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ResumeReplicationRequest request =
               ResumeReplicationRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .build();
           Replication response = netAppClient.resumeReplicationAsync(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
      • resumeReplicationOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<ResumeReplicationRequest,​Replication,​OperationMetadata> resumeReplicationOperationCallable()
        Resume Cross Region Replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ResumeReplicationRequest request =
               ResumeReplicationRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .build();
           OperationFuture<Replication, OperationMetadata> future =
               netAppClient.resumeReplicationOperationCallable().futureCall(request);
           // Do something.
           Replication response = future.get();
         }
         
      • resumeReplicationCallable

        public final com.google.api.gax.rpc.UnaryCallable<ResumeReplicationRequest,​com.google.longrunning.Operation> resumeReplicationCallable()
        Resume Cross Region Replication.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ResumeReplicationRequest request =
               ResumeReplicationRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .build();
           ApiFuture<Operation> future = netAppClient.resumeReplicationCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • reverseReplicationDirectionAsync

        public final com.google.api.gax.longrunning.OperationFuture<Replication,​OperationMetadata> reverseReplicationDirectionAsync​(ReverseReplicationDirectionRequest request)
        Reverses direction of replication. Source becomes destination and destination becomes source.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ReverseReplicationDirectionRequest request =
               ReverseReplicationDirectionRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .build();
           Replication response = netAppClient.reverseReplicationDirectionAsync(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
      • reverseReplicationDirectionOperationCallable

        public final com.google.api.gax.rpc.OperationCallable<ReverseReplicationDirectionRequest,​Replication,​OperationMetadata> reverseReplicationDirectionOperationCallable()
        Reverses direction of replication. Source becomes destination and destination becomes source.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ReverseReplicationDirectionRequest request =
               ReverseReplicationDirectionRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .build();
           OperationFuture<Replication, OperationMetadata> future =
               netAppClient.reverseReplicationDirectionOperationCallable().futureCall(request);
           // Do something.
           Replication response = future.get();
         }
         
      • reverseReplicationDirectionCallable

        public final com.google.api.gax.rpc.UnaryCallable<ReverseReplicationDirectionRequest,​com.google.longrunning.Operation> reverseReplicationDirectionCallable()
        Reverses direction of replication. Source becomes destination and destination becomes source.

        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 (NetAppClient netAppClient = NetAppClient.create()) {
           ReverseReplicationDirectionRequest request =
               ReverseReplicationDirectionRequest.newBuilder()
                   .setName(
                       ReplicationName.of("[PROJECT]", "[LOCATION]", "[VOLUME]", "[REPLICATION]")
                           .toString())
                   .build();
           ApiFuture<Operation> future =
               netAppClient.reverseReplicationDirectionCallable().futureCall(request);
           // Do something.
           Operation response = future.get();
         }
         
      • listLocations

        public final NetAppClient.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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListLocationsRequest request =
               ListLocationsRequest.newBuilder()
                   .setName("name3373707")
                   .setFilter("filter-1274492040")
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           for (Location element : netAppClient.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,​NetAppClient.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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListLocationsRequest request =
               ListLocationsRequest.newBuilder()
                   .setName("name3373707")
                   .setFilter("filter-1274492040")
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           ApiFuture<Location> future = netAppClient.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 (NetAppClient netAppClient = NetAppClient.create()) {
           ListLocationsRequest request =
               ListLocationsRequest.newBuilder()
                   .setName("name3373707")
                   .setFilter("filter-1274492040")
                   .setPageSize(883849137)
                   .setPageToken("pageToken873572522")
                   .build();
           while (true) {
             ListLocationsResponse response = netAppClient.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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
           Location response = netAppClient.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 (NetAppClient netAppClient = NetAppClient.create()) {
           GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
           ApiFuture<Location> future = netAppClient.getLocationCallable().futureCall(request);
           // Do something.
           Location 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