# Class TpuClient (2.94.0)

2.94.0 (latest) 2.92.0 2.89.0 2.88.0 2.86.0 2.84.0 2.83.0 2.81.0 2.79.0 2.77.0 2.76.0 2.75.0 2.74.0 2.73.0 2.71.0 2.69.0 2.68.0 2.65.0 2.64.0 2.63.0 2.61.0 2.60.0 2.59.0 2.58.0 2.57.0 2.56.0 2.55.0 2.54.0 2.53.0 2.52.0 2.50.0 2.49.0 2.48.0 2.47.0 2.46.0 2.45.0 2.44.0 2.43.0 2.42.0 2.41.0 2.40.0 2.38.0 2.37.0 2.36.0 2.35.0 2.34.0 2.33.0 2.32.0 2.31.0 2.30.0 2.29.0 2.28.0 2.25.0 2.24.0 2.23.0 2.22.0 2.21.0 2.20.0 2.19.0 2.18.0 2.17.0 2.16.0 2.15.0 2.14.0 2.13.0 2.12.0 2.10.0 2.9.0 2.8.0 2.7.0 2.6.0 2.5.0 2.2.6

|---|---|---|
| [GitHub Repository](https://github.com/googleapis/google-cloud-java/tree/main/java-tpu/google-cloud-tpu/src/main/java/com/google/cloud/tpu/v1/TpuClient.java) | [Product Reference](https://cloud.google.com/tpu/docs) | [REST Documentation](https://cloud.google.com/tpu/docs/reference/rest) |

Service Description: Manages TPU nodes and other resources

TPU API v1

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 (TpuClient tpuClient = TpuClient.create()) {
       NodeName name = NodeName.of("[PROJECT]", "[LOCATION]", "[NODE]");
       Node response = tpuClient.getNode(name);
     }
     
Note: close() needs to be called on the TpuClient object to clean up resources such as
threads. In the example above, try-with-resources is used, which automatically calls close().

| Method | Description | Method Variants |
|---|---|---|
| ListNodes | Lists nodes. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - listNodes(ListNodesRequest request) "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method. - listNodes(LocationName parent) - listNodes(String parent) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - listNodesPagedCallable() - listNodesCallable() |
| GetNode | Gets the details of a node. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - getNode(GetNodeRequest request) "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method. - getNode(NodeName name) - getNode(String name) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - getNodeCallable() |
| CreateNode | Creates a node. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - createNodeAsync(CreateNodeRequest request) Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service. - createNodeAsync(LocationName parent, Node node, String nodeId) - createNodeAsync(String parent, Node node, String nodeId) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - createNodeOperationCallable() - createNodeCallable() |
| DeleteNode | Deletes a node. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - deleteNodeAsync(DeleteNodeRequest request) Methods that return long-running operations have "Async" method variants that return `OperationFuture`, which is used to track polling of the service. - deleteNodeAsync(NodeName name) - deleteNodeAsync(String name) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - deleteNodeOperationCallable() - deleteNodeCallable() |
| ReimageNode | Reimages a node's OS. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - reimageNodeAsync(ReimageNodeRequest request) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - reimageNodeOperationCallable() - reimageNodeCallable() |
| StopNode | Stops a node, this operation is only available with single TPU nodes. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - stopNodeAsync(StopNodeRequest request) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - stopNodeOperationCallable() - stopNodeCallable() |
| StartNode | Starts a node. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - startNodeAsync(StartNodeRequest request) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - startNodeOperationCallable() - startNodeCallable() |
| ListTensorFlowVersions | List TensorFlow versions supported by this API. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - listTensorFlowVersions(ListTensorFlowVersionsRequest request) "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method. - listTensorFlowVersions(TensorFlowVersionName parent) - listTensorFlowVersions(String parent) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - listTensorFlowVersionsPagedCallable() - listTensorFlowVersionsCallable() |
| GetTensorFlowVersion | Gets TensorFlow Version. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - getTensorFlowVersion(GetTensorFlowVersionRequest request) "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method. - getTensorFlowVersion(TensorFlowVersionName name) - getTensorFlowVersion(String name) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - getTensorFlowVersionCallable() |
| ListAcceleratorTypes | Lists accelerator types supported by this API. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - listAcceleratorTypes(ListAcceleratorTypesRequest request) "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method. - listAcceleratorTypes(AcceleratorTypeName parent) - listAcceleratorTypes(String parent) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - listAcceleratorTypesPagedCallable() - listAcceleratorTypesCallable() |
| GetAcceleratorType | Gets AcceleratorType. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - getAcceleratorType(GetAcceleratorTypeRequest request) "Flattened" method variants have converted the fields of the request object into function parameters to enable multiple ways to call the same method. - getAcceleratorType(AcceleratorTypeName name) - getAcceleratorType(String name) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - getAcceleratorTypeCallable() |
| ListLocations | Lists information about the supported locations for this service. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - listLocations(ListLocationsRequest request) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - listLocationsPagedCallable() - listLocationsCallable() |
| GetLocation | Gets information about a location. | Request object method variants only take one parameter, a request object, which must be constructed before the call. - getLocation(GetLocationRequest request) Callable method variants take no parameters and return an immutable API callable object, which can be used to initiate calls to the service. - getLocationCallable() |
[Methods]

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 TpuSettings 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
     TpuSettings tpuSettings =
         TpuSettings.newBuilder()
             .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
             .build();
     TpuClient tpuClient = TpuClient.create(tpuSettings);
     
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
     TpuSettings tpuSettings = TpuSettings.newBuilder().setEndpoint(myEndpoint).build();
     TpuClient tpuClient = TpuClient.create(tpuSettings);
     
Please refer to the GitHub repository's samples for more quickstart code snippets.

## Inheritance

[java.lang.Object](https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html) \> TpuClient

## Static Methods

### create()

    public static final TpuClient create()

Constructs an instance of TpuClient with default settings.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient` |   |

| **Exceptions** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html` |   |

### create(TpuSettings settings)

    public static final TpuClient create(TpuSettings settings)

Constructs an instance of TpuClient, using the given settings. The channels are created based
on the settings passed in, or defaults for any settings that are not set.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `settings` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuSettings` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient` |   |

| **Exceptions** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html` |   |

### create(TpuStub stub)

    public static final TpuClient create(TpuStub stub)

Constructs an instance of TpuClient, using the given stub for making calls. This is for
advanced usage - prefer using create(TpuSettings).

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `stub` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.stub.TpuStub` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient` |   |

## Constructors

### TpuClient(TpuSettings settings)

    protected TpuClient(TpuSettings settings)

Constructs an instance of TpuClient, 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.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `settings` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuSettings` |

### TpuClient(TpuStub stub)

    protected TpuClient(TpuStub stub)

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `stub` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.stub.TpuStub` |

## Methods

### awaitTermination(long duration, TimeUnit unit)

    public boolean awaitTermination(long duration, TimeUnit unit)

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `duration` | `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` |
| `unit` | `https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/TimeUnit.html` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` |   |

| **Exceptions** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/8/docs/api/java/lang/InterruptedException.html` |   |

### close()

    public final void close()

### createNodeAsync(CreateNodeRequest request)

    public final OperationFuture<Node,OperationMetadata> createNodeAsync(CreateNodeRequest request)

Creates a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       CreateNodeRequest request =
           CreateNodeRequest.newBuilder()
               .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
               .setNodeId("nodeId-1040171331")
               .setNode(Node.newBuilder().build())
               .build();
       Node response = tpuClient.createNodeAsync(request).get();
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.CreateNodeRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.longrunning.OperationFuture.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### createNodeAsync(LocationName parent, Node node, String nodeId)

    public final OperationFuture<Node,OperationMetadata> createNodeAsync(LocationName parent, Node node, String nodeId)

Creates a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
       Node node = Node.newBuilder().build();
       String nodeId = "nodeId-1040171331";
       Node response = tpuClient.createNodeAsync(parent, node, nodeId).get();
     }
     
| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.LocationName` Required. The parent resource name. |
| `node` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node` Required. The node. |
| `nodeId` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` The unqualified resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.longrunning.OperationFuture.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### createNodeAsync(String parent, Node node, String nodeId)

    public final OperationFuture<Node,OperationMetadata> createNodeAsync(String parent, Node node, String nodeId)

Creates a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
       Node node = Node.newBuilder().build();
       String nodeId = "nodeId-1040171331";
       Node response = tpuClient.createNodeAsync(parent, node, nodeId).get();
     }
     
| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` Required. The parent resource name. |
| `node` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node` Required. The node. |
| `nodeId` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` The unqualified resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.longrunning.OperationFuture.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### createNodeCallable()

    public final UnaryCallable<CreateNodeRequest,Operation> createNodeCallable()

Creates a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       CreateNodeRequest request =
           CreateNodeRequest.newBuilder()
               .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
               .setNodeId("nodeId-1040171331")
               .setNode(Node.newBuilder().build())
               .build();
       ApiFuture<Operation> future = tpuClient.createNodeCallable().futureCall(request);
       // Do something.
       Operation response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.CreateNodeRequest,https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.longrunning.Operation.html>` |   |

### createNodeOperationCallable()

    public final OperationCallable<CreateNodeRequest,Node,OperationMetadata> createNodeOperationCallable()

Creates a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       CreateNodeRequest request =
           CreateNodeRequest.newBuilder()
               .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
               .setNodeId("nodeId-1040171331")
               .setNode(Node.newBuilder().build())
               .build();
       OperationFuture<Node, OperationMetadata> future =
           tpuClient.createNodeOperationCallable().futureCall(request);
       // Do something.
       Node response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.OperationCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.CreateNodeRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### deleteNodeAsync(DeleteNodeRequest request)

    public final OperationFuture<Node,OperationMetadata> deleteNodeAsync(DeleteNodeRequest request)

