diff --git a/google/cloud/datacatalog/__init__.py b/google/cloud/datacatalog/__init__.py index 2bdf9448..9eacd5fd 100644 --- a/google/cloud/datacatalog/__init__.py +++ b/google/cloud/datacatalog/__init__.py @@ -34,8 +34,11 @@ from google.cloud.datacatalog_v1.types.bigquery import BigQueryConnectionSpec from google.cloud.datacatalog_v1.types.bigquery import BigQueryRoutineSpec from google.cloud.datacatalog_v1.types.bigquery import CloudSqlBigQueryConnectionSpec +from google.cloud.datacatalog_v1.types.common import PersonalDetails from google.cloud.datacatalog_v1.types.common import IntegratedSystem from google.cloud.datacatalog_v1.types.data_source import DataSource +from google.cloud.datacatalog_v1.types.datacatalog import BusinessContext +from google.cloud.datacatalog_v1.types.datacatalog import Contacts from google.cloud.datacatalog_v1.types.datacatalog import CreateEntryGroupRequest from google.cloud.datacatalog_v1.types.datacatalog import CreateEntryRequest from google.cloud.datacatalog_v1.types.datacatalog import CreateTagRequest @@ -50,6 +53,7 @@ from google.cloud.datacatalog_v1.types.datacatalog import DeleteTagTemplateRequest from google.cloud.datacatalog_v1.types.datacatalog import Entry from google.cloud.datacatalog_v1.types.datacatalog import EntryGroup +from google.cloud.datacatalog_v1.types.datacatalog import EntryOverview from google.cloud.datacatalog_v1.types.datacatalog import GetEntryGroupRequest from google.cloud.datacatalog_v1.types.datacatalog import GetEntryRequest from google.cloud.datacatalog_v1.types.datacatalog import GetTagTemplateRequest @@ -60,6 +64,8 @@ from google.cloud.datacatalog_v1.types.datacatalog import ListTagsRequest from google.cloud.datacatalog_v1.types.datacatalog import ListTagsResponse from google.cloud.datacatalog_v1.types.datacatalog import LookupEntryRequest +from google.cloud.datacatalog_v1.types.datacatalog import ModifyEntryContactsRequest +from google.cloud.datacatalog_v1.types.datacatalog import ModifyEntryOverviewRequest from google.cloud.datacatalog_v1.types.datacatalog import ( RenameTagTemplateFieldEnumValueRequest, ) @@ -67,6 +73,10 @@ from google.cloud.datacatalog_v1.types.datacatalog import RoutineSpec from google.cloud.datacatalog_v1.types.datacatalog import SearchCatalogRequest from google.cloud.datacatalog_v1.types.datacatalog import SearchCatalogResponse +from google.cloud.datacatalog_v1.types.datacatalog import StarEntryRequest +from google.cloud.datacatalog_v1.types.datacatalog import StarEntryResponse +from google.cloud.datacatalog_v1.types.datacatalog import UnstarEntryRequest +from google.cloud.datacatalog_v1.types.datacatalog import UnstarEntryResponse from google.cloud.datacatalog_v1.types.datacatalog import UpdateEntryGroupRequest from google.cloud.datacatalog_v1.types.datacatalog import UpdateEntryRequest from google.cloud.datacatalog_v1.types.datacatalog import UpdateTagRequest @@ -142,8 +152,11 @@ "BigQueryConnectionSpec", "BigQueryRoutineSpec", "CloudSqlBigQueryConnectionSpec", + "PersonalDetails", "IntegratedSystem", "DataSource", + "BusinessContext", + "Contacts", "CreateEntryGroupRequest", "CreateEntryRequest", "CreateTagRequest", @@ -158,6 +171,7 @@ "DeleteTagTemplateRequest", "Entry", "EntryGroup", + "EntryOverview", "GetEntryGroupRequest", "GetEntryRequest", "GetTagTemplateRequest", @@ -168,11 +182,17 @@ "ListTagsRequest", "ListTagsResponse", "LookupEntryRequest", + "ModifyEntryContactsRequest", + "ModifyEntryOverviewRequest", "RenameTagTemplateFieldEnumValueRequest", "RenameTagTemplateFieldRequest", "RoutineSpec", "SearchCatalogRequest", "SearchCatalogResponse", + "StarEntryRequest", + "StarEntryResponse", + "UnstarEntryRequest", + "UnstarEntryResponse", "UpdateEntryGroupRequest", "UpdateEntryRequest", "UpdateTagRequest", diff --git a/google/cloud/datacatalog_v1/__init__.py b/google/cloud/datacatalog_v1/__init__.py index 37c5f8a3..5f942972 100644 --- a/google/cloud/datacatalog_v1/__init__.py +++ b/google/cloud/datacatalog_v1/__init__.py @@ -28,8 +28,11 @@ from .types.bigquery import BigQueryConnectionSpec from .types.bigquery import BigQueryRoutineSpec from .types.bigquery import CloudSqlBigQueryConnectionSpec +from .types.common import PersonalDetails from .types.common import IntegratedSystem from .types.data_source import DataSource +from .types.datacatalog import BusinessContext +from .types.datacatalog import Contacts from .types.datacatalog import CreateEntryGroupRequest from .types.datacatalog import CreateEntryRequest from .types.datacatalog import CreateTagRequest @@ -44,6 +47,7 @@ from .types.datacatalog import DeleteTagTemplateRequest from .types.datacatalog import Entry from .types.datacatalog import EntryGroup +from .types.datacatalog import EntryOverview from .types.datacatalog import GetEntryGroupRequest from .types.datacatalog import GetEntryRequest from .types.datacatalog import GetTagTemplateRequest @@ -54,11 +58,17 @@ from .types.datacatalog import ListTagsRequest from .types.datacatalog import ListTagsResponse from .types.datacatalog import LookupEntryRequest +from .types.datacatalog import ModifyEntryContactsRequest +from .types.datacatalog import ModifyEntryOverviewRequest from .types.datacatalog import RenameTagTemplateFieldEnumValueRequest from .types.datacatalog import RenameTagTemplateFieldRequest from .types.datacatalog import RoutineSpec from .types.datacatalog import SearchCatalogRequest from .types.datacatalog import SearchCatalogResponse +from .types.datacatalog import StarEntryRequest +from .types.datacatalog import StarEntryResponse +from .types.datacatalog import UnstarEntryRequest +from .types.datacatalog import UnstarEntryResponse from .types.datacatalog import UpdateEntryGroupRequest from .types.datacatalog import UpdateEntryRequest from .types.datacatalog import UpdateTagRequest @@ -116,8 +126,10 @@ "BigQueryDateShardedSpec", "BigQueryRoutineSpec", "BigQueryTableSpec", + "BusinessContext", "CloudSqlBigQueryConnectionSpec", "ColumnSchema", + "Contacts", "CreateEntryGroupRequest", "CreateEntryRequest", "CreatePolicyTagRequest", @@ -139,6 +151,7 @@ "DeleteTaxonomyRequest", "Entry", "EntryGroup", + "EntryOverview", "EntryType", "ExportTaxonomiesRequest", "ExportTaxonomiesResponse", @@ -165,6 +178,9 @@ "ListTaxonomiesRequest", "ListTaxonomiesResponse", "LookupEntryRequest", + "ModifyEntryContactsRequest", + "ModifyEntryOverviewRequest", + "PersonalDetails", "PolicyTag", "PolicyTagManagerClient", "PolicyTagManagerSerializationClient", @@ -179,6 +195,8 @@ "SearchResultType", "SerializedPolicyTag", "SerializedTaxonomy", + "StarEntryRequest", + "StarEntryResponse", "SystemTimestamps", "TableSourceType", "TableSpec", @@ -187,6 +205,8 @@ "TagTemplate", "TagTemplateField", "Taxonomy", + "UnstarEntryRequest", + "UnstarEntryResponse", "UpdateEntryGroupRequest", "UpdateEntryRequest", "UpdatePolicyTagRequest", diff --git a/google/cloud/datacatalog_v1/gapic_metadata.json b/google/cloud/datacatalog_v1/gapic_metadata.json index 99e0398a..0ab83696 100644 --- a/google/cloud/datacatalog_v1/gapic_metadata.json +++ b/google/cloud/datacatalog_v1/gapic_metadata.json @@ -100,6 +100,16 @@ "lookup_entry" ] }, + "ModifyEntryContacts": { + "methods": [ + "modify_entry_contacts" + ] + }, + "ModifyEntryOverview": { + "methods": [ + "modify_entry_overview" + ] + }, "RenameTagTemplateField": { "methods": [ "rename_tag_template_field" @@ -120,11 +130,21 @@ "set_iam_policy" ] }, + "StarEntry": { + "methods": [ + "star_entry" + ] + }, "TestIamPermissions": { "methods": [ "test_iam_permissions" ] }, + "UnstarEntry": { + "methods": [ + "unstar_entry" + ] + }, "UpdateEntry": { "methods": [ "update_entry" @@ -245,6 +265,16 @@ "lookup_entry" ] }, + "ModifyEntryContacts": { + "methods": [ + "modify_entry_contacts" + ] + }, + "ModifyEntryOverview": { + "methods": [ + "modify_entry_overview" + ] + }, "RenameTagTemplateField": { "methods": [ "rename_tag_template_field" @@ -265,11 +295,21 @@ "set_iam_policy" ] }, + "StarEntry": { + "methods": [ + "star_entry" + ] + }, "TestIamPermissions": { "methods": [ "test_iam_permissions" ] }, + "UnstarEntry": { + "methods": [ + "unstar_entry" + ] + }, "UpdateEntry": { "methods": [ "update_entry" diff --git a/google/cloud/datacatalog_v1/services/data_catalog/async_client.py b/google/cloud/datacatalog_v1/services/data_catalog/async_client.py index 2b2b99f0..4ef38a1d 100644 --- a/google/cloud/datacatalog_v1/services/data_catalog/async_client.py +++ b/google/cloud/datacatalog_v1/services/data_catalog/async_client.py @@ -255,6 +255,24 @@ async def search_catalog( For more information, see [Data Catalog search syntax] (https://cloud.google.com/data-catalog/docs/how-to/search-reference). + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_search_catalog(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.SearchCatalogRequest( + ) + + # Make the request + page_result = client.search_catalog(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.SearchCatalogRequest, dict]): The request object. Request message for @@ -394,6 +412,27 @@ async def create_entry_group( Catalog resource project `__. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreateEntryGroupRequest( + parent="parent_value", + entry_group_id="entry_group_id_value", + ) + + # Make the request + response = client.create_entry_group(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreateEntryGroupRequest, dict]): The request object. Request message for @@ -495,6 +534,25 @@ async def get_entry_group( ) -> datacatalog.EntryGroup: r"""Gets an entry group. + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = client.get_entry_group(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.GetEntryGroupRequest, dict]): The request object. Request message for @@ -593,6 +651,25 @@ async def update_entry_group( `Data Catalog resource project `__. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdateEntryGroupRequest( + ) + + # Make the request + response = client.update_entry_group(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdateEntryGroupRequest, dict]): The request object. Request message for @@ -688,6 +765,23 @@ async def delete_entry_group( Catalog resource project `__. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = client.delete_entry_group(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeleteEntryGroupRequest, dict]): The request object. Request message for @@ -752,6 +846,24 @@ async def list_entry_groups( ) -> pagers.ListEntryGroupsAsyncPager: r"""Lists entry groups. + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_list_entry_groups(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListEntryGroupsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entry_groups(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ListEntryGroupsRequest, dict]): The request object. Request message for @@ -856,6 +968,33 @@ async def create_entry( An entry group can have a maximum of 100,000 entries. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + entry = datacatalog_v1.Entry() + entry.type_ = "SERVICE" + entry.integrated_system = "DATAPROC_METASTORE" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1.CreateEntryRequest( + parent="parent_value", + entry_id="entry_id_value", + entry=entry, + ) + + # Make the request + response = client.create_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreateEntryRequest, dict]): The request object. Request message for @@ -964,6 +1103,31 @@ async def update_entry( Catalog resource project `__. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + entry = datacatalog_v1.Entry() + entry.type_ = "SERVICE" + entry.integrated_system = "DATAPROC_METASTORE" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1.UpdateEntryRequest( + entry=entry, + ) + + # Make the request + response = client.update_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdateEntryRequest, dict]): The request object. Request message for @@ -1092,6 +1256,23 @@ async def delete_entry( Catalog resource project `__. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteEntryRequest( + name="name_value", + ) + + # Make the request + response = client.delete_entry(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeleteEntryRequest, dict]): The request object. Request message for @@ -1156,6 +1337,25 @@ async def get_entry( ) -> datacatalog.Entry: r"""Gets an entry. + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetEntryRequest( + name="name_value", + ) + + # Make the request + response = client.get_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.GetEntryRequest, dict]): The request object. Request message for @@ -1246,6 +1446,26 @@ async def lookup_entry( The resource name comes from the source Google Cloud Platform service. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_lookup_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.LookupEntryRequest( + linked_resource="linked_resource_value", + ) + + # Make the request + response = client.lookup_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.LookupEntryRequest, dict]): The request object. Request message for @@ -1312,6 +1532,25 @@ async def list_entries( get a list of both custom and automatically created entries, use [SearchCatalog][google.cloud.datacatalog.v1.DataCatalog.SearchCatalog]. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_list_entries(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListEntriesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entries(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ListEntriesRequest, dict]): The request object. Request message for @@ -1391,6 +1630,152 @@ async def list_entries( # Done; return the response. return response + async def modify_entry_overview( + self, + request: Union[datacatalog.ModifyEntryOverviewRequest, dict] = None, + *, + retry: OptionalRetry = gapic_v1.method.DEFAULT, + timeout: float = None, + metadata: Sequence[Tuple[str, str]] = (), + ) -> datacatalog.EntryOverview: + r"""Modifies entry overview, part of the business context of an + [Entry][google.cloud.datacatalog.v1.Entry]. + + To call this method, you must have the + ``datacatalog.entries.updateOverview`` IAM permission on the + corresponding project. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_modify_entry_overview(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ModifyEntryOverviewRequest( + name="name_value", + ) + + # Make the request + response = client.modify_entry_overview(request=request) + + # Handle response + print(response) + + Args: + request (Union[google.cloud.datacatalog_v1.types.ModifyEntryOverviewRequest, dict]): + The request object. Request message for + [ModifyEntryOverview][google.cloud.datacatalog.v1.DataCatalog.ModifyEntryOverview]. + retry (google.api_core.retry.Retry): Designation of what errors, if any, + should be retried. + timeout (float): The timeout for this request. + metadata (Sequence[Tuple[str, str]]): Strings which should be + sent along with the request as metadata. + + Returns: + google.cloud.datacatalog_v1.types.EntryOverview: + Entry overview fields for rich text + descriptions of entries. + + """ + # Create or coerce a protobuf request object. + request = datacatalog.ModifyEntryOverviewRequest(request) + + # Wrap the RPC method; this adds retry and timeout information, + # and friendly error handling. + rpc = gapic_v1.method_async.wrap_method( + self._client._transport.modify_entry_overview, + default_timeout=None, + client_info=DEFAULT_CLIENT_INFO, + ) + + # Certain fields should be provided within the metadata header; + # add these here. + metadata = tuple(metadata) + ( + gapic_v1.routing_header.to_grpc_metadata((("name", request.name),)), + ) + + # Send the request. + response = await rpc(request, retry=retry, timeout=timeout, metadata=metadata,) + + # Done; return the response. + return response + + async def modify_entry_contacts( + self, + request: Union[datacatalog.ModifyEntryContactsRequest, dict] = None, + *, + retry: OptionalRetry = gapic_v1.method.DEFAULT, + timeout: float = None, + metadata: Sequence[Tuple[str, str]] = (), + ) -> datacatalog.Contacts: + r"""Modifies contacts, part of the business context of an + [Entry][google.cloud.datacatalog.v1.Entry]. + + To call this method, you must have the + ``datacatalog.entries.updateContacts`` IAM permission on the + corresponding project. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_modify_entry_contacts(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ModifyEntryContactsRequest( + name="name_value", + ) + + # Make the request + response = client.modify_entry_contacts(request=request) + + # Handle response + print(response) + + Args: + request (Union[google.cloud.datacatalog_v1.types.ModifyEntryContactsRequest, dict]): + The request object. Request message for + [ModifyEntryContacts][google.cloud.datacatalog.v1.DataCatalog.ModifyEntryContacts]. + retry (google.api_core.retry.Retry): Designation of what errors, if any, + should be retried. + timeout (float): The timeout for this request. + metadata (Sequence[Tuple[str, str]]): Strings which should be + sent along with the request as metadata. + + Returns: + google.cloud.datacatalog_v1.types.Contacts: + Contact people for the entry. + """ + # Create or coerce a protobuf request object. + request = datacatalog.ModifyEntryContactsRequest(request) + + # Wrap the RPC method; this adds retry and timeout information, + # and friendly error handling. + rpc = gapic_v1.method_async.wrap_method( + self._client._transport.modify_entry_contacts, + default_timeout=None, + client_info=DEFAULT_CLIENT_INFO, + ) + + # Certain fields should be provided within the metadata header; + # add these here. + metadata = tuple(metadata) + ( + gapic_v1.routing_header.to_grpc_metadata((("name", request.name),)), + ) + + # Send the request. + response = await rpc(request, retry=retry, timeout=timeout, metadata=metadata,) + + # Done; return the response. + return response + async def create_tag_template( self, request: Union[datacatalog.CreateTagTemplateRequest, dict] = None, @@ -1409,6 +1794,27 @@ async def create_tag_template( Catalog resource project] (https://cloud.google.com/data-catalog/docs/concepts/resource-project). + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreateTagTemplateRequest( + parent="parent_value", + tag_template_id="tag_template_id_value", + ) + + # Make the request + response = client.create_tag_template(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreateTagTemplateRequest, dict]): The request object. Request message for @@ -1510,6 +1916,25 @@ async def get_tag_template( ) -> tags.TagTemplate: r"""Gets a tag template. + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetTagTemplateRequest( + name="name_value", + ) + + # Make the request + response = client.get_tag_template(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.GetTagTemplateRequest, dict]): The request object. Request message for @@ -1600,6 +2025,25 @@ async def update_tag_template( see `Data Catalog resource project `__. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdateTagTemplateRequest( + ) + + # Make the request + response = client.update_tag_template(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdateTagTemplateRequest, dict]): The request object. Request message for @@ -1623,9 +2067,6 @@ async def update_tag_template( Note: Updating the ``is_publicly_readable`` field may require up to 12 hours to take effect in search results. - Additionally, it also requires the - ``tagTemplates.getIamPolicy`` and - ``tagTemplates.setIamPolicy`` permissions. This corresponds to the ``update_mask`` field on the ``request`` instance; if ``request`` is provided, this @@ -1709,6 +2150,24 @@ async def delete_tag_template( Catalog resource project `__. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTagTemplateRequest( + name="name_value", + force=True, + ) + + # Make the request + response = client.delete_tag_template(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeleteTagTemplateRequest, dict]): The request object. Request message for @@ -1791,6 +2250,31 @@ async def create_tag_template_field( Catalog resource project `__. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1.TagTemplateField() + tag_template_field.type_.primitive_type = "RICHTEXT" + + request = datacatalog_v1.CreateTagTemplateFieldRequest( + parent="parent_value", + tag_template_field_id="tag_template_field_id_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = client.create_tag_template_field(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreateTagTemplateFieldRequest, dict]): The request object. Request message for @@ -1898,6 +2382,30 @@ async def update_tag_template_field( Catalog resource project `__. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1.TagTemplateField() + tag_template_field.type_.primitive_type = "RICHTEXT" + + request = datacatalog_v1.UpdateTagTemplateFieldRequest( + name="name_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = client.update_tag_template_field(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdateTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2007,6 +2515,27 @@ async def rename_tag_template_field( Catalog resource project] (https://cloud.google.com/data-catalog/docs/concepts/resource-project). + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_rename_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.RenameTagTemplateFieldRequest( + name="name_value", + new_tag_template_field_id="new_tag_template_field_id_value", + ) + + # Make the request + response = client.rename_tag_template_field(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.RenameTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2089,6 +2618,27 @@ async def rename_tag_template_field_enum_value( r"""Renames an enum value in a tag template. Within a single enum field, enum values must be unique. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_rename_tag_template_field_enum_value(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.RenameTagTemplateFieldEnumValueRequest( + name="name_value", + new_enum_value_display_name="new_enum_value_display_name_value", + ) + + # Make the request + response = client.rename_tag_template_field_enum_value(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.RenameTagTemplateFieldEnumValueRequest, dict]): The request object. Request message for @@ -2176,6 +2726,24 @@ async def delete_tag_template_field( Catalog resource project `__. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTagTemplateFieldRequest( + name="name_value", + force=True, + ) + + # Make the request + response = client.delete_tag_template_field(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeleteTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2266,6 +2834,31 @@ async def create_tag( (https://cloud.google.com/data-catalog/docs/reference/rest/v1/projects.locations.tagTemplates/create#path-parameters) used to create the tag must be in the same organization. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_tag(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + tag = datacatalog_v1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1.CreateTagRequest( + parent="parent_value", + tag=tag, + ) + + # Make the request + response = client.create_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreateTagRequest, dict]): The request object. Request message for @@ -2357,6 +2950,29 @@ async def update_tag( ) -> tags.Tag: r"""Updates an existing tag. + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_tag(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + tag = datacatalog_v1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1.UpdateTagRequest( + tag=tag, + ) + + # Make the request + response = client.update_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdateTagRequest, dict]): The request object. Request message for @@ -2448,6 +3064,22 @@ async def delete_tag( ) -> None: r"""Deletes a tag. + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_tag(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTagRequest( + name="name_value", + ) + + # Make the request + response = client.delete_tag(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeleteTagRequest, dict]): The request object. Request message for @@ -2511,7 +3143,28 @@ async def list_tags( metadata: Sequence[Tuple[str, str]] = (), ) -> pagers.ListTagsAsyncPager: r"""Lists tags assigned to an - [Entry][google.cloud.datacatalog.v1.Entry]. + [Entry][google.cloud.datacatalog.v1.Entry]. The + [columns][google.cloud.datacatalog.v1.Tag.column] in the + response are lowercased. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_list_tags(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_tags(request=request) + for response in page_result: + print(response) Args: request (Union[google.cloud.datacatalog_v1.types.ListTagsRequest, dict]): @@ -2596,6 +3249,194 @@ async def list_tags( # Done; return the response. return response + async def star_entry( + self, + request: Union[datacatalog.StarEntryRequest, dict] = None, + *, + name: str = None, + retry: OptionalRetry = gapic_v1.method.DEFAULT, + timeout: float = None, + metadata: Sequence[Tuple[str, str]] = (), + ) -> datacatalog.StarEntryResponse: + r"""Marks an [Entry][google.cloud.datacatalog.v1.Entry] as starred + by the current user. Starring information is private to each + user. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_star_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.StarEntryRequest( + name="name_value", + ) + + # Make the request + response = client.star_entry(request=request) + + # Handle response + print(response) + + Args: + request (Union[google.cloud.datacatalog_v1.types.StarEntryRequest, dict]): + The request object. Request message for + [StarEntry][google.cloud.datacatalog.v1.DataCatalog.StarEntry]. + name (:class:`str`): + Required. The name of the entry to + mark as starred. + + This corresponds to the ``name`` field + on the ``request`` instance; if ``request`` is provided, this + should not be set. + retry (google.api_core.retry.Retry): Designation of what errors, if any, + should be retried. + timeout (float): The timeout for this request. + metadata (Sequence[Tuple[str, str]]): Strings which should be + sent along with the request as metadata. + + Returns: + google.cloud.datacatalog_v1.types.StarEntryResponse: + Response message for + [StarEntry][google.cloud.datacatalog.v1.DataCatalog.StarEntry]. + Empty for now + + """ + # Create or coerce a protobuf request object. + # Quick check: If we got a request object, we should *not* have + # gotten any keyword arguments that map to the request. + has_flattened_params = any([name]) + if request is not None and has_flattened_params: + raise ValueError( + "If the `request` argument is set, then none of " + "the individual field arguments should be set." + ) + + request = datacatalog.StarEntryRequest(request) + + # If we have keyword arguments corresponding to fields on the + # request, apply these. + if name is not None: + request.name = name + + # Wrap the RPC method; this adds retry and timeout information, + # and friendly error handling. + rpc = gapic_v1.method_async.wrap_method( + self._client._transport.star_entry, + default_timeout=None, + client_info=DEFAULT_CLIENT_INFO, + ) + + # Certain fields should be provided within the metadata header; + # add these here. + metadata = tuple(metadata) + ( + gapic_v1.routing_header.to_grpc_metadata((("name", request.name),)), + ) + + # Send the request. + response = await rpc(request, retry=retry, timeout=timeout, metadata=metadata,) + + # Done; return the response. + return response + + async def unstar_entry( + self, + request: Union[datacatalog.UnstarEntryRequest, dict] = None, + *, + name: str = None, + retry: OptionalRetry = gapic_v1.method.DEFAULT, + timeout: float = None, + metadata: Sequence[Tuple[str, str]] = (), + ) -> datacatalog.UnstarEntryResponse: + r"""Marks an [Entry][google.cloud.datacatalog.v1.Entry] as NOT + starred by the current user. Starring information is private to + each user. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_unstar_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.UnstarEntryRequest( + name="name_value", + ) + + # Make the request + response = client.unstar_entry(request=request) + + # Handle response + print(response) + + Args: + request (Union[google.cloud.datacatalog_v1.types.UnstarEntryRequest, dict]): + The request object. Request message for + [UnstarEntry][google.cloud.datacatalog.v1.DataCatalog.UnstarEntry]. + name (:class:`str`): + Required. The name of the entry to mark as **not** + starred. + + This corresponds to the ``name`` field + on the ``request`` instance; if ``request`` is provided, this + should not be set. + retry (google.api_core.retry.Retry): Designation of what errors, if any, + should be retried. + timeout (float): The timeout for this request. + metadata (Sequence[Tuple[str, str]]): Strings which should be + sent along with the request as metadata. + + Returns: + google.cloud.datacatalog_v1.types.UnstarEntryResponse: + Response message for + [UnstarEntry][google.cloud.datacatalog.v1.DataCatalog.UnstarEntry]. + Empty for now + + """ + # Create or coerce a protobuf request object. + # Quick check: If we got a request object, we should *not* have + # gotten any keyword arguments that map to the request. + has_flattened_params = any([name]) + if request is not None and has_flattened_params: + raise ValueError( + "If the `request` argument is set, then none of " + "the individual field arguments should be set." + ) + + request = datacatalog.UnstarEntryRequest(request) + + # If we have keyword arguments corresponding to fields on the + # request, apply these. + if name is not None: + request.name = name + + # Wrap the RPC method; this adds retry and timeout information, + # and friendly error handling. + rpc = gapic_v1.method_async.wrap_method( + self._client._transport.unstar_entry, + default_timeout=None, + client_info=DEFAULT_CLIENT_INFO, + ) + + # Certain fields should be provided within the metadata header; + # add these here. + metadata = tuple(metadata) + ( + gapic_v1.routing_header.to_grpc_metadata((("name", request.name),)), + ) + + # Send the request. + response = await rpc(request, retry=retry, timeout=timeout, metadata=metadata,) + + # Done; return the response. + return response + async def set_iam_policy( self, request: Union[iam_policy_pb2.SetIamPolicyRequest, dict] = None, @@ -2626,6 +3467,26 @@ async def set_iam_policy( - ``datacatalog.entryGroups.setIamPolicy`` to set policies on entry groups. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.set_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.SetIamPolicyRequest, dict]): The request object. Request message for `SetIamPolicy` @@ -2775,6 +3636,26 @@ async def get_iam_policy( - ``datacatalog.entryGroups.getIamPolicy`` to get policies on entry groups. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.get_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.GetIamPolicyRequest, dict]): The request object. Request message for `GetIamPolicy` @@ -2922,6 +3803,27 @@ async def test_iam_permissions( No Google IAM permissions are required to call this method. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = client.test_iam_permissions(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.TestIamPermissionsRequest, dict]): The request object. Request message for diff --git a/google/cloud/datacatalog_v1/services/data_catalog/client.py b/google/cloud/datacatalog_v1/services/data_catalog/client.py index 05d511b7..6ff07821 100644 --- a/google/cloud/datacatalog_v1/services/data_catalog/client.py +++ b/google/cloud/datacatalog_v1/services/data_catalog/client.py @@ -536,6 +536,25 @@ def search_catalog( For more information, see [Data Catalog search syntax] (https://cloud.google.com/data-catalog/docs/how-to/search-reference). + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_search_catalog(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.SearchCatalogRequest( + ) + + # Make the request + page_result = client.search_catalog(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.SearchCatalogRequest, dict]): The request object. Request message for @@ -666,6 +685,28 @@ def create_entry_group( Catalog resource project `__. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreateEntryGroupRequest( + parent="parent_value", + entry_group_id="entry_group_id_value", + ) + + # Make the request + response = client.create_entry_group(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreateEntryGroupRequest, dict]): The request object. Request message for @@ -767,6 +808,26 @@ def get_entry_group( ) -> datacatalog.EntryGroup: r"""Gets an entry group. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = client.get_entry_group(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.GetEntryGroupRequest, dict]): The request object. Request message for @@ -856,6 +917,26 @@ def update_entry_group( `Data Catalog resource project `__. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdateEntryGroupRequest( + ) + + # Make the request + response = client.update_entry_group(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdateEntryGroupRequest, dict]): The request object. Request message for @@ -951,6 +1032,24 @@ def delete_entry_group( Catalog resource project `__. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = client.delete_entry_group(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeleteEntryGroupRequest, dict]): The request object. Request message for @@ -1015,6 +1114,25 @@ def list_entry_groups( ) -> pagers.ListEntryGroupsPager: r"""Lists entry groups. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_list_entry_groups(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListEntryGroupsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entry_groups(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ListEntryGroupsRequest, dict]): The request object. Request message for @@ -1110,6 +1228,34 @@ def create_entry( An entry group can have a maximum of 100,000 entries. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + entry = datacatalog_v1.Entry() + entry.type_ = "SERVICE" + entry.integrated_system = "DATAPROC_METASTORE" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1.CreateEntryRequest( + parent="parent_value", + entry_id="entry_id_value", + entry=entry, + ) + + # Make the request + response = client.create_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreateEntryRequest, dict]): The request object. Request message for @@ -1218,6 +1364,32 @@ def update_entry( Catalog resource project `__. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + entry = datacatalog_v1.Entry() + entry.type_ = "SERVICE" + entry.integrated_system = "DATAPROC_METASTORE" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1.UpdateEntryRequest( + entry=entry, + ) + + # Make the request + response = client.update_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdateEntryRequest, dict]): The request object. Request message for @@ -1346,6 +1518,24 @@ def delete_entry( Catalog resource project `__. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteEntryRequest( + name="name_value", + ) + + # Make the request + response = client.delete_entry(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeleteEntryRequest, dict]): The request object. Request message for @@ -1410,6 +1600,26 @@ def get_entry( ) -> datacatalog.Entry: r"""Gets an entry. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetEntryRequest( + name="name_value", + ) + + # Make the request + response = client.get_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.GetEntryRequest, dict]): The request object. Request message for @@ -1491,6 +1701,27 @@ def lookup_entry( The resource name comes from the source Google Cloud Platform service. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_lookup_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.LookupEntryRequest( + linked_resource="linked_resource_value", + ) + + # Make the request + response = client.lookup_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.LookupEntryRequest, dict]): The request object. Request message for @@ -1549,6 +1780,26 @@ def list_entries( get a list of both custom and automatically created entries, use [SearchCatalog][google.cloud.datacatalog.v1.DataCatalog.SearchCatalog]. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_list_entries(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListEntriesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entries(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ListEntriesRequest, dict]): The request object. Request message for @@ -1619,6 +1870,156 @@ def list_entries( # Done; return the response. return response + def modify_entry_overview( + self, + request: Union[datacatalog.ModifyEntryOverviewRequest, dict] = None, + *, + retry: OptionalRetry = gapic_v1.method.DEFAULT, + timeout: float = None, + metadata: Sequence[Tuple[str, str]] = (), + ) -> datacatalog.EntryOverview: + r"""Modifies entry overview, part of the business context of an + [Entry][google.cloud.datacatalog.v1.Entry]. + + To call this method, you must have the + ``datacatalog.entries.updateOverview`` IAM permission on the + corresponding project. + + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_modify_entry_overview(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ModifyEntryOverviewRequest( + name="name_value", + ) + + # Make the request + response = client.modify_entry_overview(request=request) + + # Handle response + print(response) + + Args: + request (Union[google.cloud.datacatalog_v1.types.ModifyEntryOverviewRequest, dict]): + The request object. Request message for + [ModifyEntryOverview][google.cloud.datacatalog.v1.DataCatalog.ModifyEntryOverview]. + retry (google.api_core.retry.Retry): Designation of what errors, if any, + should be retried. + timeout (float): The timeout for this request. + metadata (Sequence[Tuple[str, str]]): Strings which should be + sent along with the request as metadata. + + Returns: + google.cloud.datacatalog_v1.types.EntryOverview: + Entry overview fields for rich text + descriptions of entries. + + """ + # Create or coerce a protobuf request object. + # Minor optimization to avoid making a copy if the user passes + # in a datacatalog.ModifyEntryOverviewRequest. + # There's no risk of modifying the input as we've already verified + # there are no flattened fields. + if not isinstance(request, datacatalog.ModifyEntryOverviewRequest): + request = datacatalog.ModifyEntryOverviewRequest(request) + + # Wrap the RPC method; this adds retry and timeout information, + # and friendly error handling. + rpc = self._transport._wrapped_methods[self._transport.modify_entry_overview] + + # Certain fields should be provided within the metadata header; + # add these here. + metadata = tuple(metadata) + ( + gapic_v1.routing_header.to_grpc_metadata((("name", request.name),)), + ) + + # Send the request. + response = rpc(request, retry=retry, timeout=timeout, metadata=metadata,) + + # Done; return the response. + return response + + def modify_entry_contacts( + self, + request: Union[datacatalog.ModifyEntryContactsRequest, dict] = None, + *, + retry: OptionalRetry = gapic_v1.method.DEFAULT, + timeout: float = None, + metadata: Sequence[Tuple[str, str]] = (), + ) -> datacatalog.Contacts: + r"""Modifies contacts, part of the business context of an + [Entry][google.cloud.datacatalog.v1.Entry]. + + To call this method, you must have the + ``datacatalog.entries.updateContacts`` IAM permission on the + corresponding project. + + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_modify_entry_contacts(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ModifyEntryContactsRequest( + name="name_value", + ) + + # Make the request + response = client.modify_entry_contacts(request=request) + + # Handle response + print(response) + + Args: + request (Union[google.cloud.datacatalog_v1.types.ModifyEntryContactsRequest, dict]): + The request object. Request message for + [ModifyEntryContacts][google.cloud.datacatalog.v1.DataCatalog.ModifyEntryContacts]. + retry (google.api_core.retry.Retry): Designation of what errors, if any, + should be retried. + timeout (float): The timeout for this request. + metadata (Sequence[Tuple[str, str]]): Strings which should be + sent along with the request as metadata. + + Returns: + google.cloud.datacatalog_v1.types.Contacts: + Contact people for the entry. + """ + # Create or coerce a protobuf request object. + # Minor optimization to avoid making a copy if the user passes + # in a datacatalog.ModifyEntryContactsRequest. + # There's no risk of modifying the input as we've already verified + # there are no flattened fields. + if not isinstance(request, datacatalog.ModifyEntryContactsRequest): + request = datacatalog.ModifyEntryContactsRequest(request) + + # Wrap the RPC method; this adds retry and timeout information, + # and friendly error handling. + rpc = self._transport._wrapped_methods[self._transport.modify_entry_contacts] + + # Certain fields should be provided within the metadata header; + # add these here. + metadata = tuple(metadata) + ( + gapic_v1.routing_header.to_grpc_metadata((("name", request.name),)), + ) + + # Send the request. + response = rpc(request, retry=retry, timeout=timeout, metadata=metadata,) + + # Done; return the response. + return response + def create_tag_template( self, request: Union[datacatalog.CreateTagTemplateRequest, dict] = None, @@ -1637,6 +2038,28 @@ def create_tag_template( Catalog resource project] (https://cloud.google.com/data-catalog/docs/concepts/resource-project). + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreateTagTemplateRequest( + parent="parent_value", + tag_template_id="tag_template_id_value", + ) + + # Make the request + response = client.create_tag_template(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreateTagTemplateRequest, dict]): The request object. Request message for @@ -1738,6 +2161,26 @@ def get_tag_template( ) -> tags.TagTemplate: r"""Gets a tag template. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetTagTemplateRequest( + name="name_value", + ) + + # Make the request + response = client.get_tag_template(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.GetTagTemplateRequest, dict]): The request object. Request message for @@ -1828,6 +2271,26 @@ def update_tag_template( see `Data Catalog resource project `__. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdateTagTemplateRequest( + ) + + # Make the request + response = client.update_tag_template(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdateTagTemplateRequest, dict]): The request object. Request message for @@ -1851,9 +2314,6 @@ def update_tag_template( Note: Updating the ``is_publicly_readable`` field may require up to 12 hours to take effect in search results. - Additionally, it also requires the - ``tagTemplates.getIamPolicy`` and - ``tagTemplates.setIamPolicy`` permissions. This corresponds to the ``update_mask`` field on the ``request`` instance; if ``request`` is provided, this @@ -1937,6 +2397,25 @@ def delete_tag_template( Catalog resource project `__. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTagTemplateRequest( + name="name_value", + force=True, + ) + + # Make the request + response = client.delete_tag_template(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeleteTagTemplateRequest, dict]): The request object. Request message for @@ -2019,6 +2498,32 @@ def create_tag_template_field( Catalog resource project `__. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1.TagTemplateField() + tag_template_field.type_.primitive_type = "RICHTEXT" + + request = datacatalog_v1.CreateTagTemplateFieldRequest( + parent="parent_value", + tag_template_field_id="tag_template_field_id_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = client.create_tag_template_field(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreateTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2128,6 +2633,31 @@ def update_tag_template_field( Catalog resource project `__. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1.TagTemplateField() + tag_template_field.type_.primitive_type = "RICHTEXT" + + request = datacatalog_v1.UpdateTagTemplateFieldRequest( + name="name_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = client.update_tag_template_field(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdateTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2239,6 +2769,28 @@ def rename_tag_template_field( Catalog resource project] (https://cloud.google.com/data-catalog/docs/concepts/resource-project). + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_rename_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.RenameTagTemplateFieldRequest( + name="name_value", + new_tag_template_field_id="new_tag_template_field_id_value", + ) + + # Make the request + response = client.rename_tag_template_field(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.RenameTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2323,6 +2875,28 @@ def rename_tag_template_field_enum_value( r"""Renames an enum value in a tag template. Within a single enum field, enum values must be unique. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_rename_tag_template_field_enum_value(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.RenameTagTemplateFieldEnumValueRequest( + name="name_value", + new_enum_value_display_name="new_enum_value_display_name_value", + ) + + # Make the request + response = client.rename_tag_template_field_enum_value(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.RenameTagTemplateFieldEnumValueRequest, dict]): The request object. Request message for @@ -2412,6 +2986,25 @@ def delete_tag_template_field( Catalog resource project `__. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTagTemplateFieldRequest( + name="name_value", + force=True, + ) + + # Make the request + response = client.delete_tag_template_field(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeleteTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2504,6 +3097,32 @@ def create_tag( (https://cloud.google.com/data-catalog/docs/reference/rest/v1/projects.locations.tagTemplates/create#path-parameters) used to create the tag must be in the same organization. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_tag(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + tag = datacatalog_v1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1.CreateTagRequest( + parent="parent_value", + tag=tag, + ) + + # Make the request + response = client.create_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreateTagRequest, dict]): The request object. Request message for @@ -2595,6 +3214,30 @@ def update_tag( ) -> tags.Tag: r"""Updates an existing tag. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_tag(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + tag = datacatalog_v1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1.UpdateTagRequest( + tag=tag, + ) + + # Make the request + response = client.update_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdateTagRequest, dict]): The request object. Request message for @@ -2686,6 +3329,23 @@ def delete_tag( ) -> None: r"""Deletes a tag. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_tag(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTagRequest( + name="name_value", + ) + + # Make the request + response = client.delete_tag(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeleteTagRequest, dict]): The request object. Request message for @@ -2749,7 +3409,29 @@ def list_tags( metadata: Sequence[Tuple[str, str]] = (), ) -> pagers.ListTagsPager: r"""Lists tags assigned to an - [Entry][google.cloud.datacatalog.v1.Entry]. + [Entry][google.cloud.datacatalog.v1.Entry]. The + [columns][google.cloud.datacatalog.v1.Tag.column] in the + response are lowercased. + + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_list_tags(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_tags(request=request) + for response in page_result: + print(response) Args: request (Union[google.cloud.datacatalog_v1.types.ListTagsRequest, dict]): @@ -2825,6 +3507,196 @@ def list_tags( # Done; return the response. return response + def star_entry( + self, + request: Union[datacatalog.StarEntryRequest, dict] = None, + *, + name: str = None, + retry: OptionalRetry = gapic_v1.method.DEFAULT, + timeout: float = None, + metadata: Sequence[Tuple[str, str]] = (), + ) -> datacatalog.StarEntryResponse: + r"""Marks an [Entry][google.cloud.datacatalog.v1.Entry] as starred + by the current user. Starring information is private to each + user. + + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_star_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.StarEntryRequest( + name="name_value", + ) + + # Make the request + response = client.star_entry(request=request) + + # Handle response + print(response) + + Args: + request (Union[google.cloud.datacatalog_v1.types.StarEntryRequest, dict]): + The request object. Request message for + [StarEntry][google.cloud.datacatalog.v1.DataCatalog.StarEntry]. + name (str): + Required. The name of the entry to + mark as starred. + + This corresponds to the ``name`` field + on the ``request`` instance; if ``request`` is provided, this + should not be set. + retry (google.api_core.retry.Retry): Designation of what errors, if any, + should be retried. + timeout (float): The timeout for this request. + metadata (Sequence[Tuple[str, str]]): Strings which should be + sent along with the request as metadata. + + Returns: + google.cloud.datacatalog_v1.types.StarEntryResponse: + Response message for + [StarEntry][google.cloud.datacatalog.v1.DataCatalog.StarEntry]. + Empty for now + + """ + # Create or coerce a protobuf request object. + # Quick check: If we got a request object, we should *not* have + # gotten any keyword arguments that map to the request. + has_flattened_params = any([name]) + if request is not None and has_flattened_params: + raise ValueError( + "If the `request` argument is set, then none of " + "the individual field arguments should be set." + ) + + # Minor optimization to avoid making a copy if the user passes + # in a datacatalog.StarEntryRequest. + # There's no risk of modifying the input as we've already verified + # there are no flattened fields. + if not isinstance(request, datacatalog.StarEntryRequest): + request = datacatalog.StarEntryRequest(request) + # If we have keyword arguments corresponding to fields on the + # request, apply these. + if name is not None: + request.name = name + + # Wrap the RPC method; this adds retry and timeout information, + # and friendly error handling. + rpc = self._transport._wrapped_methods[self._transport.star_entry] + + # Certain fields should be provided within the metadata header; + # add these here. + metadata = tuple(metadata) + ( + gapic_v1.routing_header.to_grpc_metadata((("name", request.name),)), + ) + + # Send the request. + response = rpc(request, retry=retry, timeout=timeout, metadata=metadata,) + + # Done; return the response. + return response + + def unstar_entry( + self, + request: Union[datacatalog.UnstarEntryRequest, dict] = None, + *, + name: str = None, + retry: OptionalRetry = gapic_v1.method.DEFAULT, + timeout: float = None, + metadata: Sequence[Tuple[str, str]] = (), + ) -> datacatalog.UnstarEntryResponse: + r"""Marks an [Entry][google.cloud.datacatalog.v1.Entry] as NOT + starred by the current user. Starring information is private to + each user. + + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_unstar_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.UnstarEntryRequest( + name="name_value", + ) + + # Make the request + response = client.unstar_entry(request=request) + + # Handle response + print(response) + + Args: + request (Union[google.cloud.datacatalog_v1.types.UnstarEntryRequest, dict]): + The request object. Request message for + [UnstarEntry][google.cloud.datacatalog.v1.DataCatalog.UnstarEntry]. + name (str): + Required. The name of the entry to mark as **not** + starred. + + This corresponds to the ``name`` field + on the ``request`` instance; if ``request`` is provided, this + should not be set. + retry (google.api_core.retry.Retry): Designation of what errors, if any, + should be retried. + timeout (float): The timeout for this request. + metadata (Sequence[Tuple[str, str]]): Strings which should be + sent along with the request as metadata. + + Returns: + google.cloud.datacatalog_v1.types.UnstarEntryResponse: + Response message for + [UnstarEntry][google.cloud.datacatalog.v1.DataCatalog.UnstarEntry]. + Empty for now + + """ + # Create or coerce a protobuf request object. + # Quick check: If we got a request object, we should *not* have + # gotten any keyword arguments that map to the request. + has_flattened_params = any([name]) + if request is not None and has_flattened_params: + raise ValueError( + "If the `request` argument is set, then none of " + "the individual field arguments should be set." + ) + + # Minor optimization to avoid making a copy if the user passes + # in a datacatalog.UnstarEntryRequest. + # There's no risk of modifying the input as we've already verified + # there are no flattened fields. + if not isinstance(request, datacatalog.UnstarEntryRequest): + request = datacatalog.UnstarEntryRequest(request) + # If we have keyword arguments corresponding to fields on the + # request, apply these. + if name is not None: + request.name = name + + # Wrap the RPC method; this adds retry and timeout information, + # and friendly error handling. + rpc = self._transport._wrapped_methods[self._transport.unstar_entry] + + # Certain fields should be provided within the metadata header; + # add these here. + metadata = tuple(metadata) + ( + gapic_v1.routing_header.to_grpc_metadata((("name", request.name),)), + ) + + # Send the request. + response = rpc(request, retry=retry, timeout=timeout, metadata=metadata,) + + # Done; return the response. + return response + def set_iam_policy( self, request: Union[iam_policy_pb2.SetIamPolicyRequest, dict] = None, @@ -2855,6 +3727,27 @@ def set_iam_policy( - ``datacatalog.entryGroups.setIamPolicy`` to set policies on entry groups. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.set_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.SetIamPolicyRequest, dict]): The request object. Request message for `SetIamPolicy` @@ -3003,6 +3896,27 @@ def get_iam_policy( - ``datacatalog.entryGroups.getIamPolicy`` to get policies on entry groups. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.get_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.GetIamPolicyRequest, dict]): The request object. Request message for `GetIamPolicy` @@ -3140,6 +4054,28 @@ def test_iam_permissions( No Google IAM permissions are required to call this method. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = client.test_iam_permissions(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.TestIamPermissionsRequest, dict]): The request object. Request message for diff --git a/google/cloud/datacatalog_v1/services/data_catalog/transports/base.py b/google/cloud/datacatalog_v1/services/data_catalog/transports/base.py index fe2ae712..d6c52cfe 100644 --- a/google/cloud/datacatalog_v1/services/data_catalog/transports/base.py +++ b/google/cloud/datacatalog_v1/services/data_catalog/transports/base.py @@ -226,6 +226,16 @@ def _prep_wrapped_messages(self, client_info): default_timeout=60.0, client_info=client_info, ), + self.modify_entry_overview: gapic_v1.method.wrap_method( + self.modify_entry_overview, + default_timeout=None, + client_info=client_info, + ), + self.modify_entry_contacts: gapic_v1.method.wrap_method( + self.modify_entry_contacts, + default_timeout=None, + client_info=client_info, + ), self.create_tag_template: gapic_v1.method.wrap_method( self.create_tag_template, default_timeout=None, client_info=client_info, ), @@ -286,6 +296,12 @@ def _prep_wrapped_messages(self, client_info): default_timeout=60.0, client_info=client_info, ), + self.star_entry: gapic_v1.method.wrap_method( + self.star_entry, default_timeout=None, client_info=client_info, + ), + self.unstar_entry: gapic_v1.method.wrap_method( + self.unstar_entry, default_timeout=None, client_info=client_info, + ), self.set_iam_policy: gapic_v1.method.wrap_method( self.set_iam_policy, default_timeout=None, client_info=client_info, ), @@ -435,6 +451,24 @@ def list_entries( ]: raise NotImplementedError() + @property + def modify_entry_overview( + self, + ) -> Callable[ + [datacatalog.ModifyEntryOverviewRequest], + Union[datacatalog.EntryOverview, Awaitable[datacatalog.EntryOverview]], + ]: + raise NotImplementedError() + + @property + def modify_entry_contacts( + self, + ) -> Callable[ + [datacatalog.ModifyEntryContactsRequest], + Union[datacatalog.Contacts, Awaitable[datacatalog.Contacts]], + ]: + raise NotImplementedError() + @property def create_tag_template( self, @@ -546,6 +580,26 @@ def list_tags( ]: raise NotImplementedError() + @property + def star_entry( + self, + ) -> Callable[ + [datacatalog.StarEntryRequest], + Union[datacatalog.StarEntryResponse, Awaitable[datacatalog.StarEntryResponse]], + ]: + raise NotImplementedError() + + @property + def unstar_entry( + self, + ) -> Callable[ + [datacatalog.UnstarEntryRequest], + Union[ + datacatalog.UnstarEntryResponse, Awaitable[datacatalog.UnstarEntryResponse] + ], + ]: + raise NotImplementedError() + @property def set_iam_policy( self, diff --git a/google/cloud/datacatalog_v1/services/data_catalog/transports/grpc.py b/google/cloud/datacatalog_v1/services/data_catalog/transports/grpc.py index aac8adcc..ad936f65 100644 --- a/google/cloud/datacatalog_v1/services/data_catalog/transports/grpc.py +++ b/google/cloud/datacatalog_v1/services/data_catalog/transports/grpc.py @@ -633,6 +633,68 @@ def list_entries( ) return self._stubs["list_entries"] + @property + def modify_entry_overview( + self, + ) -> Callable[[datacatalog.ModifyEntryOverviewRequest], datacatalog.EntryOverview]: + r"""Return a callable for the modify entry overview method over gRPC. + + Modifies entry overview, part of the business context of an + [Entry][google.cloud.datacatalog.v1.Entry]. + + To call this method, you must have the + ``datacatalog.entries.updateOverview`` IAM permission on the + corresponding project. + + Returns: + Callable[[~.ModifyEntryOverviewRequest], + ~.EntryOverview]: + A function that, when called, will call the underlying RPC + on the server. + """ + # Generate a "stub function" on-the-fly which will actually make + # the request. + # gRPC handles serialization and deserialization, so we just need + # to pass in the functions for each. + if "modify_entry_overview" not in self._stubs: + self._stubs["modify_entry_overview"] = self.grpc_channel.unary_unary( + "/google.cloud.datacatalog.v1.DataCatalog/ModifyEntryOverview", + request_serializer=datacatalog.ModifyEntryOverviewRequest.serialize, + response_deserializer=datacatalog.EntryOverview.deserialize, + ) + return self._stubs["modify_entry_overview"] + + @property + def modify_entry_contacts( + self, + ) -> Callable[[datacatalog.ModifyEntryContactsRequest], datacatalog.Contacts]: + r"""Return a callable for the modify entry contacts method over gRPC. + + Modifies contacts, part of the business context of an + [Entry][google.cloud.datacatalog.v1.Entry]. + + To call this method, you must have the + ``datacatalog.entries.updateContacts`` IAM permission on the + corresponding project. + + Returns: + Callable[[~.ModifyEntryContactsRequest], + ~.Contacts]: + A function that, when called, will call the underlying RPC + on the server. + """ + # Generate a "stub function" on-the-fly which will actually make + # the request. + # gRPC handles serialization and deserialization, so we just need + # to pass in the functions for each. + if "modify_entry_contacts" not in self._stubs: + self._stubs["modify_entry_contacts"] = self.grpc_channel.unary_unary( + "/google.cloud.datacatalog.v1.DataCatalog/ModifyEntryContacts", + request_serializer=datacatalog.ModifyEntryContactsRequest.serialize, + response_deserializer=datacatalog.Contacts.deserialize, + ) + return self._stubs["modify_entry_contacts"] + @property def create_tag_template( self, @@ -1008,7 +1070,9 @@ def list_tags( r"""Return a callable for the list tags method over gRPC. Lists tags assigned to an - [Entry][google.cloud.datacatalog.v1.Entry]. + [Entry][google.cloud.datacatalog.v1.Entry]. The + [columns][google.cloud.datacatalog.v1.Tag.column] in the + response are lowercased. Returns: Callable[[~.ListTagsRequest], @@ -1028,6 +1092,62 @@ def list_tags( ) return self._stubs["list_tags"] + @property + def star_entry( + self, + ) -> Callable[[datacatalog.StarEntryRequest], datacatalog.StarEntryResponse]: + r"""Return a callable for the star entry method over gRPC. + + Marks an [Entry][google.cloud.datacatalog.v1.Entry] as starred + by the current user. Starring information is private to each + user. + + Returns: + Callable[[~.StarEntryRequest], + ~.StarEntryResponse]: + A function that, when called, will call the underlying RPC + on the server. + """ + # Generate a "stub function" on-the-fly which will actually make + # the request. + # gRPC handles serialization and deserialization, so we just need + # to pass in the functions for each. + if "star_entry" not in self._stubs: + self._stubs["star_entry"] = self.grpc_channel.unary_unary( + "/google.cloud.datacatalog.v1.DataCatalog/StarEntry", + request_serializer=datacatalog.StarEntryRequest.serialize, + response_deserializer=datacatalog.StarEntryResponse.deserialize, + ) + return self._stubs["star_entry"] + + @property + def unstar_entry( + self, + ) -> Callable[[datacatalog.UnstarEntryRequest], datacatalog.UnstarEntryResponse]: + r"""Return a callable for the unstar entry method over gRPC. + + Marks an [Entry][google.cloud.datacatalog.v1.Entry] as NOT + starred by the current user. Starring information is private to + each user. + + Returns: + Callable[[~.UnstarEntryRequest], + ~.UnstarEntryResponse]: + A function that, when called, will call the underlying RPC + on the server. + """ + # Generate a "stub function" on-the-fly which will actually make + # the request. + # gRPC handles serialization and deserialization, so we just need + # to pass in the functions for each. + if "unstar_entry" not in self._stubs: + self._stubs["unstar_entry"] = self.grpc_channel.unary_unary( + "/google.cloud.datacatalog.v1.DataCatalog/UnstarEntry", + request_serializer=datacatalog.UnstarEntryRequest.serialize, + response_deserializer=datacatalog.UnstarEntryResponse.deserialize, + ) + return self._stubs["unstar_entry"] + @property def set_iam_policy( self, diff --git a/google/cloud/datacatalog_v1/services/data_catalog/transports/grpc_asyncio.py b/google/cloud/datacatalog_v1/services/data_catalog/transports/grpc_asyncio.py index 1f754ec0..8c0a6291 100644 --- a/google/cloud/datacatalog_v1/services/data_catalog/transports/grpc_asyncio.py +++ b/google/cloud/datacatalog_v1/services/data_catalog/transports/grpc_asyncio.py @@ -646,6 +646,72 @@ def list_entries( ) return self._stubs["list_entries"] + @property + def modify_entry_overview( + self, + ) -> Callable[ + [datacatalog.ModifyEntryOverviewRequest], Awaitable[datacatalog.EntryOverview] + ]: + r"""Return a callable for the modify entry overview method over gRPC. + + Modifies entry overview, part of the business context of an + [Entry][google.cloud.datacatalog.v1.Entry]. + + To call this method, you must have the + ``datacatalog.entries.updateOverview`` IAM permission on the + corresponding project. + + Returns: + Callable[[~.ModifyEntryOverviewRequest], + Awaitable[~.EntryOverview]]: + A function that, when called, will call the underlying RPC + on the server. + """ + # Generate a "stub function" on-the-fly which will actually make + # the request. + # gRPC handles serialization and deserialization, so we just need + # to pass in the functions for each. + if "modify_entry_overview" not in self._stubs: + self._stubs["modify_entry_overview"] = self.grpc_channel.unary_unary( + "/google.cloud.datacatalog.v1.DataCatalog/ModifyEntryOverview", + request_serializer=datacatalog.ModifyEntryOverviewRequest.serialize, + response_deserializer=datacatalog.EntryOverview.deserialize, + ) + return self._stubs["modify_entry_overview"] + + @property + def modify_entry_contacts( + self, + ) -> Callable[ + [datacatalog.ModifyEntryContactsRequest], Awaitable[datacatalog.Contacts] + ]: + r"""Return a callable for the modify entry contacts method over gRPC. + + Modifies contacts, part of the business context of an + [Entry][google.cloud.datacatalog.v1.Entry]. + + To call this method, you must have the + ``datacatalog.entries.updateContacts`` IAM permission on the + corresponding project. + + Returns: + Callable[[~.ModifyEntryContactsRequest], + Awaitable[~.Contacts]]: + A function that, when called, will call the underlying RPC + on the server. + """ + # Generate a "stub function" on-the-fly which will actually make + # the request. + # gRPC handles serialization and deserialization, so we just need + # to pass in the functions for each. + if "modify_entry_contacts" not in self._stubs: + self._stubs["modify_entry_contacts"] = self.grpc_channel.unary_unary( + "/google.cloud.datacatalog.v1.DataCatalog/ModifyEntryContacts", + request_serializer=datacatalog.ModifyEntryContactsRequest.serialize, + response_deserializer=datacatalog.Contacts.deserialize, + ) + return self._stubs["modify_entry_contacts"] + @property def create_tag_template( self, @@ -1038,7 +1104,9 @@ def list_tags( r"""Return a callable for the list tags method over gRPC. Lists tags assigned to an - [Entry][google.cloud.datacatalog.v1.Entry]. + [Entry][google.cloud.datacatalog.v1.Entry]. The + [columns][google.cloud.datacatalog.v1.Tag.column] in the + response are lowercased. Returns: Callable[[~.ListTagsRequest], @@ -1058,6 +1126,66 @@ def list_tags( ) return self._stubs["list_tags"] + @property + def star_entry( + self, + ) -> Callable[ + [datacatalog.StarEntryRequest], Awaitable[datacatalog.StarEntryResponse] + ]: + r"""Return a callable for the star entry method over gRPC. + + Marks an [Entry][google.cloud.datacatalog.v1.Entry] as starred + by the current user. Starring information is private to each + user. + + Returns: + Callable[[~.StarEntryRequest], + Awaitable[~.StarEntryResponse]]: + A function that, when called, will call the underlying RPC + on the server. + """ + # Generate a "stub function" on-the-fly which will actually make + # the request. + # gRPC handles serialization and deserialization, so we just need + # to pass in the functions for each. + if "star_entry" not in self._stubs: + self._stubs["star_entry"] = self.grpc_channel.unary_unary( + "/google.cloud.datacatalog.v1.DataCatalog/StarEntry", + request_serializer=datacatalog.StarEntryRequest.serialize, + response_deserializer=datacatalog.StarEntryResponse.deserialize, + ) + return self._stubs["star_entry"] + + @property + def unstar_entry( + self, + ) -> Callable[ + [datacatalog.UnstarEntryRequest], Awaitable[datacatalog.UnstarEntryResponse] + ]: + r"""Return a callable for the unstar entry method over gRPC. + + Marks an [Entry][google.cloud.datacatalog.v1.Entry] as NOT + starred by the current user. Starring information is private to + each user. + + Returns: + Callable[[~.UnstarEntryRequest], + Awaitable[~.UnstarEntryResponse]]: + A function that, when called, will call the underlying RPC + on the server. + """ + # Generate a "stub function" on-the-fly which will actually make + # the request. + # gRPC handles serialization and deserialization, so we just need + # to pass in the functions for each. + if "unstar_entry" not in self._stubs: + self._stubs["unstar_entry"] = self.grpc_channel.unary_unary( + "/google.cloud.datacatalog.v1.DataCatalog/UnstarEntry", + request_serializer=datacatalog.UnstarEntryRequest.serialize, + response_deserializer=datacatalog.UnstarEntryResponse.deserialize, + ) + return self._stubs["unstar_entry"] + @property def set_iam_policy( self, diff --git a/google/cloud/datacatalog_v1/services/policy_tag_manager/async_client.py b/google/cloud/datacatalog_v1/services/policy_tag_manager/async_client.py index 8361308d..a29356b3 100644 --- a/google/cloud/datacatalog_v1/services/policy_tag_manager/async_client.py +++ b/google/cloud/datacatalog_v1/services/policy_tag_manager/async_client.py @@ -227,6 +227,26 @@ async def create_taxonomy( The taxonomy is initially empty, that is, it doesn't contain policy tags. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreateTaxonomyRequest( + parent="parent_value", + ) + + # Make the request + response = client.create_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreateTaxonomyRequest, dict]): The request object. Request message for @@ -318,6 +338,23 @@ async def delete_taxonomy( taxonomy, their associated policies, and the policy tags references from BigQuery columns. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = client.delete_taxonomy(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeleteTaxonomyRequest, dict]): The request object. Request message for @@ -385,6 +422,25 @@ async def update_taxonomy( r"""Updates a taxonomy, including its display name, description, and activated policy types. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdateTaxonomyRequest( + ) + + # Make the request + response = client.update_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdateTaxonomyRequest, dict]): The request object. Request message for @@ -470,6 +526,25 @@ async def list_taxonomies( r"""Lists all taxonomies in a project in a particular location that you have a permission to view. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_list_taxonomies(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListTaxonomiesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_taxonomies(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ListTaxonomiesRequest, dict]): The request object. Request message for @@ -550,6 +625,25 @@ async def get_taxonomy( ) -> policytagmanager.Taxonomy: r"""Gets a taxonomy. + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = client.get_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.GetTaxonomyRequest, dict]): The request object. Request message for @@ -632,6 +726,25 @@ async def create_policy_tag( ) -> policytagmanager.PolicyTag: r"""Creates a policy tag in a taxonomy. + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreatePolicyTagRequest( + parent="parent_value", + ) + + # Make the request + response = client.create_policy_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreatePolicyTagRequest, dict]): The request object. Request message for @@ -723,6 +836,23 @@ async def delete_policy_tag( - References from BigQuery table schema of the policy tag and its descendants + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeletePolicyTagRequest( + name="name_value", + ) + + # Make the request + response = client.delete_policy_tag(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeletePolicyTagRequest, dict]): The request object. Request message for @@ -790,6 +920,25 @@ async def update_policy_tag( r"""Updates a policy tag, including its display name, description, and parent policy tag. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdatePolicyTagRequest( + ) + + # Make the request + response = client.update_policy_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdatePolicyTagRequest, dict]): The request object. Request message for @@ -871,6 +1020,24 @@ async def list_policy_tags( ) -> pagers.ListPolicyTagsAsyncPager: r"""Lists all policy tags in a taxonomy. + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_list_policy_tags(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListPolicyTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_policy_tags(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ListPolicyTagsRequest, dict]): The request object. Request message for @@ -951,6 +1118,25 @@ async def get_policy_tag( ) -> policytagmanager.PolicyTag: r"""Gets a policy tag. + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetPolicyTagRequest( + name="name_value", + ) + + # Make the request + response = client.get_policy_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.GetPolicyTagRequest, dict]): The request object. Request message for @@ -1028,6 +1214,25 @@ async def get_iam_policy( ) -> policy_pb2.Policy: r"""Gets the IAM policy for a policy tag or a taxonomy. + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.get_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.GetIamPolicyRequest, dict]): The request object. Request message for `GetIamPolicy` @@ -1133,6 +1338,25 @@ async def set_iam_policy( ) -> policy_pb2.Policy: r"""Sets the IAM policy for a policy tag or a taxonomy. + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.set_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.SetIamPolicyRequest, dict]): The request object. Request message for `SetIamPolicy` @@ -1239,6 +1463,27 @@ async def test_iam_permissions( r"""Returns your permissions on a specified policy tag or taxonomy. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = client.test_iam_permissions(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.TestIamPermissionsRequest, dict]): The request object. Request message for diff --git a/google/cloud/datacatalog_v1/services/policy_tag_manager/client.py b/google/cloud/datacatalog_v1/services/policy_tag_manager/client.py index 23ddc5ee..529261f5 100644 --- a/google/cloud/datacatalog_v1/services/policy_tag_manager/client.py +++ b/google/cloud/datacatalog_v1/services/policy_tag_manager/client.py @@ -443,6 +443,27 @@ def create_taxonomy( The taxonomy is initially empty, that is, it doesn't contain policy tags. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreateTaxonomyRequest( + parent="parent_value", + ) + + # Make the request + response = client.create_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreateTaxonomyRequest, dict]): The request object. Request message for @@ -534,6 +555,24 @@ def delete_taxonomy( taxonomy, their associated policies, and the policy tags references from BigQuery columns. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = client.delete_taxonomy(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeleteTaxonomyRequest, dict]): The request object. Request message for @@ -601,6 +640,26 @@ def update_taxonomy( r"""Updates a taxonomy, including its display name, description, and activated policy types. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdateTaxonomyRequest( + ) + + # Make the request + response = client.update_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdateTaxonomyRequest, dict]): The request object. Request message for @@ -686,6 +745,26 @@ def list_taxonomies( r"""Lists all taxonomies in a project in a particular location that you have a permission to view. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_list_taxonomies(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListTaxonomiesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_taxonomies(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ListTaxonomiesRequest, dict]): The request object. Request message for @@ -766,6 +845,26 @@ def get_taxonomy( ) -> policytagmanager.Taxonomy: r"""Gets a taxonomy. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = client.get_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.GetTaxonomyRequest, dict]): The request object. Request message for @@ -848,6 +947,26 @@ def create_policy_tag( ) -> policytagmanager.PolicyTag: r"""Creates a policy tag in a taxonomy. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_create_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreatePolicyTagRequest( + parent="parent_value", + ) + + # Make the request + response = client.create_policy_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.CreatePolicyTagRequest, dict]): The request object. Request message for @@ -939,6 +1058,24 @@ def delete_policy_tag( - References from BigQuery table schema of the policy tag and its descendants + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_delete_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeletePolicyTagRequest( + name="name_value", + ) + + # Make the request + response = client.delete_policy_tag(request=request) + Args: request (Union[google.cloud.datacatalog_v1.types.DeletePolicyTagRequest, dict]): The request object. Request message for @@ -1006,6 +1143,26 @@ def update_policy_tag( r"""Updates a policy tag, including its display name, description, and parent policy tag. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_update_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdatePolicyTagRequest( + ) + + # Make the request + response = client.update_policy_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.UpdatePolicyTagRequest, dict]): The request object. Request message for @@ -1087,6 +1244,25 @@ def list_policy_tags( ) -> pagers.ListPolicyTagsPager: r"""Lists all policy tags in a taxonomy. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_list_policy_tags(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListPolicyTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_policy_tags(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ListPolicyTagsRequest, dict]): The request object. Request message for @@ -1167,6 +1343,26 @@ def get_policy_tag( ) -> policytagmanager.PolicyTag: r"""Gets a policy tag. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetPolicyTagRequest( + name="name_value", + ) + + # Make the request + response = client.get_policy_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.GetPolicyTagRequest, dict]): The request object. Request message for @@ -1244,6 +1440,26 @@ def get_iam_policy( ) -> policy_pb2.Policy: r"""Gets the IAM policy for a policy tag or a taxonomy. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.get_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.GetIamPolicyRequest, dict]): The request object. Request message for `GetIamPolicy` @@ -1348,6 +1564,26 @@ def set_iam_policy( ) -> policy_pb2.Policy: r"""Sets the IAM policy for a policy tag or a taxonomy. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.set_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.SetIamPolicyRequest, dict]): The request object. Request message for `SetIamPolicy` @@ -1453,6 +1689,28 @@ def test_iam_permissions( r"""Returns your permissions on a specified policy tag or taxonomy. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = client.test_iam_permissions(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.TestIamPermissionsRequest, dict]): The request object. Request message for diff --git a/google/cloud/datacatalog_v1/services/policy_tag_manager_serialization/async_client.py b/google/cloud/datacatalog_v1/services/policy_tag_manager_serialization/async_client.py index 486a22b5..c9c11788 100644 --- a/google/cloud/datacatalog_v1/services/policy_tag_manager_serialization/async_client.py +++ b/google/cloud/datacatalog_v1/services/policy_tag_manager_serialization/async_client.py @@ -240,6 +240,30 @@ async def replace_taxonomy( considered new. - Updates policy tags with valid resources names accordingly. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_replace_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + serialized_taxonomy = datacatalog_v1.SerializedTaxonomy() + serialized_taxonomy.display_name = "display_name_value" + + request = datacatalog_v1.ReplaceTaxonomyRequest( + name="name_value", + serialized_taxonomy=serialized_taxonomy, + ) + + # Make the request + response = client.replace_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ReplaceTaxonomyRequest, dict]): The request object. Request message for @@ -308,6 +332,30 @@ async def import_taxonomies( For an inlined source, taxonomies and policy tags are created in bulk using nested protocol buffer structures. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_import_taxonomies(): + # Create a client + client = datacatalog_v1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + inline_source = datacatalog_v1.InlineSource() + inline_source.taxonomies.display_name = "display_name_value" + + request = datacatalog_v1.ImportTaxonomiesRequest( + inline_source=inline_source, + parent="parent_value", + ) + + # Make the request + response = client.import_taxonomies(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ImportTaxonomiesRequest, dict]): The request object. Request message for @@ -365,6 +413,28 @@ async def export_taxonomies( with nested policy tags that can be used as input for ``ImportTaxonomies`` calls. + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_export_taxonomies(): + # Create a client + client = datacatalog_v1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + request = datacatalog_v1.ExportTaxonomiesRequest( + serialized_taxonomies=True, + parent="parent_value", + taxonomies=['taxonomies_value_1', 'taxonomies_value_2'], + ) + + # Make the request + response = client.export_taxonomies(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ExportTaxonomiesRequest, dict]): The request object. Request message for diff --git a/google/cloud/datacatalog_v1/services/policy_tag_manager_serialization/client.py b/google/cloud/datacatalog_v1/services/policy_tag_manager_serialization/client.py index 22125c5f..28a9d485 100644 --- a/google/cloud/datacatalog_v1/services/policy_tag_manager_serialization/client.py +++ b/google/cloud/datacatalog_v1/services/policy_tag_manager_serialization/client.py @@ -434,6 +434,31 @@ def replace_taxonomy( considered new. - Updates policy tags with valid resources names accordingly. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_replace_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + serialized_taxonomy = datacatalog_v1.SerializedTaxonomy() + serialized_taxonomy.display_name = "display_name_value" + + request = datacatalog_v1.ReplaceTaxonomyRequest( + name="name_value", + serialized_taxonomy=serialized_taxonomy, + ) + + # Make the request + response = client.replace_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ReplaceTaxonomyRequest, dict]): The request object. Request message for @@ -505,6 +530,31 @@ def import_taxonomies( For an inlined source, taxonomies and policy tags are created in bulk using nested protocol buffer structures. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_import_taxonomies(): + # Create a client + client = datacatalog_v1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + inline_source = datacatalog_v1.InlineSource() + inline_source.taxonomies.display_name = "display_name_value" + + request = datacatalog_v1.ImportTaxonomiesRequest( + inline_source=inline_source, + parent="parent_value", + ) + + # Make the request + response = client.import_taxonomies(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ImportTaxonomiesRequest, dict]): The request object. Request message for @@ -565,6 +615,29 @@ def export_taxonomies( with nested policy tags that can be used as input for ``ImportTaxonomies`` calls. + + + .. code-block:: + + from google.cloud import datacatalog_v1 + + def sample_export_taxonomies(): + # Create a client + client = datacatalog_v1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + request = datacatalog_v1.ExportTaxonomiesRequest( + serialized_taxonomies=True, + parent="parent_value", + taxonomies=['taxonomies_value_1', 'taxonomies_value_2'], + ) + + # Make the request + response = client.export_taxonomies(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1.types.ExportTaxonomiesRequest, dict]): The request object. Request message for diff --git a/google/cloud/datacatalog_v1/types/__init__.py b/google/cloud/datacatalog_v1/types/__init__.py index 79dd1780..0fa54948 100644 --- a/google/cloud/datacatalog_v1/types/__init__.py +++ b/google/cloud/datacatalog_v1/types/__init__.py @@ -18,8 +18,14 @@ BigQueryRoutineSpec, CloudSqlBigQueryConnectionSpec, ) +from .common import ( + PersonalDetails, + IntegratedSystem, +) from .data_source import DataSource from .datacatalog import ( + BusinessContext, + Contacts, CreateEntryGroupRequest, CreateEntryRequest, CreateTagRequest, @@ -34,6 +40,7 @@ DeleteTagTemplateRequest, Entry, EntryGroup, + EntryOverview, GetEntryGroupRequest, GetEntryRequest, GetTagTemplateRequest, @@ -44,11 +51,17 @@ ListTagsRequest, ListTagsResponse, LookupEntryRequest, + ModifyEntryContactsRequest, + ModifyEntryOverviewRequest, RenameTagTemplateFieldEnumValueRequest, RenameTagTemplateFieldRequest, RoutineSpec, SearchCatalogRequest, SearchCatalogResponse, + StarEntryRequest, + StarEntryResponse, + UnstarEntryRequest, + UnstarEntryResponse, UpdateEntryGroupRequest, UpdateEntryRequest, UpdateTagRequest, @@ -119,8 +132,11 @@ "BigQueryConnectionSpec", "BigQueryRoutineSpec", "CloudSqlBigQueryConnectionSpec", + "PersonalDetails", "IntegratedSystem", "DataSource", + "BusinessContext", + "Contacts", "CreateEntryGroupRequest", "CreateEntryRequest", "CreateTagRequest", @@ -135,6 +151,7 @@ "DeleteTagTemplateRequest", "Entry", "EntryGroup", + "EntryOverview", "GetEntryGroupRequest", "GetEntryRequest", "GetTagTemplateRequest", @@ -145,11 +162,17 @@ "ListTagsRequest", "ListTagsResponse", "LookupEntryRequest", + "ModifyEntryContactsRequest", + "ModifyEntryOverviewRequest", "RenameTagTemplateFieldEnumValueRequest", "RenameTagTemplateFieldRequest", "RoutineSpec", "SearchCatalogRequest", "SearchCatalogResponse", + "StarEntryRequest", + "StarEntryResponse", + "UnstarEntryRequest", + "UnstarEntryResponse", "UpdateEntryGroupRequest", "UpdateEntryRequest", "UpdateTagRequest", diff --git a/google/cloud/datacatalog_v1/types/common.py b/google/cloud/datacatalog_v1/types/common.py index f9dcee7e..eb63ed45 100644 --- a/google/cloud/datacatalog_v1/types/common.py +++ b/google/cloud/datacatalog_v1/types/common.py @@ -15,9 +15,12 @@ # import proto # type: ignore +from google.protobuf import timestamp_pb2 # type: ignore + __protobuf__ = proto.module( - package="google.cloud.datacatalog.v1", manifest={"IntegratedSystem",}, + package="google.cloud.datacatalog.v1", + manifest={"IntegratedSystem", "PersonalDetails",}, ) @@ -31,4 +34,19 @@ class IntegratedSystem(proto.Enum): DATAPROC_METASTORE = 3 +class PersonalDetails(proto.Message): + r"""Entry metadata relevant only to the user and private to them. + + Attributes: + starred (bool): + True if the entry is starred by the user; + false otherwise. + star_time (google.protobuf.timestamp_pb2.Timestamp): + Set if the entry is starred; unset otherwise. + """ + + starred = proto.Field(proto.BOOL, number=1,) + star_time = proto.Field(proto.MESSAGE, number=2, message=timestamp_pb2.Timestamp,) + + __all__ = tuple(sorted(__protobuf__.manifest)) diff --git a/google/cloud/datacatalog_v1/types/datacatalog.py b/google/cloud/datacatalog_v1/types/datacatalog.py index 3c261100..a22cbbf2 100644 --- a/google/cloud/datacatalog_v1/types/datacatalog.py +++ b/google/cloud/datacatalog_v1/types/datacatalog.py @@ -49,6 +49,9 @@ "DatabaseTableSpec", "DataSourceConnectionSpec", "RoutineSpec", + "BusinessContext", + "EntryOverview", + "Contacts", "EntryGroup", "CreateTagTemplateRequest", "GetTagTemplateRequest", @@ -66,6 +69,12 @@ "ListTagsResponse", "ListEntriesRequest", "ListEntriesResponse", + "StarEntryRequest", + "StarEntryResponse", + "UnstarEntryRequest", + "UnstarEntryResponse", + "ModifyEntryOverviewRequest", + "ModifyEntryContactsRequest", }, ) @@ -137,6 +146,7 @@ class SearchCatalogRequest(proto.Message): - ``relevance`` that can only be descending - ``last_modified_timestamp [asc|desc]`` with descending (``desc``) as default + - ``default`` that can only be descending If this parameter is omitted, it defaults to the descending ``relevance``. @@ -178,22 +188,21 @@ class Scope(proto.Message): additional information on the error, repeat the search request and set the location name as the value of this parameter. + starred_only (bool): + Optional. If ``true``, search only among starred entries. + + By default, all results are returned, starred or not. include_public_tag_templates (bool): - Optional. If ``true``, include [public tag - templates][google.cloud.datacatalog.v1.TagTemplate.is_publicly_readable] - in the search results. By default, they are included only if - you have explicit permissions on them to view them. For - example, if you are the owner. - - Other scope fields, for example, ``include_org_ids``, still - restrict the returned public tag templates and at least one - of them is required. + Optional. This field is deprecated. The + search mechanism for public and private tag + templates is the same. """ include_org_ids = proto.RepeatedField(proto.STRING, number=2,) include_project_ids = proto.RepeatedField(proto.STRING, number=3,) include_gcp_public_datasets = proto.Field(proto.BOOL, number=7,) restricted_locations = proto.RepeatedField(proto.STRING, number=16,) + starred_only = proto.Field(proto.BOOL, number=18,) include_public_tag_templates = proto.Field(proto.BOOL, number=19,) scope = proto.Field(proto.MESSAGE, number=6, message=Scope,) @@ -689,6 +698,9 @@ class Entry(proto.Message): returns (CR), and page breaks (FF). The maximum size is 2000 bytes when encoded in UTF-8. Default value is an empty string. + business_context (google.cloud.datacatalog_v1.types.BusinessContext): + Business Context of the entry. Not supported + for BigQuery datasets. schema (google.cloud.datacatalog_v1.types.Schema): Schema of the entry. An entry might not have any schema attached to it. @@ -710,6 +722,9 @@ class Entry(proto.Message): the source system. data_source (google.cloud.datacatalog_v1.types.DataSource): Output only. Physical location of the entry. + personal_details (google.cloud.datacatalog_v1.types.PersonalDetails): + Output only. Additional information related + to the entry. Private to the current user. """ name = proto.Field(proto.STRING, number=1,) @@ -750,6 +765,7 @@ class Entry(proto.Message): ) display_name = proto.Field(proto.STRING, number=3,) description = proto.Field(proto.STRING, number=4,) + business_context = proto.Field(proto.MESSAGE, number=37, message="BusinessContext",) schema = proto.Field(proto.MESSAGE, number=5, message=gcd_schema.Schema,) source_system_timestamps = proto.Field( proto.MESSAGE, number=7, message=timestamps.SystemTimestamps, @@ -759,6 +775,9 @@ class Entry(proto.Message): data_source = proto.Field( proto.MESSAGE, number=20, message=gcd_data_source.DataSource, ) + personal_details = proto.Field( + proto.MESSAGE, number=26, message=common.PersonalDetails, + ) class DatabaseTableSpec(proto.Message): @@ -868,6 +887,65 @@ class Mode(proto.Enum): ) +class BusinessContext(proto.Message): + r"""Business Context of the entry. + + Attributes: + entry_overview (google.cloud.datacatalog_v1.types.EntryOverview): + Entry overview fields for rich text + descriptions of entries. + contacts (google.cloud.datacatalog_v1.types.Contacts): + Contact people for the entry. + """ + + entry_overview = proto.Field(proto.MESSAGE, number=1, message="EntryOverview",) + contacts = proto.Field(proto.MESSAGE, number=2, message="Contacts",) + + +class EntryOverview(proto.Message): + r"""Entry overview fields for rich text descriptions of entries. + + Attributes: + overview (str): + Entry overview with support for rich text. + The overview must only contain Unicode + characters, and should be formatted using HTML. + The maximum length is 10 MiB as this value holds + HTML descriptions including encoded images. The + maximum length of the text without images is 100 + KiB. + """ + + overview = proto.Field(proto.STRING, number=1,) + + +class Contacts(proto.Message): + r"""Contact people for the entry. + + Attributes: + people (Sequence[google.cloud.datacatalog_v1.types.Contacts.Person]): + The list of contact people for the entry. + """ + + class Person(proto.Message): + r"""A contact person for the entry. + + Attributes: + designation (str): + Designation of the person, for example, Data + Steward. + email (str): + Email of the person in the format of + ``john.doe@example.com``, ````, or + ``John Doe``. + """ + + designation = proto.Field(proto.STRING, number=1,) + email = proto.Field(proto.STRING, number=2,) + + people = proto.RepeatedField(proto.MESSAGE, number=1, message=Person,) + + class EntryGroup(proto.Message): r"""Entry group metadata. @@ -960,9 +1038,6 @@ class UpdateTagTemplateRequest(proto.Message): Note: Updating the ``is_publicly_readable`` field may require up to 12 hours to take effect in search results. - Additionally, it also requires the - ``tagTemplates.getIamPolicy`` and - ``tagTemplates.setIamPolicy`` permissions. """ tag_template = proto.Field(proto.MESSAGE, number=1, message=gcd_tags.TagTemplate,) @@ -1264,4 +1339,78 @@ def raw_page(self): next_page_token = proto.Field(proto.STRING, number=2,) +class StarEntryRequest(proto.Message): + r"""Request message for + [StarEntry][google.cloud.datacatalog.v1.DataCatalog.StarEntry]. + + Attributes: + name (str): + Required. The name of the entry to mark as + starred. + """ + + name = proto.Field(proto.STRING, number=1,) + + +class StarEntryResponse(proto.Message): + r"""Response message for + [StarEntry][google.cloud.datacatalog.v1.DataCatalog.StarEntry]. + Empty for now + + """ + + +class UnstarEntryRequest(proto.Message): + r"""Request message for + [UnstarEntry][google.cloud.datacatalog.v1.DataCatalog.UnstarEntry]. + + Attributes: + name (str): + Required. The name of the entry to mark as **not** starred. + """ + + name = proto.Field(proto.STRING, number=1,) + + +class UnstarEntryResponse(proto.Message): + r"""Response message for + [UnstarEntry][google.cloud.datacatalog.v1.DataCatalog.UnstarEntry]. + Empty for now + + """ + + +class ModifyEntryOverviewRequest(proto.Message): + r"""Request message for + [ModifyEntryOverview][google.cloud.datacatalog.v1.DataCatalog.ModifyEntryOverview]. + + Attributes: + name (str): + Required. The full resource name of the + entry. + entry_overview (google.cloud.datacatalog_v1.types.EntryOverview): + Required. The new value for the Entry + Overview. + """ + + name = proto.Field(proto.STRING, number=1,) + entry_overview = proto.Field(proto.MESSAGE, number=2, message="EntryOverview",) + + +class ModifyEntryContactsRequest(proto.Message): + r"""Request message for + [ModifyEntryContacts][google.cloud.datacatalog.v1.DataCatalog.ModifyEntryContacts]. + + Attributes: + name (str): + Required. The full resource name of the + entry. + contacts (google.cloud.datacatalog_v1.types.Contacts): + Required. The new value for the Contacts. + """ + + name = proto.Field(proto.STRING, number=1,) + contacts = proto.Field(proto.MESSAGE, number=2, message="Contacts",) + + __all__ = tuple(sorted(__protobuf__.manifest)) diff --git a/google/cloud/datacatalog_v1/types/tags.py b/google/cloud/datacatalog_v1/types/tags.py index 8b5b34e9..0225cab4 100644 --- a/google/cloud/datacatalog_v1/types/tags.py +++ b/google/cloud/datacatalog_v1/types/tags.py @@ -183,38 +183,13 @@ class TagTemplate(proto.Message): underscores (_), dashes (-), spaces ( ), and can't start or end with spaces. The maximum length is 200 characters. is_publicly_readable (bool): - Indicates whether this is a public tag template. - - Every user has view access to a *public* tag template by - default. This means that: - - - Every user can use this tag template to tag an entry. - - If an entry is tagged using the tag template, the tag is - always shown in the response to ``ListTags`` called on - the entry. - - To get the template using the GetTagTemplate method, you - need view access either on the project or the - organization the tag template resides in but no other - permission is needed. - - Operations on the tag template other than viewing (for - example, editing IAM policies) follow standard IAM - structures. - - Tags created with a public tag template are referred to as - public tags. - - You can search for a public tag by value with a simple - search query instead of using a ``tag:`` predicate. - - Public tag templates may not appear in search results - depending on scope, see: - [include_public_tag_templates][google.cloud.datacatalog.v1.SearchCatalogRequest.Scope.include_public_tag_templates] - - Note: If an `IAM domain - restriction `__ - is configured in the tag template's location, the public - access will not be enabled but the simple search for tag - values will still work. + Indicates whether tags created with this template are + public. Public tags do not require tag template access to + appear in [ListTags][google.cloud.datacatalog.v1.ListTags] + API response. + + Additionally, you can search for a public tag by value with + a simple search query instead of using a ``tag:`` predicate. fields (Sequence[google.cloud.datacatalog_v1.types.TagTemplate.FieldsEntry]): Required. Map of tag template field IDs to the settings for the field. This map is an exhaustive list of the allowed diff --git a/google/cloud/datacatalog_v1beta1/services/data_catalog/async_client.py b/google/cloud/datacatalog_v1beta1/services/data_catalog/async_client.py index 4749fc9f..5a8a12f1 100644 --- a/google/cloud/datacatalog_v1beta1/services/data_catalog/async_client.py +++ b/google/cloud/datacatalog_v1beta1/services/data_catalog/async_client.py @@ -248,6 +248,25 @@ async def search_catalog( Syntax `__ for more information. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_search_catalog(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.SearchCatalogRequest( + query="query_value", + ) + + # Make the request + page_result = client.search_catalog(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.SearchCatalogRequest, dict]): The request object. Request message for @@ -355,6 +374,27 @@ async def create_entry_group( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreateEntryGroupRequest( + parent="parent_value", + entry_group_id="entry_group_id_value", + ) + + # Make the request + response = client.create_entry_group(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreateEntryGroupRequest, dict]): The request object. Request message for @@ -461,6 +501,25 @@ async def update_entry_group( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdateEntryGroupRequest( + ) + + # Make the request + response = client.update_entry_group(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdateEntryGroupRequest, dict]): The request object. Request message for @@ -548,6 +607,25 @@ async def get_entry_group( ) -> datacatalog.EntryGroup: r"""Gets an EntryGroup. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = client.get_entry_group(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.GetEntryGroupRequest, dict]): The request object. Request message for @@ -646,6 +724,23 @@ async def delete_entry_group( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = client.delete_entry_group(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeleteEntryGroupRequest, dict]): The request object. Request message for @@ -720,6 +815,24 @@ async def list_entry_groups( ) -> pagers.ListEntryGroupsAsyncPager: r"""Lists entry groups. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_list_entry_groups(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListEntryGroupsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entry_groups(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ListEntryGroupsRequest, dict]): The request object. Request message for @@ -814,6 +927,33 @@ async def create_entry( A maximum of 100,000 entries may be created per entry group. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + entry = datacatalog_v1beta1.Entry() + entry.type_ = "FILESET" + entry.integrated_system = "CLOUD_PUBSUB" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1beta1.CreateEntryRequest( + parent="parent_value", + entry_id="entry_id_value", + entry=entry, + ) + + # Make the request + response = client.create_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreateEntryRequest, dict]): The request object. Request message for @@ -921,6 +1061,31 @@ async def update_entry( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + entry = datacatalog_v1beta1.Entry() + entry.type_ = "FILESET" + entry.integrated_system = "CLOUD_PUBSUB" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1beta1.UpdateEntryRequest( + entry=entry, + ) + + # Make the request + response = client.update_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdateEntryRequest, dict]): The request object. Request message for @@ -1043,6 +1208,23 @@ async def delete_entry( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteEntryRequest( + name="name_value", + ) + + # Make the request + response = client.delete_entry(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeleteEntryRequest, dict]): The request object. Request message for @@ -1118,6 +1300,25 @@ async def get_entry( ) -> datacatalog.Entry: r"""Gets an entry. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetEntryRequest( + name="name_value", + ) + + # Make the request + response = client.get_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.GetEntryRequest, dict]): The request object. Request message for @@ -1212,6 +1413,26 @@ async def lookup_entry( Google Cloud Platform service to get the Data Catalog Entry. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_lookup_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.LookupEntryRequest( + linked_resource="linked_resource_value", + ) + + # Make the request + response = client.lookup_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.LookupEntryRequest, dict]): The request object. Request message for @@ -1276,6 +1497,24 @@ async def list_entries( ) -> pagers.ListEntriesAsyncPager: r"""Lists entries. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_list_entries(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListEntriesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entries(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ListEntriesRequest, dict]): The request object. Request message for @@ -1364,6 +1603,27 @@ async def create_tag_template( Project `__ for more information). + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreateTagTemplateRequest( + parent="parent_value", + tag_template_id="tag_template_id_value", + ) + + # Make the request + response = client.create_tag_template(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreateTagTemplateRequest, dict]): The request object. Request message for @@ -1463,6 +1723,25 @@ async def get_tag_template( ) -> tags.TagTemplate: r"""Gets a tag template. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetTagTemplateRequest( + name="name_value", + ) + + # Make the request + response = client.get_tag_template(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.GetTagTemplateRequest, dict]): The request object. Request message for @@ -1561,6 +1840,25 @@ async def update_tag_template( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdateTagTemplateRequest( + ) + + # Make the request + response = client.update_tag_template(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdateTagTemplateRequest, dict]): The request object. Request message for @@ -1662,6 +1960,24 @@ async def delete_tag_template( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTagTemplateRequest( + name="name_value", + force=True, + ) + + # Make the request + response = client.delete_tag_template(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeleteTagTemplateRequest, dict]): The request object. Request message for @@ -1755,6 +2071,31 @@ async def create_tag_template_field( Project `__ for more information). + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1beta1.TagTemplateField() + tag_template_field.type_.primitive_type = "TIMESTAMP" + + request = datacatalog_v1beta1.CreateTagTemplateFieldRequest( + parent="parent_value", + tag_template_field_id="tag_template_field_id_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = client.create_tag_template_field(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreateTagTemplateFieldRequest, dict]): The request object. Request message for @@ -1860,6 +2201,30 @@ async def update_tag_template_field( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1beta1.TagTemplateField() + tag_template_field.type_.primitive_type = "TIMESTAMP" + + request = datacatalog_v1beta1.UpdateTagTemplateFieldRequest( + name="name_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = client.update_tag_template_field(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdateTagTemplateFieldRequest, dict]): The request object. Request message for @@ -1966,6 +2331,27 @@ async def rename_tag_template_field( Project `__ for more information). + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_rename_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.RenameTagTemplateFieldRequest( + name="name_value", + new_tag_template_field_id="new_tag_template_field_id_value", + ) + + # Make the request + response = client.rename_tag_template_field(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.RenameTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2053,6 +2439,24 @@ async def delete_tag_template_field( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTagTemplateFieldRequest( + name="name_value", + force=True, + ) + + # Make the request + response = client.delete_tag_template_field(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeleteTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2147,6 +2551,31 @@ async def create_tag( template `__ used to create the tag must be from the same organization. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_tag(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + tag = datacatalog_v1beta1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1beta1.CreateTagRequest( + parent="parent_value", + tag=tag, + ) + + # Make the request + response = client.create_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreateTagRequest, dict]): The request object. Request message for @@ -2237,6 +2666,29 @@ async def update_tag( ) -> tags.Tag: r"""Updates an existing tag. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_tag(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + tag = datacatalog_v1beta1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1beta1.UpdateTagRequest( + tag=tag, + ) + + # Make the request + response = client.update_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdateTagRequest, dict]): The request object. Request message for @@ -2324,6 +2776,22 @@ async def delete_tag( ) -> None: r"""Deletes a tag. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_tag(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTagRequest( + name="name_value", + ) + + # Make the request + response = client.delete_tag(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeleteTagRequest, dict]): The request object. Request message for @@ -2400,6 +2868,25 @@ async def list_tags( r"""Lists the tags on an [Entry][google.cloud.datacatalog.v1beta1.Entry]. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_list_tags(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_tags(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ListTagsRequest, dict]): The request object. Request message for @@ -2513,6 +3000,26 @@ async def set_iam_policy( - ``datacatalog.entryGroups.setIamPolicy`` to set policies on entry groups. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.set_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.SetIamPolicyRequest, dict]): The request object. Request message for `SetIamPolicy` @@ -2659,6 +3166,26 @@ async def get_iam_policy( - ``datacatalog.entryGroups.getIamPolicy`` to get policies on entry groups. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.get_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.GetIamPolicyRequest, dict]): The request object. Request message for `GetIamPolicy` @@ -2797,6 +3324,27 @@ async def test_iam_permissions( A caller is not required to have Google IAM permission to make this request. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = client.test_iam_permissions(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.TestIamPermissionsRequest, dict]): The request object. Request message for diff --git a/google/cloud/datacatalog_v1beta1/services/data_catalog/client.py b/google/cloud/datacatalog_v1beta1/services/data_catalog/client.py index 5b8b9680..910e17d0 100644 --- a/google/cloud/datacatalog_v1beta1/services/data_catalog/client.py +++ b/google/cloud/datacatalog_v1beta1/services/data_catalog/client.py @@ -509,6 +509,26 @@ def search_catalog( Syntax `__ for more information. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_search_catalog(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.SearchCatalogRequest( + query="query_value", + ) + + # Make the request + page_result = client.search_catalog(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.SearchCatalogRequest, dict]): The request object. Request message for @@ -616,6 +636,28 @@ def create_entry_group( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreateEntryGroupRequest( + parent="parent_value", + entry_group_id="entry_group_id_value", + ) + + # Make the request + response = client.create_entry_group(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreateEntryGroupRequest, dict]): The request object. Request message for @@ -722,6 +764,26 @@ def update_entry_group( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdateEntryGroupRequest( + ) + + # Make the request + response = client.update_entry_group(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdateEntryGroupRequest, dict]): The request object. Request message for @@ -809,6 +871,26 @@ def get_entry_group( ) -> datacatalog.EntryGroup: r"""Gets an EntryGroup. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = client.get_entry_group(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.GetEntryGroupRequest, dict]): The request object. Request message for @@ -897,6 +979,24 @@ def delete_entry_group( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = client.delete_entry_group(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeleteEntryGroupRequest, dict]): The request object. Request message for @@ -961,6 +1061,25 @@ def list_entry_groups( ) -> pagers.ListEntryGroupsPager: r"""Lists entry groups. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_list_entry_groups(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListEntryGroupsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entry_groups(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ListEntryGroupsRequest, dict]): The request object. Request message for @@ -1055,6 +1174,34 @@ def create_entry( A maximum of 100,000 entries may be created per entry group. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + entry = datacatalog_v1beta1.Entry() + entry.type_ = "FILESET" + entry.integrated_system = "CLOUD_PUBSUB" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1beta1.CreateEntryRequest( + parent="parent_value", + entry_id="entry_id_value", + entry=entry, + ) + + # Make the request + response = client.create_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreateEntryRequest, dict]): The request object. Request message for @@ -1162,6 +1309,32 @@ def update_entry( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + entry = datacatalog_v1beta1.Entry() + entry.type_ = "FILESET" + entry.integrated_system = "CLOUD_PUBSUB" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1beta1.UpdateEntryRequest( + entry=entry, + ) + + # Make the request + response = client.update_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdateEntryRequest, dict]): The request object. Request message for @@ -1284,6 +1457,24 @@ def delete_entry( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteEntryRequest( + name="name_value", + ) + + # Make the request + response = client.delete_entry(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeleteEntryRequest, dict]): The request object. Request message for @@ -1349,6 +1540,26 @@ def get_entry( ) -> datacatalog.Entry: r"""Gets an entry. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetEntryRequest( + name="name_value", + ) + + # Make the request + response = client.get_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.GetEntryRequest, dict]): The request object. Request message for @@ -1433,6 +1644,27 @@ def lookup_entry( Google Cloud Platform service to get the Data Catalog Entry. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_lookup_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.LookupEntryRequest( + linked_resource="linked_resource_value", + ) + + # Make the request + response = client.lookup_entry(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.LookupEntryRequest, dict]): The request object. Request message for @@ -1488,6 +1720,25 @@ def list_entries( ) -> pagers.ListEntriesPager: r"""Lists entries. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_list_entries(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListEntriesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entries(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ListEntriesRequest, dict]): The request object. Request message for @@ -1576,6 +1827,28 @@ def create_tag_template( Project `__ for more information). + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreateTagTemplateRequest( + parent="parent_value", + tag_template_id="tag_template_id_value", + ) + + # Make the request + response = client.create_tag_template(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreateTagTemplateRequest, dict]): The request object. Request message for @@ -1675,6 +1948,26 @@ def get_tag_template( ) -> tags.TagTemplate: r"""Gets a tag template. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetTagTemplateRequest( + name="name_value", + ) + + # Make the request + response = client.get_tag_template(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.GetTagTemplateRequest, dict]): The request object. Request message for @@ -1763,6 +2056,26 @@ def update_tag_template( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdateTagTemplateRequest( + ) + + # Make the request + response = client.update_tag_template(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdateTagTemplateRequest, dict]): The request object. Request message for @@ -1864,6 +2177,25 @@ def delete_tag_template( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTagTemplateRequest( + name="name_value", + force=True, + ) + + # Make the request + response = client.delete_tag_template(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeleteTagTemplateRequest, dict]): The request object. Request message for @@ -1947,6 +2279,32 @@ def create_tag_template_field( Project `__ for more information). + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1beta1.TagTemplateField() + tag_template_field.type_.primitive_type = "TIMESTAMP" + + request = datacatalog_v1beta1.CreateTagTemplateFieldRequest( + parent="parent_value", + tag_template_field_id="tag_template_field_id_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = client.create_tag_template_field(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreateTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2054,6 +2412,31 @@ def update_tag_template_field( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1beta1.TagTemplateField() + tag_template_field.type_.primitive_type = "TIMESTAMP" + + request = datacatalog_v1beta1.UpdateTagTemplateFieldRequest( + name="name_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = client.update_tag_template_field(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdateTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2162,6 +2545,28 @@ def rename_tag_template_field( Project `__ for more information). + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_rename_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.RenameTagTemplateFieldRequest( + name="name_value", + new_tag_template_field_id="new_tag_template_field_id_value", + ) + + # Make the request + response = client.rename_tag_template_field(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.RenameTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2251,6 +2656,25 @@ def delete_tag_template_field( (https://cloud.google.com/data-catalog/docs/concepts/resource-project) for more information). + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTagTemplateFieldRequest( + name="name_value", + force=True, + ) + + # Make the request + response = client.delete_tag_template_field(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeleteTagTemplateFieldRequest, dict]): The request object. Request message for @@ -2337,6 +2761,32 @@ def create_tag( template `__ used to create the tag must be from the same organization. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_tag(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + tag = datacatalog_v1beta1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1beta1.CreateTagRequest( + parent="parent_value", + tag=tag, + ) + + # Make the request + response = client.create_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreateTagRequest, dict]): The request object. Request message for @@ -2427,6 +2877,30 @@ def update_tag( ) -> tags.Tag: r"""Updates an existing tag. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_tag(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + tag = datacatalog_v1beta1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1beta1.UpdateTagRequest( + tag=tag, + ) + + # Make the request + response = client.update_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdateTagRequest, dict]): The request object. Request message for @@ -2514,6 +2988,23 @@ def delete_tag( ) -> None: r"""Deletes a tag. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_tag(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTagRequest( + name="name_value", + ) + + # Make the request + response = client.delete_tag(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeleteTagRequest, dict]): The request object. Request message for @@ -2580,6 +3071,26 @@ def list_tags( r"""Lists the tags on an [Entry][google.cloud.datacatalog.v1beta1.Entry]. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_list_tags(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_tags(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ListTagsRequest, dict]): The request object. Request message for @@ -2683,6 +3194,27 @@ def set_iam_policy( - ``datacatalog.entryGroups.setIamPolicy`` to set policies on entry groups. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.set_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.SetIamPolicyRequest, dict]): The request object. Request message for `SetIamPolicy` @@ -2828,6 +3360,27 @@ def get_iam_policy( - ``datacatalog.entryGroups.getIamPolicy`` to get policies on entry groups. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.get_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.GetIamPolicyRequest, dict]): The request object. Request message for `GetIamPolicy` @@ -2965,6 +3518,28 @@ def test_iam_permissions( A caller is not required to have Google IAM permission to make this request. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = client.test_iam_permissions(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.TestIamPermissionsRequest, dict]): The request object. Request message for diff --git a/google/cloud/datacatalog_v1beta1/services/policy_tag_manager/async_client.py b/google/cloud/datacatalog_v1beta1/services/policy_tag_manager/async_client.py index 99b92b8a..e1993c0a 100644 --- a/google/cloud/datacatalog_v1beta1/services/policy_tag_manager/async_client.py +++ b/google/cloud/datacatalog_v1beta1/services/policy_tag_manager/async_client.py @@ -220,6 +220,25 @@ async def create_taxonomy( ) -> policytagmanager.Taxonomy: r"""Creates a taxonomy in the specified project. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreateTaxonomyRequest( + parent="parent_value", + ) + + # Make the request + response = client.create_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreateTaxonomyRequest, dict]): The request object. Request message for @@ -305,6 +324,23 @@ async def delete_taxonomy( all policy tags in this taxonomy along with their associated policies. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = client.delete_taxonomy(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeleteTaxonomyRequest, dict]): The request object. Request message for @@ -370,6 +406,24 @@ async def update_taxonomy( ) -> policytagmanager.Taxonomy: r"""Updates a taxonomy. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdateTaxonomyRequest( + ) + + # Make the request + response = client.update_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdateTaxonomyRequest, dict]): The request object. Request message for @@ -448,6 +502,25 @@ async def list_taxonomies( r"""Lists all taxonomies in a project in a particular location that the caller has permission to view. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_list_taxonomies(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListTaxonomiesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_taxonomies(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ListTaxonomiesRequest, dict]): The request object. Request message for @@ -528,6 +601,25 @@ async def get_taxonomy( ) -> policytagmanager.Taxonomy: r"""Gets a taxonomy. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = client.get_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.GetTaxonomyRequest, dict]): The request object. Request message for @@ -604,6 +696,25 @@ async def create_policy_tag( ) -> policytagmanager.PolicyTag: r"""Creates a policy tag in the specified taxonomy. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreatePolicyTagRequest( + parent="parent_value", + ) + + # Make the request + response = client.create_policy_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreatePolicyTagRequest, dict]): The request object. Request message for @@ -690,6 +801,23 @@ async def delete_policy_tag( r"""Deletes a policy tag. Also deletes all of its descendant policy tags. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeletePolicyTagRequest( + name="name_value", + ) + + # Make the request + response = client.delete_policy_tag(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeletePolicyTagRequest, dict]): The request object. Request message for @@ -755,6 +883,24 @@ async def update_policy_tag( ) -> policytagmanager.PolicyTag: r"""Updates a policy tag. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdatePolicyTagRequest( + ) + + # Make the request + response = client.update_policy_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdatePolicyTagRequest, dict]): The request object. Request message for @@ -835,6 +981,24 @@ async def list_policy_tags( ) -> pagers.ListPolicyTagsAsyncPager: r"""Lists all policy tags in a taxonomy. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_list_policy_tags(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListPolicyTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_policy_tags(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ListPolicyTagsRequest, dict]): The request object. Request message for @@ -915,6 +1079,25 @@ async def get_policy_tag( ) -> policytagmanager.PolicyTag: r"""Gets a policy tag. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetPolicyTagRequest( + name="name_value", + ) + + # Make the request + response = client.get_policy_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.GetPolicyTagRequest, dict]): The request object. Request message for @@ -991,6 +1174,25 @@ async def get_iam_policy( ) -> policy_pb2.Policy: r"""Gets the IAM policy for a taxonomy or a policy tag. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.get_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.GetIamPolicyRequest, dict]): The request object. Request message for `GetIamPolicy` @@ -1096,6 +1298,25 @@ async def set_iam_policy( ) -> policy_pb2.Policy: r"""Sets the IAM policy for a taxonomy or a policy tag. + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.set_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.SetIamPolicyRequest, dict]): The request object. Request message for `SetIamPolicy` @@ -1202,6 +1423,27 @@ async def test_iam_permissions( r"""Returns the permissions that a caller has on the specified taxonomy or policy tag. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = client.test_iam_permissions(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.TestIamPermissionsRequest, dict]): The request object. Request message for diff --git a/google/cloud/datacatalog_v1beta1/services/policy_tag_manager/client.py b/google/cloud/datacatalog_v1beta1/services/policy_tag_manager/client.py index a1338976..701edb9b 100644 --- a/google/cloud/datacatalog_v1beta1/services/policy_tag_manager/client.py +++ b/google/cloud/datacatalog_v1beta1/services/policy_tag_manager/client.py @@ -436,6 +436,26 @@ def create_taxonomy( ) -> policytagmanager.Taxonomy: r"""Creates a taxonomy in the specified project. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreateTaxonomyRequest( + parent="parent_value", + ) + + # Make the request + response = client.create_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreateTaxonomyRequest, dict]): The request object. Request message for @@ -521,6 +541,24 @@ def delete_taxonomy( all policy tags in this taxonomy along with their associated policies. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = client.delete_taxonomy(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeleteTaxonomyRequest, dict]): The request object. Request message for @@ -586,6 +624,25 @@ def update_taxonomy( ) -> policytagmanager.Taxonomy: r"""Updates a taxonomy. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdateTaxonomyRequest( + ) + + # Make the request + response = client.update_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdateTaxonomyRequest, dict]): The request object. Request message for @@ -664,6 +721,26 @@ def list_taxonomies( r"""Lists all taxonomies in a project in a particular location that the caller has permission to view. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_list_taxonomies(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListTaxonomiesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_taxonomies(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ListTaxonomiesRequest, dict]): The request object. Request message for @@ -744,6 +821,26 @@ def get_taxonomy( ) -> policytagmanager.Taxonomy: r"""Gets a taxonomy. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = client.get_taxonomy(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.GetTaxonomyRequest, dict]): The request object. Request message for @@ -820,6 +917,26 @@ def create_policy_tag( ) -> policytagmanager.PolicyTag: r"""Creates a policy tag in the specified taxonomy. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_create_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreatePolicyTagRequest( + parent="parent_value", + ) + + # Make the request + response = client.create_policy_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.CreatePolicyTagRequest, dict]): The request object. Request message for @@ -906,6 +1023,24 @@ def delete_policy_tag( r"""Deletes a policy tag. Also deletes all of its descendant policy tags. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_delete_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeletePolicyTagRequest( + name="name_value", + ) + + # Make the request + response = client.delete_policy_tag(request=request) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.DeletePolicyTagRequest, dict]): The request object. Request message for @@ -971,6 +1106,25 @@ def update_policy_tag( ) -> policytagmanager.PolicyTag: r"""Updates a policy tag. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_update_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdatePolicyTagRequest( + ) + + # Make the request + response = client.update_policy_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.UpdatePolicyTagRequest, dict]): The request object. Request message for @@ -1051,6 +1205,25 @@ def list_policy_tags( ) -> pagers.ListPolicyTagsPager: r"""Lists all policy tags in a taxonomy. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_list_policy_tags(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListPolicyTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_policy_tags(request=request) + for response in page_result: + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ListPolicyTagsRequest, dict]): The request object. Request message for @@ -1131,6 +1304,26 @@ def get_policy_tag( ) -> policytagmanager.PolicyTag: r"""Gets a policy tag. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetPolicyTagRequest( + name="name_value", + ) + + # Make the request + response = client.get_policy_tag(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.GetPolicyTagRequest, dict]): The request object. Request message for @@ -1207,6 +1400,26 @@ def get_iam_policy( ) -> policy_pb2.Policy: r"""Gets the IAM policy for a taxonomy or a policy tag. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.get_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.GetIamPolicyRequest, dict]): The request object. Request message for `GetIamPolicy` @@ -1311,6 +1524,26 @@ def set_iam_policy( ) -> policy_pb2.Policy: r"""Sets the IAM policy for a taxonomy or a policy tag. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.set_iam_policy(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.SetIamPolicyRequest, dict]): The request object. Request message for `SetIamPolicy` @@ -1416,6 +1649,28 @@ def test_iam_permissions( r"""Returns the permissions that a caller has on the specified taxonomy or policy tag. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = client.test_iam_permissions(request=request) + + # Handle response + print(response) + Args: request (Union[google.iam.v1.iam_policy_pb2.TestIamPermissionsRequest, dict]): The request object. Request message for diff --git a/google/cloud/datacatalog_v1beta1/services/policy_tag_manager_serialization/async_client.py b/google/cloud/datacatalog_v1beta1/services/policy_tag_manager_serialization/async_client.py index 012ca0eb..529a72c9 100644 --- a/google/cloud/datacatalog_v1beta1/services/policy_tag_manager_serialization/async_client.py +++ b/google/cloud/datacatalog_v1beta1/services/policy_tag_manager_serialization/async_client.py @@ -230,6 +230,30 @@ async def import_taxonomies( This method provides a bulk taxonomy / policy tag creation using nested proto structure. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_import_taxonomies(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + inline_source = datacatalog_v1beta1.InlineSource() + inline_source.taxonomies.display_name = "display_name_value" + + request = datacatalog_v1beta1.ImportTaxonomiesRequest( + inline_source=inline_source, + parent="parent_value", + ) + + # Make the request + response = client.import_taxonomies(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ImportTaxonomiesRequest, dict]): The request object. Request message for @@ -285,6 +309,28 @@ async def export_taxonomies( nested policy tags that can be used as an input for future ImportTaxonomies calls. + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_export_taxonomies(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ExportTaxonomiesRequest( + serialized_taxonomies=True, + parent="parent_value", + taxonomies=['taxonomies_value_1', 'taxonomies_value_2'], + ) + + # Make the request + response = client.export_taxonomies(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ExportTaxonomiesRequest, dict]): The request object. Request message for diff --git a/google/cloud/datacatalog_v1beta1/services/policy_tag_manager_serialization/client.py b/google/cloud/datacatalog_v1beta1/services/policy_tag_manager_serialization/client.py index 42b965a7..e9adff00 100644 --- a/google/cloud/datacatalog_v1beta1/services/policy_tag_manager_serialization/client.py +++ b/google/cloud/datacatalog_v1beta1/services/policy_tag_manager_serialization/client.py @@ -424,6 +424,31 @@ def import_taxonomies( This method provides a bulk taxonomy / policy tag creation using nested proto structure. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_import_taxonomies(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + inline_source = datacatalog_v1beta1.InlineSource() + inline_source.taxonomies.display_name = "display_name_value" + + request = datacatalog_v1beta1.ImportTaxonomiesRequest( + inline_source=inline_source, + parent="parent_value", + ) + + # Make the request + response = client.import_taxonomies(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ImportTaxonomiesRequest, dict]): The request object. Request message for @@ -482,6 +507,29 @@ def export_taxonomies( nested policy tags that can be used as an input for future ImportTaxonomies calls. + + + .. code-block:: + + from google.cloud import datacatalog_v1beta1 + + def sample_export_taxonomies(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ExportTaxonomiesRequest( + serialized_taxonomies=True, + parent="parent_value", + taxonomies=['taxonomies_value_1', 'taxonomies_value_2'], + ) + + # Make the request + response = client.export_taxonomies(request=request) + + # Handle response + print(response) + Args: request (Union[google.cloud.datacatalog_v1beta1.types.ExportTaxonomiesRequest, dict]): The request object. Request message for diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_entry_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_entry_async.py new file mode 100644 index 00000000..345ece09 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_entry_async.py @@ -0,0 +1,52 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_CreateEntry_async] +from google.cloud import datacatalog_v1 + + +async def sample_create_entry(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + entry = datacatalog_v1.Entry() + entry.type_ = "SERVICE" + entry.integrated_system = "DATAPROC_METASTORE" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1.CreateEntryRequest( + parent="parent_value", + entry_id="entry_id_value", + entry=entry, + ) + + # Make the request + response = await client.create_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_CreateEntry_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_entry_group_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_entry_group_async.py new file mode 100644 index 00000000..ff2b9848 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_entry_group_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_CreateEntryGroup_async] +from google.cloud import datacatalog_v1 + + +async def sample_create_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreateEntryGroupRequest( + parent="parent_value", + entry_group_id="entry_group_id_value", + ) + + # Make the request + response = await client.create_entry_group(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_CreateEntryGroup_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_entry_group_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_entry_group_sync.py new file mode 100644 index 00000000..62e48711 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_entry_group_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_CreateEntryGroup_sync] +from google.cloud import datacatalog_v1 + + +def sample_create_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreateEntryGroupRequest( + parent="parent_value", + entry_group_id="entry_group_id_value", + ) + + # Make the request + response = client.create_entry_group(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_CreateEntryGroup_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_entry_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_entry_sync.py new file mode 100644 index 00000000..8506d5b8 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_entry_sync.py @@ -0,0 +1,52 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_CreateEntry_sync] +from google.cloud import datacatalog_v1 + + +def sample_create_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + entry = datacatalog_v1.Entry() + entry.type_ = "SERVICE" + entry.integrated_system = "DATAPROC_METASTORE" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1.CreateEntryRequest( + parent="parent_value", + entry_id="entry_id_value", + entry=entry, + ) + + # Make the request + response = client.create_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_CreateEntry_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_async.py new file mode 100644 index 00000000..b7752909 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_async.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_CreateTag_async] +from google.cloud import datacatalog_v1 + + +async def sample_create_tag(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + tag = datacatalog_v1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1.CreateTagRequest( + parent="parent_value", + tag=tag, + ) + + # Make the request + response = await client.create_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_CreateTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_sync.py new file mode 100644 index 00000000..0599ead7 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_sync.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_CreateTag_sync] +from google.cloud import datacatalog_v1 + + +def sample_create_tag(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + tag = datacatalog_v1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1.CreateTagRequest( + parent="parent_value", + tag=tag, + ) + + # Make the request + response = client.create_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_CreateTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_async.py new file mode 100644 index 00000000..03459b13 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_CreateTagTemplate_async] +from google.cloud import datacatalog_v1 + + +async def sample_create_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreateTagTemplateRequest( + parent="parent_value", + tag_template_id="tag_template_id_value", + ) + + # Make the request + response = await client.create_tag_template(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_CreateTagTemplate_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_field_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_field_async.py new file mode 100644 index 00000000..e499785e --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_field_async.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_CreateTagTemplateField_async] +from google.cloud import datacatalog_v1 + + +async def sample_create_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1.TagTemplateField() + tag_template_field.type_.primitive_type = "RICHTEXT" + + request = datacatalog_v1.CreateTagTemplateFieldRequest( + parent="parent_value", + tag_template_field_id="tag_template_field_id_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = await client.create_tag_template_field(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_CreateTagTemplateField_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_field_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_field_sync.py new file mode 100644 index 00000000..dcbeebc6 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_field_sync.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_CreateTagTemplateField_sync] +from google.cloud import datacatalog_v1 + + +def sample_create_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1.TagTemplateField() + tag_template_field.type_.primitive_type = "RICHTEXT" + + request = datacatalog_v1.CreateTagTemplateFieldRequest( + parent="parent_value", + tag_template_field_id="tag_template_field_id_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = client.create_tag_template_field(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_CreateTagTemplateField_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_sync.py new file mode 100644 index 00000000..2a5febff --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_CreateTagTemplate_sync] +from google.cloud import datacatalog_v1 + + +def sample_create_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreateTagTemplateRequest( + parent="parent_value", + tag_template_id="tag_template_id_value", + ) + + # Make the request + response = client.create_tag_template(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_CreateTagTemplate_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_async.py new file mode 100644 index 00000000..b4fbabfc --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_async.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_DeleteEntry_async] +from google.cloud import datacatalog_v1 + + +async def sample_delete_entry(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteEntryRequest( + name="name_value", + ) + + # Make the request + response = await client.delete_entry(request=request) + + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_DeleteEntry_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_group_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_group_async.py new file mode 100644 index 00000000..93b82b0a --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_group_async.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_DeleteEntryGroup_async] +from google.cloud import datacatalog_v1 + + +async def sample_delete_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = await client.delete_entry_group(request=request) + + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_DeleteEntryGroup_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_group_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_group_sync.py new file mode 100644 index 00000000..a137241b --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_group_sync.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_DeleteEntryGroup_sync] +from google.cloud import datacatalog_v1 + + +def sample_delete_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = client.delete_entry_group(request=request) + + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_DeleteEntryGroup_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_sync.py new file mode 100644 index 00000000..09684fb7 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_sync.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_DeleteEntry_sync] +from google.cloud import datacatalog_v1 + + +def sample_delete_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteEntryRequest( + name="name_value", + ) + + # Make the request + response = client.delete_entry(request=request) + + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_DeleteEntry_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_async.py new file mode 100644 index 00000000..2738b204 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_async.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTag_async] +from google.cloud import datacatalog_v1 + + +async def sample_delete_tag(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTagRequest( + name="name_value", + ) + + # Make the request + response = await client.delete_tag(request=request) + + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_sync.py new file mode 100644 index 00000000..ecbd7a71 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_sync.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTag_sync] +from google.cloud import datacatalog_v1 + + +def sample_delete_tag(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTagRequest( + name="name_value", + ) + + # Make the request + response = client.delete_tag(request=request) + + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_async.py new file mode 100644 index 00000000..77496dd9 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTagTemplate_async] +from google.cloud import datacatalog_v1 + + +async def sample_delete_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTagTemplateRequest( + name="name_value", + force=True, + ) + + # Make the request + response = await client.delete_tag_template(request=request) + + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTagTemplate_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_field_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_field_async.py new file mode 100644 index 00000000..8f1a3299 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_field_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTagTemplateField_async] +from google.cloud import datacatalog_v1 + + +async def sample_delete_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTagTemplateFieldRequest( + name="name_value", + force=True, + ) + + # Make the request + response = await client.delete_tag_template_field(request=request) + + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTagTemplateField_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_field_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_field_sync.py new file mode 100644 index 00000000..4ac6ec88 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_field_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTagTemplateField_sync] +from google.cloud import datacatalog_v1 + + +def sample_delete_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTagTemplateFieldRequest( + name="name_value", + force=True, + ) + + # Make the request + response = client.delete_tag_template_field(request=request) + + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTagTemplateField_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_sync.py new file mode 100644 index 00000000..c0841bf1 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTagTemplate_sync] +from google.cloud import datacatalog_v1 + + +def sample_delete_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTagTemplateRequest( + name="name_value", + force=True, + ) + + # Make the request + response = client.delete_tag_template(request=request) + + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTagTemplate_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_entry_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_entry_async.py new file mode 100644 index 00000000..24c53502 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_entry_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_GetEntry_async] +from google.cloud import datacatalog_v1 + + +async def sample_get_entry(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetEntryRequest( + name="name_value", + ) + + # Make the request + response = await client.get_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_GetEntry_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_entry_group_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_entry_group_async.py new file mode 100644 index 00000000..efa31b3e --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_entry_group_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_GetEntryGroup_async] +from google.cloud import datacatalog_v1 + + +async def sample_get_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = await client.get_entry_group(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_GetEntryGroup_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_entry_group_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_entry_group_sync.py new file mode 100644 index 00000000..8b5313d1 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_entry_group_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_GetEntryGroup_sync] +from google.cloud import datacatalog_v1 + + +def sample_get_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = client.get_entry_group(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_GetEntryGroup_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_entry_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_entry_sync.py new file mode 100644 index 00000000..af31cd5f --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_entry_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_GetEntry_sync] +from google.cloud import datacatalog_v1 + + +def sample_get_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetEntryRequest( + name="name_value", + ) + + # Make the request + response = client.get_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_GetEntry_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_iam_policy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_iam_policy_async.py new file mode 100644 index 00000000..3f7a9999 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_iam_policy_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_GetIamPolicy_async] +from google.cloud import datacatalog_v1 + + +async def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = await client.get_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_GetIamPolicy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_iam_policy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_iam_policy_sync.py new file mode 100644 index 00000000..f81acfb7 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_iam_policy_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_GetIamPolicy_sync] +from google.cloud import datacatalog_v1 + + +def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.get_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_GetIamPolicy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_tag_template_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_tag_template_async.py new file mode 100644 index 00000000..26fcfabc --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_tag_template_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_GetTagTemplate_async] +from google.cloud import datacatalog_v1 + + +async def sample_get_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetTagTemplateRequest( + name="name_value", + ) + + # Make the request + response = await client.get_tag_template(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_GetTagTemplate_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_tag_template_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_tag_template_sync.py new file mode 100644 index 00000000..a7331cb2 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_get_tag_template_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_GetTagTemplate_sync] +from google.cloud import datacatalog_v1 + + +def sample_get_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetTagTemplateRequest( + name="name_value", + ) + + # Make the request + response = client.get_tag_template(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_GetTagTemplate_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_entries_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_entries_async.py new file mode 100644 index 00000000..00353269 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_entries_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListEntries +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_ListEntries_async] +from google.cloud import datacatalog_v1 + + +async def sample_list_entries(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListEntriesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entries(request=request) + async for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_ListEntries_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_entries_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_entries_sync.py new file mode 100644 index 00000000..c8dabcd9 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_entries_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListEntries +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_ListEntries_sync] +from google.cloud import datacatalog_v1 + + +def sample_list_entries(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListEntriesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entries(request=request) + for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_ListEntries_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_entry_groups_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_entry_groups_async.py new file mode 100644 index 00000000..1c474f17 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_entry_groups_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListEntryGroups +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_ListEntryGroups_async] +from google.cloud import datacatalog_v1 + + +async def sample_list_entry_groups(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListEntryGroupsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entry_groups(request=request) + async for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_ListEntryGroups_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_entry_groups_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_entry_groups_sync.py new file mode 100644 index 00000000..b8379f6b --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_entry_groups_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListEntryGroups +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_ListEntryGroups_sync] +from google.cloud import datacatalog_v1 + + +def sample_list_entry_groups(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListEntryGroupsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entry_groups(request=request) + for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_ListEntryGroups_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_tags_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_tags_async.py new file mode 100644 index 00000000..d15f81f2 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_tags_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListTags +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_ListTags_async] +from google.cloud import datacatalog_v1 + + +async def sample_list_tags(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_tags(request=request) + async for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_ListTags_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_tags_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_tags_sync.py new file mode 100644 index 00000000..a2235f5e --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_list_tags_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListTags +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_ListTags_sync] +from google.cloud import datacatalog_v1 + + +def sample_list_tags(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_tags(request=request) + for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_ListTags_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_lookup_entry_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_lookup_entry_async.py new file mode 100644 index 00000000..286d4fc6 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_lookup_entry_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for LookupEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_LookupEntry_async] +from google.cloud import datacatalog_v1 + + +async def sample_lookup_entry(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.LookupEntryRequest( + linked_resource="linked_resource_value", + ) + + # Make the request + response = await client.lookup_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_LookupEntry_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_lookup_entry_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_lookup_entry_sync.py new file mode 100644 index 00000000..53b904a0 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_lookup_entry_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for LookupEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_LookupEntry_sync] +from google.cloud import datacatalog_v1 + + +def sample_lookup_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.LookupEntryRequest( + linked_resource="linked_resource_value", + ) + + # Make the request + response = client.lookup_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_LookupEntry_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_contacts_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_contacts_async.py new file mode 100644 index 00000000..0e7e1273 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_contacts_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ModifyEntryContacts +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_ModifyEntryContacts_async] +from google.cloud import datacatalog_v1 + + +async def sample_modify_entry_contacts(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.ModifyEntryContactsRequest( + name="name_value", + ) + + # Make the request + response = await client.modify_entry_contacts(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_ModifyEntryContacts_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_contacts_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_contacts_sync.py new file mode 100644 index 00000000..0093794e --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_contacts_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ModifyEntryContacts +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_ModifyEntryContacts_sync] +from google.cloud import datacatalog_v1 + + +def sample_modify_entry_contacts(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ModifyEntryContactsRequest( + name="name_value", + ) + + # Make the request + response = client.modify_entry_contacts(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_ModifyEntryContacts_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_overview_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_overview_async.py new file mode 100644 index 00000000..46465b23 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_overview_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ModifyEntryOverview +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_ModifyEntryOverview_async] +from google.cloud import datacatalog_v1 + + +async def sample_modify_entry_overview(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.ModifyEntryOverviewRequest( + name="name_value", + ) + + # Make the request + response = await client.modify_entry_overview(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_ModifyEntryOverview_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_overview_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_overview_sync.py new file mode 100644 index 00000000..fedfdd09 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_overview_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ModifyEntryOverview +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_ModifyEntryOverview_sync] +from google.cloud import datacatalog_v1 + + +def sample_modify_entry_overview(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.ModifyEntryOverviewRequest( + name="name_value", + ) + + # Make the request + response = client.modify_entry_overview(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_ModifyEntryOverview_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_async.py new file mode 100644 index 00000000..fd082a39 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for RenameTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_RenameTagTemplateField_async] +from google.cloud import datacatalog_v1 + + +async def sample_rename_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.RenameTagTemplateFieldRequest( + name="name_value", + new_tag_template_field_id="new_tag_template_field_id_value", + ) + + # Make the request + response = await client.rename_tag_template_field(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_RenameTagTemplateField_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_enum_value_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_enum_value_async.py new file mode 100644 index 00000000..e5908b03 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_enum_value_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for RenameTagTemplateFieldEnumValue +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_RenameTagTemplateFieldEnumValue_async] +from google.cloud import datacatalog_v1 + + +async def sample_rename_tag_template_field_enum_value(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.RenameTagTemplateFieldEnumValueRequest( + name="name_value", + new_enum_value_display_name="new_enum_value_display_name_value", + ) + + # Make the request + response = await client.rename_tag_template_field_enum_value(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_RenameTagTemplateFieldEnumValue_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_enum_value_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_enum_value_sync.py new file mode 100644 index 00000000..13003787 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_enum_value_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for RenameTagTemplateFieldEnumValue +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_RenameTagTemplateFieldEnumValue_sync] +from google.cloud import datacatalog_v1 + + +def sample_rename_tag_template_field_enum_value(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.RenameTagTemplateFieldEnumValueRequest( + name="name_value", + new_enum_value_display_name="new_enum_value_display_name_value", + ) + + # Make the request + response = client.rename_tag_template_field_enum_value(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_RenameTagTemplateFieldEnumValue_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_sync.py new file mode 100644 index 00000000..c25511f5 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for RenameTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_RenameTagTemplateField_sync] +from google.cloud import datacatalog_v1 + + +def sample_rename_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.RenameTagTemplateFieldRequest( + name="name_value", + new_tag_template_field_id="new_tag_template_field_id_value", + ) + + # Make the request + response = client.rename_tag_template_field(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_RenameTagTemplateField_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_search_catalog_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_search_catalog_async.py new file mode 100644 index 00000000..932d35b3 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_search_catalog_async.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SearchCatalog +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_SearchCatalog_async] +from google.cloud import datacatalog_v1 + + +async def sample_search_catalog(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.SearchCatalogRequest( + ) + + # Make the request + page_result = client.search_catalog(request=request) + async for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_SearchCatalog_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_search_catalog_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_search_catalog_sync.py new file mode 100644 index 00000000..6f6e9e06 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_search_catalog_sync.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SearchCatalog +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_SearchCatalog_sync] +from google.cloud import datacatalog_v1 + + +def sample_search_catalog(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.SearchCatalogRequest( + ) + + # Make the request + page_result = client.search_catalog(request=request) + for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_SearchCatalog_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_set_iam_policy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_set_iam_policy_async.py new file mode 100644 index 00000000..40bc754c --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_set_iam_policy_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_SetIamPolicy_async] +from google.cloud import datacatalog_v1 + + +async def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = await client.set_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_SetIamPolicy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_set_iam_policy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_set_iam_policy_sync.py new file mode 100644 index 00000000..850f99cb --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_set_iam_policy_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_SetIamPolicy_sync] +from google.cloud import datacatalog_v1 + + +def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.set_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_SetIamPolicy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_star_entry_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_star_entry_async.py new file mode 100644 index 00000000..b56729f6 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_star_entry_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for StarEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_StarEntry_async] +from google.cloud import datacatalog_v1 + + +async def sample_star_entry(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.StarEntryRequest( + name="name_value", + ) + + # Make the request + response = await client.star_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_StarEntry_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_star_entry_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_star_entry_sync.py new file mode 100644 index 00000000..6e31a0df --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_star_entry_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for StarEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_StarEntry_sync] +from google.cloud import datacatalog_v1 + + +def sample_star_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.StarEntryRequest( + name="name_value", + ) + + # Make the request + response = client.star_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_StarEntry_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_test_iam_permissions_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_test_iam_permissions_async.py new file mode 100644 index 00000000..13e429e0 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_test_iam_permissions_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for TestIamPermissions +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_TestIamPermissions_async] +from google.cloud import datacatalog_v1 + + +async def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = await client.test_iam_permissions(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_TestIamPermissions_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_test_iam_permissions_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_test_iam_permissions_sync.py new file mode 100644 index 00000000..200423d2 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_test_iam_permissions_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for TestIamPermissions +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_TestIamPermissions_sync] +from google.cloud import datacatalog_v1 + + +def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = client.test_iam_permissions(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_TestIamPermissions_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_unstar_entry_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_unstar_entry_async.py new file mode 100644 index 00000000..8bfeb0e8 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_unstar_entry_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UnstarEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_UnstarEntry_async] +from google.cloud import datacatalog_v1 + + +async def sample_unstar_entry(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.UnstarEntryRequest( + name="name_value", + ) + + # Make the request + response = await client.unstar_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_UnstarEntry_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_unstar_entry_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_unstar_entry_sync.py new file mode 100644 index 00000000..6861480d --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_unstar_entry_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UnstarEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_UnstarEntry_sync] +from google.cloud import datacatalog_v1 + + +def sample_unstar_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.UnstarEntryRequest( + name="name_value", + ) + + # Make the request + response = client.unstar_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_UnstarEntry_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_entry_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_entry_async.py new file mode 100644 index 00000000..2fb23164 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_entry_async.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_UpdateEntry_async] +from google.cloud import datacatalog_v1 + + +async def sample_update_entry(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + entry = datacatalog_v1.Entry() + entry.type_ = "SERVICE" + entry.integrated_system = "DATAPROC_METASTORE" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1.UpdateEntryRequest( + entry=entry, + ) + + # Make the request + response = await client.update_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_UpdateEntry_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_entry_group_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_entry_group_async.py new file mode 100644 index 00000000..d2267b3c --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_entry_group_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_UpdateEntryGroup_async] +from google.cloud import datacatalog_v1 + + +async def sample_update_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdateEntryGroupRequest( + ) + + # Make the request + response = await client.update_entry_group(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_UpdateEntryGroup_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_entry_group_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_entry_group_sync.py new file mode 100644 index 00000000..3e32a83d --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_entry_group_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_UpdateEntryGroup_sync] +from google.cloud import datacatalog_v1 + + +def sample_update_entry_group(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdateEntryGroupRequest( + ) + + # Make the request + response = client.update_entry_group(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_UpdateEntryGroup_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_entry_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_entry_sync.py new file mode 100644 index 00000000..c526ed58 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_entry_sync.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_UpdateEntry_sync] +from google.cloud import datacatalog_v1 + + +def sample_update_entry(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + entry = datacatalog_v1.Entry() + entry.type_ = "SERVICE" + entry.integrated_system = "DATAPROC_METASTORE" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1.UpdateEntryRequest( + entry=entry, + ) + + # Make the request + response = client.update_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_UpdateEntry_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_async.py new file mode 100644 index 00000000..8687d4a9 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_async.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTag_async] +from google.cloud import datacatalog_v1 + + +async def sample_update_tag(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + tag = datacatalog_v1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1.UpdateTagRequest( + tag=tag, + ) + + # Make the request + response = await client.update_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_sync.py new file mode 100644 index 00000000..b26188b8 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_sync.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTag_sync] +from google.cloud import datacatalog_v1 + + +def sample_update_tag(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + tag = datacatalog_v1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1.UpdateTagRequest( + tag=tag, + ) + + # Make the request + response = client.update_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_async.py new file mode 100644 index 00000000..8db5bd8a --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTagTemplate_async] +from google.cloud import datacatalog_v1 + + +async def sample_update_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdateTagTemplateRequest( + ) + + # Make the request + response = await client.update_tag_template(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTagTemplate_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_field_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_field_async.py new file mode 100644 index 00000000..14ade8fc --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_field_async.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTagTemplateField_async] +from google.cloud import datacatalog_v1 + + +async def sample_update_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogAsyncClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1.TagTemplateField() + tag_template_field.type_.primitive_type = "RICHTEXT" + + request = datacatalog_v1.UpdateTagTemplateFieldRequest( + name="name_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = await client.update_tag_template_field(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTagTemplateField_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_field_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_field_sync.py new file mode 100644 index 00000000..8e9fc850 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_field_sync.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTagTemplateField_sync] +from google.cloud import datacatalog_v1 + + +def sample_update_tag_template_field(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1.TagTemplateField() + tag_template_field.type_.primitive_type = "RICHTEXT" + + request = datacatalog_v1.UpdateTagTemplateFieldRequest( + name="name_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = client.update_tag_template_field(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTagTemplateField_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_sync.py new file mode 100644 index 00000000..f966ada3 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTagTemplate_sync] +from google.cloud import datacatalog_v1 + + +def sample_update_tag_template(): + # Create a client + client = datacatalog_v1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdateTagTemplateRequest( + ) + + # Make the request + response = client.update_tag_template(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTagTemplate_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_create_policy_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_create_policy_tag_async.py new file mode 100644 index 00000000..322b23b9 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_create_policy_tag_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreatePolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_CreatePolicyTag_async] +from google.cloud import datacatalog_v1 + + +async def sample_create_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreatePolicyTagRequest( + parent="parent_value", + ) + + # Make the request + response = await client.create_policy_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_CreatePolicyTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_create_policy_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_create_policy_tag_sync.py new file mode 100644 index 00000000..81a3559a --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_create_policy_tag_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreatePolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_CreatePolicyTag_sync] +from google.cloud import datacatalog_v1 + + +def sample_create_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreatePolicyTagRequest( + parent="parent_value", + ) + + # Make the request + response = client.create_policy_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_CreatePolicyTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_create_taxonomy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_create_taxonomy_async.py new file mode 100644 index 00000000..52b7d43a --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_create_taxonomy_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_CreateTaxonomy_async] +from google.cloud import datacatalog_v1 + + +async def sample_create_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreateTaxonomyRequest( + parent="parent_value", + ) + + # Make the request + response = await client.create_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_CreateTaxonomy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_create_taxonomy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_create_taxonomy_sync.py new file mode 100644 index 00000000..ee5a6f3f --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_create_taxonomy_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_CreateTaxonomy_sync] +from google.cloud import datacatalog_v1 + + +def sample_create_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.CreateTaxonomyRequest( + parent="parent_value", + ) + + # Make the request + response = client.create_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_CreateTaxonomy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_policy_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_policy_tag_async.py new file mode 100644 index 00000000..345f4a2d --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_policy_tag_async.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeletePolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_DeletePolicyTag_async] +from google.cloud import datacatalog_v1 + + +async def sample_delete_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeletePolicyTagRequest( + name="name_value", + ) + + # Make the request + response = await client.delete_policy_tag(request=request) + + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_DeletePolicyTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_policy_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_policy_tag_sync.py new file mode 100644 index 00000000..3f8b0492 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_policy_tag_sync.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeletePolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_DeletePolicyTag_sync] +from google.cloud import datacatalog_v1 + + +def sample_delete_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeletePolicyTagRequest( + name="name_value", + ) + + # Make the request + response = client.delete_policy_tag(request=request) + + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_DeletePolicyTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_taxonomy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_taxonomy_async.py new file mode 100644 index 00000000..7884af7c --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_taxonomy_async.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_DeleteTaxonomy_async] +from google.cloud import datacatalog_v1 + + +async def sample_delete_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = await client.delete_taxonomy(request=request) + + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_DeleteTaxonomy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_taxonomy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_taxonomy_sync.py new file mode 100644 index 00000000..aff65b48 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_taxonomy_sync.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_DeleteTaxonomy_sync] +from google.cloud import datacatalog_v1 + + +def sample_delete_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.DeleteTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = client.delete_taxonomy(request=request) + + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_DeleteTaxonomy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_iam_policy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_iam_policy_async.py new file mode 100644 index 00000000..229d90c3 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_iam_policy_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_GetIamPolicy_async] +from google.cloud import datacatalog_v1 + + +async def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = await client.get_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_GetIamPolicy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_iam_policy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_iam_policy_sync.py new file mode 100644 index 00000000..550c94a8 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_iam_policy_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_GetIamPolicy_sync] +from google.cloud import datacatalog_v1 + + +def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.get_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_GetIamPolicy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_policy_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_policy_tag_async.py new file mode 100644 index 00000000..def3afcb --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_policy_tag_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetPolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_GetPolicyTag_async] +from google.cloud import datacatalog_v1 + + +async def sample_get_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetPolicyTagRequest( + name="name_value", + ) + + # Make the request + response = await client.get_policy_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_GetPolicyTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_policy_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_policy_tag_sync.py new file mode 100644 index 00000000..6645bd72 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_policy_tag_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetPolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_GetPolicyTag_sync] +from google.cloud import datacatalog_v1 + + +def sample_get_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetPolicyTagRequest( + name="name_value", + ) + + # Make the request + response = client.get_policy_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_GetPolicyTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_taxonomy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_taxonomy_async.py new file mode 100644 index 00000000..c2549152 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_taxonomy_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_GetTaxonomy_async] +from google.cloud import datacatalog_v1 + + +async def sample_get_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = await client.get_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_GetTaxonomy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_taxonomy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_taxonomy_sync.py new file mode 100644 index 00000000..dd6e4d6e --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_get_taxonomy_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_GetTaxonomy_sync] +from google.cloud import datacatalog_v1 + + +def sample_get_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.GetTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = client.get_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_GetTaxonomy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_list_policy_tags_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_list_policy_tags_async.py new file mode 100644 index 00000000..8d817667 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_list_policy_tags_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListPolicyTags +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_ListPolicyTags_async] +from google.cloud import datacatalog_v1 + + +async def sample_list_policy_tags(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListPolicyTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_policy_tags(request=request) + async for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_ListPolicyTags_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_list_policy_tags_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_list_policy_tags_sync.py new file mode 100644 index 00000000..a1a71f45 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_list_policy_tags_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListPolicyTags +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_ListPolicyTags_sync] +from google.cloud import datacatalog_v1 + + +def sample_list_policy_tags(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListPolicyTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_policy_tags(request=request) + for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_ListPolicyTags_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_list_taxonomies_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_list_taxonomies_async.py new file mode 100644 index 00000000..11d9283f --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_list_taxonomies_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListTaxonomies +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_ListTaxonomies_async] +from google.cloud import datacatalog_v1 + + +async def sample_list_taxonomies(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListTaxonomiesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_taxonomies(request=request) + async for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_ListTaxonomies_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_list_taxonomies_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_list_taxonomies_sync.py new file mode 100644 index 00000000..8c2a57b8 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_list_taxonomies_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListTaxonomies +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_ListTaxonomies_sync] +from google.cloud import datacatalog_v1 + + +def sample_list_taxonomies(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.ListTaxonomiesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_taxonomies(request=request) + for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_ListTaxonomies_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_export_taxonomies_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_export_taxonomies_async.py new file mode 100644 index 00000000..fa9ee76d --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_export_taxonomies_async.py @@ -0,0 +1,47 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ExportTaxonomies +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ExportTaxonomies_async] +from google.cloud import datacatalog_v1 + + +async def sample_export_taxonomies(): + # Create a client + client = datacatalog_v1.PolicyTagManagerSerializationAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.ExportTaxonomiesRequest( + serialized_taxonomies=True, + parent="parent_value", + taxonomies=['taxonomies_value_1', 'taxonomies_value_2'], + ) + + # Make the request + response = await client.export_taxonomies(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ExportTaxonomies_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_export_taxonomies_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_export_taxonomies_sync.py new file mode 100644 index 00000000..7704aab7 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_export_taxonomies_sync.py @@ -0,0 +1,47 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ExportTaxonomies +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ExportTaxonomies_sync] +from google.cloud import datacatalog_v1 + + +def sample_export_taxonomies(): + # Create a client + client = datacatalog_v1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + request = datacatalog_v1.ExportTaxonomiesRequest( + serialized_taxonomies=True, + parent="parent_value", + taxonomies=['taxonomies_value_1', 'taxonomies_value_2'], + ) + + # Make the request + response = client.export_taxonomies(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ExportTaxonomies_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_import_taxonomies_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_import_taxonomies_async.py new file mode 100644 index 00000000..c0a07ec6 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_import_taxonomies_async.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ImportTaxonomies +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ImportTaxonomies_async] +from google.cloud import datacatalog_v1 + + +async def sample_import_taxonomies(): + # Create a client + client = datacatalog_v1.PolicyTagManagerSerializationAsyncClient() + + # Initialize request argument(s) + inline_source = datacatalog_v1.InlineSource() + inline_source.taxonomies.display_name = "display_name_value" + + request = datacatalog_v1.ImportTaxonomiesRequest( + inline_source=inline_source, + parent="parent_value", + ) + + # Make the request + response = await client.import_taxonomies(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ImportTaxonomies_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_import_taxonomies_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_import_taxonomies_sync.py new file mode 100644 index 00000000..318219c4 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_import_taxonomies_sync.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ImportTaxonomies +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ImportTaxonomies_sync] +from google.cloud import datacatalog_v1 + + +def sample_import_taxonomies(): + # Create a client + client = datacatalog_v1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + inline_source = datacatalog_v1.InlineSource() + inline_source.taxonomies.display_name = "display_name_value" + + request = datacatalog_v1.ImportTaxonomiesRequest( + inline_source=inline_source, + parent="parent_value", + ) + + # Make the request + response = client.import_taxonomies(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ImportTaxonomies_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_replace_taxonomy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_replace_taxonomy_async.py new file mode 100644 index 00000000..47439f70 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_replace_taxonomy_async.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ReplaceTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ReplaceTaxonomy_async] +from google.cloud import datacatalog_v1 + + +async def sample_replace_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerSerializationAsyncClient() + + # Initialize request argument(s) + serialized_taxonomy = datacatalog_v1.SerializedTaxonomy() + serialized_taxonomy.display_name = "display_name_value" + + request = datacatalog_v1.ReplaceTaxonomyRequest( + name="name_value", + serialized_taxonomy=serialized_taxonomy, + ) + + # Make the request + response = await client.replace_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ReplaceTaxonomy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_replace_taxonomy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_replace_taxonomy_sync.py new file mode 100644 index 00000000..202179e7 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_replace_taxonomy_sync.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ReplaceTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ReplaceTaxonomy_sync] +from google.cloud import datacatalog_v1 + + +def sample_replace_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + serialized_taxonomy = datacatalog_v1.SerializedTaxonomy() + serialized_taxonomy.display_name = "display_name_value" + + request = datacatalog_v1.ReplaceTaxonomyRequest( + name="name_value", + serialized_taxonomy=serialized_taxonomy, + ) + + # Make the request + response = client.replace_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ReplaceTaxonomy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_set_iam_policy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_set_iam_policy_async.py new file mode 100644 index 00000000..254902d5 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_set_iam_policy_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_SetIamPolicy_async] +from google.cloud import datacatalog_v1 + + +async def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = await client.set_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_SetIamPolicy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_set_iam_policy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_set_iam_policy_sync.py new file mode 100644 index 00000000..f6508608 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_set_iam_policy_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_SetIamPolicy_sync] +from google.cloud import datacatalog_v1 + + +def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.set_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_SetIamPolicy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_test_iam_permissions_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_test_iam_permissions_async.py new file mode 100644 index 00000000..7c9609ba --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_test_iam_permissions_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for TestIamPermissions +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_TestIamPermissions_async] +from google.cloud import datacatalog_v1 + + +async def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = await client.test_iam_permissions(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_TestIamPermissions_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_test_iam_permissions_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_test_iam_permissions_sync.py new file mode 100644 index 00000000..a9c463c9 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_test_iam_permissions_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for TestIamPermissions +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_TestIamPermissions_sync] +from google.cloud import datacatalog_v1 + + +def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = client.test_iam_permissions(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_TestIamPermissions_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_update_policy_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_update_policy_tag_async.py new file mode 100644 index 00000000..1457400e --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_update_policy_tag_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdatePolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_UpdatePolicyTag_async] +from google.cloud import datacatalog_v1 + + +async def sample_update_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdatePolicyTagRequest( + ) + + # Make the request + response = await client.update_policy_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_UpdatePolicyTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_update_policy_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_update_policy_tag_sync.py new file mode 100644 index 00000000..f181fdf7 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_update_policy_tag_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdatePolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_UpdatePolicyTag_sync] +from google.cloud import datacatalog_v1 + + +def sample_update_policy_tag(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdatePolicyTagRequest( + ) + + # Make the request + response = client.update_policy_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_UpdatePolicyTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_update_taxonomy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_update_taxonomy_async.py new file mode 100644 index 00000000..e3f3ff1f --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_update_taxonomy_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_UpdateTaxonomy_async] +from google.cloud import datacatalog_v1 + + +async def sample_update_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdateTaxonomyRequest( + ) + + # Make the request + response = await client.update_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_UpdateTaxonomy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_update_taxonomy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_update_taxonomy_sync.py new file mode 100644 index 00000000..a00b4656 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1_policy_tag_manager_update_taxonomy_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1_PolicyTagManager_UpdateTaxonomy_sync] +from google.cloud import datacatalog_v1 + + +def sample_update_taxonomy(): + # Create a client + client = datacatalog_v1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1.UpdateTaxonomyRequest( + ) + + # Make the request + response = client.update_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1_PolicyTagManager_UpdateTaxonomy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_async.py new file mode 100644 index 00000000..fc8de846 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_async.py @@ -0,0 +1,52 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateEntry_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_create_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + entry = datacatalog_v1beta1.Entry() + entry.type_ = "FILESET" + entry.integrated_system = "CLOUD_PUBSUB" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1beta1.CreateEntryRequest( + parent="parent_value", + entry_id="entry_id_value", + entry=entry, + ) + + # Make the request + response = await client.create_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateEntry_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_group_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_group_async.py new file mode 100644 index 00000000..e0efa9cb --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_group_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateEntryGroup_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_create_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreateEntryGroupRequest( + parent="parent_value", + entry_group_id="entry_group_id_value", + ) + + # Make the request + response = await client.create_entry_group(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateEntryGroup_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_group_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_group_sync.py new file mode 100644 index 00000000..8fb35155 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_group_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateEntryGroup_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_create_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreateEntryGroupRequest( + parent="parent_value", + entry_group_id="entry_group_id_value", + ) + + # Make the request + response = client.create_entry_group(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateEntryGroup_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_sync.py new file mode 100644 index 00000000..d7842671 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_sync.py @@ -0,0 +1,52 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateEntry_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_create_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + entry = datacatalog_v1beta1.Entry() + entry.type_ = "FILESET" + entry.integrated_system = "CLOUD_PUBSUB" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1beta1.CreateEntryRequest( + parent="parent_value", + entry_id="entry_id_value", + entry=entry, + ) + + # Make the request + response = client.create_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateEntry_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_async.py new file mode 100644 index 00000000..dc856b61 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_async.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTag_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_create_tag(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + tag = datacatalog_v1beta1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1beta1.CreateTagRequest( + parent="parent_value", + tag=tag, + ) + + # Make the request + response = await client.create_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_sync.py new file mode 100644 index 00000000..12953e51 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_sync.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTag_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_create_tag(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + tag = datacatalog_v1beta1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1beta1.CreateTagRequest( + parent="parent_value", + tag=tag, + ) + + # Make the request + response = client.create_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_async.py new file mode 100644 index 00000000..9be0d57c --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTagTemplate_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_create_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreateTagTemplateRequest( + parent="parent_value", + tag_template_id="tag_template_id_value", + ) + + # Make the request + response = await client.create_tag_template(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTagTemplate_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_field_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_field_async.py new file mode 100644 index 00000000..79074c87 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_field_async.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTagTemplateField_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_create_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1beta1.TagTemplateField() + tag_template_field.type_.primitive_type = "TIMESTAMP" + + request = datacatalog_v1beta1.CreateTagTemplateFieldRequest( + parent="parent_value", + tag_template_field_id="tag_template_field_id_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = await client.create_tag_template_field(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTagTemplateField_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_field_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_field_sync.py new file mode 100644 index 00000000..3a5152b4 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_field_sync.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTagTemplateField_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_create_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1beta1.TagTemplateField() + tag_template_field.type_.primitive_type = "TIMESTAMP" + + request = datacatalog_v1beta1.CreateTagTemplateFieldRequest( + parent="parent_value", + tag_template_field_id="tag_template_field_id_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = client.create_tag_template_field(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTagTemplateField_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_sync.py new file mode 100644 index 00000000..5aa18c37 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTagTemplate_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_create_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreateTagTemplateRequest( + parent="parent_value", + tag_template_id="tag_template_id_value", + ) + + # Make the request + response = client.create_tag_template(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTagTemplate_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_async.py new file mode 100644 index 00000000..dda423f0 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_async.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteEntry_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_delete_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteEntryRequest( + name="name_value", + ) + + # Make the request + response = await client.delete_entry(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteEntry_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_group_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_group_async.py new file mode 100644 index 00000000..7eae354b --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_group_async.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteEntryGroup_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_delete_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = await client.delete_entry_group(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteEntryGroup_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_group_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_group_sync.py new file mode 100644 index 00000000..aa7f2084 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_group_sync.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteEntryGroup_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_delete_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = client.delete_entry_group(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteEntryGroup_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_sync.py new file mode 100644 index 00000000..471e25d7 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_sync.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteEntry_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_delete_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteEntryRequest( + name="name_value", + ) + + # Make the request + response = client.delete_entry(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteEntry_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_async.py new file mode 100644 index 00000000..0e16ad45 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_async.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTag_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_delete_tag(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTagRequest( + name="name_value", + ) + + # Make the request + response = await client.delete_tag(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_sync.py new file mode 100644 index 00000000..18fbe8fc --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_sync.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTag_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_delete_tag(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTagRequest( + name="name_value", + ) + + # Make the request + response = client.delete_tag(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_async.py new file mode 100644 index 00000000..262081be --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTagTemplate_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_delete_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTagTemplateRequest( + name="name_value", + force=True, + ) + + # Make the request + response = await client.delete_tag_template(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTagTemplate_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_field_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_field_async.py new file mode 100644 index 00000000..10f410e3 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_field_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTagTemplateField_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_delete_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTagTemplateFieldRequest( + name="name_value", + force=True, + ) + + # Make the request + response = await client.delete_tag_template_field(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTagTemplateField_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_field_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_field_sync.py new file mode 100644 index 00000000..456b15f1 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_field_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTagTemplateField_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_delete_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTagTemplateFieldRequest( + name="name_value", + force=True, + ) + + # Make the request + response = client.delete_tag_template_field(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTagTemplateField_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_sync.py new file mode 100644 index 00000000..b5b9f80f --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTagTemplate_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_delete_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTagTemplateRequest( + name="name_value", + force=True, + ) + + # Make the request + response = client.delete_tag_template(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTagTemplate_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_async.py new file mode 100644 index 00000000..a0a0939d --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetEntry_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_get_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetEntryRequest( + name="name_value", + ) + + # Make the request + response = await client.get_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetEntry_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_group_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_group_async.py new file mode 100644 index 00000000..1f4d0d9e --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_group_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetEntryGroup_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_get_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = await client.get_entry_group(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetEntryGroup_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_group_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_group_sync.py new file mode 100644 index 00000000..3e46462c --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_group_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetEntryGroup_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_get_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetEntryGroupRequest( + name="name_value", + ) + + # Make the request + response = client.get_entry_group(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetEntryGroup_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_sync.py new file mode 100644 index 00000000..accc037e --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetEntry_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_get_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetEntryRequest( + name="name_value", + ) + + # Make the request + response = client.get_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetEntry_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_iam_policy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_iam_policy_async.py new file mode 100644 index 00000000..6d538055 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_iam_policy_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetIamPolicy_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = await client.get_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetIamPolicy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_iam_policy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_iam_policy_sync.py new file mode 100644 index 00000000..a259c31e --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_iam_policy_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetIamPolicy_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.get_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetIamPolicy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_tag_template_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_tag_template_async.py new file mode 100644 index 00000000..dcd03dc7 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_tag_template_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetTagTemplate_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_get_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetTagTemplateRequest( + name="name_value", + ) + + # Make the request + response = await client.get_tag_template(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetTagTemplate_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_tag_template_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_tag_template_sync.py new file mode 100644 index 00000000..6fc7cc34 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_get_tag_template_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetTagTemplate_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_get_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetTagTemplateRequest( + name="name_value", + ) + + # Make the request + response = client.get_tag_template(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetTagTemplate_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entries_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entries_async.py new file mode 100644 index 00000000..dd5be688 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entries_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListEntries +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListEntries_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_list_entries(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListEntriesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entries(request=request) + async for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListEntries_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entries_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entries_sync.py new file mode 100644 index 00000000..ecbf0240 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entries_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListEntries +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListEntries_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_list_entries(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListEntriesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entries(request=request) + for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListEntries_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entry_groups_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entry_groups_async.py new file mode 100644 index 00000000..faefc14f --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entry_groups_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListEntryGroups +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListEntryGroups_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_list_entry_groups(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListEntryGroupsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entry_groups(request=request) + async for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListEntryGroups_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entry_groups_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entry_groups_sync.py new file mode 100644 index 00000000..7a524fab --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entry_groups_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListEntryGroups +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListEntryGroups_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_list_entry_groups(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListEntryGroupsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_entry_groups(request=request) + for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListEntryGroups_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_tags_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_tags_async.py new file mode 100644 index 00000000..86656f37 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_tags_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListTags +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListTags_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_list_tags(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_tags(request=request) + async for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListTags_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_tags_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_tags_sync.py new file mode 100644 index 00000000..ee517721 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_list_tags_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListTags +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListTags_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_list_tags(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_tags(request=request) + for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListTags_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_lookup_entry_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_lookup_entry_async.py new file mode 100644 index 00000000..ba0d750c --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_lookup_entry_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for LookupEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_LookupEntry_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_lookup_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.LookupEntryRequest( + linked_resource="linked_resource_value", + ) + + # Make the request + response = await client.lookup_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_LookupEntry_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_lookup_entry_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_lookup_entry_sync.py new file mode 100644 index 00000000..dd278571 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_lookup_entry_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for LookupEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_LookupEntry_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_lookup_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.LookupEntryRequest( + linked_resource="linked_resource_value", + ) + + # Make the request + response = client.lookup_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_LookupEntry_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_rename_tag_template_field_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_rename_tag_template_field_async.py new file mode 100644 index 00000000..1dddf388 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_rename_tag_template_field_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for RenameTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_RenameTagTemplateField_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_rename_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.RenameTagTemplateFieldRequest( + name="name_value", + new_tag_template_field_id="new_tag_template_field_id_value", + ) + + # Make the request + response = await client.rename_tag_template_field(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_RenameTagTemplateField_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_rename_tag_template_field_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_rename_tag_template_field_sync.py new file mode 100644 index 00000000..3a44462e --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_rename_tag_template_field_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for RenameTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_RenameTagTemplateField_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_rename_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.RenameTagTemplateFieldRequest( + name="name_value", + new_tag_template_field_id="new_tag_template_field_id_value", + ) + + # Make the request + response = client.rename_tag_template_field(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_RenameTagTemplateField_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_search_catalog_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_search_catalog_async.py new file mode 100644 index 00000000..eb678a7f --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_search_catalog_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SearchCatalog +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_SearchCatalog_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_search_catalog(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.SearchCatalogRequest( + query="query_value", + ) + + # Make the request + page_result = client.search_catalog(request=request) + async for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_SearchCatalog_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_search_catalog_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_search_catalog_sync.py new file mode 100644 index 00000000..cf65c211 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_search_catalog_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SearchCatalog +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_SearchCatalog_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_search_catalog(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.SearchCatalogRequest( + query="query_value", + ) + + # Make the request + page_result = client.search_catalog(request=request) + for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_SearchCatalog_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_set_iam_policy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_set_iam_policy_async.py new file mode 100644 index 00000000..c5871bc8 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_set_iam_policy_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_SetIamPolicy_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = await client.set_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_SetIamPolicy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_set_iam_policy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_set_iam_policy_sync.py new file mode 100644 index 00000000..870ceb6b --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_set_iam_policy_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_SetIamPolicy_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.set_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_SetIamPolicy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_test_iam_permissions_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_test_iam_permissions_async.py new file mode 100644 index 00000000..e653fa9f --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_test_iam_permissions_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for TestIamPermissions +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_TestIamPermissions_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = await client.test_iam_permissions(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_TestIamPermissions_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_test_iam_permissions_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_test_iam_permissions_sync.py new file mode 100644 index 00000000..9146f6ab --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_test_iam_permissions_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for TestIamPermissions +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_TestIamPermissions_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = client.test_iam_permissions(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_TestIamPermissions_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_async.py new file mode 100644 index 00000000..b3740a2b --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_async.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateEntry_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_update_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + entry = datacatalog_v1beta1.Entry() + entry.type_ = "FILESET" + entry.integrated_system = "CLOUD_PUBSUB" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1beta1.UpdateEntryRequest( + entry=entry, + ) + + # Make the request + response = await client.update_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateEntry_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_group_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_group_async.py new file mode 100644 index 00000000..b83ed5b0 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_group_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateEntryGroup_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_update_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdateEntryGroupRequest( + ) + + # Make the request + response = await client.update_entry_group(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateEntryGroup_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_group_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_group_sync.py new file mode 100644 index 00000000..0cdcb896 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_group_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateEntryGroup +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateEntryGroup_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_update_entry_group(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdateEntryGroupRequest( + ) + + # Make the request + response = client.update_entry_group(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateEntryGroup_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_sync.py new file mode 100644 index 00000000..ea8a5bb4 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_sync.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateEntry +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateEntry_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_update_entry(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + entry = datacatalog_v1beta1.Entry() + entry.type_ = "FILESET" + entry.integrated_system = "CLOUD_PUBSUB" + entry.gcs_fileset_spec.file_patterns = ['file_patterns_value_1', 'file_patterns_value_2'] + + request = datacatalog_v1beta1.UpdateEntryRequest( + entry=entry, + ) + + # Make the request + response = client.update_entry(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateEntry_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_async.py new file mode 100644 index 00000000..5a0aca4f --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_async.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTag_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_update_tag(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + tag = datacatalog_v1beta1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1beta1.UpdateTagRequest( + tag=tag, + ) + + # Make the request + response = await client.update_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_sync.py new file mode 100644 index 00000000..476f75aa --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_sync.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTag_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_update_tag(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + tag = datacatalog_v1beta1.Tag() + tag.column = "column_value" + tag.template = "template_value" + + request = datacatalog_v1beta1.UpdateTagRequest( + tag=tag, + ) + + # Make the request + response = client.update_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_async.py new file mode 100644 index 00000000..46987c08 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTagTemplate_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_update_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdateTagTemplateRequest( + ) + + # Make the request + response = await client.update_tag_template(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTagTemplate_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_field_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_field_async.py new file mode 100644 index 00000000..2be9072d --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_field_async.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTagTemplateField_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_update_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogAsyncClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1beta1.TagTemplateField() + tag_template_field.type_.primitive_type = "TIMESTAMP" + + request = datacatalog_v1beta1.UpdateTagTemplateFieldRequest( + name="name_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = await client.update_tag_template_field(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTagTemplateField_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_field_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_field_sync.py new file mode 100644 index 00000000..e9adaaad --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_field_sync.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTagTemplateField +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTagTemplateField_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_update_tag_template_field(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + tag_template_field = datacatalog_v1beta1.TagTemplateField() + tag_template_field.type_.primitive_type = "TIMESTAMP" + + request = datacatalog_v1beta1.UpdateTagTemplateFieldRequest( + name="name_value", + tag_template_field=tag_template_field, + ) + + # Make the request + response = client.update_tag_template_field(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTagTemplateField_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_sync.py new file mode 100644 index 00000000..8faaf4ac --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTagTemplate +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTagTemplate_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_update_tag_template(): + # Create a client + client = datacatalog_v1beta1.DataCatalogClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdateTagTemplateRequest( + ) + + # Make the request + response = client.update_tag_template(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTagTemplate_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_policy_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_policy_tag_async.py new file mode 100644 index 00000000..80e7a86d --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_policy_tag_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreatePolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_CreatePolicyTag_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_create_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreatePolicyTagRequest( + parent="parent_value", + ) + + # Make the request + response = await client.create_policy_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_CreatePolicyTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_policy_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_policy_tag_sync.py new file mode 100644 index 00000000..86909070 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_policy_tag_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreatePolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_CreatePolicyTag_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_create_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreatePolicyTagRequest( + parent="parent_value", + ) + + # Make the request + response = client.create_policy_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_CreatePolicyTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_taxonomy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_taxonomy_async.py new file mode 100644 index 00000000..4a16b227 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_taxonomy_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_CreateTaxonomy_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_create_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreateTaxonomyRequest( + parent="parent_value", + ) + + # Make the request + response = await client.create_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_CreateTaxonomy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_taxonomy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_taxonomy_sync.py new file mode 100644 index 00000000..fbaf1d0a --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_taxonomy_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for CreateTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_CreateTaxonomy_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_create_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.CreateTaxonomyRequest( + parent="parent_value", + ) + + # Make the request + response = client.create_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_CreateTaxonomy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_policy_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_policy_tag_async.py new file mode 100644 index 00000000..0c36a2fd --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_policy_tag_async.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeletePolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_DeletePolicyTag_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_delete_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeletePolicyTagRequest( + name="name_value", + ) + + # Make the request + response = await client.delete_policy_tag(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_DeletePolicyTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_policy_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_policy_tag_sync.py new file mode 100644 index 00000000..34f85039 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_policy_tag_sync.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeletePolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_DeletePolicyTag_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_delete_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeletePolicyTagRequest( + name="name_value", + ) + + # Make the request + response = client.delete_policy_tag(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_DeletePolicyTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_taxonomy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_taxonomy_async.py new file mode 100644 index 00000000..040ab8ac --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_taxonomy_async.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_DeleteTaxonomy_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_delete_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = await client.delete_taxonomy(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_DeleteTaxonomy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_taxonomy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_taxonomy_sync.py new file mode 100644 index 00000000..efb483f9 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_taxonomy_sync.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for DeleteTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_DeleteTaxonomy_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_delete_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.DeleteTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = client.delete_taxonomy(request=request) + + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_DeleteTaxonomy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_iam_policy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_iam_policy_async.py new file mode 100644 index 00000000..c9c0c4ba --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_iam_policy_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetIamPolicy_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = await client.get_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetIamPolicy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_iam_policy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_iam_policy_sync.py new file mode 100644 index 00000000..91510782 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_iam_policy_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetIamPolicy_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_get_iam_policy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.get_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetIamPolicy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_policy_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_policy_tag_async.py new file mode 100644 index 00000000..26fa4eff --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_policy_tag_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetPolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetPolicyTag_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_get_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetPolicyTagRequest( + name="name_value", + ) + + # Make the request + response = await client.get_policy_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetPolicyTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_policy_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_policy_tag_sync.py new file mode 100644 index 00000000..d61d1640 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_policy_tag_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetPolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetPolicyTag_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_get_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetPolicyTagRequest( + name="name_value", + ) + + # Make the request + response = client.get_policy_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetPolicyTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_taxonomy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_taxonomy_async.py new file mode 100644 index 00000000..a5755e7d --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_taxonomy_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetTaxonomy_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_get_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = await client.get_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetTaxonomy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_taxonomy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_taxonomy_sync.py new file mode 100644 index 00000000..f375162d --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_taxonomy_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for GetTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetTaxonomy_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_get_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.GetTaxonomyRequest( + name="name_value", + ) + + # Make the request + response = client.get_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetTaxonomy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_policy_tags_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_policy_tags_async.py new file mode 100644 index 00000000..056082d9 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_policy_tags_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListPolicyTags +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_ListPolicyTags_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_list_policy_tags(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListPolicyTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_policy_tags(request=request) + async for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_ListPolicyTags_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_policy_tags_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_policy_tags_sync.py new file mode 100644 index 00000000..12c64eb4 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_policy_tags_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListPolicyTags +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_ListPolicyTags_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_list_policy_tags(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListPolicyTagsRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_policy_tags(request=request) + for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_ListPolicyTags_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_taxonomies_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_taxonomies_async.py new file mode 100644 index 00000000..91eb49f6 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_taxonomies_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListTaxonomies +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_ListTaxonomies_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_list_taxonomies(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListTaxonomiesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_taxonomies(request=request) + async for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_ListTaxonomies_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_taxonomies_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_taxonomies_sync.py new file mode 100644 index 00000000..56da603d --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_taxonomies_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ListTaxonomies +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_ListTaxonomies_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_list_taxonomies(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ListTaxonomiesRequest( + parent="parent_value", + ) + + # Make the request + page_result = client.list_taxonomies(request=request) + for response in page_result: + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_ListTaxonomies_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_export_taxonomies_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_export_taxonomies_async.py new file mode 100644 index 00000000..30847202 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_export_taxonomies_async.py @@ -0,0 +1,47 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ExportTaxonomies +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManagerSerialization_ExportTaxonomies_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_export_taxonomies(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerSerializationAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ExportTaxonomiesRequest( + serialized_taxonomies=True, + parent="parent_value", + taxonomies=['taxonomies_value_1', 'taxonomies_value_2'], + ) + + # Make the request + response = await client.export_taxonomies(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManagerSerialization_ExportTaxonomies_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_export_taxonomies_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_export_taxonomies_sync.py new file mode 100644 index 00000000..10fd99a3 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_export_taxonomies_sync.py @@ -0,0 +1,47 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ExportTaxonomies +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManagerSerialization_ExportTaxonomies_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_export_taxonomies(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.ExportTaxonomiesRequest( + serialized_taxonomies=True, + parent="parent_value", + taxonomies=['taxonomies_value_1', 'taxonomies_value_2'], + ) + + # Make the request + response = client.export_taxonomies(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManagerSerialization_ExportTaxonomies_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_import_taxonomies_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_import_taxonomies_async.py new file mode 100644 index 00000000..afe1d48c --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_import_taxonomies_async.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ImportTaxonomies +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManagerSerialization_ImportTaxonomies_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_import_taxonomies(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerSerializationAsyncClient() + + # Initialize request argument(s) + inline_source = datacatalog_v1beta1.InlineSource() + inline_source.taxonomies.display_name = "display_name_value" + + request = datacatalog_v1beta1.ImportTaxonomiesRequest( + inline_source=inline_source, + parent="parent_value", + ) + + # Make the request + response = await client.import_taxonomies(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManagerSerialization_ImportTaxonomies_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_import_taxonomies_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_import_taxonomies_sync.py new file mode 100644 index 00000000..388d4eff --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_import_taxonomies_sync.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for ImportTaxonomies +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManagerSerialization_ImportTaxonomies_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_import_taxonomies(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerSerializationClient() + + # Initialize request argument(s) + inline_source = datacatalog_v1beta1.InlineSource() + inline_source.taxonomies.display_name = "display_name_value" + + request = datacatalog_v1beta1.ImportTaxonomiesRequest( + inline_source=inline_source, + parent="parent_value", + ) + + # Make the request + response = client.import_taxonomies(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManagerSerialization_ImportTaxonomies_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_set_iam_policy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_set_iam_policy_async.py new file mode 100644 index 00000000..62900ac2 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_set_iam_policy_async.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_SetIamPolicy_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = await client.set_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_SetIamPolicy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_set_iam_policy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_set_iam_policy_sync.py new file mode 100644 index 00000000..e2c88c0e --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_set_iam_policy_sync.py @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for SetIamPolicy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_SetIamPolicy_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_set_iam_policy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.SetIamPolicyRequest( + resource="resource_value", + ) + + # Make the request + response = client.set_iam_policy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_SetIamPolicy_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_test_iam_permissions_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_test_iam_permissions_async.py new file mode 100644 index 00000000..637e4e12 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_test_iam_permissions_async.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for TestIamPermissions +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_TestIamPermissions_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = await client.test_iam_permissions(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_TestIamPermissions_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_test_iam_permissions_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_test_iam_permissions_sync.py new file mode 100644 index 00000000..a3fb78f7 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_test_iam_permissions_sync.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for TestIamPermissions +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_TestIamPermissions_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_test_iam_permissions(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.TestIamPermissionsRequest( + resource="resource_value", + permissions=['permissions_value_1', 'permissions_value_2'], + ) + + # Make the request + response = client.test_iam_permissions(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_TestIamPermissions_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_policy_tag_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_policy_tag_async.py new file mode 100644 index 00000000..f7e0d9a6 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_policy_tag_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdatePolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_UpdatePolicyTag_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_update_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdatePolicyTagRequest( + ) + + # Make the request + response = await client.update_policy_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_UpdatePolicyTag_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_policy_tag_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_policy_tag_sync.py new file mode 100644 index 00000000..ff0afafe --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_policy_tag_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdatePolicyTag +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_UpdatePolicyTag_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_update_policy_tag(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdatePolicyTagRequest( + ) + + # Make the request + response = client.update_policy_tag(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_UpdatePolicyTag_sync] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_taxonomy_async.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_taxonomy_async.py new file mode 100644 index 00000000..a67e5b1d --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_taxonomy_async.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_UpdateTaxonomy_async] +from google.cloud import datacatalog_v1beta1 + + +async def sample_update_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerAsyncClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdateTaxonomyRequest( + ) + + # Make the request + response = await client.update_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_UpdateTaxonomy_async] diff --git a/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_taxonomy_sync.py b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_taxonomy_sync.py new file mode 100644 index 00000000..fe7dde98 --- /dev/null +++ b/samples/generated_samples/datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_taxonomy_sync.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Generated code. DO NOT EDIT! +# +# Snippet for UpdateTaxonomy +# NOTE: This snippet has been automatically generated for illustrative purposes only. +# It may require modifications to work in your environment. + +# To install the latest published package dependency, execute the following: +# python3 -m pip install google-cloud-datacatalog + + +# [START datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_UpdateTaxonomy_sync] +from google.cloud import datacatalog_v1beta1 + + +def sample_update_taxonomy(): + # Create a client + client = datacatalog_v1beta1.PolicyTagManagerClient() + + # Initialize request argument(s) + request = datacatalog_v1beta1.UpdateTaxonomyRequest( + ) + + # Make the request + response = client.update_taxonomy(request=request) + + # Handle response + print(response) + +# [END datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_UpdateTaxonomy_sync] diff --git a/samples/generated_samples/snippet_metadata_datacatalog_v1.json b/samples/generated_samples/snippet_metadata_datacatalog_v1.json new file mode 100644 index 00000000..19ce54de --- /dev/null +++ b/samples/generated_samples/snippet_metadata_datacatalog_v1.json @@ -0,0 +1,4224 @@ +{ + "snippets": [ + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_create_entry_group_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_CreateEntryGroup_async", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_create_entry_group_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_CreateEntryGroup_sync", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_create_entry_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_CreateEntry_async", + "segments": [ + { + "end": 51, + "start": 27, + "type": "FULL" + }, + { + "end": 51, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 45, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 48, + "start": 46, + "type": "REQUEST_EXECUTION" + }, + { + "end": 52, + "start": 49, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_create_entry_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_CreateEntry_sync", + "segments": [ + { + "end": 51, + "start": 27, + "type": "FULL" + }, + { + "end": 51, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 45, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 48, + "start": 46, + "type": "REQUEST_EXECUTION" + }, + { + "end": 52, + "start": 49, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_field_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_CreateTagTemplateField_async", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_field_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_CreateTagTemplateField_sync", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_CreateTagTemplate_async", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_create_tag_template_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_CreateTagTemplate_sync", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_create_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_CreateTag_async", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_create_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_CreateTag_sync", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_group_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_DeleteEntryGroup_async", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_group_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_DeleteEntryGroup_sync", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_DeleteEntry_async", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_delete_entry_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_DeleteEntry_sync", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_field_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTagTemplateField_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_field_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTagTemplateField_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTagTemplate_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_template_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTagTemplate_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTag_async", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_delete_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_DeleteTag_sync", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_get_entry_group_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_GetEntryGroup_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_get_entry_group_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_GetEntryGroup_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_get_entry_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_GetEntry_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_get_entry_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_GetEntry_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_get_iam_policy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_GetIamPolicy_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_get_iam_policy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_GetIamPolicy_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_get_tag_template_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_GetTagTemplate_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_get_tag_template_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_GetTagTemplate_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ListEntries" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_list_entries_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_ListEntries_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ListEntries" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_list_entries_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_ListEntries_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ListEntryGroups" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_list_entry_groups_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_ListEntryGroups_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ListEntryGroups" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_list_entry_groups_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_ListEntryGroups_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ListTags" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_list_tags_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_ListTags_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ListTags" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_list_tags_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_ListTags_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "LookupEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_lookup_entry_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_LookupEntry_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "LookupEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_lookup_entry_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_LookupEntry_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ModifyEntryContacts" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_contacts_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_ModifyEntryContacts_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ModifyEntryContacts" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_contacts_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_ModifyEntryContacts_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ModifyEntryOverview" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_overview_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_ModifyEntryOverview_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ModifyEntryOverview" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_modify_entry_overview_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_ModifyEntryOverview_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "RenameTagTemplateFieldEnumValue" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_enum_value_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_RenameTagTemplateFieldEnumValue_async", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "RenameTagTemplateFieldEnumValue" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_enum_value_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_RenameTagTemplateFieldEnumValue_sync", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "RenameTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_RenameTagTemplateField_async", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "RenameTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_rename_tag_template_field_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_RenameTagTemplateField_sync", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "SearchCatalog" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_search_catalog_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_SearchCatalog_async", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "SearchCatalog" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_search_catalog_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_SearchCatalog_sync", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "SetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_set_iam_policy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_SetIamPolicy_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "SetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_set_iam_policy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_SetIamPolicy_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "StarEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_star_entry_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_StarEntry_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "StarEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_star_entry_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_StarEntry_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "TestIamPermissions" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_test_iam_permissions_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_TestIamPermissions_async", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "TestIamPermissions" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_test_iam_permissions_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_TestIamPermissions_sync", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UnstarEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_unstar_entry_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_UnstarEntry_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UnstarEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_unstar_entry_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_UnstarEntry_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_update_entry_group_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_UpdateEntryGroup_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_update_entry_group_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_UpdateEntryGroup_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_update_entry_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_UpdateEntry_async", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_update_entry_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_UpdateEntry_sync", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_field_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTagTemplateField_async", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_field_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTagTemplateField_sync", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTagTemplate_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_update_tag_template_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTagTemplate_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_update_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTag_async", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_data_catalog_update_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_DataCatalog_UpdateTag_sync", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManagerSerialization" + }, + "shortName": "ExportTaxonomies" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_export_taxonomies_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ExportTaxonomies_async", + "segments": [ + { + "end": 46, + "start": 27, + "type": "FULL" + }, + { + "end": 46, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 40, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 43, + "start": 41, + "type": "REQUEST_EXECUTION" + }, + { + "end": 47, + "start": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManagerSerialization" + }, + "shortName": "ExportTaxonomies" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_export_taxonomies_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ExportTaxonomies_sync", + "segments": [ + { + "end": 46, + "start": 27, + "type": "FULL" + }, + { + "end": 46, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 40, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 43, + "start": 41, + "type": "REQUEST_EXECUTION" + }, + { + "end": 47, + "start": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManagerSerialization" + }, + "shortName": "ImportTaxonomies" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_import_taxonomies_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ImportTaxonomies_async", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManagerSerialization" + }, + "shortName": "ImportTaxonomies" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_import_taxonomies_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ImportTaxonomies_sync", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManagerSerialization" + }, + "shortName": "ReplaceTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_replace_taxonomy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ReplaceTaxonomy_async", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManagerSerialization" + }, + "shortName": "ReplaceTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_serialization_replace_taxonomy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManagerSerialization_ReplaceTaxonomy_sync", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "CreatePolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_create_policy_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_CreatePolicyTag_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "CreatePolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_create_policy_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_CreatePolicyTag_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "CreateTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_create_taxonomy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_CreateTaxonomy_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "CreateTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_create_taxonomy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_CreateTaxonomy_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "DeletePolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_policy_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_DeletePolicyTag_async", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "DeletePolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_policy_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_DeletePolicyTag_sync", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "DeleteTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_taxonomy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_DeleteTaxonomy_async", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "DeleteTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_delete_taxonomy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_DeleteTaxonomy_sync", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "GetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_get_iam_policy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_GetIamPolicy_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "GetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_get_iam_policy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_GetIamPolicy_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "GetPolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_get_policy_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_GetPolicyTag_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "GetPolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_get_policy_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_GetPolicyTag_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "GetTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_get_taxonomy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_GetTaxonomy_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "GetTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_get_taxonomy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_GetTaxonomy_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "ListPolicyTags" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_list_policy_tags_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_ListPolicyTags_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "ListPolicyTags" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_list_policy_tags_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_ListPolicyTags_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "ListTaxonomies" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_list_taxonomies_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_ListTaxonomies_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "ListTaxonomies" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_list_taxonomies_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_ListTaxonomies_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "SetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_set_iam_policy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_SetIamPolicy_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "SetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_set_iam_policy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_SetIamPolicy_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "TestIamPermissions" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_test_iam_permissions_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_TestIamPermissions_async", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "TestIamPermissions" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_test_iam_permissions_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_TestIamPermissions_sync", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "UpdatePolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_update_policy_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_UpdatePolicyTag_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "UpdatePolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_update_policy_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_UpdatePolicyTag_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "UpdateTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_update_taxonomy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_UpdateTaxonomy_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "UpdateTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1_policy_tag_manager_update_taxonomy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1_PolicyTagManager_UpdateTaxonomy_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + } + ] +} diff --git a/samples/generated_samples/snippet_metadata_datacatalog_v1beta1.json b/samples/generated_samples/snippet_metadata_datacatalog_v1beta1.json new file mode 100644 index 00000000..6d3d4e54 --- /dev/null +++ b/samples/generated_samples/snippet_metadata_datacatalog_v1beta1.json @@ -0,0 +1,3690 @@ +{ + "snippets": [ + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_group_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateEntryGroup_async", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_group_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateEntryGroup_sync", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateEntry_async", + "segments": [ + { + "end": 51, + "start": 27, + "type": "FULL" + }, + { + "end": 51, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 45, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 48, + "start": 46, + "type": "REQUEST_EXECUTION" + }, + { + "end": 52, + "start": 49, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_create_entry_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateEntry_sync", + "segments": [ + { + "end": 51, + "start": 27, + "type": "FULL" + }, + { + "end": 51, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 45, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 48, + "start": 46, + "type": "REQUEST_EXECUTION" + }, + { + "end": 52, + "start": 49, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_field_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTagTemplateField_async", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_field_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTagTemplateField_sync", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTagTemplate_async", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_template_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTagTemplate_sync", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTag_async", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "CreateTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_create_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_CreateTag_sync", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_group_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteEntryGroup_async", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_group_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteEntryGroup_sync", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteEntry_async", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_entry_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteEntry_sync", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_field_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTagTemplateField_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_field_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTagTemplateField_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTagTemplate_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_template_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTagTemplate_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTag_async", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "DeleteTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_delete_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_DeleteTag_sync", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_group_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetEntryGroup_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_group_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetEntryGroup_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetEntry_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_get_entry_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetEntry_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_get_iam_policy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetIamPolicy_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_get_iam_policy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetIamPolicy_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_get_tag_template_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetTagTemplate_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "GetTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_get_tag_template_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_GetTagTemplate_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ListEntries" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entries_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListEntries_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ListEntries" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entries_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListEntries_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ListEntryGroups" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entry_groups_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListEntryGroups_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ListEntryGroups" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_list_entry_groups_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListEntryGroups_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ListTags" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_list_tags_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListTags_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "ListTags" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_list_tags_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_ListTags_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "LookupEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_lookup_entry_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_LookupEntry_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "LookupEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_lookup_entry_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_LookupEntry_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "RenameTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_rename_tag_template_field_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_RenameTagTemplateField_async", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "RenameTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_rename_tag_template_field_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_RenameTagTemplateField_sync", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "SearchCatalog" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_search_catalog_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_SearchCatalog_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "SearchCatalog" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_search_catalog_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_SearchCatalog_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "SetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_set_iam_policy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_SetIamPolicy_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "SetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_set_iam_policy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_SetIamPolicy_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "TestIamPermissions" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_test_iam_permissions_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_TestIamPermissions_async", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "TestIamPermissions" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_test_iam_permissions_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_TestIamPermissions_sync", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_group_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateEntryGroup_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateEntryGroup" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_group_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateEntryGroup_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateEntry_async", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateEntry" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_update_entry_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateEntry_sync", + "segments": [ + { + "end": 49, + "start": 27, + "type": "FULL" + }, + { + "end": 49, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 43, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 46, + "start": 44, + "type": "REQUEST_EXECUTION" + }, + { + "end": 50, + "start": 47, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_field_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTagTemplateField_async", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateTagTemplateField" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_field_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTagTemplateField_sync", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTagTemplate_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateTagTemplate" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_template_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTagTemplate_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTag_async", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "DataCatalog" + }, + "shortName": "UpdateTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_data_catalog_update_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_DataCatalog_UpdateTag_sync", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManagerSerialization" + }, + "shortName": "ExportTaxonomies" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_export_taxonomies_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManagerSerialization_ExportTaxonomies_async", + "segments": [ + { + "end": 46, + "start": 27, + "type": "FULL" + }, + { + "end": 46, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 40, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 43, + "start": 41, + "type": "REQUEST_EXECUTION" + }, + { + "end": 47, + "start": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManagerSerialization" + }, + "shortName": "ExportTaxonomies" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_export_taxonomies_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManagerSerialization_ExportTaxonomies_sync", + "segments": [ + { + "end": 46, + "start": 27, + "type": "FULL" + }, + { + "end": 46, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 40, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 43, + "start": 41, + "type": "REQUEST_EXECUTION" + }, + { + "end": 47, + "start": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManagerSerialization" + }, + "shortName": "ImportTaxonomies" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_import_taxonomies_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManagerSerialization_ImportTaxonomies_async", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManagerSerialization" + }, + "shortName": "ImportTaxonomies" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_serialization_import_taxonomies_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManagerSerialization_ImportTaxonomies_sync", + "segments": [ + { + "end": 48, + "start": 27, + "type": "FULL" + }, + { + "end": 48, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 42, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 45, + "start": 43, + "type": "REQUEST_EXECUTION" + }, + { + "end": 49, + "start": 46, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "CreatePolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_policy_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_CreatePolicyTag_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "CreatePolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_policy_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_CreatePolicyTag_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "CreateTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_taxonomy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_CreateTaxonomy_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "CreateTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_create_taxonomy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_CreateTaxonomy_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "DeletePolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_policy_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_DeletePolicyTag_async", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "DeletePolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_policy_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_DeletePolicyTag_sync", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "DeleteTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_taxonomy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_DeleteTaxonomy_async", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "DeleteTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_delete_taxonomy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_DeleteTaxonomy_sync", + "segments": [ + { + "end": 42, + "start": 27, + "type": "FULL" + }, + { + "end": 42, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "GetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_iam_policy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetIamPolicy_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "GetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_iam_policy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetIamPolicy_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "GetPolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_policy_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetPolicyTag_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "GetPolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_policy_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetPolicyTag_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "GetTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_taxonomy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetTaxonomy_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "GetTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_get_taxonomy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_GetTaxonomy_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "ListPolicyTags" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_policy_tags_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_ListPolicyTags_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "ListPolicyTags" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_policy_tags_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_ListPolicyTags_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "ListTaxonomies" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_taxonomies_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_ListTaxonomies_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "ListTaxonomies" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_list_taxonomies_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_ListTaxonomies_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "SetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_set_iam_policy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_SetIamPolicy_async", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "SetIamPolicy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_set_iam_policy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_SetIamPolicy_sync", + "segments": [ + { + "end": 44, + "start": 27, + "type": "FULL" + }, + { + "end": 44, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 38, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 41, + "start": 39, + "type": "REQUEST_EXECUTION" + }, + { + "end": 45, + "start": 42, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "TestIamPermissions" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_test_iam_permissions_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_TestIamPermissions_async", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "TestIamPermissions" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_test_iam_permissions_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_TestIamPermissions_sync", + "segments": [ + { + "end": 45, + "start": 27, + "type": "FULL" + }, + { + "end": 45, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 39, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 42, + "start": 40, + "type": "REQUEST_EXECUTION" + }, + { + "end": 46, + "start": 43, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "UpdatePolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_policy_tag_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_UpdatePolicyTag_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "UpdatePolicyTag" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_policy_tag_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_UpdatePolicyTag_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "async": true, + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "UpdateTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_taxonomy_async.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_UpdateTaxonomy_async", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + }, + { + "clientMethod": { + "method": { + "service": { + "shortName": "PolicyTagManager" + }, + "shortName": "UpdateTaxonomy" + } + }, + "file": "datacatalog_generated_datacatalog_v1beta1_policy_tag_manager_update_taxonomy_sync.py", + "regionTag": "datacatalog_generated_datacatalog_v1beta1_PolicyTagManager_UpdateTaxonomy_sync", + "segments": [ + { + "end": 43, + "start": 27, + "type": "FULL" + }, + { + "end": 43, + "start": 27, + "type": "SHORT" + }, + { + "end": 33, + "start": 31, + "type": "CLIENT_INITIALIZATION" + }, + { + "end": 37, + "start": 34, + "type": "REQUEST_INITIALIZATION" + }, + { + "end": 40, + "start": 38, + "type": "REQUEST_EXECUTION" + }, + { + "end": 44, + "start": 41, + "type": "RESPONSE_HANDLING" + } + ] + } + ] +} diff --git a/scripts/fixup_datacatalog_v1_keywords.py b/scripts/fixup_datacatalog_v1_keywords.py index 33d41aed..30d95859 100644 --- a/scripts/fixup_datacatalog_v1_keywords.py +++ b/scripts/fixup_datacatalog_v1_keywords.py @@ -67,12 +67,16 @@ class datacatalogCallTransformer(cst.CSTTransformer): 'list_tags': ('parent', 'page_size', 'page_token', ), 'list_taxonomies': ('parent', 'page_size', 'page_token', ), 'lookup_entry': ('linked_resource', 'sql_resource', 'fully_qualified_name', ), + 'modify_entry_contacts': ('name', 'contacts', ), + 'modify_entry_overview': ('name', 'entry_overview', ), 'rename_tag_template_field': ('name', 'new_tag_template_field_id', ), 'rename_tag_template_field_enum_value': ('name', 'new_enum_value_display_name', ), 'replace_taxonomy': ('name', 'serialized_taxonomy', ), 'search_catalog': ('scope', 'query', 'page_size', 'page_token', 'order_by', ), 'set_iam_policy': ('resource', 'policy', ), + 'star_entry': ('name', ), 'test_iam_permissions': ('resource', 'permissions', ), + 'unstar_entry': ('name', ), 'update_entry': ('entry', 'update_mask', ), 'update_entry_group': ('entry_group', 'update_mask', ), 'update_policy_tag': ('policy_tag', 'update_mask', ), diff --git a/tests/unit/gapic/datacatalog_v1/test_data_catalog.py b/tests/unit/gapic/datacatalog_v1/test_data_catalog.py index 997f2909..468db5df 100644 --- a/tests/unit/gapic/datacatalog_v1/test_data_catalog.py +++ b/tests/unit/gapic/datacatalog_v1/test_data_catalog.py @@ -3550,6 +3550,282 @@ async def test_list_entries_async_pages(): assert page_.raw_page.next_page_token == token +@pytest.mark.parametrize( + "request_type", [datacatalog.ModifyEntryOverviewRequest, dict,] +) +def test_modify_entry_overview(request_type, transport: str = "grpc"): + client = DataCatalogClient( + credentials=ga_credentials.AnonymousCredentials(), transport=transport, + ) + + # Everything is optional in proto3 as far as the runtime is concerned, + # and we are mocking out the actual API, so just send an empty request. + request = request_type() + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object( + type(client.transport.modify_entry_overview), "__call__" + ) as call: + # Designate an appropriate return value for the call. + call.return_value = datacatalog.EntryOverview(overview="overview_value",) + response = client.modify_entry_overview(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) == 1 + _, args, _ = call.mock_calls[0] + assert args[0] == datacatalog.ModifyEntryOverviewRequest() + + # Establish that the response is the type that we expect. + assert isinstance(response, datacatalog.EntryOverview) + assert response.overview == "overview_value" + + +def test_modify_entry_overview_empty_call(): + # This test is a coverage failsafe to make sure that totally empty calls, + # i.e. request == None and no flattened fields passed, work. + client = DataCatalogClient( + credentials=ga_credentials.AnonymousCredentials(), transport="grpc", + ) + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object( + type(client.transport.modify_entry_overview), "__call__" + ) as call: + client.modify_entry_overview() + call.assert_called() + _, args, _ = call.mock_calls[0] + assert args[0] == datacatalog.ModifyEntryOverviewRequest() + + +@pytest.mark.asyncio +async def test_modify_entry_overview_async( + transport: str = "grpc_asyncio", request_type=datacatalog.ModifyEntryOverviewRequest +): + client = DataCatalogAsyncClient( + credentials=ga_credentials.AnonymousCredentials(), transport=transport, + ) + + # Everything is optional in proto3 as far as the runtime is concerned, + # and we are mocking out the actual API, so just send an empty request. + request = request_type() + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object( + type(client.transport.modify_entry_overview), "__call__" + ) as call: + # Designate an appropriate return value for the call. + call.return_value = grpc_helpers_async.FakeUnaryUnaryCall( + datacatalog.EntryOverview(overview="overview_value",) + ) + response = await client.modify_entry_overview(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) + _, args, _ = call.mock_calls[0] + assert args[0] == datacatalog.ModifyEntryOverviewRequest() + + # Establish that the response is the type that we expect. + assert isinstance(response, datacatalog.EntryOverview) + assert response.overview == "overview_value" + + +@pytest.mark.asyncio +async def test_modify_entry_overview_async_from_dict(): + await test_modify_entry_overview_async(request_type=dict) + + +def test_modify_entry_overview_field_headers(): + client = DataCatalogClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Any value that is part of the HTTP/1.1 URI should be sent as + # a field header. Set these to a non-empty value. + request = datacatalog.ModifyEntryOverviewRequest() + + request.name = "name/value" + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object( + type(client.transport.modify_entry_overview), "__call__" + ) as call: + call.return_value = datacatalog.EntryOverview() + client.modify_entry_overview(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) == 1 + _, args, _ = call.mock_calls[0] + assert args[0] == request + + # Establish that the field header was sent. + _, _, kw = call.mock_calls[0] + assert ("x-goog-request-params", "name=name/value",) in kw["metadata"] + + +@pytest.mark.asyncio +async def test_modify_entry_overview_field_headers_async(): + client = DataCatalogAsyncClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Any value that is part of the HTTP/1.1 URI should be sent as + # a field header. Set these to a non-empty value. + request = datacatalog.ModifyEntryOverviewRequest() + + request.name = "name/value" + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object( + type(client.transport.modify_entry_overview), "__call__" + ) as call: + call.return_value = grpc_helpers_async.FakeUnaryUnaryCall( + datacatalog.EntryOverview() + ) + await client.modify_entry_overview(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) + _, args, _ = call.mock_calls[0] + assert args[0] == request + + # Establish that the field header was sent. + _, _, kw = call.mock_calls[0] + assert ("x-goog-request-params", "name=name/value",) in kw["metadata"] + + +@pytest.mark.parametrize( + "request_type", [datacatalog.ModifyEntryContactsRequest, dict,] +) +def test_modify_entry_contacts(request_type, transport: str = "grpc"): + client = DataCatalogClient( + credentials=ga_credentials.AnonymousCredentials(), transport=transport, + ) + + # Everything is optional in proto3 as far as the runtime is concerned, + # and we are mocking out the actual API, so just send an empty request. + request = request_type() + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object( + type(client.transport.modify_entry_contacts), "__call__" + ) as call: + # Designate an appropriate return value for the call. + call.return_value = datacatalog.Contacts() + response = client.modify_entry_contacts(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) == 1 + _, args, _ = call.mock_calls[0] + assert args[0] == datacatalog.ModifyEntryContactsRequest() + + # Establish that the response is the type that we expect. + assert isinstance(response, datacatalog.Contacts) + + +def test_modify_entry_contacts_empty_call(): + # This test is a coverage failsafe to make sure that totally empty calls, + # i.e. request == None and no flattened fields passed, work. + client = DataCatalogClient( + credentials=ga_credentials.AnonymousCredentials(), transport="grpc", + ) + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object( + type(client.transport.modify_entry_contacts), "__call__" + ) as call: + client.modify_entry_contacts() + call.assert_called() + _, args, _ = call.mock_calls[0] + assert args[0] == datacatalog.ModifyEntryContactsRequest() + + +@pytest.mark.asyncio +async def test_modify_entry_contacts_async( + transport: str = "grpc_asyncio", request_type=datacatalog.ModifyEntryContactsRequest +): + client = DataCatalogAsyncClient( + credentials=ga_credentials.AnonymousCredentials(), transport=transport, + ) + + # Everything is optional in proto3 as far as the runtime is concerned, + # and we are mocking out the actual API, so just send an empty request. + request = request_type() + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object( + type(client.transport.modify_entry_contacts), "__call__" + ) as call: + # Designate an appropriate return value for the call. + call.return_value = grpc_helpers_async.FakeUnaryUnaryCall( + datacatalog.Contacts() + ) + response = await client.modify_entry_contacts(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) + _, args, _ = call.mock_calls[0] + assert args[0] == datacatalog.ModifyEntryContactsRequest() + + # Establish that the response is the type that we expect. + assert isinstance(response, datacatalog.Contacts) + + +@pytest.mark.asyncio +async def test_modify_entry_contacts_async_from_dict(): + await test_modify_entry_contacts_async(request_type=dict) + + +def test_modify_entry_contacts_field_headers(): + client = DataCatalogClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Any value that is part of the HTTP/1.1 URI should be sent as + # a field header. Set these to a non-empty value. + request = datacatalog.ModifyEntryContactsRequest() + + request.name = "name/value" + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object( + type(client.transport.modify_entry_contacts), "__call__" + ) as call: + call.return_value = datacatalog.Contacts() + client.modify_entry_contacts(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) == 1 + _, args, _ = call.mock_calls[0] + assert args[0] == request + + # Establish that the field header was sent. + _, _, kw = call.mock_calls[0] + assert ("x-goog-request-params", "name=name/value",) in kw["metadata"] + + +@pytest.mark.asyncio +async def test_modify_entry_contacts_field_headers_async(): + client = DataCatalogAsyncClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Any value that is part of the HTTP/1.1 URI should be sent as + # a field header. Set these to a non-empty value. + request = datacatalog.ModifyEntryContactsRequest() + + request.name = "name/value" + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object( + type(client.transport.modify_entry_contacts), "__call__" + ) as call: + call.return_value = grpc_helpers_async.FakeUnaryUnaryCall( + datacatalog.Contacts() + ) + await client.modify_entry_contacts(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) + _, args, _ = call.mock_calls[0] + assert args[0] == request + + # Establish that the field header was sent. + _, _, kw = call.mock_calls[0] + assert ("x-goog-request-params", "name=name/value",) in kw["metadata"] + + @pytest.mark.parametrize("request_type", [datacatalog.CreateTagTemplateRequest, dict,]) def test_create_tag_template(request_type, transport: str = "grpc"): client = DataCatalogClient( @@ -6598,6 +6874,392 @@ async def test_list_tags_async_pages(): assert page_.raw_page.next_page_token == token +@pytest.mark.parametrize("request_type", [datacatalog.StarEntryRequest, dict,]) +def test_star_entry(request_type, transport: str = "grpc"): + client = DataCatalogClient( + credentials=ga_credentials.AnonymousCredentials(), transport=transport, + ) + + # Everything is optional in proto3 as far as the runtime is concerned, + # and we are mocking out the actual API, so just send an empty request. + request = request_type() + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.star_entry), "__call__") as call: + # Designate an appropriate return value for the call. + call.return_value = datacatalog.StarEntryResponse() + response = client.star_entry(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) == 1 + _, args, _ = call.mock_calls[0] + assert args[0] == datacatalog.StarEntryRequest() + + # Establish that the response is the type that we expect. + assert isinstance(response, datacatalog.StarEntryResponse) + + +def test_star_entry_empty_call(): + # This test is a coverage failsafe to make sure that totally empty calls, + # i.e. request == None and no flattened fields passed, work. + client = DataCatalogClient( + credentials=ga_credentials.AnonymousCredentials(), transport="grpc", + ) + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.star_entry), "__call__") as call: + client.star_entry() + call.assert_called() + _, args, _ = call.mock_calls[0] + assert args[0] == datacatalog.StarEntryRequest() + + +@pytest.mark.asyncio +async def test_star_entry_async( + transport: str = "grpc_asyncio", request_type=datacatalog.StarEntryRequest +): + client = DataCatalogAsyncClient( + credentials=ga_credentials.AnonymousCredentials(), transport=transport, + ) + + # Everything is optional in proto3 as far as the runtime is concerned, + # and we are mocking out the actual API, so just send an empty request. + request = request_type() + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.star_entry), "__call__") as call: + # Designate an appropriate return value for the call. + call.return_value = grpc_helpers_async.FakeUnaryUnaryCall( + datacatalog.StarEntryResponse() + ) + response = await client.star_entry(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) + _, args, _ = call.mock_calls[0] + assert args[0] == datacatalog.StarEntryRequest() + + # Establish that the response is the type that we expect. + assert isinstance(response, datacatalog.StarEntryResponse) + + +@pytest.mark.asyncio +async def test_star_entry_async_from_dict(): + await test_star_entry_async(request_type=dict) + + +def test_star_entry_field_headers(): + client = DataCatalogClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Any value that is part of the HTTP/1.1 URI should be sent as + # a field header. Set these to a non-empty value. + request = datacatalog.StarEntryRequest() + + request.name = "name/value" + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.star_entry), "__call__") as call: + call.return_value = datacatalog.StarEntryResponse() + client.star_entry(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) == 1 + _, args, _ = call.mock_calls[0] + assert args[0] == request + + # Establish that the field header was sent. + _, _, kw = call.mock_calls[0] + assert ("x-goog-request-params", "name=name/value",) in kw["metadata"] + + +@pytest.mark.asyncio +async def test_star_entry_field_headers_async(): + client = DataCatalogAsyncClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Any value that is part of the HTTP/1.1 URI should be sent as + # a field header. Set these to a non-empty value. + request = datacatalog.StarEntryRequest() + + request.name = "name/value" + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.star_entry), "__call__") as call: + call.return_value = grpc_helpers_async.FakeUnaryUnaryCall( + datacatalog.StarEntryResponse() + ) + await client.star_entry(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) + _, args, _ = call.mock_calls[0] + assert args[0] == request + + # Establish that the field header was sent. + _, _, kw = call.mock_calls[0] + assert ("x-goog-request-params", "name=name/value",) in kw["metadata"] + + +def test_star_entry_flattened(): + client = DataCatalogClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.star_entry), "__call__") as call: + # Designate an appropriate return value for the call. + call.return_value = datacatalog.StarEntryResponse() + # Call the method with a truthy value for each flattened field, + # using the keyword arguments to the method. + client.star_entry(name="name_value",) + + # Establish that the underlying call was made with the expected + # request object values. + assert len(call.mock_calls) == 1 + _, args, _ = call.mock_calls[0] + arg = args[0].name + mock_val = "name_value" + assert arg == mock_val + + +def test_star_entry_flattened_error(): + client = DataCatalogClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Attempting to call a method with both a request object and flattened + # fields is an error. + with pytest.raises(ValueError): + client.star_entry( + datacatalog.StarEntryRequest(), name="name_value", + ) + + +@pytest.mark.asyncio +async def test_star_entry_flattened_async(): + client = DataCatalogAsyncClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.star_entry), "__call__") as call: + # Designate an appropriate return value for the call. + call.return_value = datacatalog.StarEntryResponse() + + call.return_value = grpc_helpers_async.FakeUnaryUnaryCall( + datacatalog.StarEntryResponse() + ) + # Call the method with a truthy value for each flattened field, + # using the keyword arguments to the method. + response = await client.star_entry(name="name_value",) + + # Establish that the underlying call was made with the expected + # request object values. + assert len(call.mock_calls) + _, args, _ = call.mock_calls[0] + arg = args[0].name + mock_val = "name_value" + assert arg == mock_val + + +@pytest.mark.asyncio +async def test_star_entry_flattened_error_async(): + client = DataCatalogAsyncClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Attempting to call a method with both a request object and flattened + # fields is an error. + with pytest.raises(ValueError): + await client.star_entry( + datacatalog.StarEntryRequest(), name="name_value", + ) + + +@pytest.mark.parametrize("request_type", [datacatalog.UnstarEntryRequest, dict,]) +def test_unstar_entry(request_type, transport: str = "grpc"): + client = DataCatalogClient( + credentials=ga_credentials.AnonymousCredentials(), transport=transport, + ) + + # Everything is optional in proto3 as far as the runtime is concerned, + # and we are mocking out the actual API, so just send an empty request. + request = request_type() + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.unstar_entry), "__call__") as call: + # Designate an appropriate return value for the call. + call.return_value = datacatalog.UnstarEntryResponse() + response = client.unstar_entry(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) == 1 + _, args, _ = call.mock_calls[0] + assert args[0] == datacatalog.UnstarEntryRequest() + + # Establish that the response is the type that we expect. + assert isinstance(response, datacatalog.UnstarEntryResponse) + + +def test_unstar_entry_empty_call(): + # This test is a coverage failsafe to make sure that totally empty calls, + # i.e. request == None and no flattened fields passed, work. + client = DataCatalogClient( + credentials=ga_credentials.AnonymousCredentials(), transport="grpc", + ) + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.unstar_entry), "__call__") as call: + client.unstar_entry() + call.assert_called() + _, args, _ = call.mock_calls[0] + assert args[0] == datacatalog.UnstarEntryRequest() + + +@pytest.mark.asyncio +async def test_unstar_entry_async( + transport: str = "grpc_asyncio", request_type=datacatalog.UnstarEntryRequest +): + client = DataCatalogAsyncClient( + credentials=ga_credentials.AnonymousCredentials(), transport=transport, + ) + + # Everything is optional in proto3 as far as the runtime is concerned, + # and we are mocking out the actual API, so just send an empty request. + request = request_type() + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.unstar_entry), "__call__") as call: + # Designate an appropriate return value for the call. + call.return_value = grpc_helpers_async.FakeUnaryUnaryCall( + datacatalog.UnstarEntryResponse() + ) + response = await client.unstar_entry(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) + _, args, _ = call.mock_calls[0] + assert args[0] == datacatalog.UnstarEntryRequest() + + # Establish that the response is the type that we expect. + assert isinstance(response, datacatalog.UnstarEntryResponse) + + +@pytest.mark.asyncio +async def test_unstar_entry_async_from_dict(): + await test_unstar_entry_async(request_type=dict) + + +def test_unstar_entry_field_headers(): + client = DataCatalogClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Any value that is part of the HTTP/1.1 URI should be sent as + # a field header. Set these to a non-empty value. + request = datacatalog.UnstarEntryRequest() + + request.name = "name/value" + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.unstar_entry), "__call__") as call: + call.return_value = datacatalog.UnstarEntryResponse() + client.unstar_entry(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) == 1 + _, args, _ = call.mock_calls[0] + assert args[0] == request + + # Establish that the field header was sent. + _, _, kw = call.mock_calls[0] + assert ("x-goog-request-params", "name=name/value",) in kw["metadata"] + + +@pytest.mark.asyncio +async def test_unstar_entry_field_headers_async(): + client = DataCatalogAsyncClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Any value that is part of the HTTP/1.1 URI should be sent as + # a field header. Set these to a non-empty value. + request = datacatalog.UnstarEntryRequest() + + request.name = "name/value" + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.unstar_entry), "__call__") as call: + call.return_value = grpc_helpers_async.FakeUnaryUnaryCall( + datacatalog.UnstarEntryResponse() + ) + await client.unstar_entry(request) + + # Establish that the underlying gRPC stub method was called. + assert len(call.mock_calls) + _, args, _ = call.mock_calls[0] + assert args[0] == request + + # Establish that the field header was sent. + _, _, kw = call.mock_calls[0] + assert ("x-goog-request-params", "name=name/value",) in kw["metadata"] + + +def test_unstar_entry_flattened(): + client = DataCatalogClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.unstar_entry), "__call__") as call: + # Designate an appropriate return value for the call. + call.return_value = datacatalog.UnstarEntryResponse() + # Call the method with a truthy value for each flattened field, + # using the keyword arguments to the method. + client.unstar_entry(name="name_value",) + + # Establish that the underlying call was made with the expected + # request object values. + assert len(call.mock_calls) == 1 + _, args, _ = call.mock_calls[0] + arg = args[0].name + mock_val = "name_value" + assert arg == mock_val + + +def test_unstar_entry_flattened_error(): + client = DataCatalogClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Attempting to call a method with both a request object and flattened + # fields is an error. + with pytest.raises(ValueError): + client.unstar_entry( + datacatalog.UnstarEntryRequest(), name="name_value", + ) + + +@pytest.mark.asyncio +async def test_unstar_entry_flattened_async(): + client = DataCatalogAsyncClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Mock the actual call within the gRPC stub, and fake the request. + with mock.patch.object(type(client.transport.unstar_entry), "__call__") as call: + # Designate an appropriate return value for the call. + call.return_value = datacatalog.UnstarEntryResponse() + + call.return_value = grpc_helpers_async.FakeUnaryUnaryCall( + datacatalog.UnstarEntryResponse() + ) + # Call the method with a truthy value for each flattened field, + # using the keyword arguments to the method. + response = await client.unstar_entry(name="name_value",) + + # Establish that the underlying call was made with the expected + # request object values. + assert len(call.mock_calls) + _, args, _ = call.mock_calls[0] + arg = args[0].name + mock_val = "name_value" + assert arg == mock_val + + +@pytest.mark.asyncio +async def test_unstar_entry_flattened_error_async(): + client = DataCatalogAsyncClient(credentials=ga_credentials.AnonymousCredentials(),) + + # Attempting to call a method with both a request object and flattened + # fields is an error. + with pytest.raises(ValueError): + await client.unstar_entry( + datacatalog.UnstarEntryRequest(), name="name_value", + ) + + @pytest.mark.parametrize("request_type", [iam_policy_pb2.SetIamPolicyRequest, dict,]) def test_set_iam_policy(request_type, transport: str = "grpc"): client = DataCatalogClient( @@ -7298,6 +7960,8 @@ def test_data_catalog_base_transport(): "get_entry", "lookup_entry", "list_entries", + "modify_entry_overview", + "modify_entry_contacts", "create_tag_template", "get_tag_template", "update_tag_template", @@ -7311,6 +7975,8 @@ def test_data_catalog_base_transport(): "update_tag", "delete_tag", "list_tags", + "star_entry", + "unstar_entry", "set_iam_policy", "get_iam_policy", "test_iam_permissions",