- 1.51.0 (latest)
- 1.50.0
- 1.49.0
- 1.47.0
- 1.46.0
- 1.45.0
- 1.44.0
- 1.43.0
- 1.42.0
- 1.41.0
- 1.40.0
- 1.39.0
- 1.38.0
- 1.37.0
- 1.35.0
- 1.34.0
- 1.33.0
- 1.32.0
- 1.31.0
- 1.30.0
- 1.29.0
- 1.28.0
- 1.27.0
- 1.26.0
- 1.25.0
- 1.22.0
- 1.21.0
- 1.20.0
- 1.19.0
- 1.18.0
- 1.17.0
- 1.16.0
- 1.15.0
- 1.14.0
- 1.13.0
- 1.12.0
- 1.11.0
- 1.10.0
- 1.9.0
- 1.7.0
- 1.6.0
- 1.5.0
- 1.4.0
- 1.3.0
- 1.2.0
- 1.1.2
- 1.0.1
- 0.2.2
public class DataScanServiceClient implements BackgroundResource
Service Description: DataScanService manages DataScan resources which can be configured to run various types of data scanning workload and generate enriched metadata (e.g. Data Profile, Data Quality) for the data source.
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 (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
DataScanName name = DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]");
DataScan response = dataScanServiceClient.getDataScan(name);
}
Note: close() needs to be called on the DataScanServiceClient 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:
- 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.
- 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.
- 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 DataScanServiceSettings 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
DataScanServiceSettings dataScanServiceSettings =
DataScanServiceSettings.newBuilder()
.setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
.build();
DataScanServiceClient dataScanServiceClient =
DataScanServiceClient.create(dataScanServiceSettings);
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
DataScanServiceSettings dataScanServiceSettings =
DataScanServiceSettings.newBuilder().setEndpoint(myEndpoint).build();
DataScanServiceClient dataScanServiceClient =
DataScanServiceClient.create(dataScanServiceSettings);
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
DataScanServiceSettings dataScanServiceSettings =
DataScanServiceSettings.newHttpJsonBuilder().build();
DataScanServiceClient dataScanServiceClient =
DataScanServiceClient.create(dataScanServiceSettings);
Please refer to the GitHub repository's samples for more quickstart code snippets.
Implements
BackgroundResourceStatic Methods
create()
public static final DataScanServiceClient create()
Constructs an instance of DataScanServiceClient with default settings.
Returns | |
---|---|
Type | Description |
DataScanServiceClient |
Exceptions | |
---|---|
Type | Description |
IOException |
create(DataScanServiceSettings settings)
public static final DataScanServiceClient create(DataScanServiceSettings settings)
Constructs an instance of DataScanServiceClient, 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 | DataScanServiceSettings |
Returns | |
---|---|
Type | Description |
DataScanServiceClient |
Exceptions | |
---|---|
Type | Description |
IOException |
create(DataScanServiceStub stub)
public static final DataScanServiceClient create(DataScanServiceStub stub)
Constructs an instance of DataScanServiceClient, using the given stub for making calls. This is for advanced usage - prefer using create(DataScanServiceSettings).
Parameter | |
---|---|
Name | Description |
stub | DataScanServiceStub |
Returns | |
---|---|
Type | Description |
DataScanServiceClient |
Constructors
DataScanServiceClient(DataScanServiceSettings settings)
protected DataScanServiceClient(DataScanServiceSettings settings)
Constructs an instance of DataScanServiceClient, 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 | DataScanServiceSettings |
DataScanServiceClient(DataScanServiceStub stub)
protected DataScanServiceClient(DataScanServiceStub stub)
Parameter | |
---|---|
Name | Description |
stub | DataScanServiceStub |
Methods
awaitTermination(long duration, TimeUnit unit)
public boolean awaitTermination(long duration, TimeUnit unit)
Parameters | |
---|---|
Name | Description |
duration | long |
unit | TimeUnit |
Returns | |
---|---|
Type | Description |
boolean |
Exceptions | |
---|---|
Type | Description |
InterruptedException |
close()
public final void close()
createDataScanAsync(CreateDataScanRequest request)
public final OperationFuture<DataScan,OperationMetadata> createDataScanAsync(CreateDataScanRequest request)
Creates a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
CreateDataScanRequest request =
CreateDataScanRequest.newBuilder()
.setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
.setDataScan(DataScan.newBuilder().build())
.setDataScanId("dataScanId1260787906")
.setValidateOnly(true)
.build();
DataScan response = dataScanServiceClient.createDataScanAsync(request).get();
}
Parameter | |
---|---|
Name | Description |
request | CreateDataScanRequest The request object containing all of the parameters for the API call. |
Returns | |
---|---|
Type | Description |
OperationFuture<DataScan,OperationMetadata> |
createDataScanAsync(LocationName parent, DataScan dataScan, String dataScanId)
public final OperationFuture<DataScan,OperationMetadata> createDataScanAsync(LocationName parent, DataScan dataScan, String dataScanId)
Creates a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
DataScan dataScan = DataScan.newBuilder().build();
String dataScanId = "dataScanId1260787906";
DataScan response =
dataScanServiceClient.createDataScanAsync(parent, dataScan, dataScanId).get();
}
Parameters | |
---|---|
Name | Description |
parent | LocationName Required. The resource name of the parent location:
|
dataScan | DataScan Required. DataScan resource. |
dataScanId | String Required. DataScan identifier.
|
Returns | |
---|---|
Type | Description |
OperationFuture<DataScan,OperationMetadata> |
createDataScanAsync(String parent, DataScan dataScan, String dataScanId)
public final OperationFuture<DataScan,OperationMetadata> createDataScanAsync(String parent, DataScan dataScan, String dataScanId)
Creates a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
DataScan dataScan = DataScan.newBuilder().build();
String dataScanId = "dataScanId1260787906";
DataScan response =
dataScanServiceClient.createDataScanAsync(parent, dataScan, dataScanId).get();
}
Parameters | |
---|---|
Name | Description |
parent | String Required. The resource name of the parent location:
|
dataScan | DataScan Required. DataScan resource. |
dataScanId | String Required. DataScan identifier.
|
Returns | |
---|---|
Type | Description |
OperationFuture<DataScan,OperationMetadata> |
createDataScanCallable()
public final UnaryCallable<CreateDataScanRequest,Operation> createDataScanCallable()
Creates a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
CreateDataScanRequest request =
CreateDataScanRequest.newBuilder()
.setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
.setDataScan(DataScan.newBuilder().build())
.setDataScanId("dataScanId1260787906")
.setValidateOnly(true)
.build();
ApiFuture<Operation> future =
dataScanServiceClient.createDataScanCallable().futureCall(request);
// Do something.
Operation response = future.get();
}
Returns | |
---|---|
Type | Description |
UnaryCallable<CreateDataScanRequest,Operation> |
createDataScanOperationCallable()
public final OperationCallable<CreateDataScanRequest,DataScan,OperationMetadata> createDataScanOperationCallable()
Creates a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
CreateDataScanRequest request =
CreateDataScanRequest.newBuilder()
.setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
.setDataScan(DataScan.newBuilder().build())
.setDataScanId("dataScanId1260787906")
.setValidateOnly(true)
.build();
OperationFuture<DataScan, OperationMetadata> future =
dataScanServiceClient.createDataScanOperationCallable().futureCall(request);
// Do something.
DataScan response = future.get();
}
Returns | |
---|---|
Type | Description |
OperationCallable<CreateDataScanRequest,DataScan,OperationMetadata> |
deleteDataScanAsync(DataScanName name)
public final OperationFuture<Empty,OperationMetadata> deleteDataScanAsync(DataScanName name)
Deletes a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
DataScanName name = DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]");
dataScanServiceClient.deleteDataScanAsync(name).get();
}
Parameter | |
---|---|
Name | Description |
name | DataScanName Required. The resource name of the dataScan:
|
Returns | |
---|---|
Type | Description |
OperationFuture<Empty,OperationMetadata> |
deleteDataScanAsync(DeleteDataScanRequest request)
public final OperationFuture<Empty,OperationMetadata> deleteDataScanAsync(DeleteDataScanRequest request)
Deletes a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
DeleteDataScanRequest request =
DeleteDataScanRequest.newBuilder()
.setName(DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString())
.build();
dataScanServiceClient.deleteDataScanAsync(request).get();
}
Parameter | |
---|---|
Name | Description |
request | DeleteDataScanRequest The request object containing all of the parameters for the API call. |
Returns | |
---|---|
Type | Description |
OperationFuture<Empty,OperationMetadata> |
deleteDataScanAsync(String name)
public final OperationFuture<Empty,OperationMetadata> deleteDataScanAsync(String name)
Deletes a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
String name = DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString();
dataScanServiceClient.deleteDataScanAsync(name).get();
}
Parameter | |
---|---|
Name | Description |
name | String Required. The resource name of the dataScan:
|
Returns | |
---|---|
Type | Description |
OperationFuture<Empty,OperationMetadata> |
deleteDataScanCallable()
public final UnaryCallable<DeleteDataScanRequest,Operation> deleteDataScanCallable()
Deletes a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
DeleteDataScanRequest request =
DeleteDataScanRequest.newBuilder()
.setName(DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString())
.build();
ApiFuture<Operation> future =
dataScanServiceClient.deleteDataScanCallable().futureCall(request);
// Do something.
future.get();
}
Returns | |
---|---|
Type | Description |
UnaryCallable<DeleteDataScanRequest,Operation> |
deleteDataScanOperationCallable()
public final OperationCallable<DeleteDataScanRequest,Empty,OperationMetadata> deleteDataScanOperationCallable()
Deletes a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
DeleteDataScanRequest request =
DeleteDataScanRequest.newBuilder()
.setName(DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString())
.build();
OperationFuture<Empty, OperationMetadata> future =
dataScanServiceClient.deleteDataScanOperationCallable().futureCall(request);
// Do something.
future.get();
}
Returns | |
---|---|
Type | Description |
OperationCallable<DeleteDataScanRequest,Empty,OperationMetadata> |
getDataScan(DataScanName name)
public final DataScan getDataScan(DataScanName name)
Gets a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
DataScanName name = DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]");
DataScan response = dataScanServiceClient.getDataScan(name);
}
Parameter | |
---|---|
Name | Description |
name | DataScanName Required. The resource name of the dataScan:
|
Returns | |
---|---|
Type | Description |
DataScan |
getDataScan(GetDataScanRequest request)
public final DataScan getDataScan(GetDataScanRequest request)
Gets a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
GetDataScanRequest request =
GetDataScanRequest.newBuilder()
.setName(DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString())
.build();
DataScan response = dataScanServiceClient.getDataScan(request);
}
Parameter | |
---|---|
Name | Description |
request | GetDataScanRequest The request object containing all of the parameters for the API call. |
Returns | |
---|---|
Type | Description |
DataScan |
getDataScan(String name)
public final DataScan getDataScan(String name)
Gets a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
String name = DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString();
DataScan response = dataScanServiceClient.getDataScan(name);
}
Parameter | |
---|---|
Name | Description |
name | String Required. The resource name of the dataScan:
|
Returns | |
---|---|
Type | Description |
DataScan |
getDataScanCallable()
public final UnaryCallable<GetDataScanRequest,DataScan> getDataScanCallable()
Gets a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
GetDataScanRequest request =
GetDataScanRequest.newBuilder()
.setName(DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString())
.build();
ApiFuture<DataScan> future = dataScanServiceClient.getDataScanCallable().futureCall(request);
// Do something.
DataScan response = future.get();
}
Returns | |
---|---|
Type | Description |
UnaryCallable<GetDataScanRequest,DataScan> |
getDataScanJob(DataScanJobName name)
public final DataScanJob getDataScanJob(DataScanJobName name)
Gets a DataScanJob resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
DataScanJobName name = DataScanJobName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]", "[JOB]");
DataScanJob response = dataScanServiceClient.getDataScanJob(name);
}
Parameter | |
---|---|
Name | Description |
name | DataScanJobName Required. The resource name of the DataScanJob:
|
Returns | |
---|---|
Type | Description |
DataScanJob |
getDataScanJob(GetDataScanJobRequest request)
public final DataScanJob getDataScanJob(GetDataScanJobRequest request)
Gets a DataScanJob resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
GetDataScanJobRequest request =
GetDataScanJobRequest.newBuilder()
.setName(
DataScanJobName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]", "[JOB]").toString())
.build();
DataScanJob response = dataScanServiceClient.getDataScanJob(request);
}
Parameter | |
---|---|
Name | Description |
request | GetDataScanJobRequest The request object containing all of the parameters for the API call. |
Returns | |
---|---|
Type | Description |
DataScanJob |
getDataScanJob(String name)
public final DataScanJob getDataScanJob(String name)
Gets a DataScanJob resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
String name = DataScanJobName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]", "[JOB]").toString();
DataScanJob response = dataScanServiceClient.getDataScanJob(name);
}
Parameter | |
---|---|
Name | Description |
name | String Required. The resource name of the DataScanJob:
|
Returns | |
---|---|
Type | Description |
DataScanJob |
getDataScanJobCallable()
public final UnaryCallable<GetDataScanJobRequest,DataScanJob> getDataScanJobCallable()
Gets a DataScanJob resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
GetDataScanJobRequest request =
GetDataScanJobRequest.newBuilder()
.setName(
DataScanJobName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]", "[JOB]").toString())
.build();
ApiFuture<DataScanJob> future =
dataScanServiceClient.getDataScanJobCallable().futureCall(request);
// Do something.
DataScanJob response = future.get();
}
Returns | |
---|---|
Type | Description |
UnaryCallable<GetDataScanJobRequest,DataScanJob> |
getHttpJsonOperationsClient()
public final OperationsClient getHttpJsonOperationsClient()
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 |
OperationsClient |
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 (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
Location response = dataScanServiceClient.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 (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
ApiFuture<Location> future = dataScanServiceClient.getLocationCallable().futureCall(request);
// Do something.
Location response = future.get();
}
Returns | |
---|---|
Type | Description |
UnaryCallable<com.google.cloud.location.GetLocationRequest,com.google.cloud.location.Location> |
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 |
OperationsClient |
getSettings()
public final DataScanServiceSettings getSettings()
Returns | |
---|---|
Type | Description |
DataScanServiceSettings |
getStub()
public DataScanServiceStub getStub()
Returns | |
---|---|
Type | Description |
DataScanServiceStub |
isShutdown()
public boolean isShutdown()
Returns | |
---|---|
Type | Description |
boolean |
isTerminated()
public boolean isTerminated()
Returns | |
---|---|
Type | Description |
boolean |
listDataScanJobs(DataScanName parent)
public final DataScanServiceClient.ListDataScanJobsPagedResponse listDataScanJobs(DataScanName parent)
Lists DataScanJobs under the given DataScan.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
DataScanName parent = DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]");
for (DataScanJob element : dataScanServiceClient.listDataScanJobs(parent).iterateAll()) {
// doThingsWith(element);
}
}
Parameter | |
---|---|
Name | Description |
parent | DataScanName Required. The resource name of the parent environment:
|
Returns | |
---|---|
Type | Description |
DataScanServiceClient.ListDataScanJobsPagedResponse |
listDataScanJobs(ListDataScanJobsRequest request)
public final DataScanServiceClient.ListDataScanJobsPagedResponse listDataScanJobs(ListDataScanJobsRequest request)
Lists DataScanJobs under the given DataScan.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
ListDataScanJobsRequest request =
ListDataScanJobsRequest.newBuilder()
.setParent(DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString())
.setPageSize(883849137)
.setPageToken("pageToken873572522")
.setFilter("filter-1274492040")
.build();
for (DataScanJob element : dataScanServiceClient.listDataScanJobs(request).iterateAll()) {
// doThingsWith(element);
}
}
Parameter | |
---|---|
Name | Description |
request | ListDataScanJobsRequest The request object containing all of the parameters for the API call. |
Returns | |
---|---|
Type | Description |
DataScanServiceClient.ListDataScanJobsPagedResponse |
listDataScanJobs(String parent)
public final DataScanServiceClient.ListDataScanJobsPagedResponse listDataScanJobs(String parent)
Lists DataScanJobs under the given DataScan.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
String parent = DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString();
for (DataScanJob element : dataScanServiceClient.listDataScanJobs(parent).iterateAll()) {
// doThingsWith(element);
}
}
Parameter | |
---|---|
Name | Description |
parent | String Required. The resource name of the parent environment:
|
Returns | |
---|---|
Type | Description |
DataScanServiceClient.ListDataScanJobsPagedResponse |
listDataScanJobsCallable()
public final UnaryCallable<ListDataScanJobsRequest,ListDataScanJobsResponse> listDataScanJobsCallable()
Lists DataScanJobs under the given DataScan.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
ListDataScanJobsRequest request =
ListDataScanJobsRequest.newBuilder()
.setParent(DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString())
.setPageSize(883849137)
.setPageToken("pageToken873572522")
.setFilter("filter-1274492040")
.build();
while (true) {
ListDataScanJobsResponse response =
dataScanServiceClient.listDataScanJobsCallable().call(request);
for (DataScanJob element : response.getDataScanJobsList()) {
// doThingsWith(element);
}
String nextPageToken = response.getNextPageToken();
if (!Strings.isNullOrEmpty(nextPageToken)) {
request = request.toBuilder().setPageToken(nextPageToken).build();
} else {
break;
}
}
}
Returns | |
---|---|
Type | Description |
UnaryCallable<ListDataScanJobsRequest,ListDataScanJobsResponse> |
listDataScanJobsPagedCallable()
public final UnaryCallable<ListDataScanJobsRequest,DataScanServiceClient.ListDataScanJobsPagedResponse> listDataScanJobsPagedCallable()
Lists DataScanJobs under the given DataScan.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
ListDataScanJobsRequest request =
ListDataScanJobsRequest.newBuilder()
.setParent(DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString())
.setPageSize(883849137)
.setPageToken("pageToken873572522")
.setFilter("filter-1274492040")
.build();
ApiFuture<DataScanJob> future =
dataScanServiceClient.listDataScanJobsPagedCallable().futureCall(request);
// Do something.
for (DataScanJob element : future.get().iterateAll()) {
// doThingsWith(element);
}
}
Returns | |
---|---|
Type | Description |
UnaryCallable<ListDataScanJobsRequest,ListDataScanJobsPagedResponse> |
listDataScans(ListDataScansRequest request)
public final DataScanServiceClient.ListDataScansPagedResponse listDataScans(ListDataScansRequest request)
Lists DataScans.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
ListDataScansRequest request =
ListDataScansRequest.newBuilder()
.setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
.setPageSize(883849137)
.setPageToken("pageToken873572522")
.setFilter("filter-1274492040")
.setOrderBy("orderBy-1207110587")
.build();
for (DataScan element : dataScanServiceClient.listDataScans(request).iterateAll()) {
// doThingsWith(element);
}
}
Parameter | |
---|---|
Name | Description |
request | ListDataScansRequest The request object containing all of the parameters for the API call. |
Returns | |
---|---|
Type | Description |
DataScanServiceClient.ListDataScansPagedResponse |
listDataScans(LocationName parent)
public final DataScanServiceClient.ListDataScansPagedResponse listDataScans(LocationName parent)
Lists DataScans.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
for (DataScan element : dataScanServiceClient.listDataScans(parent).iterateAll()) {
// doThingsWith(element);
}
}
Parameter | |
---|---|
Name | Description |
parent | LocationName Required. The resource name of the parent location:
|
Returns | |
---|---|
Type | Description |
DataScanServiceClient.ListDataScansPagedResponse |
listDataScans(String parent)
public final DataScanServiceClient.ListDataScansPagedResponse listDataScans(String parent)
Lists DataScans.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
for (DataScan element : dataScanServiceClient.listDataScans(parent).iterateAll()) {
// doThingsWith(element);
}
}
Parameter | |
---|---|
Name | Description |
parent | String Required. The resource name of the parent location:
|
Returns | |
---|---|
Type | Description |
DataScanServiceClient.ListDataScansPagedResponse |
listDataScansCallable()
public final UnaryCallable<ListDataScansRequest,ListDataScansResponse> listDataScansCallable()
Lists DataScans.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
ListDataScansRequest request =
ListDataScansRequest.newBuilder()
.setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
.setPageSize(883849137)
.setPageToken("pageToken873572522")
.setFilter("filter-1274492040")
.setOrderBy("orderBy-1207110587")
.build();
while (true) {
ListDataScansResponse response =
dataScanServiceClient.listDataScansCallable().call(request);
for (DataScan element : response.getDataScansList()) {
// doThingsWith(element);
}
String nextPageToken = response.getNextPageToken();
if (!Strings.isNullOrEmpty(nextPageToken)) {
request = request.toBuilder().setPageToken(nextPageToken).build();
} else {
break;
}
}
}
Returns | |
---|---|
Type | Description |
UnaryCallable<ListDataScansRequest,ListDataScansResponse> |
listDataScansPagedCallable()
public final UnaryCallable<ListDataScansRequest,DataScanServiceClient.ListDataScansPagedResponse> listDataScansPagedCallable()
Lists DataScans.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
ListDataScansRequest request =
ListDataScansRequest.newBuilder()
.setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
.setPageSize(883849137)
.setPageToken("pageToken873572522")
.setFilter("filter-1274492040")
.setOrderBy("orderBy-1207110587")
.build();
ApiFuture<DataScan> future =
dataScanServiceClient.listDataScansPagedCallable().futureCall(request);
// Do something.
for (DataScan element : future.get().iterateAll()) {
// doThingsWith(element);
}
}
Returns | |
---|---|
Type | Description |
UnaryCallable<ListDataScansRequest,ListDataScansPagedResponse> |
listLocations(ListLocationsRequest request)
public final DataScanServiceClient.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 (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
ListLocationsRequest request =
ListLocationsRequest.newBuilder()
.setName("name3373707")
.setFilter("filter-1274492040")
.setPageSize(883849137)
.setPageToken("pageToken873572522")
.build();
for (Location element : dataScanServiceClient.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 |
DataScanServiceClient.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 (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
ListLocationsRequest request =
ListLocationsRequest.newBuilder()
.setName("name3373707")
.setFilter("filter-1274492040")
.setPageSize(883849137)
.setPageToken("pageToken873572522")
.build();
while (true) {
ListLocationsResponse response =
dataScanServiceClient.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 |
UnaryCallable<com.google.cloud.location.ListLocationsRequest,com.google.cloud.location.ListLocationsResponse> |
listLocationsPagedCallable()
public final UnaryCallable<ListLocationsRequest,DataScanServiceClient.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 (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
ListLocationsRequest request =
ListLocationsRequest.newBuilder()
.setName("name3373707")
.setFilter("filter-1274492040")
.setPageSize(883849137)
.setPageToken("pageToken873572522")
.build();
ApiFuture<Location> future =
dataScanServiceClient.listLocationsPagedCallable().futureCall(request);
// Do something.
for (Location element : future.get().iterateAll()) {
// doThingsWith(element);
}
}
Returns | |
---|---|
Type | Description |
UnaryCallable<com.google.cloud.location.ListLocationsRequest,ListLocationsPagedResponse> |
runDataScan(DataScanName name)
public final RunDataScanResponse runDataScan(DataScanName name)
Runs an on-demand execution of a DataScan
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
DataScanName name = DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]");
RunDataScanResponse response = dataScanServiceClient.runDataScan(name);
}
Parameter | |
---|---|
Name | Description |
name | DataScanName Required. The resource name of the DataScan:
Only **OnDemand** data scans are allowed. |
Returns | |
---|---|
Type | Description |
RunDataScanResponse |
runDataScan(RunDataScanRequest request)
public final RunDataScanResponse runDataScan(RunDataScanRequest request)
Runs an on-demand execution of a DataScan
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
RunDataScanRequest request =
RunDataScanRequest.newBuilder()
.setName(DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString())
.build();
RunDataScanResponse response = dataScanServiceClient.runDataScan(request);
}
Parameter | |
---|---|
Name | Description |
request | RunDataScanRequest The request object containing all of the parameters for the API call. |
Returns | |
---|---|
Type | Description |
RunDataScanResponse |
runDataScan(String name)
public final RunDataScanResponse runDataScan(String name)
Runs an on-demand execution of a DataScan
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
String name = DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString();
RunDataScanResponse response = dataScanServiceClient.runDataScan(name);
}
Parameter | |
---|---|
Name | Description |
name | String Required. The resource name of the DataScan:
Only **OnDemand** data scans are allowed. |
Returns | |
---|---|
Type | Description |
RunDataScanResponse |
runDataScanCallable()
public final UnaryCallable<RunDataScanRequest,RunDataScanResponse> runDataScanCallable()
Runs an on-demand execution of a DataScan
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
RunDataScanRequest request =
RunDataScanRequest.newBuilder()
.setName(DataScanName.of("[PROJECT]", "[LOCATION]", "[DATASCAN]").toString())
.build();
ApiFuture<RunDataScanResponse> future =
dataScanServiceClient.runDataScanCallable().futureCall(request);
// Do something.
RunDataScanResponse response = future.get();
}
Returns | |
---|---|
Type | Description |
UnaryCallable<RunDataScanRequest,RunDataScanResponse> |
shutdown()
public void shutdown()
shutdownNow()
public void shutdownNow()
updateDataScanAsync(DataScan dataScan, FieldMask updateMask)
public final OperationFuture<DataScan,OperationMetadata> updateDataScanAsync(DataScan dataScan, FieldMask updateMask)
Updates a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
DataScan dataScan = DataScan.newBuilder().build();
FieldMask updateMask = FieldMask.newBuilder().build();
DataScan response = dataScanServiceClient.updateDataScanAsync(dataScan, updateMask).get();
}
Parameters | |
---|---|
Name | Description |
dataScan | DataScan Required. DataScan resource to be updated. Only fields specified in |
updateMask | FieldMask Required. Mask of fields to update. |
Returns | |
---|---|
Type | Description |
OperationFuture<DataScan,OperationMetadata> |
updateDataScanAsync(UpdateDataScanRequest request)
public final OperationFuture<DataScan,OperationMetadata> updateDataScanAsync(UpdateDataScanRequest request)
Updates a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
UpdateDataScanRequest request =
UpdateDataScanRequest.newBuilder()
.setDataScan(DataScan.newBuilder().build())
.setUpdateMask(FieldMask.newBuilder().build())
.setValidateOnly(true)
.build();
DataScan response = dataScanServiceClient.updateDataScanAsync(request).get();
}
Parameter | |
---|---|
Name | Description |
request | UpdateDataScanRequest The request object containing all of the parameters for the API call. |
Returns | |
---|---|
Type | Description |
OperationFuture<DataScan,OperationMetadata> |
updateDataScanCallable()
public final UnaryCallable<UpdateDataScanRequest,Operation> updateDataScanCallable()
Updates a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
UpdateDataScanRequest request =
UpdateDataScanRequest.newBuilder()
.setDataScan(DataScan.newBuilder().build())
.setUpdateMask(FieldMask.newBuilder().build())
.setValidateOnly(true)
.build();
ApiFuture<Operation> future =
dataScanServiceClient.updateDataScanCallable().futureCall(request);
// Do something.
Operation response = future.get();
}
Returns | |
---|---|
Type | Description |
UnaryCallable<UpdateDataScanRequest,Operation> |
updateDataScanOperationCallable()
public final OperationCallable<UpdateDataScanRequest,DataScan,OperationMetadata> updateDataScanOperationCallable()
Updates a DataScan resource.
Sample code:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DataScanServiceClient dataScanServiceClient = DataScanServiceClient.create()) {
UpdateDataScanRequest request =
UpdateDataScanRequest.newBuilder()
.setDataScan(DataScan.newBuilder().build())
.setUpdateMask(FieldMask.newBuilder().build())
.setValidateOnly(true)
.build();
OperationFuture<DataScan, OperationMetadata> future =
dataScanServiceClient.updateDataScanOperationCallable().futureCall(request);
// Do something.
DataScan response = future.get();
}
Returns | |
---|---|
Type | Description |
OperationCallable<UpdateDataScanRequest,DataScan,OperationMetadata> |