Deletes a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       DeleteNodeRequest request =
           DeleteNodeRequest.newBuilder()
               .setName(NodeName.of("[PROJECT]", "[LOCATION]", "[NODE]").toString())
               .build();
       Node response = tpuClient.deleteNodeAsync(request).get();
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.DeleteNodeRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.longrunning.OperationFuture.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### deleteNodeAsync(NodeName name)

    public final OperationFuture<Node,OperationMetadata> deleteNodeAsync(NodeName name)

Deletes a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       NodeName name = NodeName.of("[PROJECT]", "[LOCATION]", "[NODE]");
       Node response = tpuClient.deleteNodeAsync(name).get();
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.NodeName` Required. The resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.longrunning.OperationFuture.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### deleteNodeAsync(String name)

    public final OperationFuture<Node,OperationMetadata> deleteNodeAsync(String name)

Deletes a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       String name = NodeName.of("[PROJECT]", "[LOCATION]", "[NODE]").toString();
       Node response = tpuClient.deleteNodeAsync(name).get();
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` Required. The resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.longrunning.OperationFuture.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### deleteNodeCallable()

    public final UnaryCallable<DeleteNodeRequest,Operation> deleteNodeCallable()

Deletes a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       DeleteNodeRequest request =
           DeleteNodeRequest.newBuilder()
               .setName(NodeName.of("[PROJECT]", "[LOCATION]", "[NODE]").toString())
               .build();
       ApiFuture<Operation> future = tpuClient.deleteNodeCallable().futureCall(request);
       // Do something.
       Operation response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.DeleteNodeRequest,https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.longrunning.Operation.html>` |   |

### deleteNodeOperationCallable()

    public final OperationCallable<DeleteNodeRequest,Node,OperationMetadata> deleteNodeOperationCallable()

Deletes a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       DeleteNodeRequest request =
           DeleteNodeRequest.newBuilder()
               .setName(NodeName.of("[PROJECT]", "[LOCATION]", "[NODE]").toString())
               .build();
       OperationFuture<Node, OperationMetadata> future =
           tpuClient.deleteNodeOperationCallable().futureCall(request);
       // Do something.
       Node response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.OperationCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.DeleteNodeRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### getAcceleratorType(AcceleratorTypeName name)

    public final AcceleratorType getAcceleratorType(AcceleratorTypeName name)

Gets AcceleratorType.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       AcceleratorTypeName name =
           AcceleratorTypeName.of("[PROJECT]", "[LOCATION]", "[ACCELERATOR_TYPE]");
       AcceleratorType response = tpuClient.getAcceleratorType(name);
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.AcceleratorTypeName` Required. The resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.AcceleratorType` |   |

### getAcceleratorType(GetAcceleratorTypeRequest request)

    public final AcceleratorType getAcceleratorType(GetAcceleratorTypeRequest request)

Gets AcceleratorType.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       GetAcceleratorTypeRequest request =
           GetAcceleratorTypeRequest.newBuilder()
               .setName(
                   AcceleratorTypeName.of("[PROJECT]", "[LOCATION]", "[ACCELERATOR_TYPE]")
                       .toString())
               .build();
       AcceleratorType response = tpuClient.getAcceleratorType(request);
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.GetAcceleratorTypeRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.AcceleratorType` |   |

### getAcceleratorType(String name)

    public final AcceleratorType getAcceleratorType(String name)

Gets AcceleratorType.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       String name =
           AcceleratorTypeName.of("[PROJECT]", "[LOCATION]", "[ACCELERATOR_TYPE]").toString();
       AcceleratorType response = tpuClient.getAcceleratorType(name);
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` Required. The resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.AcceleratorType` |   |

### getAcceleratorTypeCallable()

    public final UnaryCallable<GetAcceleratorTypeRequest,AcceleratorType> getAcceleratorTypeCallable()

