diff --git a/google-cloud-datacatalog/src/main/java/com/google/cloud/datacatalog/v1/DataCatalogClient.java b/google-cloud-datacatalog/src/main/java/com/google/cloud/datacatalog/v1/DataCatalogClient.java index 979c5866..796e9972 100644 --- a/google-cloud-datacatalog/src/main/java/com/google/cloud/datacatalog/v1/DataCatalogClient.java +++ b/google-cloud-datacatalog/src/main/java/com/google/cloud/datacatalog/v1/DataCatalogClient.java @@ -163,7 +163,7 @@ public DataCatalogStub getStub() { * *
This is a custom method (https://cloud.google.com/apis/design/custom_methods) and does not * return the complete resource, only the resource identifier and high level fields. Clients can - * subsequentally call `Get` methods. + * subsequently call `Get` methods. * *
Note that Data Catalog search queries do not guarantee full recall. Query results that match * your query may not be returned, even in subsequent result pages. Also note that results @@ -189,7 +189,8 @@ public DataCatalogStub getStub() { * @param scope Required. The scope of this search request. A `scope` that has empty * `include_org_ids`, `include_project_ids` AND false `include_gcp_public_datasets` is * considered invalid. Data Catalog will return an error in such a case. - * @param query Required. The query string in search query syntax. The query must be non-empty. + * @param query Optional. The query string in search query syntax. An empty query string will + * result in all data assets (in the specified scope) that the user has access to. *
Query strings can be simple as "x" or more qualified as: *
This is a custom method (https://cloud.google.com/apis/design/custom_methods) and does not * return the complete resource, only the resource identifier and high level fields. Clients can - * subsequentally call `Get` methods. + * subsequently call `Get` methods. * *
Note that Data Catalog search queries do not guarantee full recall. Query results that match * your query may not be returned, even in subsequent result pages. Also note that results @@ -256,7 +257,7 @@ public final SearchCatalogPagedResponse searchCatalog(SearchCatalogRequest reque * *
This is a custom method (https://cloud.google.com/apis/design/custom_methods) and does not * return the complete resource, only the resource identifier and high level fields. Clients can - * subsequentally call `Get` methods. + * subsequently call `Get` methods. * *
Note that Data Catalog search queries do not guarantee full recall. Query results that match * your query may not be returned, even in subsequent result pages. Also note that results @@ -298,7 +299,7 @@ public final SearchCatalogPagedResponse searchCatalog(SearchCatalogRequest reque * *
This is a custom method (https://cloud.google.com/apis/design/custom_methods) and does not * return the complete resource, only the resource identifier and high level fields. Clients can - * subsequentally call `Get` methods. + * subsequently call `Get` methods. * *
Note that Data Catalog search queries do not guarantee full recall. Query results that match
* your query may not be returned, even in subsequent result pages. Also note that results
@@ -369,15 +370,13 @@ public final UnaryCallable Note that this EntryGroup and its child resources may not actually be stored in the
- * location in this name.
- * @param entryGroupId Required. The id of the entry group to create. The id must begin with a
- * letter or underscore, contain only English letters, numbers and underscores, and be at most
- * 64 characters.
+ * @param parent Required. The name of the project this entry group belongs to. Example:
+ * `projects/{project_id}/locations/{location}`
+ * Note: The entry group itself and its child resources might not be stored in the location
+ * specified in its name.
+ * @param entryGroupId Required. The ID of the entry group to create.
+ * The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and must
+ * start with a letter or underscore. The maximum size is 64 bytes when encoded in UTF-8.
* @param entryGroup The entry group to create. Defaults to an empty entry group.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
@@ -422,15 +421,13 @@ public final EntryGroup createEntryGroup(
* }
* }
*
- * @param parent Required. The name of the project this entry group is in. Example:
- * Note that this EntryGroup and its child resources may not actually be stored in the
- * location in this name.
- * @param entryGroupId Required. The id of the entry group to create. The id must begin with a
- * letter or underscore, contain only English letters, numbers and underscores, and be at most
- * 64 characters.
+ * @param parent Required. The name of the project this entry group belongs to. Example:
+ * `projects/{project_id}/locations/{location}`
+ * Note: The entry group itself and its child resources might not be stored in the location
+ * specified in its name.
+ * @param entryGroupId Required. The ID of the entry group to create.
+ * The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and must
+ * start with a letter or underscore. The maximum size is 64 bytes when encoded in UTF-8.
* @param entryGroup The entry group to create. Defaults to an empty entry group.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
@@ -711,8 +708,9 @@ public final EntryGroup updateEntryGroup(EntryGroup entryGroup) {
* }
*
* @param entryGroup Required. The updated entry group. "name" field must be set.
- * @param updateMask The fields to update on the entry group. If absent or empty, all modifiable
- * fields are updated.
+ * @param updateMask Names of fields whose values to overwrite on an entry group.
+ * If this parameter is absent or empty, all modifiable fields are overwritten. If such
+ * fields are non-required and omitted in the request body, their values are emptied.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
public final EntryGroup updateEntryGroup(EntryGroup entryGroup, FieldMask updateMask) {
@@ -1031,7 +1029,8 @@ public final ListEntryGroupsPagedResponse listEntryGroups(ListEntryGroupsRequest
// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
- * Creates an entry. Only entries of 'FILESET' type or user-specified type can be created.
+ * Creates an entry. Only entries of types 'FILESET', 'CLUSTER', 'DATA_STREAM' or with a
+ * user-specified type can be created.
*
* Users should enable the Data Catalog API in the project identified by the `parent` parameter
* (see [Data Catalog Resource Project]
@@ -1050,13 +1049,13 @@ public final ListEntryGroupsPagedResponse listEntryGroups(ListEntryGroupsRequest
* }
* }
*
- * @param parent Required. The name of the entry group this entry is in. Example:
- * Note that this Entry and its child resources may not actually be stored in the location
- * in this name.
- * @param entryId Required. The id of the entry to create.
+ * @param parent Required. The name of the entry group this entry belongs to. Example:
+ * `projects/{project_id}/locations/{location}/entryGroups/{entry_group_id}`
+ * Note: The entry itself and its child resources might not be stored in the location
+ * specified in its name.
+ * @param entryId Required. The ID of the entry to create.
+ * The ID must contain only letters (a-z, A-Z), numbers (0-9), and underscores (_). The
+ * maximum size is 64 bytes when encoded in UTF-8.
* @param entry Required. The entry to create.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
@@ -1072,7 +1071,8 @@ public final Entry createEntry(EntryGroupName parent, String entryId, Entry entr
// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
- * Creates an entry. Only entries of 'FILESET' type or user-specified type can be created.
+ * Creates an entry. Only entries of types 'FILESET', 'CLUSTER', 'DATA_STREAM' or with a
+ * user-specified type can be created.
*
* Users should enable the Data Catalog API in the project identified by the `parent` parameter
* (see [Data Catalog Resource Project]
@@ -1091,13 +1091,13 @@ public final Entry createEntry(EntryGroupName parent, String entryId, Entry entr
* }
* }
*
- * @param parent Required. The name of the entry group this entry is in. Example:
- * Note that this Entry and its child resources may not actually be stored in the location
- * in this name.
- * @param entryId Required. The id of the entry to create.
+ * @param parent Required. The name of the entry group this entry belongs to. Example:
+ * `projects/{project_id}/locations/{location}/entryGroups/{entry_group_id}`
+ * Note: The entry itself and its child resources might not be stored in the location
+ * specified in its name.
+ * @param entryId Required. The ID of the entry to create.
+ * The ID must contain only letters (a-z, A-Z), numbers (0-9), and underscores (_). The
+ * maximum size is 64 bytes when encoded in UTF-8.
* @param entry Required. The entry to create.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
@@ -1113,7 +1113,8 @@ public final Entry createEntry(String parent, String entryId, Entry entry) {
// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
- * Creates an entry. Only entries of 'FILESET' type or user-specified type can be created.
+ * Creates an entry. Only entries of types 'FILESET', 'CLUSTER', 'DATA_STREAM' or with a
+ * user-specified type can be created.
*
* Users should enable the Data Catalog API in the project identified by the `parent` parameter
* (see [Data Catalog Resource Project]
@@ -1144,7 +1145,8 @@ public final Entry createEntry(CreateEntryRequest request) {
// AUTO-GENERATED DOCUMENTATION AND METHOD.
/**
- * Creates an entry. Only entries of 'FILESET' type or user-specified type can be created.
+ * Creates an entry. Only entries of types 'FILESET', 'CLUSTER', 'DATA_STREAM' or with a
+ * user-specified type can be created.
*
* Users should enable the Data Catalog API in the project identified by the `parent` parameter
* (see [Data Catalog Resource Project]
@@ -1212,16 +1214,17 @@ public final Entry updateEntry(Entry entry) {
* }
*
* @param entry Required. The updated entry. The "name" field must be set.
- * @param updateMask The fields to update on the entry. If absent or empty, all modifiable fields
- * are updated.
+ * @param updateMask Names of fields whose values to overwrite on an entry.
+ * If this parameter is absent or empty, all modifiable fields are overwritten. If such
+ * fields are non-required and omitted in the request body, their values are emptied.
* The following fields are modifiable:
*
- *
- *
- *
- *
- *
- *
- *
- *
*
*
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
@@ -1711,7 +1714,9 @@ public final UnaryCallable
The ID must contain only lowercase letters (a-z), numbers (0-9), or underscores (_), and + * must start with a letter or underscore. The maximum size is 64 bytes when encoded in UTF-8. * @param tagTemplate Required. The tag template to create. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -1752,7 +1757,9 @@ public final TagTemplate createTagTemplate( *
The ID must contain only lowercase letters (a-z), numbers (0-9), or underscores (_), and + * must start with a letter or underscore. The maximum size is 64 bytes when encoded in UTF-8. * @param tagTemplate Required. The tag template to create. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -1965,10 +1972,10 @@ public final TagTemplate updateTagTemplate(TagTemplate tagTemplate) { * } * * @param tagTemplate Required. The template to update. The "name" field must be set. - * @param updateMask The field mask specifies the parts of the template to overwrite. - *
Allowed fields: - *
* `display_name` - *
If absent or empty, all of the allowed fields above will be updated. + * @param updateMask Names of fields whose values to overwrite on a tag template. Currently, only + * `display_name` can be overwritten. + *
In general, if this parameter is absent or empty, all modifiable fields are overwritten.
+ * If such fields are non-required and omitted in the request body, their values are emptied.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
public final TagTemplate updateTagTemplate(TagTemplate tagTemplate, FieldMask updateMask) {
@@ -2180,10 +2187,11 @@ public final UnaryCallable Note: Adding a required field to an existing template is *not* allowed.
+ * Field IDs can contain letters (both uppercase and lowercase), numbers (0-9), underscores
+ * (_) and dashes (-). Field IDs must be at least 1 character long and at most 128 characters
+ * long. Field IDs must also be unique within their template.
* @param tagTemplateField Required. The tag template field to create.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
@@ -2224,10 +2232,11 @@ public final TagTemplateField createTagTemplateField(
* Note: Adding a required field to an existing template is *not* allowed.
+ * Field IDs can contain letters (both uppercase and lowercase), numbers (0-9), underscores
+ * (_) and dashes (-). Field IDs must be at least 1 character long and at most 128 characters
+ * long. Field IDs must also be unique within their template.
* @param tagTemplateField Required. The tag template field to create.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
@@ -2398,13 +2407,19 @@ public final TagTemplateField updateTagTemplateField(
*
*
* @param tagTemplateField Required. The template to update.
- * @param updateMask Optional. The field mask specifies the parts of the template to be updated.
- * Allowed fields:
+ * @param updateMask Optional. Names of fields whose values to overwrite on an individual field of
+ * a tag template. The following fields are modifiable:
* * `display_name` * `type.enum_type` * `is_required`
- * If `update_mask` is not set or empty, all of the allowed fields above will be updated.
- * When updating an enum type, the provided values will be merged with the existing values.
- * Therefore, enum values can only be added, existing enum values cannot be deleted nor
- * renamed. Updating a template field from optional to required is NOT allowed.
+ * If this parameter is absent or empty, all modifiable fields are overwritten. If such
+ * fields are non-required and omitted in the request body, their values are emptied with one
+ * exception: when updating an enum type, the provided values are merged with the existing
+ * values. Therefore, enum values can only be added, existing enum values cannot be deleted or
+ * renamed.
+ * Additionally, updating a template field from optional to required is
+ * * `display_name` * `type.enum_type` * `is_required`
- * If `update_mask` is not set or empty, all of the allowed fields above will be updated.
- * When updating an enum type, the provided values will be merged with the existing values.
- * Therefore, enum values can only be added, existing enum values cannot be deleted nor
- * renamed. Updating a template field from optional to required is NOT allowed.
+ * If this parameter is absent or empty, all modifiable fields are overwritten. If such
+ * fields are non-required and omitted in the request body, their values are emptied with one
+ * exception: when updating an enum type, the provided values are merged with the existing
+ * values. Therefore, enum values can only be added, existing enum values cannot be deleted or
+ * renamed.
+ * Additionally, updating a template field from optional to required is
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Note that this Tag and its child resources may not actually be stored in the location in
- * this name.
+ * entries. An entry can have up to 1000 attached tags. Example:
+ * `projects/{project_id}/locations/{location}/entryGroups/{entry_group_id}/entries/{entry_id}`
+ * Note: The tag and its child resources might not be stored in the location specified in
+ * its name.
* @param tag Required. The tag to create.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
@@ -2851,12 +3019,10 @@ public final Tag createTag(TagName parent, Tag tag) {
* }
*
* @param parent Required. The name of the resource to attach this tag to. Tags can be attached to
- * Entries. Example:
- * Note that this Tag and its child resources may not actually be stored in the location in
- * this name.
+ * entries. An entry can have up to 1000 attached tags. Example:
+ * `projects/{project_id}/locations/{location}/entryGroups/{entry_group_id}/entries/{entry_id}`
+ * Note: The tag and its child resources might not be stored in the location specified in
+ * its name.
* @param tag Required. The tag to create.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
@@ -2962,8 +3128,10 @@ public final Tag updateTag(Tag tag) {
* }
*
* @param tag Required. The updated tag. The "name" field must be set.
- * @param updateMask The fields to update on the Tag. If absent or empty, all modifiable fields
- * are updated. Currently the only modifiable field is the field `fields`.
+ * @param updateMask Names of fields whose values to overwrite on a tag. Currently, a tag has the
+ * only modifiable field with the name `fields`.
+ * In general, if this parameter is absent or empty, all modifiable fields are overwritten.
+ * If such fields are non-required and omitted in the request body, their values are emptied.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
public final Tag updateTag(Tag tag, FieldMask updateMask) {
@@ -3291,7 +3459,7 @@ public final UnaryCallable Policy tags are used to tag BigQuery columns and apply additional access control policies. A
+ * taxonomy is a hierarchical grouping of policy tags that classify data along a common axis.
+ *
+ * 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:
+ *
+ * Note: close() needs to be called on the PolicyTagManagerClient 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:
+ *
+ * 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 PolicyTagManagerSettings to
+ * create(). For example:
+ *
+ * To customize credentials:
+ *
+ * To customize the endpoint:
+ *
+ * Please refer to the GitHub repository's samples for more quickstart code snippets.
+ */
+@Generated("by gapic-generator-java")
+public class PolicyTagManagerClient implements BackgroundResource {
+ private final PolicyTagManagerSettings settings;
+ private final PolicyTagManagerStub stub;
+
+ /** Constructs an instance of PolicyTagManagerClient with default settings. */
+ public static final PolicyTagManagerClient create() throws IOException {
+ return create(PolicyTagManagerSettings.newBuilder().build());
+ }
+
+ /**
+ * Constructs an instance of PolicyTagManagerClient, using the given settings. The channels are
+ * created based on the settings passed in, or defaults for any settings that are not set.
+ */
+ public static final PolicyTagManagerClient create(PolicyTagManagerSettings settings)
+ throws IOException {
+ return new PolicyTagManagerClient(settings);
+ }
+
+ /**
+ * Constructs an instance of PolicyTagManagerClient, using the given stub for making calls. This
+ * is for advanced usage - prefer using create(PolicyTagManagerSettings).
+ */
+ @BetaApi("A restructuring of stub classes is planned, so this may break in the future")
+ public static final PolicyTagManagerClient create(PolicyTagManagerStub stub) {
+ return new PolicyTagManagerClient(stub);
+ }
+
+ /**
+ * Constructs an instance of PolicyTagManagerClient, 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.
+ */
+ protected PolicyTagManagerClient(PolicyTagManagerSettings settings) throws IOException {
+ this.settings = settings;
+ this.stub = ((PolicyTagManagerStubSettings) settings.getStubSettings()).createStub();
+ }
+
+ @BetaApi("A restructuring of stub classes is planned, so this may break in the future")
+ protected PolicyTagManagerClient(PolicyTagManagerStub stub) {
+ this.settings = null;
+ this.stub = stub;
+ }
+
+ public final PolicyTagManagerSettings getSettings() {
+ return settings;
+ }
+
+ @BetaApi("A restructuring of stub classes is planned, so this may break in the future")
+ public PolicyTagManagerStub getStub() {
+ return stub;
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Creates a taxonomy in a specified project. The taxonomy is initially empty, i.e., does not
+ * contain policy tags.
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * Sample code:
+ *
+ * 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:
+ *
+ * Note: close() needs to be called on the PolicyTagManagerSerializationClient 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:
+ *
+ * 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
+ * PolicyTagManagerSerializationSettings to create(). For example:
+ *
+ * To customize credentials:
+ *
+ * To customize the endpoint:
+ *
+ * Please refer to the GitHub repository's samples for more quickstart code snippets.
+ */
+@Generated("by gapic-generator-java")
+public class PolicyTagManagerSerializationClient implements BackgroundResource {
+ private final PolicyTagManagerSerializationSettings settings;
+ private final PolicyTagManagerSerializationStub stub;
+
+ /** Constructs an instance of PolicyTagManagerSerializationClient with default settings. */
+ public static final PolicyTagManagerSerializationClient create() throws IOException {
+ return create(PolicyTagManagerSerializationSettings.newBuilder().build());
+ }
+
+ /**
+ * Constructs an instance of PolicyTagManagerSerializationClient, using the given settings. The
+ * channels are created based on the settings passed in, or defaults for any settings that are not
+ * set.
+ */
+ public static final PolicyTagManagerSerializationClient create(
+ PolicyTagManagerSerializationSettings settings) throws IOException {
+ return new PolicyTagManagerSerializationClient(settings);
+ }
+
+ /**
+ * Constructs an instance of PolicyTagManagerSerializationClient, using the given stub for making
+ * calls. This is for advanced usage - prefer using create(PolicyTagManagerSerializationSettings).
+ */
+ @BetaApi("A restructuring of stub classes is planned, so this may break in the future")
+ public static final PolicyTagManagerSerializationClient create(
+ PolicyTagManagerSerializationStub stub) {
+ return new PolicyTagManagerSerializationClient(stub);
+ }
+
+ /**
+ * Constructs an instance of PolicyTagManagerSerializationClient, 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.
+ */
+ protected PolicyTagManagerSerializationClient(PolicyTagManagerSerializationSettings settings)
+ throws IOException {
+ this.settings = settings;
+ this.stub =
+ ((PolicyTagManagerSerializationStubSettings) settings.getStubSettings()).createStub();
+ }
+
+ @BetaApi("A restructuring of stub classes is planned, so this may break in the future")
+ protected PolicyTagManagerSerializationClient(PolicyTagManagerSerializationStub stub) {
+ this.settings = null;
+ this.stub = stub;
+ }
+
+ public final PolicyTagManagerSerializationSettings getSettings() {
+ return settings;
+ }
+
+ @BetaApi("A restructuring of stub classes is planned, so this may break in the future")
+ public PolicyTagManagerSerializationStub getStub() {
+ return stub;
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Creates new taxonomies (including their policy tags) by importing from inlined source or
+ * cross-regional source. New taxonomies will be created in a given parent project.
+ *
+ * If using the cross-regional source, a new taxonomy is created by copying from a source in
+ * another region.
+ *
+ * If using the inlined source, this method provides a way to bulk create taxonomies and policy
+ * tags using nested proto structure.
+ *
+ * Sample code:
+ *
+ * If using the cross-regional source, a new taxonomy is created by copying from a source in
+ * another region.
+ *
+ * If using the inlined source, this method provides a way to bulk create taxonomies and policy
+ * tags using nested proto structure.
+ *
+ * Sample code:
+ *
+ * SerializedTaxonomy protos with nested policy tags that are generated by this method can be
+ * used as input for future ImportTaxonomies calls.
+ *
+ * Sample code:
+ *
+ * SerializedTaxonomy protos with nested policy tags that are generated by this method can be
+ * used as input for future ImportTaxonomies calls.
+ *
+ * Sample code:
+ *
+ * The default instance has everything set to sensible defaults:
+ *
+ * The builder of this class is recursive, so contained classes are themselves builders. When
+ * build() is called, the tree of builders is called to create the complete settings object.
+ *
+ * For example, to set the total timeout of importTaxonomies to 30 seconds:
+ *
+ * Note: This method does not support applying settings to streaming methods.
+ */
+ public Builder applyToAllUnaryMethods(
+ ApiFunction The default instance has everything set to sensible defaults:
+ *
+ * The builder of this class is recursive, so contained classes are themselves builders. When
+ * build() is called, the tree of builders is called to create the complete settings object.
+ *
+ * For example, to set the total timeout of createTaxonomy to 30 seconds:
+ *
+ * Note: This method does not support applying settings to streaming methods.
+ */
+ public Builder applyToAllUnaryMethods(
+ ApiFunction ======================= PolicyTagManagerClient =======================
+ *
+ * Service Description: Policy Tag Manager API service allows clients to manage their policy tags
+ * and taxonomies.
+ *
+ * Policy tags are used to tag BigQuery columns and apply additional access control policies. A
+ * taxonomy is a hierarchical grouping of policy tags that classify data along a common axis.
+ *
+ * Sample for PolicyTagManagerClient:
+ *
+ * ======================= PolicyTagManagerSerializationClient =======================
+ *
+ * Service Description: Policy Tag Manager serialization API service allows clients to manipulate
+ * their policy tags and taxonomies in serialized format, where taxonomy is a hierarchical group of
+ * policy tags.
+ *
+ * Sample for PolicyTagManagerSerializationClient:
+ *
+ * This class is for advanced usage.
+ */
+@Generated("by gapic-generator-java")
+public class GrpcPolicyTagManagerCallableFactory implements GrpcStubCallableFactory {
+
+ @Override
+ public This class is for advanced usage.
+ */
+@Generated("by gapic-generator-java")
+public class GrpcPolicyTagManagerSerializationCallableFactory implements GrpcStubCallableFactory {
+
+ @Override
+ public This class is for advanced usage and reflects the underlying API directly.
+ */
+@Generated("by gapic-generator-java")
+public class GrpcPolicyTagManagerSerializationStub extends PolicyTagManagerSerializationStub {
+ private static final MethodDescriptor This class is for advanced usage and reflects the underlying API directly.
+ */
+@Generated("by gapic-generator-java")
+public class GrpcPolicyTagManagerStub extends PolicyTagManagerStub {
+ private static final MethodDescriptor This class is for advanced usage and reflects the underlying API directly.
+ */
+@Generated("by gapic-generator-java")
+public abstract class PolicyTagManagerSerializationStub implements BackgroundResource {
+
+ public UnaryCallable The default instance has everything set to sensible defaults:
+ *
+ * The builder of this class is recursive, so contained classes are themselves builders. When
+ * build() is called, the tree of builders is called to create the complete settings object.
+ *
+ * For example, to set the total timeout of importTaxonomies to 30 seconds:
+ *
+ *
+ *
+ *
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
public final TagTemplateField updateTagTemplateField(
@@ -2445,13 +2460,19 @@ public final TagTemplateField updateTagTemplateField(
*
*
* @param tagTemplateField Required. The template to update.
- * @param updateMask Optional. The field mask specifies the parts of the template to be updated.
- * Allowed fields:
+ * @param updateMask Optional. Names of fields whose values to overwrite on an individual field of
+ * a tag template. The following fields are modifiable:
*
+ *
+ *
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
public final TagTemplateField updateTagTemplateField(
@@ -2661,6 +2682,155 @@ public final TagTemplateField renameTagTemplateField(RenameTagTemplateFieldReque
return stub.renameTagTemplateFieldCallable();
}
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Renames an enum value in a tag template. The enum values have to be unique within one enum
+ * field.
+ *
+ * {@code
+ * try (DataCatalogClient dataCatalogClient = DataCatalogClient.create()) {
+ * TagTemplateFieldEnumValueName name =
+ * TagTemplateFieldEnumValueName.of(
+ * "[PROJECT]",
+ * "[LOCATION]",
+ * "[TAG_TEMPLATE]",
+ * "[TAG_TEMPLATE_FIELD_ID]",
+ * "[ENUM_VALUE_DISPLAY_NAME]");
+ * String newEnumValueDisplayName = "newEnumValueDisplayName-1119629027";
+ * TagTemplateField response =
+ * dataCatalogClient.renameTagTemplateFieldEnumValue(name, newEnumValueDisplayName);
+ * }
+ * }
+ *
+ * @param name Required. The name of the enum field value. Example:
+ *
+ *
+ *
+ * @param newEnumValueDisplayName Required. The new display name of the enum value. For example,
+ * `my_new_enum_value`.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final TagTemplateField renameTagTemplateFieldEnumValue(
+ TagTemplateFieldEnumValueName name, String newEnumValueDisplayName) {
+ RenameTagTemplateFieldEnumValueRequest request =
+ RenameTagTemplateFieldEnumValueRequest.newBuilder()
+ .setName(name == null ? null : name.toString())
+ .setNewEnumValueDisplayName(newEnumValueDisplayName)
+ .build();
+ return renameTagTemplateFieldEnumValue(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Renames an enum value in a tag template. The enum values have to be unique within one enum
+ * field.
+ *
+ * {@code
+ * try (DataCatalogClient dataCatalogClient = DataCatalogClient.create()) {
+ * String name =
+ * TagTemplateFieldEnumValueName.of(
+ * "[PROJECT]",
+ * "[LOCATION]",
+ * "[TAG_TEMPLATE]",
+ * "[TAG_TEMPLATE_FIELD_ID]",
+ * "[ENUM_VALUE_DISPLAY_NAME]")
+ * .toString();
+ * String newEnumValueDisplayName = "newEnumValueDisplayName-1119629027";
+ * TagTemplateField response =
+ * dataCatalogClient.renameTagTemplateFieldEnumValue(name, newEnumValueDisplayName);
+ * }
+ * }
+ *
+ * @param name Required. The name of the enum field value. Example:
+ *
+ *
+ *
+ * @param newEnumValueDisplayName Required. The new display name of the enum value. For example,
+ * `my_new_enum_value`.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final TagTemplateField renameTagTemplateFieldEnumValue(
+ String name, String newEnumValueDisplayName) {
+ RenameTagTemplateFieldEnumValueRequest request =
+ RenameTagTemplateFieldEnumValueRequest.newBuilder()
+ .setName(name)
+ .setNewEnumValueDisplayName(newEnumValueDisplayName)
+ .build();
+ return renameTagTemplateFieldEnumValue(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Renames an enum value in a tag template. The enum values have to be unique within one enum
+ * field.
+ *
+ * {@code
+ * try (DataCatalogClient dataCatalogClient = DataCatalogClient.create()) {
+ * RenameTagTemplateFieldEnumValueRequest request =
+ * RenameTagTemplateFieldEnumValueRequest.newBuilder()
+ * .setName(
+ * TagTemplateFieldEnumValueName.of(
+ * "[PROJECT]",
+ * "[LOCATION]",
+ * "[TAG_TEMPLATE]",
+ * "[TAG_TEMPLATE_FIELD_ID]",
+ * "[ENUM_VALUE_DISPLAY_NAME]")
+ * .toString())
+ * .setNewEnumValueDisplayName("newEnumValueDisplayName-1119629027")
+ * .build();
+ * TagTemplateField response = dataCatalogClient.renameTagTemplateFieldEnumValue(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final TagTemplateField renameTagTemplateFieldEnumValue(
+ RenameTagTemplateFieldEnumValueRequest request) {
+ return renameTagTemplateFieldEnumValueCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Renames an enum value in a tag template. The enum values have to be unique within one enum
+ * field.
+ *
+ * {@code
+ * try (DataCatalogClient dataCatalogClient = DataCatalogClient.create()) {
+ * RenameTagTemplateFieldEnumValueRequest request =
+ * RenameTagTemplateFieldEnumValueRequest.newBuilder()
+ * .setName(
+ * TagTemplateFieldEnumValueName.of(
+ * "[PROJECT]",
+ * "[LOCATION]",
+ * "[TAG_TEMPLATE]",
+ * "[TAG_TEMPLATE_FIELD_ID]",
+ * "[ENUM_VALUE_DISPLAY_NAME]")
+ * .toString())
+ * .setNewEnumValueDisplayName("newEnumValueDisplayName-1119629027")
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable
- *
- *
- *
- * {@code
* try (DataCatalogClient dataCatalogClient = DataCatalogClient.create()) {
- * ResourceName resource = TagTemplateName.of("[PROJECT]", "[LOCATION]", "[TAG_TEMPLATE]");
+ * ResourceName resource = TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]");
* Policy policy = Policy.newBuilder().build();
* Policy response = dataCatalogClient.setIamPolicy(resource, policy);
* }
@@ -3328,7 +3496,7 @@ public final Policy setIamPolicy(ResourceName resource, Policy policy) {
*
*
{@code
* try (DataCatalogClient dataCatalogClient = DataCatalogClient.create()) {
- * String resource = TagTemplateName.of("[PROJECT]", "[LOCATION]", "[TAG_TEMPLATE]").toString();
+ * String resource = TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString();
* Policy policy = Policy.newBuilder().build();
* Policy response = dataCatalogClient.setIamPolicy(resource, policy);
* }
@@ -3364,8 +3532,7 @@ public final Policy setIamPolicy(String resource, Policy policy) {
* try (DataCatalogClient dataCatalogClient = DataCatalogClient.create()) {
* SetIamPolicyRequest request =
* SetIamPolicyRequest.newBuilder()
- * .setResource(
- * TagTemplateName.of("[PROJECT]", "[LOCATION]", "[TAG_TEMPLATE]").toString())
+ * .setResource(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
* .setPolicy(Policy.newBuilder().build())
* .build();
* Policy response = dataCatalogClient.setIamPolicy(request);
@@ -3396,8 +3563,7 @@ public final Policy setIamPolicy(SetIamPolicyRequest request) {
* try (DataCatalogClient dataCatalogClient = DataCatalogClient.create()) {
* SetIamPolicyRequest request =
* SetIamPolicyRequest.newBuilder()
- * .setResource(
- * TagTemplateName.of("[PROJECT]", "[LOCATION]", "[TAG_TEMPLATE]").toString())
+ * .setResource(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
* .setPolicy(Policy.newBuilder().build())
* .build();
* ApiFuture
+ *
+ * {@code
* try (DataCatalogClient dataCatalogClient = DataCatalogClient.create()) {
- * ResourceName resource = TagTemplateName.of("[PROJECT]", "[LOCATION]", "[TAG_TEMPLATE]");
+ * ResourceName resource = TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]");
* Policy response = dataCatalogClient.getIamPolicy(resource);
* }
* }
@@ -3463,7 +3629,7 @@ public final Policy getIamPolicy(ResourceName resource) {
*
* {@code
* try (DataCatalogClient dataCatalogClient = DataCatalogClient.create()) {
- * String resource = TagTemplateName.of("[PROJECT]", "[LOCATION]", "[TAG_TEMPLATE]").toString();
+ * String resource = TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString();
* Policy response = dataCatalogClient.getIamPolicy(resource);
* }
* }
@@ -3497,8 +3663,7 @@ public final Policy getIamPolicy(String resource) {
* try (DataCatalogClient dataCatalogClient = DataCatalogClient.create()) {
* GetIamPolicyRequest request =
* GetIamPolicyRequest.newBuilder()
- * .setResource(
- * TagTemplateName.of("[PROJECT]", "[LOCATION]", "[TAG_TEMPLATE]").toString())
+ * .setResource(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
* .setOptions(GetPolicyOptions.newBuilder().build())
* .build();
* Policy response = dataCatalogClient.getIamPolicy(request);
@@ -3532,8 +3697,7 @@ public final Policy getIamPolicy(GetIamPolicyRequest request) {
* try (DataCatalogClient dataCatalogClient = DataCatalogClient.create()) {
* GetIamPolicyRequest request =
* GetIamPolicyRequest.newBuilder()
- * .setResource(
- * TagTemplateName.of("[PROJECT]", "[LOCATION]", "[TAG_TEMPLATE]").toString())
+ * .setResource(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
* .setOptions(GetPolicyOptions.newBuilder().build())
* .build();
* ApiFuture{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+ * Taxonomy taxonomy = Taxonomy.newBuilder().build();
+ * Taxonomy response = policyTagManagerClient.createTaxonomy(parent, taxonomy);
+ * }
+ * }
+ *
+ *
+ *
+ *
+ * {@code
+ * PolicyTagManagerSettings policyTagManagerSettings =
+ * PolicyTagManagerSettings.newBuilder()
+ * .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ * .build();
+ * PolicyTagManagerClient policyTagManagerClient =
+ * PolicyTagManagerClient.create(policyTagManagerSettings);
+ * }
+ *
+ * {@code
+ * PolicyTagManagerSettings policyTagManagerSettings =
+ * PolicyTagManagerSettings.newBuilder().setEndpoint(myEndpoint).build();
+ * PolicyTagManagerClient policyTagManagerClient =
+ * PolicyTagManagerClient.create(policyTagManagerSettings);
+ * }
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+ * Taxonomy taxonomy = Taxonomy.newBuilder().build();
+ * Taxonomy response = policyTagManagerClient.createTaxonomy(parent, taxonomy);
+ * }
+ * }
+ *
+ * @param parent Required. Resource name of the project that the taxonomy will belong to.
+ * @param taxonomy The taxonomy to be created.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final Taxonomy createTaxonomy(LocationName parent, Taxonomy taxonomy) {
+ CreateTaxonomyRequest request =
+ CreateTaxonomyRequest.newBuilder()
+ .setParent(parent == null ? null : parent.toString())
+ .setTaxonomy(taxonomy)
+ .build();
+ return createTaxonomy(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Creates a taxonomy in a specified project. The taxonomy is initially empty, i.e., does not
+ * contain policy tags.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * String parent = TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString();
+ * Taxonomy taxonomy = Taxonomy.newBuilder().build();
+ * Taxonomy response = policyTagManagerClient.createTaxonomy(parent, taxonomy);
+ * }
+ * }
+ *
+ * @param parent Required. Resource name of the project that the taxonomy will belong to.
+ * @param taxonomy The taxonomy to be created.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final Taxonomy createTaxonomy(String parent, Taxonomy taxonomy) {
+ CreateTaxonomyRequest request =
+ CreateTaxonomyRequest.newBuilder().setParent(parent).setTaxonomy(taxonomy).build();
+ return createTaxonomy(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Creates a taxonomy in a specified project. The taxonomy is initially empty, i.e., does not
+ * contain policy tags.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * CreateTaxonomyRequest request =
+ * CreateTaxonomyRequest.newBuilder()
+ * .setParent(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .setTaxonomy(Taxonomy.newBuilder().build())
+ * .build();
+ * Taxonomy response = policyTagManagerClient.createTaxonomy(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final Taxonomy createTaxonomy(CreateTaxonomyRequest request) {
+ return createTaxonomyCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Creates a taxonomy in a specified project. The taxonomy is initially empty, i.e., does not
+ * contain policy tags.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * CreateTaxonomyRequest request =
+ * CreateTaxonomyRequest.newBuilder()
+ * .setParent(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .setTaxonomy(Taxonomy.newBuilder().build())
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * TaxonomyName name = TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]");
+ * policyTagManagerClient.deleteTaxonomy(name);
+ * }
+ * }
+ *
+ * @param name Required. Resource name of the taxonomy to be deleted. All policy tags in this
+ * taxonomy will also be deleted.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final void deleteTaxonomy(TaxonomyName name) {
+ DeleteTaxonomyRequest request =
+ DeleteTaxonomyRequest.newBuilder().setName(name == null ? null : name.toString()).build();
+ deleteTaxonomy(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Deletes a taxonomy. This method will also delete all policy tags in this taxonomy, their
+ * associated policies, and the policy tags references from BigQuery columns.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * String name = TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString();
+ * policyTagManagerClient.deleteTaxonomy(name);
+ * }
+ * }
+ *
+ * @param name Required. Resource name of the taxonomy to be deleted. All policy tags in this
+ * taxonomy will also be deleted.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final void deleteTaxonomy(String name) {
+ DeleteTaxonomyRequest request = DeleteTaxonomyRequest.newBuilder().setName(name).build();
+ deleteTaxonomy(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Deletes a taxonomy. This method will also delete all policy tags in this taxonomy, their
+ * associated policies, and the policy tags references from BigQuery columns.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * DeleteTaxonomyRequest request =
+ * DeleteTaxonomyRequest.newBuilder()
+ * .setName(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .build();
+ * policyTagManagerClient.deleteTaxonomy(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final void deleteTaxonomy(DeleteTaxonomyRequest request) {
+ deleteTaxonomyCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Deletes a taxonomy. This method will also delete all policy tags in this taxonomy, their
+ * associated policies, and the policy tags references from BigQuery columns.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * DeleteTaxonomyRequest request =
+ * DeleteTaxonomyRequest.newBuilder()
+ * .setName(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * Taxonomy taxonomy = Taxonomy.newBuilder().build();
+ * Taxonomy response = policyTagManagerClient.updateTaxonomy(taxonomy);
+ * }
+ * }
+ *
+ * @param taxonomy The taxonomy to update. Only description, display_name, and activated policy
+ * types can be updated.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final Taxonomy updateTaxonomy(Taxonomy taxonomy) {
+ UpdateTaxonomyRequest request =
+ UpdateTaxonomyRequest.newBuilder().setTaxonomy(taxonomy).build();
+ return updateTaxonomy(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Updates a taxonomy. This method can update the taxonomy's display name, description, and
+ * activated policy types.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * UpdateTaxonomyRequest request =
+ * UpdateTaxonomyRequest.newBuilder()
+ * .setTaxonomy(Taxonomy.newBuilder().build())
+ * .setUpdateMask(FieldMask.newBuilder().build())
+ * .build();
+ * Taxonomy response = policyTagManagerClient.updateTaxonomy(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final Taxonomy updateTaxonomy(UpdateTaxonomyRequest request) {
+ return updateTaxonomyCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Updates a taxonomy. This method can update the taxonomy's display name, description, and
+ * activated policy types.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * UpdateTaxonomyRequest request =
+ * UpdateTaxonomyRequest.newBuilder()
+ * .setTaxonomy(Taxonomy.newBuilder().build())
+ * .setUpdateMask(FieldMask.newBuilder().build())
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+ * for (Taxonomy element : policyTagManagerClient.listTaxonomies(parent).iterateAll()) {
+ * // doThingsWith(element);
+ * }
+ * }
+ * }
+ *
+ * @param parent Required. Resource name of the project to list the taxonomies of.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final ListTaxonomiesPagedResponse listTaxonomies(LocationName parent) {
+ ListTaxonomiesRequest request =
+ ListTaxonomiesRequest.newBuilder()
+ .setParent(parent == null ? null : parent.toString())
+ .build();
+ return listTaxonomies(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Lists all taxonomies in a project in a particular location that the caller has permission to
+ * view.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * String parent = TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString();
+ * for (Taxonomy element : policyTagManagerClient.listTaxonomies(parent).iterateAll()) {
+ * // doThingsWith(element);
+ * }
+ * }
+ * }
+ *
+ * @param parent Required. Resource name of the project to list the taxonomies of.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final ListTaxonomiesPagedResponse listTaxonomies(String parent) {
+ ListTaxonomiesRequest request = ListTaxonomiesRequest.newBuilder().setParent(parent).build();
+ return listTaxonomies(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Lists all taxonomies in a project in a particular location that the caller has permission to
+ * view.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * ListTaxonomiesRequest request =
+ * ListTaxonomiesRequest.newBuilder()
+ * .setParent(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .setPageSize(883849137)
+ * .setPageToken("pageToken873572522")
+ * .build();
+ * for (Taxonomy element : policyTagManagerClient.listTaxonomies(request).iterateAll()) {
+ * // doThingsWith(element);
+ * }
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final ListTaxonomiesPagedResponse listTaxonomies(ListTaxonomiesRequest request) {
+ return listTaxonomiesPagedCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Lists all taxonomies in a project in a particular location that the caller has permission to
+ * view.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * ListTaxonomiesRequest request =
+ * ListTaxonomiesRequest.newBuilder()
+ * .setParent(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .setPageSize(883849137)
+ * .setPageToken("pageToken873572522")
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * ListTaxonomiesRequest request =
+ * ListTaxonomiesRequest.newBuilder()
+ * .setParent(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .setPageSize(883849137)
+ * .setPageToken("pageToken873572522")
+ * .build();
+ * while (true) {
+ * ListTaxonomiesResponse response =
+ * policyTagManagerClient.listTaxonomiesCallable().call(request);
+ * for (Taxonomy element : response.getResponsesList()) {
+ * // doThingsWith(element);
+ * }
+ * String nextPageToken = response.getNextPageToken();
+ * if (!Strings.isNullOrEmpty(nextPageToken)) {
+ * request = request.toBuilder().setPageToken(nextPageToken).build();
+ * } else {
+ * break;
+ * }
+ * }
+ * }
+ * }
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * TaxonomyName name = TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]");
+ * Taxonomy response = policyTagManagerClient.getTaxonomy(name);
+ * }
+ * }
+ *
+ * @param name Required. Resource name of the requested taxonomy.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final Taxonomy getTaxonomy(TaxonomyName name) {
+ GetTaxonomyRequest request =
+ GetTaxonomyRequest.newBuilder().setName(name == null ? null : name.toString()).build();
+ return getTaxonomy(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Gets a taxonomy.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * String name = TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString();
+ * Taxonomy response = policyTagManagerClient.getTaxonomy(name);
+ * }
+ * }
+ *
+ * @param name Required. Resource name of the requested taxonomy.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final Taxonomy getTaxonomy(String name) {
+ GetTaxonomyRequest request = GetTaxonomyRequest.newBuilder().setName(name).build();
+ return getTaxonomy(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Gets a taxonomy.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * GetTaxonomyRequest request =
+ * GetTaxonomyRequest.newBuilder()
+ * .setName(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .build();
+ * Taxonomy response = policyTagManagerClient.getTaxonomy(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final Taxonomy getTaxonomy(GetTaxonomyRequest request) {
+ return getTaxonomyCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Gets a taxonomy.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * GetTaxonomyRequest request =
+ * GetTaxonomyRequest.newBuilder()
+ * .setName(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * TaxonomyName parent = TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]");
+ * PolicyTag policyTag = PolicyTag.newBuilder().build();
+ * PolicyTag response = policyTagManagerClient.createPolicyTag(parent, policyTag);
+ * }
+ * }
+ *
+ * @param parent Required. Resource name of the taxonomy that the policy tag will belong to.
+ * @param policyTag The policy tag to be created.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final PolicyTag createPolicyTag(TaxonomyName parent, PolicyTag policyTag) {
+ CreatePolicyTagRequest request =
+ CreatePolicyTagRequest.newBuilder()
+ .setParent(parent == null ? null : parent.toString())
+ .setPolicyTag(policyTag)
+ .build();
+ return createPolicyTag(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Creates a policy tag in a taxonomy.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * String parent =
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]").toString();
+ * PolicyTag policyTag = PolicyTag.newBuilder().build();
+ * PolicyTag response = policyTagManagerClient.createPolicyTag(parent, policyTag);
+ * }
+ * }
+ *
+ * @param parent Required. Resource name of the taxonomy that the policy tag will belong to.
+ * @param policyTag The policy tag to be created.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final PolicyTag createPolicyTag(String parent, PolicyTag policyTag) {
+ CreatePolicyTagRequest request =
+ CreatePolicyTagRequest.newBuilder().setParent(parent).setPolicyTag(policyTag).build();
+ return createPolicyTag(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Creates a policy tag in a taxonomy.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * CreatePolicyTagRequest request =
+ * CreatePolicyTagRequest.newBuilder()
+ * .setParent(
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]")
+ * .toString())
+ * .setPolicyTag(PolicyTag.newBuilder().build())
+ * .build();
+ * PolicyTag response = policyTagManagerClient.createPolicyTag(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final PolicyTag createPolicyTag(CreatePolicyTagRequest request) {
+ return createPolicyTagCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Creates a policy tag in a taxonomy.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * CreatePolicyTagRequest request =
+ * CreatePolicyTagRequest.newBuilder()
+ * .setParent(
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]")
+ * .toString())
+ * .setPolicyTag(PolicyTag.newBuilder().build())
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * PolicyTagName name =
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]");
+ * policyTagManagerClient.deletePolicyTag(name);
+ * }
+ * }
+ *
+ * @param name Required. Resource name of the policy tag to be deleted. All of its descendant
+ * policy tags will also be deleted.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final void deletePolicyTag(PolicyTagName name) {
+ DeletePolicyTagRequest request =
+ DeletePolicyTagRequest.newBuilder().setName(name == null ? null : name.toString()).build();
+ deletePolicyTag(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Deletes a policy tag. This method also deletes - all of its descendant policy tags, if any, -
+ * the policies associated with the policy tag and its descendants, and - references from BigQuery
+ * table schema of the policy tag and its descendants.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * String name =
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]").toString();
+ * policyTagManagerClient.deletePolicyTag(name);
+ * }
+ * }
+ *
+ * @param name Required. Resource name of the policy tag to be deleted. All of its descendant
+ * policy tags will also be deleted.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final void deletePolicyTag(String name) {
+ DeletePolicyTagRequest request = DeletePolicyTagRequest.newBuilder().setName(name).build();
+ deletePolicyTag(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Deletes a policy tag. This method also deletes - all of its descendant policy tags, if any, -
+ * the policies associated with the policy tag and its descendants, and - references from BigQuery
+ * table schema of the policy tag and its descendants.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * DeletePolicyTagRequest request =
+ * DeletePolicyTagRequest.newBuilder()
+ * .setName(
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]")
+ * .toString())
+ * .build();
+ * policyTagManagerClient.deletePolicyTag(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final void deletePolicyTag(DeletePolicyTagRequest request) {
+ deletePolicyTagCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Deletes a policy tag. This method also deletes - all of its descendant policy tags, if any, -
+ * the policies associated with the policy tag and its descendants, and - references from BigQuery
+ * table schema of the policy tag and its descendants.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * DeletePolicyTagRequest request =
+ * DeletePolicyTagRequest.newBuilder()
+ * .setName(
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]")
+ * .toString())
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * PolicyTag policyTag = PolicyTag.newBuilder().build();
+ * PolicyTag response = policyTagManagerClient.updatePolicyTag(policyTag);
+ * }
+ * }
+ *
+ * @param policyTag The policy tag to update. Only the description, display_name, and
+ * parent_policy_tag fields can be updated.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final PolicyTag updatePolicyTag(PolicyTag policyTag) {
+ UpdatePolicyTagRequest request =
+ UpdatePolicyTagRequest.newBuilder().setPolicyTag(policyTag).build();
+ return updatePolicyTag(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Updates a policy tag. This method can update the policy tag's display name, description, and
+ * parent policy tag.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * UpdatePolicyTagRequest request =
+ * UpdatePolicyTagRequest.newBuilder()
+ * .setPolicyTag(PolicyTag.newBuilder().build())
+ * .setUpdateMask(FieldMask.newBuilder().build())
+ * .build();
+ * PolicyTag response = policyTagManagerClient.updatePolicyTag(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final PolicyTag updatePolicyTag(UpdatePolicyTagRequest request) {
+ return updatePolicyTagCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Updates a policy tag. This method can update the policy tag's display name, description, and
+ * parent policy tag.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * UpdatePolicyTagRequest request =
+ * UpdatePolicyTagRequest.newBuilder()
+ * .setPolicyTag(PolicyTag.newBuilder().build())
+ * .setUpdateMask(FieldMask.newBuilder().build())
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * TaxonomyName parent = TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]");
+ * for (PolicyTag element : policyTagManagerClient.listPolicyTags(parent).iterateAll()) {
+ * // doThingsWith(element);
+ * }
+ * }
+ * }
+ *
+ * @param parent Required. Resource name of the taxonomy to list the policy tags of.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final ListPolicyTagsPagedResponse listPolicyTags(TaxonomyName parent) {
+ ListPolicyTagsRequest request =
+ ListPolicyTagsRequest.newBuilder()
+ .setParent(parent == null ? null : parent.toString())
+ .build();
+ return listPolicyTags(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Lists all policy tags in a taxonomy.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * String parent =
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]").toString();
+ * for (PolicyTag element : policyTagManagerClient.listPolicyTags(parent).iterateAll()) {
+ * // doThingsWith(element);
+ * }
+ * }
+ * }
+ *
+ * @param parent Required. Resource name of the taxonomy to list the policy tags of.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final ListPolicyTagsPagedResponse listPolicyTags(String parent) {
+ ListPolicyTagsRequest request = ListPolicyTagsRequest.newBuilder().setParent(parent).build();
+ return listPolicyTags(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Lists all policy tags in a taxonomy.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * ListPolicyTagsRequest request =
+ * ListPolicyTagsRequest.newBuilder()
+ * .setParent(
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]")
+ * .toString())
+ * .setPageSize(883849137)
+ * .setPageToken("pageToken873572522")
+ * .build();
+ * for (PolicyTag element : policyTagManagerClient.listPolicyTags(request).iterateAll()) {
+ * // doThingsWith(element);
+ * }
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final ListPolicyTagsPagedResponse listPolicyTags(ListPolicyTagsRequest request) {
+ return listPolicyTagsPagedCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Lists all policy tags in a taxonomy.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * ListPolicyTagsRequest request =
+ * ListPolicyTagsRequest.newBuilder()
+ * .setParent(
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]")
+ * .toString())
+ * .setPageSize(883849137)
+ * .setPageToken("pageToken873572522")
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * ListPolicyTagsRequest request =
+ * ListPolicyTagsRequest.newBuilder()
+ * .setParent(
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]")
+ * .toString())
+ * .setPageSize(883849137)
+ * .setPageToken("pageToken873572522")
+ * .build();
+ * while (true) {
+ * ListPolicyTagsResponse response =
+ * policyTagManagerClient.listPolicyTagsCallable().call(request);
+ * for (PolicyTag element : response.getResponsesList()) {
+ * // doThingsWith(element);
+ * }
+ * String nextPageToken = response.getNextPageToken();
+ * if (!Strings.isNullOrEmpty(nextPageToken)) {
+ * request = request.toBuilder().setPageToken(nextPageToken).build();
+ * } else {
+ * break;
+ * }
+ * }
+ * }
+ * }
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * PolicyTagName name =
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]");
+ * PolicyTag response = policyTagManagerClient.getPolicyTag(name);
+ * }
+ * }
+ *
+ * @param name Required. Resource name of the requested policy tag.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final PolicyTag getPolicyTag(PolicyTagName name) {
+ GetPolicyTagRequest request =
+ GetPolicyTagRequest.newBuilder().setName(name == null ? null : name.toString()).build();
+ return getPolicyTag(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Gets a policy tag.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * String name =
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]").toString();
+ * PolicyTag response = policyTagManagerClient.getPolicyTag(name);
+ * }
+ * }
+ *
+ * @param name Required. Resource name of the requested policy tag.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final PolicyTag getPolicyTag(String name) {
+ GetPolicyTagRequest request = GetPolicyTagRequest.newBuilder().setName(name).build();
+ return getPolicyTag(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Gets a policy tag.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * GetPolicyTagRequest request =
+ * GetPolicyTagRequest.newBuilder()
+ * .setName(
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]")
+ * .toString())
+ * .build();
+ * PolicyTag response = policyTagManagerClient.getPolicyTag(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final PolicyTag getPolicyTag(GetPolicyTagRequest request) {
+ return getPolicyTagCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Gets a policy tag.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * GetPolicyTagRequest request =
+ * GetPolicyTagRequest.newBuilder()
+ * .setName(
+ * PolicyTagName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]", "[POLICY_TAG]")
+ * .toString())
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * GetIamPolicyRequest request =
+ * GetIamPolicyRequest.newBuilder()
+ * .setResource(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .setOptions(GetPolicyOptions.newBuilder().build())
+ * .build();
+ * Policy response = policyTagManagerClient.getIamPolicy(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final Policy getIamPolicy(GetIamPolicyRequest request) {
+ return getIamPolicyCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Gets the IAM policy for a policy tag or a taxonomy.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * GetIamPolicyRequest request =
+ * GetIamPolicyRequest.newBuilder()
+ * .setResource(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .setOptions(GetPolicyOptions.newBuilder().build())
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * SetIamPolicyRequest request =
+ * SetIamPolicyRequest.newBuilder()
+ * .setResource(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .setPolicy(Policy.newBuilder().build())
+ * .build();
+ * Policy response = policyTagManagerClient.setIamPolicy(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final Policy setIamPolicy(SetIamPolicyRequest request) {
+ return setIamPolicyCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Sets the IAM policy for a policy tag or a taxonomy.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * SetIamPolicyRequest request =
+ * SetIamPolicyRequest.newBuilder()
+ * .setResource(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .setPolicy(Policy.newBuilder().build())
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * TestIamPermissionsRequest request =
+ * TestIamPermissionsRequest.newBuilder()
+ * .setResource(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .addAllPermissions(new ArrayList
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final TestIamPermissionsResponse testIamPermissions(TestIamPermissionsRequest request) {
+ return testIamPermissionsCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Returns the permissions that a caller has on a specified policy tag or taxonomy.
+ *
+ * {@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * TestIamPermissionsRequest request =
+ * TestIamPermissionsRequest.newBuilder()
+ * .setResource(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .addAllPermissions(new ArrayList
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerSerializationClient policyTagManagerSerializationClient =
+ * PolicyTagManagerSerializationClient.create()) {
+ * ImportTaxonomiesRequest request =
+ * ImportTaxonomiesRequest.newBuilder()
+ * .setParent(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .build();
+ * ImportTaxonomiesResponse response =
+ * policyTagManagerSerializationClient.importTaxonomies(request);
+ * }
+ * }
+ *
+ *
+ *
+ *
+ * {@code
+ * PolicyTagManagerSerializationSettings policyTagManagerSerializationSettings =
+ * PolicyTagManagerSerializationSettings.newBuilder()
+ * .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ * .build();
+ * PolicyTagManagerSerializationClient policyTagManagerSerializationClient =
+ * PolicyTagManagerSerializationClient.create(policyTagManagerSerializationSettings);
+ * }
+ *
+ * {@code
+ * PolicyTagManagerSerializationSettings policyTagManagerSerializationSettings =
+ * PolicyTagManagerSerializationSettings.newBuilder().setEndpoint(myEndpoint).build();
+ * PolicyTagManagerSerializationClient policyTagManagerSerializationClient =
+ * PolicyTagManagerSerializationClient.create(policyTagManagerSerializationSettings);
+ * }
+ *
+ * {@code
+ * try (PolicyTagManagerSerializationClient policyTagManagerSerializationClient =
+ * PolicyTagManagerSerializationClient.create()) {
+ * ImportTaxonomiesRequest request =
+ * ImportTaxonomiesRequest.newBuilder()
+ * .setParent(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .build();
+ * ImportTaxonomiesResponse response =
+ * policyTagManagerSerializationClient.importTaxonomies(request);
+ * }
+ * }
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final ImportTaxonomiesResponse importTaxonomies(ImportTaxonomiesRequest request) {
+ return importTaxonomiesCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Creates new taxonomies (including their policy tags) by importing from inlined source or
+ * cross-regional source. New taxonomies will be created in a given parent project.
+ *
+ * {@code
+ * try (PolicyTagManagerSerializationClient policyTagManagerSerializationClient =
+ * PolicyTagManagerSerializationClient.create()) {
+ * ImportTaxonomiesRequest request =
+ * ImportTaxonomiesRequest.newBuilder()
+ * .setParent(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .build();
+ * ApiFuture
+ */
+ public final UnaryCallable{@code
+ * try (PolicyTagManagerSerializationClient policyTagManagerSerializationClient =
+ * PolicyTagManagerSerializationClient.create()) {
+ * ExportTaxonomiesRequest request =
+ * ExportTaxonomiesRequest.newBuilder()
+ * .setParent(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .addAllTaxonomies(new ArrayList
+ *
+ * @param request The request object containing all of the parameters for the API call.
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
+ */
+ public final ExportTaxonomiesResponse exportTaxonomies(ExportTaxonomiesRequest request) {
+ return exportTaxonomiesCallable().call(request);
+ }
+
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
+ /**
+ * Exports taxonomies as the requested type and returns the taxonomies including their policy
+ * tags. The requested taxonomies must belong to one project.
+ *
+ * {@code
+ * try (PolicyTagManagerSerializationClient policyTagManagerSerializationClient =
+ * PolicyTagManagerSerializationClient.create()) {
+ * ExportTaxonomiesRequest request =
+ * ExportTaxonomiesRequest.newBuilder()
+ * .setParent(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .addAllTaxonomies(new ArrayList
+ */
+ public final UnaryCallable
+ *
+ *
+ * {@code
+ * PolicyTagManagerSerializationSettings.Builder policyTagManagerSerializationSettingsBuilder =
+ * PolicyTagManagerSerializationSettings.newBuilder();
+ * policyTagManagerSerializationSettingsBuilder
+ * .importTaxonomiesSettings()
+ * .setRetrySettings(
+ * policyTagManagerSerializationSettingsBuilder
+ * .importTaxonomiesSettings()
+ * .getRetrySettings()
+ * .toBuilder()
+ * .setTotalTimeout(Duration.ofSeconds(30))
+ * .build());
+ * PolicyTagManagerSerializationSettings policyTagManagerSerializationSettings =
+ * policyTagManagerSerializationSettingsBuilder.build();
+ * }
+ */
+@Generated("by gapic-generator-java")
+public class PolicyTagManagerSerializationSettings
+ extends ClientSettings
+ *
+ *
+ * {@code
+ * PolicyTagManagerSettings.Builder policyTagManagerSettingsBuilder =
+ * PolicyTagManagerSettings.newBuilder();
+ * policyTagManagerSettingsBuilder
+ * .createTaxonomySettings()
+ * .setRetrySettings(
+ * policyTagManagerSettingsBuilder
+ * .createTaxonomySettings()
+ * .getRetrySettings()
+ * .toBuilder()
+ * .setTotalTimeout(Duration.ofSeconds(30))
+ * .build());
+ * PolicyTagManagerSettings policyTagManagerSettings = policyTagManagerSettingsBuilder.build();
+ * }
+ */
+@Generated("by gapic-generator-java")
+public class PolicyTagManagerSettings extends ClientSettings{@code
+ * try (PolicyTagManagerClient policyTagManagerClient = PolicyTagManagerClient.create()) {
+ * LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+ * Taxonomy taxonomy = Taxonomy.newBuilder().build();
+ * Taxonomy response = policyTagManagerClient.createTaxonomy(parent, taxonomy);
+ * }
+ * }
+ *
+ * {@code
+ * try (PolicyTagManagerSerializationClient policyTagManagerSerializationClient =
+ * PolicyTagManagerSerializationClient.create()) {
+ * ImportTaxonomiesRequest request =
+ * ImportTaxonomiesRequest.newBuilder()
+ * .setParent(TaxonomyName.of("[PROJECT]", "[LOCATION]", "[TAXONOMY]").toString())
+ * .build();
+ * ImportTaxonomiesResponse response =
+ * policyTagManagerSerializationClient.importTaxonomies(request);
+ * }
+ * }
*/
@Generated("by gapic-generator-java")
package com.google.cloud.datacatalog.v1;
diff --git a/google-cloud-datacatalog/src/main/java/com/google/cloud/datacatalog/v1/stub/DataCatalogStub.java b/google-cloud-datacatalog/src/main/java/com/google/cloud/datacatalog/v1/stub/DataCatalogStub.java
index fa31267e..d24ff7b2 100644
--- a/google-cloud-datacatalog/src/main/java/com/google/cloud/datacatalog/v1/stub/DataCatalogStub.java
+++ b/google-cloud-datacatalog/src/main/java/com/google/cloud/datacatalog/v1/stub/DataCatalogStub.java
@@ -45,6 +45,7 @@
import com.google.cloud.datacatalog.v1.ListTagsRequest;
import com.google.cloud.datacatalog.v1.ListTagsResponse;
import com.google.cloud.datacatalog.v1.LookupEntryRequest;
+import com.google.cloud.datacatalog.v1.RenameTagTemplateFieldEnumValueRequest;
import com.google.cloud.datacatalog.v1.RenameTagTemplateFieldRequest;
import com.google.cloud.datacatalog.v1.SearchCatalogRequest;
import com.google.cloud.datacatalog.v1.SearchCatalogResponse;
@@ -166,6 +167,12 @@ public UnaryCallable
+ *
+ *
+ * {@code
+ * PolicyTagManagerSerializationStubSettings.Builder policyTagManagerSerializationSettingsBuilder =
+ * PolicyTagManagerSerializationStubSettings.newBuilder();
+ * policyTagManagerSerializationSettingsBuilder
+ * .importTaxonomiesSettings()
+ * .setRetrySettings(
+ * policyTagManagerSerializationSettingsBuilder
+ * .importTaxonomiesSettings()
+ * .getRetrySettings()
+ * .toBuilder()
+ * .setTotalTimeout(Duration.ofSeconds(30))
+ * .build());
+ * PolicyTagManagerSerializationStubSettings policyTagManagerSerializationSettings =
+ * policyTagManagerSerializationSettingsBuilder.build();
+ * }
+ */
+@Generated("by gapic-generator-java")
+public class PolicyTagManagerSerializationStubSettings
+ extends StubSettings