Gets AcceleratorType.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       GetAcceleratorTypeRequest request =
           GetAcceleratorTypeRequest.newBuilder()
               .setName(
                   AcceleratorTypeName.of("[PROJECT]", "[LOCATION]", "[ACCELERATOR_TYPE]")
                       .toString())
               .build();
       ApiFuture<AcceleratorType> future =
           tpuClient.getAcceleratorTypeCallable().futureCall(request);
       // Do something.
       AcceleratorType response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.GetAcceleratorTypeRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.AcceleratorType>` |   |

### getLocation(GetLocationRequest request)

    public final Location getLocation(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 (TpuClient tpuClient = TpuClient.create()) {
       GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
       Location response = tpuClient.getLocation(request);
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `com.google.cloud.location.GetLocationRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `com.google.cloud.location.Location` |   |

### getLocationCallable()

    public final UnaryCallable<GetLocationRequest,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 (TpuClient tpuClient = TpuClient.create()) {
       GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
       ApiFuture<Location> future = tpuClient.getLocationCallable().futureCall(request);
       // Do something.
       Location response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<com.google.cloud.location.GetLocationRequest,com.google.cloud.location.Location>` |   |

### getNode(GetNodeRequest request)

    public final Node getNode(GetNodeRequest request)

Gets the details of a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       GetNodeRequest request =
           GetNodeRequest.newBuilder()
               .setName(NodeName.of("[PROJECT]", "[LOCATION]", "[NODE]").toString())
               .build();
       Node response = tpuClient.getNode(request);
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.GetNodeRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node` |   |

### getNode(NodeName name)

    public final Node getNode(NodeName name)

Gets the details of a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       NodeName name = NodeName.of("[PROJECT]", "[LOCATION]", "[NODE]");
       Node response = tpuClient.getNode(name);
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.NodeName` Required. The resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node` |   |

### getNode(String name)

    public final Node getNode(String name)

Gets the details of a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       String name = NodeName.of("[PROJECT]", "[LOCATION]", "[NODE]").toString();
       Node response = tpuClient.getNode(name);
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` Required. The resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node` |   |

### getNodeCallable()

    public final UnaryCallable<GetNodeRequest,Node> getNodeCallable()

Gets the details of a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       GetNodeRequest request =
           GetNodeRequest.newBuilder()
               .setName(NodeName.of("[PROJECT]", "[LOCATION]", "[NODE]").toString())
               .build();
       ApiFuture<Node> future = tpuClient.getNodeCallable().futureCall(request);
       // Do something.
       Node response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.GetNodeRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node>` |   |

### getOperationsClient()

    public final OperationsClient getOperationsClient()

Returns the OperationsClient that can be used to query the status of a long-running operation
returned by another API method call.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.longrunning.OperationsClient.html` |   |

### getSettings()

    public final TpuSettings getSettings()

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuSettings` |   |

### getStub()

    public TpuStub getStub()

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.stub.TpuStub` |   |

### getTensorFlowVersion(GetTensorFlowVersionRequest request)

    public final TensorFlowVersion getTensorFlowVersion(GetTensorFlowVersionRequest request)

Gets TensorFlow Version.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       GetTensorFlowVersionRequest request =
           GetTensorFlowVersionRequest.newBuilder()
               .setName(
                   TensorFlowVersionName.of("[PROJECT]", "[LOCATION]", "[TENSOR_FLOW_VERSION]")
                       .toString())
               .build();
       TensorFlowVersion response = tpuClient.getTensorFlowVersion(request);
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.GetTensorFlowVersionRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TensorFlowVersion` |   |

### getTensorFlowVersion(TensorFlowVersionName name)

    public final TensorFlowVersion getTensorFlowVersion(TensorFlowVersionName name)

Gets TensorFlow Version.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       TensorFlowVersionName name =
           TensorFlowVersionName.of("[PROJECT]", "[LOCATION]", "[TENSOR_FLOW_VERSION]");
       TensorFlowVersion response = tpuClient.getTensorFlowVersion(name);
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TensorFlowVersionName` Required. The resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TensorFlowVersion` |   |

### getTensorFlowVersion(String name)

    public final TensorFlowVersion getTensorFlowVersion(String name)

Gets TensorFlow Version.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       String name =
           TensorFlowVersionName.of("[PROJECT]", "[LOCATION]", "[TENSOR_FLOW_VERSION]").toString();
       TensorFlowVersion response = tpuClient.getTensorFlowVersion(name);
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` Required. The resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TensorFlowVersion` |   |

### getTensorFlowVersionCallable()

    public final UnaryCallable<GetTensorFlowVersionRequest,TensorFlowVersion> getTensorFlowVersionCallable()

Gets TensorFlow Version.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       GetTensorFlowVersionRequest request =
           GetTensorFlowVersionRequest.newBuilder()
               .setName(
                   TensorFlowVersionName.of("[PROJECT]", "[LOCATION]", "[TENSOR_FLOW_VERSION]")
                       .toString())
               .build();
       ApiFuture<TensorFlowVersion> future =
           tpuClient.getTensorFlowVersionCallable().futureCall(request);
       // Do something.
       TensorFlowVersion response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.GetTensorFlowVersionRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TensorFlowVersion>` |   |

### isShutdown()

    public boolean isShutdown()

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` |   |

### isTerminated()

    public boolean isTerminated()

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` |   |

### listAcceleratorTypes(AcceleratorTypeName parent)

    public final TpuClient.ListAcceleratorTypesPagedResponse listAcceleratorTypes(AcceleratorTypeName parent)

Lists accelerator types supported by this API.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       AcceleratorTypeName parent =
           AcceleratorTypeName.of("[PROJECT]", "[LOCATION]", "[ACCELERATOR_TYPE]");
       for (AcceleratorType element : tpuClient.listAcceleratorTypes(parent).iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.AcceleratorTypeName` Required. The parent resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListAcceleratorTypesPagedResponse` |   |

### listAcceleratorTypes(ListAcceleratorTypesRequest request)

    public final TpuClient.ListAcceleratorTypesPagedResponse listAcceleratorTypes(ListAcceleratorTypesRequest request)

Lists accelerator types supported by this API.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       ListAcceleratorTypesRequest request =
           ListAcceleratorTypesRequest.newBuilder()
               .setParent(
                   AcceleratorTypeName.of("[PROJECT]", "[LOCATION]", "[ACCELERATOR_TYPE]")
                       .toString())
               .setPageSize(883849137)
               .setPageToken("pageToken873572522")
               .setFilter("filter-1274492040")
               .setOrderBy("orderBy-1207110587")
               .build();
       for (AcceleratorType element : tpuClient.listAcceleratorTypes(request).iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ListAcceleratorTypesRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListAcceleratorTypesPagedResponse` |   |

### listAcceleratorTypes(String parent)

    public final TpuClient.ListAcceleratorTypesPagedResponse listAcceleratorTypes(String parent)

Lists accelerator types supported by this API.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       String parent =
           AcceleratorTypeName.of("[PROJECT]", "[LOCATION]", "[ACCELERATOR_TYPE]").toString();
       for (AcceleratorType element : tpuClient.listAcceleratorTypes(parent).iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` Required. The parent resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListAcceleratorTypesPagedResponse` |   |

### listAcceleratorTypesCallable()

    public final UnaryCallable<ListAcceleratorTypesRequest,ListAcceleratorTypesResponse> listAcceleratorTypesCallable()

Lists accelerator types supported by this API.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       ListAcceleratorTypesRequest request =
           ListAcceleratorTypesRequest.newBuilder()
               .setParent(
                   AcceleratorTypeName.of("[PROJECT]", "[LOCATION]", "[ACCELERATOR_TYPE]")
                       .toString())
               .setPageSize(883849137)
               .setPageToken("pageToken873572522")
               .setFilter("filter-1274492040")
               .setOrderBy("orderBy-1207110587")
               .build();
       while (true) {
         ListAcceleratorTypesResponse response =
             tpuClient.listAcceleratorTypesCallable().call(request);
         for (AcceleratorType element : response.getAcceleratorTypesList()) {
           // doThingsWith(element);
         }
         String nextPageToken = response.getNextPageToken();
         if (!Strings.isNullOrEmpty(nextPageToken)) {
           request = request.toBuilder().setPageToken(nextPageToken).build();
         } else {
           break;
         }
       }
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ListAcceleratorTypesRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ListAcceleratorTypesResponse>` |   |

### listAcceleratorTypesPagedCallable()

    public final UnaryCallable<ListAcceleratorTypesRequest,TpuClient.ListAcceleratorTypesPagedResponse> listAcceleratorTypesPagedCallable()

Lists accelerator types supported by this API.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       ListAcceleratorTypesRequest request =
           ListAcceleratorTypesRequest.newBuilder()
               .setParent(
                   AcceleratorTypeName.of("[PROJECT]", "[LOCATION]", "[ACCELERATOR_TYPE]")
                       .toString())
               .setPageSize(883849137)
               .setPageToken("pageToken873572522")
               .setFilter("filter-1274492040")
               .setOrderBy("orderBy-1207110587")
               .build();
       ApiFuture<AcceleratorType> future =
           tpuClient.listAcceleratorTypesPagedCallable().futureCall(request);
       // Do something.
       for (AcceleratorType element : future.get().iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ListAcceleratorTypesRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListAcceleratorTypesPagedResponse>` |   |

### listLocations(ListLocationsRequest request)

    public final TpuClient.ListLocationsPagedResponse listLocations(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 (TpuClient tpuClient = TpuClient.create()) {
       ListLocationsRequest request =
           ListLocationsRequest.newBuilder()
               .setName("name3373707")
               .setFilter("filter-1274492040")
               .setPageSize(883849137)
               .setPageToken("pageToken873572522")
               .build();
       for (Location element : tpuClient.listLocations(request).iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `com.google.cloud.location.ListLocationsRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListLocationsPagedResponse` |   |

### listLocationsCallable()

    public final UnaryCallable<ListLocationsRequest,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 (TpuClient tpuClient = TpuClient.create()) {
       ListLocationsRequest request =
           ListLocationsRequest.newBuilder()
               .setName("name3373707")
               .setFilter("filter-1274492040")
               .setPageSize(883849137)
               .setPageToken("pageToken873572522")
               .build();
       while (true) {
         ListLocationsResponse response = tpuClient.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;
         }
       }
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<com.google.cloud.location.ListLocationsRequest,com.google.cloud.location.ListLocationsResponse>` |   |

### listLocationsPagedCallable()

    public final UnaryCallable<ListLocationsRequest,TpuClient.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 (TpuClient tpuClient = TpuClient.create()) {
       ListLocationsRequest request =
           ListLocationsRequest.newBuilder()
               .setName("name3373707")
               .setFilter("filter-1274492040")
               .setPageSize(883849137)
               .setPageToken("pageToken873572522")
               .build();
       ApiFuture<Location> future = tpuClient.listLocationsPagedCallable().futureCall(request);
       // Do something.
       for (Location element : future.get().iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<com.google.cloud.location.ListLocationsRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListLocationsPagedResponse>` |   |

### listNodes(ListNodesRequest request)

    public final TpuClient.ListNodesPagedResponse listNodes(ListNodesRequest request)

Lists nodes.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       ListNodesRequest request =
           ListNodesRequest.newBuilder()
               .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
               .setPageSize(883849137)
               .setPageToken("pageToken873572522")
               .build();
       for (Node element : tpuClient.listNodes(request).iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ListNodesRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListNodesPagedResponse` |   |

### listNodes(LocationName parent)

    public final TpuClient.ListNodesPagedResponse listNodes(LocationName parent)

Lists nodes.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
       for (Node element : tpuClient.listNodes(parent).iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.LocationName` Required. The parent resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListNodesPagedResponse` |   |

### listNodes(String parent)

    public final TpuClient.ListNodesPagedResponse listNodes(String parent)

Lists nodes.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
       for (Node element : tpuClient.listNodes(parent).iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` Required. The parent resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListNodesPagedResponse` |   |

### listNodesCallable()

    public final UnaryCallable<ListNodesRequest,ListNodesResponse> listNodesCallable()

Lists nodes.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       ListNodesRequest request =
           ListNodesRequest.newBuilder()
               .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
               .setPageSize(883849137)
               .setPageToken("pageToken873572522")
               .build();
       while (true) {
         ListNodesResponse response = tpuClient.listNodesCallable().call(request);
         for (Node element : response.getNodesList()) {
           // doThingsWith(element);
         }
         String nextPageToken = response.getNextPageToken();
         if (!Strings.isNullOrEmpty(nextPageToken)) {
           request = request.toBuilder().setPageToken(nextPageToken).build();
         } else {
           break;
         }
       }
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ListNodesRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ListNodesResponse>` |   |

### listNodesPagedCallable()

    public final UnaryCallable<ListNodesRequest,TpuClient.ListNodesPagedResponse> listNodesPagedCallable()

Lists nodes.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       ListNodesRequest request =
           ListNodesRequest.newBuilder()
               .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
               .setPageSize(883849137)
               .setPageToken("pageToken873572522")
               .build();
       ApiFuture<Node> future = tpuClient.listNodesPagedCallable().futureCall(request);
       // Do something.
       for (Node element : future.get().iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ListNodesRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListNodesPagedResponse>` |   |

### listTensorFlowVersions(ListTensorFlowVersionsRequest request)

    public final TpuClient.ListTensorFlowVersionsPagedResponse listTensorFlowVersions(ListTensorFlowVersionsRequest request)

List TensorFlow versions supported by this API.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       ListTensorFlowVersionsRequest request =
           ListTensorFlowVersionsRequest.newBuilder()
               .setParent(
                   TensorFlowVersionName.of("[PROJECT]", "[LOCATION]", "[TENSOR_FLOW_VERSION]")
                       .toString())
               .setPageSize(883849137)
               .setPageToken("pageToken873572522")
               .setFilter("filter-1274492040")
               .setOrderBy("orderBy-1207110587")
               .build();
       for (TensorFlowVersion element : tpuClient.listTensorFlowVersions(request).iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ListTensorFlowVersionsRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListTensorFlowVersionsPagedResponse` |   |

### listTensorFlowVersions(TensorFlowVersionName parent)

    public final TpuClient.ListTensorFlowVersionsPagedResponse listTensorFlowVersions(TensorFlowVersionName parent)

List TensorFlow versions supported by this API.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       TensorFlowVersionName parent =
           TensorFlowVersionName.of("[PROJECT]", "[LOCATION]", "[TENSOR_FLOW_VERSION]");
       for (TensorFlowVersion element : tpuClient.listTensorFlowVersions(parent).iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TensorFlowVersionName` Required. The parent resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListTensorFlowVersionsPagedResponse` |   |

### listTensorFlowVersions(String parent)

    public final TpuClient.ListTensorFlowVersionsPagedResponse listTensorFlowVersions(String parent)

List TensorFlow versions supported by this API.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       String parent =
           TensorFlowVersionName.of("[PROJECT]", "[LOCATION]", "[TENSOR_FLOW_VERSION]").toString();
       for (TensorFlowVersion element : tpuClient.listTensorFlowVersions(parent).iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` Required. The parent resource name. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListTensorFlowVersionsPagedResponse` |   |

### listTensorFlowVersionsCallable()

    public final UnaryCallable<ListTensorFlowVersionsRequest,ListTensorFlowVersionsResponse> listTensorFlowVersionsCallable()

List TensorFlow versions supported by this API.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       ListTensorFlowVersionsRequest request =
           ListTensorFlowVersionsRequest.newBuilder()
               .setParent(
                   TensorFlowVersionName.of("[PROJECT]", "[LOCATION]", "[TENSOR_FLOW_VERSION]")
                       .toString())
               .setPageSize(883849137)
               .setPageToken("pageToken873572522")
               .setFilter("filter-1274492040")
               .setOrderBy("orderBy-1207110587")
               .build();
       while (true) {
         ListTensorFlowVersionsResponse response =
             tpuClient.listTensorFlowVersionsCallable().call(request);
         for (TensorFlowVersion element : response.getTensorflowVersionsList()) {
           // doThingsWith(element);
         }
         String nextPageToken = response.getNextPageToken();
         if (!Strings.isNullOrEmpty(nextPageToken)) {
           request = request.toBuilder().setPageToken(nextPageToken).build();
         } else {
           break;
         }
       }
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ListTensorFlowVersionsRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ListTensorFlowVersionsResponse>` |   |

### listTensorFlowVersionsPagedCallable()

    public final UnaryCallable<ListTensorFlowVersionsRequest,TpuClient.ListTensorFlowVersionsPagedResponse> listTensorFlowVersionsPagedCallable()

List TensorFlow versions supported by this API.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       ListTensorFlowVersionsRequest request =
           ListTensorFlowVersionsRequest.newBuilder()
               .setParent(
                   TensorFlowVersionName.of("[PROJECT]", "[LOCATION]", "[TENSOR_FLOW_VERSION]")
                       .toString())
               .setPageSize(883849137)
               .setPageToken("pageToken873572522")
               .setFilter("filter-1274492040")
               .setOrderBy("orderBy-1207110587")
               .build();
       ApiFuture<TensorFlowVersion> future =
           tpuClient.listTensorFlowVersionsPagedCallable().futureCall(request);
       // Do something.
       for (TensorFlowVersion element : future.get().iterateAll()) {
         // doThingsWith(element);
       }
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ListTensorFlowVersionsRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.TpuClient.ListTensorFlowVersionsPagedResponse>` |   |

### reimageNodeAsync(ReimageNodeRequest request)

    public final OperationFuture<Node,OperationMetadata> reimageNodeAsync(ReimageNodeRequest request)

Reimages a node's OS.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       ReimageNodeRequest request =
           ReimageNodeRequest.newBuilder()
               .setName("name3373707")
               .setTensorflowVersion("tensorflowVersion-470125103")
               .build();
       Node response = tpuClient.reimageNodeAsync(request).get();
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ReimageNodeRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.longrunning.OperationFuture.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### reimageNodeCallable()

    public final UnaryCallable<ReimageNodeRequest,Operation> reimageNodeCallable()

Reimages a node's OS.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       ReimageNodeRequest request =
           ReimageNodeRequest.newBuilder()
               .setName("name3373707")
               .setTensorflowVersion("tensorflowVersion-470125103")
               .build();
       ApiFuture<Operation> future = tpuClient.reimageNodeCallable().futureCall(request);
       // Do something.
       Operation response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ReimageNodeRequest,https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.longrunning.Operation.html>` |   |

### reimageNodeOperationCallable()

    public final OperationCallable<ReimageNodeRequest,Node,OperationMetadata> reimageNodeOperationCallable()

Reimages a node's OS.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       ReimageNodeRequest request =
           ReimageNodeRequest.newBuilder()
               .setName("name3373707")
               .setTensorflowVersion("tensorflowVersion-470125103")
               .build();
       OperationFuture<Node, OperationMetadata> future =
           tpuClient.reimageNodeOperationCallable().futureCall(request);
       // Do something.
       Node response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.OperationCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.ReimageNodeRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### shutdown()

    public void shutdown()

### shutdownNow()

    public void shutdownNow()

### startNodeAsync(StartNodeRequest request)

    public final OperationFuture<Node,OperationMetadata> startNodeAsync(StartNodeRequest request)

Starts a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       StartNodeRequest request = StartNodeRequest.newBuilder().setName("name3373707").build();
       Node response = tpuClient.startNodeAsync(request).get();
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.StartNodeRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.longrunning.OperationFuture.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### startNodeCallable()

    public final UnaryCallable<StartNodeRequest,Operation> startNodeCallable()

Starts a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       StartNodeRequest request = StartNodeRequest.newBuilder().setName("name3373707").build();
       ApiFuture<Operation> future = tpuClient.startNodeCallable().futureCall(request);
       // Do something.
       Operation response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.StartNodeRequest,https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.longrunning.Operation.html>` |   |

### startNodeOperationCallable()

    public final OperationCallable<StartNodeRequest,Node,OperationMetadata> startNodeOperationCallable()

Starts a node.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       StartNodeRequest request = StartNodeRequest.newBuilder().setName("name3373707").build();
       OperationFuture<Node, OperationMetadata> future =
           tpuClient.startNodeOperationCallable().futureCall(request);
       // Do something.
       Node response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.OperationCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.StartNodeRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### stopNodeAsync(StopNodeRequest request)

    public final OperationFuture<Node,OperationMetadata> stopNodeAsync(StopNodeRequest request)

Stops a node, this operation is only available with single TPU nodes.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       StopNodeRequest request = StopNodeRequest.newBuilder().setName("name3373707").build();
       Node response = tpuClient.stopNodeAsync(request).get();
     }
     
| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.StopNodeRequest` The request object containing all of the parameters for the API call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.longrunning.OperationFuture.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |

### stopNodeCallable()

    public final UnaryCallable<StopNodeRequest,Operation> stopNodeCallable()

Stops a node, this operation is only available with single TPU nodes.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       StopNodeRequest request = StopNodeRequest.newBuilder().setName("name3373707").build();
       ApiFuture<Operation> future = tpuClient.stopNodeCallable().futureCall(request);
       // Do something.
       Operation response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.UnaryCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.StopNodeRequest,https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.longrunning.Operation.html>` |   |

### stopNodeOperationCallable()

    public final OperationCallable<StopNodeRequest,Node,OperationMetadata> stopNodeOperationCallable()

Stops a node, this operation is only available with single TPU nodes.

Sample code:


     // This snippet has been automatically generated and should be regarded as a code template only.
     // It will require modifications to work:
     // - It may require correct/in-range values for request initialization.
     // - It may require specifying regional endpoints when creating the service client as shown in
     // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
     try (TpuClient tpuClient = TpuClient.create()) {
       StopNodeRequest request = StopNodeRequest.newBuilder().setName("name3373707").build();
       OperationFuture<Node, OperationMetadata> future =
           tpuClient.stopNodeOperationCallable().futureCall(request);
       // Do something.
       Node response = future.get();
     }
     
| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/gax/latest/com.google.api.gax.rpc.OperationCallable.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.StopNodeRequest,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.Node,https://docs.cloud.google.com/java/docs/reference/google-cloud-tpu/latest/com.google.cloud.tpu.v1.OperationMetadata>` |   |